@@ -477,6 +477,7 @@ static inline int is_hibernate_resume_dev(dev_t dev) { return 0; }
#define PM_POST_SUSPEND 0x0004 /* Suspend finished */
#define PM_RESTORE_PREPARE 0x0005 /* Going to restore a saved image */
#define PM_POST_RESTORE 0x0006 /* Restore failed */
+#define PM_SUSPEND_LATE 0x0007 /* Late suspend phase */
extern struct mutex system_transition_mutex;
@@ -415,6 +415,8 @@ static int suspend_enter(suspend_state_t state, bool *wakeup)
if (suspend_test(TEST_PLATFORM))
goto Platform_wake;
+ pm_notifier_call_chain(PM_SUSPEND_LATE);
+
if (state == PM_SUSPEND_TO_IDLE) {
s2idle_loop();
goto Platform_wake;