Message ID | 1663294501-6377-1-git-send-email-u0084500@gmail.com |
---|---|
State | New |
Headers | show |
Series | [RFC] PM: core: Add pm_wakeup_pending check in device suspend_noirq | expand |
diff --git a/drivers/base/power/main.c b/drivers/base/power/main.c index c501392..7cd7dc5 100644 --- a/drivers/base/power/main.c +++ b/drivers/base/power/main.c @@ -1210,6 +1210,11 @@ static int __device_suspend_noirq(struct device *dev, pm_message_t state, bool a if (async_error) goto Complete; + if (pm_wakeup_pending()) { + async_error = -EBUSY; + goto Complete; + } + if (dev->power.syscore || dev->power.direct_complete) goto Complete;