power: delay early_suspend for 1s
Xin Xie [Sun, 21 Aug 2011 03:31:34 +0000 (20:31 -0700)]
bug 857053

Original-Change-Id: I9ae35026009d2a73e253386661902004d99a25c9
Reviewed-on: http://git-master/r/48349
Reviewed-by: Xin Xie <xxie@nvidia.com>
Tested-by: Xin Xie <xxie@nvidia.com>
Reviewed-by: Daniel Solomon <daniels@nvidia.com>
Tested-by: Daniel Solomon <daniels@nvidia.com>
Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com>

Rebase-Id: Rc7feea74d63f9e4a34694e98e3d6e7a92add3421

kernel/power/earlysuspend.c

index b15f02e..9baa87d 100644 (file)
@@ -20,6 +20,7 @@
 #include <linux/syscalls.h> /* sys_sync */
 #include <linux/wakelock.h>
 #include <linux/workqueue.h>
+#include <linux/delay.h>
 
 #include "power.h"
 
@@ -94,6 +95,7 @@ static void early_suspend(struct work_struct *work)
 
        if (debug_mask & DEBUG_SUSPEND)
                pr_info("early_suspend: call handlers\n");
+       msleep(1000);
        list_for_each_entry(pos, &early_suspend_handlers, link) {
                if (pos->suspend != NULL) {
                        if (debug_mask & DEBUG_VERBOSE)