Skip to content

Commit

Permalink
Revert "PM / Domains: Handle safely genpd_syscore_switch() call on no…
Browse files Browse the repository at this point in the history
…n-genpd device"

Revert commit 8b55e55 (PM / Domains: Handle safely
genpd_syscore_switch() call on non-genpd device) which was misguided
(the change made by it was not necessary) and it introduced a call to
a function that may sleep into an atomic context code path.

Reported-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Rafael J. Wysocki committed Jul 4, 2017
1 parent 268cd2e commit 23c6d2c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/base/power/domain.c
Original file line number Diff line number Diff line change
Expand Up @@ -1148,8 +1148,8 @@ static void genpd_syscore_switch(struct device *dev, bool suspend)
{
struct generic_pm_domain *genpd;

genpd = genpd_lookup_dev(dev);
if (!genpd)
genpd = dev_to_genpd(dev);
if (!pm_genpd_present(genpd))
return;

if (suspend) {
Expand Down

0 comments on commit 23c6d2c

Please sign in to comment.