From 972ee83df88a7fd84c228a31b4f9611299898984 Mon Sep 17 00:00:00 2001 From: Robin Holt Date: Mon, 8 Jul 2013 16:01:34 -0700 Subject: reboot: checkpatch.pl the new kernel/reboot.c file Get the new file to pass scripts/checkpatch.pl Signed-off-by: Robin Holt Cc: H. Peter Anvin Cc: Russ Anderson Cc: Robin Holt Cc: Russell King Cc: Guan Xuetao Cc: Ingo Molnar Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/reboot.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/linux/reboot.h') diff --git a/include/linux/reboot.h b/include/linux/reboot.h index 23b36304cd88..c6eba210e592 100644 --- a/include/linux/reboot.h +++ b/include/linux/reboot.h @@ -26,7 +26,7 @@ extern void machine_shutdown(void); struct pt_regs; extern void machine_crash_shutdown(struct pt_regs *); -/* +/* * Architecture independent implemenations of sys_reboot commands. */ -- cgit v1.2.3 From edf2b1394611fef7806d4af72179dc3ac101f275 Mon Sep 17 00:00:00 2001 From: Robin Holt Date: Mon, 8 Jul 2013 16:01:35 -0700 Subject: reboot: x86: prepare reboot_mode for moving to generic kernel code Prepare for the moving the parsing of reboot= to the generic kernel code by making reboot_mode into a more generic form. Signed-off-by: Robin Holt Cc: H. Peter Anvin Cc: Miguel Boton Cc: Russ Anderson Cc: Robin Holt Cc: Russell King Cc: Guan Xuetao Acked-by: Ingo Molnar Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/reboot.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include/linux/reboot.h') diff --git a/include/linux/reboot.h b/include/linux/reboot.h index c6eba210e592..37d56c356a06 100644 --- a/include/linux/reboot.h +++ b/include/linux/reboot.h @@ -10,6 +10,11 @@ #define SYS_HALT 0x0002 /* Notify of system halt */ #define SYS_POWER_OFF 0x0003 /* Notify of system power off */ +enum reboot_mode { + REBOOT_COLD = 0, + REBOOT_WARM, +}; + extern int register_reboot_notifier(struct notifier_block *); extern int unregister_reboot_notifier(struct notifier_block *); -- cgit v1.2.3 From c97a7008517abb7c805fbdd49410032a652def26 Mon Sep 17 00:00:00 2001 From: Robin Holt Date: Mon, 8 Jul 2013 16:01:36 -0700 Subject: reboot: unicore32: prepare reboot_mode for moving to generic kernel code Prepare for the moving the parsing of reboot= to the generic kernel code by making reboot_mode into a more generic form. Signed-off-by: Robin Holt Cc: Guan Xuetao Cc: Russ Anderson Cc: Robin Holt Cc: Russell King Cc: H. Peter Anvin Acked-by: Guan Xuetao Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/reboot.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/linux/reboot.h') diff --git a/include/linux/reboot.h b/include/linux/reboot.h index 37d56c356a06..ca29a6ffc08e 100644 --- a/include/linux/reboot.h +++ b/include/linux/reboot.h @@ -13,6 +13,8 @@ enum reboot_mode { REBOOT_COLD = 0, REBOOT_WARM, + REBOOT_HARD, + REBOOT_SOFT, }; extern int register_reboot_notifier(struct notifier_block *); -- cgit v1.2.3 From 7b6d864b48d95e6ea1df7df64475b9cb9616dcf9 Mon Sep 17 00:00:00 2001 From: Robin Holt Date: Mon, 8 Jul 2013 16:01:40 -0700 Subject: reboot: arm: change reboot_mode to use enum reboot_mode Preparing to move the parsing of reboot= to generic kernel code forces the change in reboot_mode handling to use the enum. [akpm@linux-foundation.org: fix arch/arm/mach-socfpga/socfpga.c] Signed-off-by: Robin Holt Cc: Russell King Cc: Russ Anderson Cc: Robin Holt Cc: H. Peter Anvin Cc: Guan Xuetao Acked-by: Russell King Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/reboot.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/linux/reboot.h') diff --git a/include/linux/reboot.h b/include/linux/reboot.h index ca29a6ffc08e..5a5d7f7e81b7 100644 --- a/include/linux/reboot.h +++ b/include/linux/reboot.h @@ -15,6 +15,7 @@ enum reboot_mode { REBOOT_WARM, REBOOT_HARD, REBOOT_SOFT, + REBOOT_GPIO, }; extern int register_reboot_notifier(struct notifier_block *); -- cgit v1.2.3 From 1b3a5d02ee070c8f9943333b9b6370f486601e0f Mon Sep 17 00:00:00 2001 From: Robin Holt Date: Mon, 8 Jul 2013 16:01:42 -0700 Subject: reboot: move arch/x86 reboot= handling to generic kernel Merge together the unicore32, arm, and x86 reboot= command line parameter handling. Signed-off-by: Robin Holt Cc: H. Peter Anvin Cc: Russell King Cc: Guan Xuetao Cc: Russ Anderson Cc: Robin Holt Acked-by: Ingo Molnar Acked-by: Guan Xuetao Acked-by: Russell King Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/reboot.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'include/linux/reboot.h') diff --git a/include/linux/reboot.h b/include/linux/reboot.h index 5a5d7f7e81b7..8e00f9f6f963 100644 --- a/include/linux/reboot.h +++ b/include/linux/reboot.h @@ -17,6 +17,23 @@ enum reboot_mode { REBOOT_SOFT, REBOOT_GPIO, }; +extern enum reboot_mode reboot_mode; + +enum reboot_type { + BOOT_TRIPLE = 't', + BOOT_KBD = 'k', + BOOT_BIOS = 'b', + BOOT_ACPI = 'a', + BOOT_EFI = 'e', + BOOT_CF9 = 'p', + BOOT_CF9_COND = 'q', +}; +extern enum reboot_type reboot_type; + +extern int reboot_default; +extern int reboot_cpu; +extern int reboot_force; + extern int register_reboot_notifier(struct notifier_block *); extern int unregister_reboot_notifier(struct notifier_block *); -- cgit v1.2.3