mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
[PATCH] Use kernel_power_off in sysrq-o
We already do all of the gymnastics to run from process context to call the power off code so call into the power off code cleanly. This especially helps acpi as part of it's shutdown logic should run acpi_shutdown called from device_shutdown which was not being called from here. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
62b3a04d75
commit
ff31977782
1 changed files with 2 additions and 2 deletions
|
@ -9,6 +9,7 @@
|
|||
#include <linux/init.h>
|
||||
#include <linux/pm.h>
|
||||
#include <linux/workqueue.h>
|
||||
#include <linux/reboot.h>
|
||||
|
||||
/*
|
||||
* When the user hits Sys-Rq o to power down the machine this is the
|
||||
|
@ -17,8 +18,7 @@
|
|||
|
||||
static void do_poweroff(void *dummy)
|
||||
{
|
||||
if (pm_power_off)
|
||||
pm_power_off();
|
||||
kernel_power_off();
|
||||
}
|
||||
|
||||
static DECLARE_WORK(poweroff_work, do_poweroff, NULL);
|
||||
|
|
Loading…
Reference in a new issue