Skip to content

Commit 0cebf7c

Browse files
committed
pmdomain: core: Don't clear suspended_count at genpd_prepare()
There is no longer any need to clear genpd->suspended_count in genpd_prepare(), as it should be correctly incremented and decremented for all cases. In fact, if the counter isn't correctly managed we would be hiding a problem that we shouldn't. Therefore, let's not clear it. Signed-off-by: Ulf Hansson <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 5af7f59 commit 0cebf7c

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

drivers/pmdomain/core.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1255,10 +1255,7 @@ static int genpd_prepare(struct device *dev)
12551255
return -EINVAL;
12561256

12571257
genpd_lock(genpd);
1258-
1259-
if (genpd->prepared_count++ == 0)
1260-
genpd->suspended_count = 0;
1261-
1258+
genpd->prepared_count++;
12621259
genpd_unlock(genpd);
12631260

12641261
ret = pm_generic_prepare(dev);

0 commit comments

Comments
 (0)