OSDN Git Service

drivers: power: Add watchdog timer to catch drivers which lockup during suspend.
authorBenoit Goby <benoit@android.com>
Thu, 13 Aug 2009 16:40:42 +0000 (09:40 -0700)
committerChih-Wei Huang <cwhuang@linux.org.tw>
Mon, 13 Apr 2015 16:42:52 +0000 (00:42 +0800)
commit9fa809bea43f1368a2eb465f9feed794a6f6e002
treef12ac4106a8d8a8a02679a2f739b7509b0eaee6c
parentb735d56263884a5e4acfaccc1feb5e5bf567ccb8
drivers: power: Add watchdog timer to catch drivers which lockup during suspend.

Rather than hard-lock the kernel, dump the suspend thread stack and
BUG() when a driver takes too long to suspend.  The timeout is set
to 12 seconds to be longer than the usbhid 10 second timeout.

Exclude from the watchdog the time spent waiting for children that
are resumed asynchronously and time every device, whether or not they
resumed synchronously.

Change-Id: Ifd211c06b104860c2fee6eecfe0d61774aa4508a
Original-author: San Mehat <san@google.com>
Signed-off-by: Benoit Goby <benoit@android.com>
drivers/base/power/main.c