diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2009-03-19 12:20:24 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-03-19 12:20:24 -0400 |
commit | be093beb608edf821b45fe00a8a080fb5c6ed4af (patch) | |
tree | 05751248a909761dab9ccb29fd08bf2c5683ef0d /arch | |
parent | 14b6848bc0134b8838d374c423df3edda9b1490e (diff) |
[ARM] pass reboot command line to arch_reset()
OMAP wishes to pass state to the boot loader upon reboot in order to
instruct it whether to wait for USB-based reflashing or not. There is
already a facility to do this via the reboot() syscall, except we ignore
the string passed to machine_restart().
This patch fixes things to pass this string to arch_reset(). This means
that we keep the reboot mode limited to telling the kernel _how_ to
perform the reboot which should be independent of what we request the
boot loader to do.
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch')
50 files changed, 65 insertions, 65 deletions
diff --git a/arch/arm/include/asm/system.h b/arch/arm/include/asm/system.h index 811be55f338e..0a0d49ae1e6d 100644 --- a/arch/arm/include/asm/system.h +++ b/arch/arm/include/asm/system.h | |||
@@ -97,8 +97,8 @@ extern void __show_regs(struct pt_regs *); | |||
97 | extern int cpu_architecture(void); | 97 | extern int cpu_architecture(void); |
98 | extern void cpu_init(void); | 98 | extern void cpu_init(void); |
99 | 99 | ||
100 | void arm_machine_restart(char mode); | 100 | void arm_machine_restart(char mode, const char *cmd); |
101 | extern void (*arm_pm_restart)(char str); | 101 | extern void (*arm_pm_restart)(char str, const char *cmd); |
102 | 102 | ||
103 | #define UDBG_UNDEFINED (1 << 0) | 103 | #define UDBG_UNDEFINED (1 << 0) |
104 | #define UDBG_SYSCALL (1 << 1) | 104 | #define UDBG_SYSCALL (1 << 1) |
diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c index af377c73d90b..2de14e2afdc5 100644 --- a/arch/arm/kernel/process.c +++ b/arch/arm/kernel/process.c | |||
@@ -83,7 +83,7 @@ static int __init hlt_setup(char *__unused) | |||
83 | __setup("nohlt", nohlt_setup); | 83 | __setup("nohlt", nohlt_setup); |
84 | __setup("hlt", hlt_setup); | 84 | __setup("hlt", hlt_setup); |
85 | 85 | ||
86 | void arm_machine_restart(char mode) | 86 | void arm_machine_restart(char mode, const char *cmd) |
87 | { | 87 | { |
88 | /* | 88 | /* |
89 | * Clean and disable cache, and turn off interrupts | 89 | * Clean and disable cache, and turn off interrupts |
@@ -100,7 +100,7 @@ void arm_machine_restart(char mode) | |||
100 | /* | 100 | /* |
101 | * Now call the architecture specific reboot code. | 101 | * Now call the architecture specific reboot code. |
102 | */ | 102 | */ |
103 | arch_reset(mode); | 103 | arch_reset(mode, cmd); |
104 | 104 | ||
105 | /* | 105 | /* |
106 | * Whoops - the architecture was unable to reboot. | 106 | * Whoops - the architecture was unable to reboot. |
@@ -120,7 +120,7 @@ EXPORT_SYMBOL(pm_idle); | |||
120 | void (*pm_power_off)(void); | 120 | void (*pm_power_off)(void); |
121 | EXPORT_SYMBOL(pm_power_off); | 121 | EXPORT_SYMBOL(pm_power_off); |
122 | 122 | ||
123 | void (*arm_pm_restart)(char str) = arm_machine_restart; | 123 | void (*arm_pm_restart)(char str, const char *cmd) = arm_machine_restart; |
124 | EXPORT_SYMBOL_GPL(arm_pm_restart); | 124 | EXPORT_SYMBOL_GPL(arm_pm_restart); |
125 | 125 | ||
126 | 126 | ||
@@ -195,9 +195,9 @@ void machine_power_off(void) | |||
195 | pm_power_off(); | 195 | pm_power_off(); |
196 | } | 196 | } |
197 | 197 | ||
198 | void machine_restart(char * __unused) | 198 | void machine_restart(char *cmd) |
199 | { | 199 | { |
200 | arm_pm_restart(reboot_mode); | 200 | arm_pm_restart(reboot_mode, cmd); |
201 | } | 201 | } |
202 | 202 | ||
203 | void __show_regs(struct pt_regs *regs) | 203 | void __show_regs(struct pt_regs *regs) |
diff --git a/arch/arm/mach-aaec2000/include/mach/system.h b/arch/arm/mach-aaec2000/include/mach/system.h index 8f4115d734ce..fe08ca1add6f 100644 --- a/arch/arm/mach-aaec2000/include/mach/system.h +++ b/arch/arm/mach-aaec2000/include/mach/system.h | |||
@@ -16,7 +16,7 @@ static inline void arch_idle(void) | |||
16 | cpu_do_idle(); | 16 | cpu_do_idle(); |
17 | } | 17 | } |
18 | 18 | ||
19 | static inline void arch_reset(char mode) | 19 | static inline void arch_reset(char mode, const char *cmd) |
20 | { | 20 | { |
21 | cpu_reset(0); | 21 | cpu_reset(0); |
22 | } | 22 | } |
diff --git a/arch/arm/mach-at91/include/mach/system.h b/arch/arm/mach-at91/include/mach/system.h index e712658d966c..5268af3933c2 100644 --- a/arch/arm/mach-at91/include/mach/system.h +++ b/arch/arm/mach-at91/include/mach/system.h | |||
@@ -43,7 +43,7 @@ static inline void arch_idle(void) | |||
43 | 43 | ||
44 | void (*at91_arch_reset)(void); | 44 | void (*at91_arch_reset)(void); |
45 | 45 | ||
46 | static inline void arch_reset(char mode) | 46 | static inline void arch_reset(char mode, const char *cmd) |
47 | { | 47 | { |
48 | /* call the CPU-specific reset function */ | 48 | /* call the CPU-specific reset function */ |
49 | if (at91_arch_reset) | 49 | if (at91_arch_reset) |
diff --git a/arch/arm/mach-clps711x/include/mach/system.h b/arch/arm/mach-clps711x/include/mach/system.h index 24e96159e3e7..f916cd7a477d 100644 --- a/arch/arm/mach-clps711x/include/mach/system.h +++ b/arch/arm/mach-clps711x/include/mach/system.h | |||
@@ -32,7 +32,7 @@ static inline void arch_idle(void) | |||
32 | mov r0, r0"); | 32 | mov r0, r0"); |
33 | } | 33 | } |
34 | 34 | ||
35 | static inline void arch_reset(char mode) | 35 | static inline void arch_reset(char mode, const char *cmd) |
36 | { | 36 | { |
37 | cpu_reset(0); | 37 | cpu_reset(0); |
38 | } | 38 | } |
diff --git a/arch/arm/mach-davinci/include/mach/system.h b/arch/arm/mach-davinci/include/mach/system.h index 17ca41dc2c53..b7e7036674fa 100644 --- a/arch/arm/mach-davinci/include/mach/system.h +++ b/arch/arm/mach-davinci/include/mach/system.h | |||
@@ -21,7 +21,7 @@ static void arch_idle(void) | |||
21 | cpu_do_idle(); | 21 | cpu_do_idle(); |
22 | } | 22 | } |
23 | 23 | ||
24 | static void arch_reset(char mode) | 24 | static void arch_reset(char mode, const char *cmd) |
25 | { | 25 | { |
26 | davinci_watchdog_reset(); | 26 | davinci_watchdog_reset(); |
27 | } | 27 | } |
diff --git a/arch/arm/mach-ebsa110/include/mach/system.h b/arch/arm/mach-ebsa110/include/mach/system.h index 350a028997ef..9a26245bf1fc 100644 --- a/arch/arm/mach-ebsa110/include/mach/system.h +++ b/arch/arm/mach-ebsa110/include/mach/system.h | |||
@@ -34,6 +34,6 @@ static inline void arch_idle(void) | |||
34 | asm volatile ("mcr p15, 0, ip, c15, c1, 2" : : : "cc"); | 34 | asm volatile ("mcr p15, 0, ip, c15, c1, 2" : : : "cc"); |
35 | } | 35 | } |
36 | 36 | ||
37 | #define arch_reset(mode) cpu_reset(0x80000000) | 37 | #define arch_reset(mode, cmd) cpu_reset(0x80000000) |
38 | 38 | ||
39 | #endif | 39 | #endif |
diff --git a/arch/arm/mach-ep93xx/include/mach/system.h b/arch/arm/mach-ep93xx/include/mach/system.h index 67789d0f329e..ed8f35e4f068 100644 --- a/arch/arm/mach-ep93xx/include/mach/system.h +++ b/arch/arm/mach-ep93xx/include/mach/system.h | |||
@@ -9,7 +9,7 @@ static inline void arch_idle(void) | |||
9 | cpu_do_idle(); | 9 | cpu_do_idle(); |
10 | } | 10 | } |
11 | 11 | ||
12 | static inline void arch_reset(char mode) | 12 | static inline void arch_reset(char mode, const char *cmd) |
13 | { | 13 | { |
14 | u32 devicecfg; | 14 | u32 devicecfg; |
15 | 15 | ||
diff --git a/arch/arm/mach-footbridge/include/mach/system.h b/arch/arm/mach-footbridge/include/mach/system.h index 2db7f36bd6ca..0b2931566209 100644 --- a/arch/arm/mach-footbridge/include/mach/system.h +++ b/arch/arm/mach-footbridge/include/mach/system.h | |||
@@ -18,7 +18,7 @@ static inline void arch_idle(void) | |||
18 | cpu_do_idle(); | 18 | cpu_do_idle(); |
19 | } | 19 | } |
20 | 20 | ||
21 | static inline void arch_reset(char mode) | 21 | static inline void arch_reset(char mode, const char *cmd) |
22 | { | 22 | { |
23 | if (mode == 's') { | 23 | if (mode == 's') { |
24 | /* | 24 | /* |
diff --git a/arch/arm/mach-h720x/include/mach/system.h b/arch/arm/mach-h720x/include/mach/system.h index e4a7c760d52a..a708d24ee46d 100644 --- a/arch/arm/mach-h720x/include/mach/system.h +++ b/arch/arm/mach-h720x/include/mach/system.h | |||
@@ -25,7 +25,7 @@ static void arch_idle(void) | |||
25 | } | 25 | } |
26 | 26 | ||
27 | 27 | ||
28 | static __inline__ void arch_reset(char mode) | 28 | static __inline__ void arch_reset(char mode, const char *cmd) |
29 | { | 29 | { |
30 | CPU_REG (PMU_BASE, PMU_STAT) |= PMU_WARMRESET; | 30 | CPU_REG (PMU_BASE, PMU_STAT) |= PMU_WARMRESET; |
31 | } | 31 | } |
diff --git a/arch/arm/mach-imx/include/mach/system.h b/arch/arm/mach-imx/include/mach/system.h index adee7e51bab2..46d4ca91af79 100644 --- a/arch/arm/mach-imx/include/mach/system.h +++ b/arch/arm/mach-imx/include/mach/system.h | |||
@@ -32,7 +32,7 @@ arch_idle(void) | |||
32 | } | 32 | } |
33 | 33 | ||
34 | static inline void | 34 | static inline void |
35 | arch_reset(char mode) | 35 | arch_reset(char mode, const char *cmd) |
36 | { | 36 | { |
37 | cpu_reset(0); | 37 | cpu_reset(0); |
38 | } | 38 | } |
diff --git a/arch/arm/mach-integrator/include/mach/system.h b/arch/arm/mach-integrator/include/mach/system.h index c485345c8c77..e1551b8dab77 100644 --- a/arch/arm/mach-integrator/include/mach/system.h +++ b/arch/arm/mach-integrator/include/mach/system.h | |||
@@ -32,7 +32,7 @@ static inline void arch_idle(void) | |||
32 | cpu_do_idle(); | 32 | cpu_do_idle(); |
33 | } | 33 | } |
34 | 34 | ||
35 | static inline void arch_reset(char mode) | 35 | static inline void arch_reset(char mode, const char *cmd) |
36 | { | 36 | { |
37 | /* | 37 | /* |
38 | * To reset, we hit the on-board reset register | 38 | * To reset, we hit the on-board reset register |
diff --git a/arch/arm/mach-iop13xx/include/mach/system.h b/arch/arm/mach-iop13xx/include/mach/system.h index c7127f416e1f..d0c66ef450a7 100644 --- a/arch/arm/mach-iop13xx/include/mach/system.h +++ b/arch/arm/mach-iop13xx/include/mach/system.h | |||
@@ -13,7 +13,7 @@ static inline void arch_idle(void) | |||
13 | cpu_do_idle(); | 13 | cpu_do_idle(); |
14 | } | 14 | } |
15 | 15 | ||
16 | static inline void arch_reset(char mode) | 16 | static inline void arch_reset(char mode, const char *cmd) |
17 | { | 17 | { |
18 | /* | 18 | /* |
19 | * Reset the internal bus (warning both cores are reset) | 19 | * Reset the internal bus (warning both cores are reset) |
diff --git a/arch/arm/mach-iop32x/include/mach/system.h b/arch/arm/mach-iop32x/include/mach/system.h index 32d9e5b0a28d..a4b808fe0d81 100644 --- a/arch/arm/mach-iop32x/include/mach/system.h +++ b/arch/arm/mach-iop32x/include/mach/system.h | |||
@@ -16,7 +16,7 @@ static inline void arch_idle(void) | |||
16 | cpu_do_idle(); | 16 | cpu_do_idle(); |
17 | } | 17 | } |
18 | 18 | ||
19 | static inline void arch_reset(char mode) | 19 | static inline void arch_reset(char mode, const char *cmd) |
20 | { | 20 | { |
21 | local_irq_disable(); | 21 | local_irq_disable(); |
22 | 22 | ||
diff --git a/arch/arm/mach-iop33x/include/mach/system.h b/arch/arm/mach-iop33x/include/mach/system.h index 0cb3ad862acd..f192a34be073 100644 --- a/arch/arm/mach-iop33x/include/mach/system.h +++ b/arch/arm/mach-iop33x/include/mach/system.h | |||
@@ -14,7 +14,7 @@ static inline void arch_idle(void) | |||
14 | cpu_do_idle(); | 14 | cpu_do_idle(); |
15 | } | 15 | } |
16 | 16 | ||
17 | static inline void arch_reset(char mode) | 17 | static inline void arch_reset(char mode, const char *cmd) |
18 | { | 18 | { |
19 | *IOP3XX_PCSR = 0x30; | 19 | *IOP3XX_PCSR = 0x30; |
20 | 20 | ||
diff --git a/arch/arm/mach-ixp2000/include/mach/system.h b/arch/arm/mach-ixp2000/include/mach/system.h index 2e9c68f95a24..de370992c848 100644 --- a/arch/arm/mach-ixp2000/include/mach/system.h +++ b/arch/arm/mach-ixp2000/include/mach/system.h | |||
@@ -17,7 +17,7 @@ static inline void arch_idle(void) | |||
17 | cpu_do_idle(); | 17 | cpu_do_idle(); |
18 | } | 18 | } |
19 | 19 | ||
20 | static inline void arch_reset(char mode) | 20 | static inline void arch_reset(char mode, const char *cmd) |
21 | { | 21 | { |
22 | local_irq_disable(); | 22 | local_irq_disable(); |
23 | 23 | ||
diff --git a/arch/arm/mach-ixp23xx/include/mach/system.h b/arch/arm/mach-ixp23xx/include/mach/system.h index d57c3fc10f1f..8920ff2dff1f 100644 --- a/arch/arm/mach-ixp23xx/include/mach/system.h +++ b/arch/arm/mach-ixp23xx/include/mach/system.h | |||
@@ -19,7 +19,7 @@ static inline void arch_idle(void) | |||
19 | #endif | 19 | #endif |
20 | } | 20 | } |
21 | 21 | ||
22 | static inline void arch_reset(char mode) | 22 | static inline void arch_reset(char mode, const char *cmd) |
23 | { | 23 | { |
24 | /* First try machine specific support */ | 24 | /* First try machine specific support */ |
25 | if (machine_is_ixdp2351()) { | 25 | if (machine_is_ixdp2351()) { |
diff --git a/arch/arm/mach-ixp4xx/include/mach/system.h b/arch/arm/mach-ixp4xx/include/mach/system.h index 92a7e8ddf69a..d2aa26f5acd7 100644 --- a/arch/arm/mach-ixp4xx/include/mach/system.h +++ b/arch/arm/mach-ixp4xx/include/mach/system.h | |||
@@ -20,7 +20,7 @@ static inline void arch_idle(void) | |||
20 | } | 20 | } |
21 | 21 | ||
22 | 22 | ||
23 | static inline void arch_reset(char mode) | 23 | static inline void arch_reset(char mode, const char *cmd) |
24 | { | 24 | { |
25 | if ( 1 && mode == 's') { | 25 | if ( 1 && mode == 's') { |
26 | /* Jump into ROM at address 0 */ | 26 | /* Jump into ROM at address 0 */ |
diff --git a/arch/arm/mach-kirkwood/include/mach/system.h b/arch/arm/mach-kirkwood/include/mach/system.h index 8510f6cfdabf..23a1914c1da8 100644 --- a/arch/arm/mach-kirkwood/include/mach/system.h +++ b/arch/arm/mach-kirkwood/include/mach/system.h | |||
@@ -17,7 +17,7 @@ static inline void arch_idle(void) | |||
17 | cpu_do_idle(); | 17 | cpu_do_idle(); |
18 | } | 18 | } |
19 | 19 | ||
20 | static inline void arch_reset(char mode) | 20 | static inline void arch_reset(char mode, const char *cmd) |
21 | { | 21 | { |
22 | /* | 22 | /* |
23 | * Enable soft reset to assert RSTOUTn. | 23 | * Enable soft reset to assert RSTOUTn. |
diff --git a/arch/arm/mach-ks8695/include/mach/system.h b/arch/arm/mach-ks8695/include/mach/system.h index 5a9b032bdbeb..fb1dda9be2d0 100644 --- a/arch/arm/mach-ks8695/include/mach/system.h +++ b/arch/arm/mach-ks8695/include/mach/system.h | |||
@@ -27,7 +27,7 @@ static void arch_idle(void) | |||
27 | 27 | ||
28 | } | 28 | } |
29 | 29 | ||
30 | static void arch_reset(char mode) | 30 | static void arch_reset(char mode, const char *cmd) |
31 | { | 31 | { |
32 | unsigned int reg; | 32 | unsigned int reg; |
33 | 33 | ||
diff --git a/arch/arm/mach-l7200/include/mach/system.h b/arch/arm/mach-l7200/include/mach/system.h index 5272abee0d0e..e0dd3b6ae4aa 100644 --- a/arch/arm/mach-l7200/include/mach/system.h +++ b/arch/arm/mach-l7200/include/mach/system.h | |||
@@ -19,7 +19,7 @@ static inline void arch_idle(void) | |||
19 | *(unsigned long *)(IO_BASE + 0x50004) = 1; /* idle mode */ | 19 | *(unsigned long *)(IO_BASE + 0x50004) = 1; /* idle mode */ |
20 | } | 20 | } |
21 | 21 | ||
22 | static inline void arch_reset(char mode) | 22 | static inline void arch_reset(char mode, const char *cmd) |
23 | { | 23 | { |
24 | if (mode == 's') { | 24 | if (mode == 's') { |
25 | cpu_reset(0); | 25 | cpu_reset(0); |
diff --git a/arch/arm/mach-lh7a40x/include/mach/system.h b/arch/arm/mach-lh7a40x/include/mach/system.h index fa46bb1ef07b..45a56d3b93d7 100644 --- a/arch/arm/mach-lh7a40x/include/mach/system.h +++ b/arch/arm/mach-lh7a40x/include/mach/system.h | |||
@@ -13,7 +13,7 @@ static inline void arch_idle(void) | |||
13 | cpu_do_idle (); | 13 | cpu_do_idle (); |
14 | } | 14 | } |
15 | 15 | ||
16 | static inline void arch_reset(char mode) | 16 | static inline void arch_reset(char mode, const char *cmd) |
17 | { | 17 | { |
18 | cpu_reset (0); | 18 | cpu_reset (0); |
19 | } | 19 | } |
diff --git a/arch/arm/mach-loki/include/mach/system.h b/arch/arm/mach-loki/include/mach/system.h index 8db1147d4ec5..c1de36fe9b37 100644 --- a/arch/arm/mach-loki/include/mach/system.h +++ b/arch/arm/mach-loki/include/mach/system.h | |||
@@ -17,7 +17,7 @@ static inline void arch_idle(void) | |||
17 | cpu_do_idle(); | 17 | cpu_do_idle(); |
18 | } | 18 | } |
19 | 19 | ||
20 | static inline void arch_reset(char mode) | 20 | static inline void arch_reset(char mode, const char *cmd) |
21 | { | 21 | { |
22 | /* | 22 | /* |
23 | * Enable soft reset to assert RSTOUTn. | 23 | * Enable soft reset to assert RSTOUTn. |
diff --git a/arch/arm/mach-msm/include/mach/system.h b/arch/arm/mach-msm/include/mach/system.h index f05ad2e0f235..574ccc493daf 100644 --- a/arch/arm/mach-msm/include/mach/system.h +++ b/arch/arm/mach-msm/include/mach/system.h | |||
@@ -17,7 +17,7 @@ | |||
17 | 17 | ||
18 | void arch_idle(void); | 18 | void arch_idle(void); |
19 | 19 | ||
20 | static inline void arch_reset(char mode) | 20 | static inline void arch_reset(char mode, const char *cmd) |
21 | { | 21 | { |
22 | for (;;) ; /* depends on IPC w/ other core */ | 22 | for (;;) ; /* depends on IPC w/ other core */ |
23 | } | 23 | } |
diff --git a/arch/arm/mach-mv78xx0/include/mach/system.h b/arch/arm/mach-mv78xx0/include/mach/system.h index 7d5179408832..1d6350b22d0b 100644 --- a/arch/arm/mach-mv78xx0/include/mach/system.h +++ b/arch/arm/mach-mv78xx0/include/mach/system.h | |||
@@ -17,7 +17,7 @@ static inline void arch_idle(void) | |||
17 | cpu_do_idle(); | 17 | cpu_do_idle(); |
18 | } | 18 | } |
19 | 19 | ||
20 | static inline void arch_reset(char mode) | 20 | static inline void arch_reset(char mode, const char *cmd) |
21 | { | 21 | { |
22 | /* | 22 | /* |
23 | * Enable soft reset to assert RSTOUTn. | 23 | * Enable soft reset to assert RSTOUTn. |
diff --git a/arch/arm/mach-mx2/system.c b/arch/arm/mach-mx2/system.c index 7b8269719d11..92c79d4bd162 100644 --- a/arch/arm/mach-mx2/system.c +++ b/arch/arm/mach-mx2/system.c | |||
@@ -46,7 +46,7 @@ void arch_idle(void) | |||
46 | /* | 46 | /* |
47 | * Reset the system. It is called by machine_restart(). | 47 | * Reset the system. It is called by machine_restart(). |
48 | */ | 48 | */ |
49 | void arch_reset(char mode) | 49 | void arch_reset(char mode, const char *cmd) |
50 | { | 50 | { |
51 | struct clk *clk; | 51 | struct clk *clk; |
52 | 52 | ||
diff --git a/arch/arm/mach-netx/include/mach/system.h b/arch/arm/mach-netx/include/mach/system.h index 6c1023b8a9ab..dc7b4bc003c5 100644 --- a/arch/arm/mach-netx/include/mach/system.h +++ b/arch/arm/mach-netx/include/mach/system.h | |||
@@ -28,7 +28,7 @@ static inline void arch_idle(void) | |||
28 | cpu_do_idle(); | 28 | cpu_do_idle(); |
29 | } | 29 | } |
30 | 30 | ||
31 | static inline void arch_reset(char mode) | 31 | static inline void arch_reset(char mode, const char *cmd) |
32 | { | 32 | { |
33 | writel(NETX_SYSTEM_RES_CR_FIRMW_RES_EN | NETX_SYSTEM_RES_CR_FIRMW_RES, | 33 | writel(NETX_SYSTEM_RES_CR_FIRMW_RES_EN | NETX_SYSTEM_RES_CR_FIRMW_RES, |
34 | NETX_SYSTEM_RES_CR); | 34 | NETX_SYSTEM_RES_CR); |
diff --git a/arch/arm/mach-ns9xxx/include/mach/system.h b/arch/arm/mach-ns9xxx/include/mach/system.h index e2068c57415f..1561588ca364 100644 --- a/arch/arm/mach-ns9xxx/include/mach/system.h +++ b/arch/arm/mach-ns9xxx/include/mach/system.h | |||
@@ -20,7 +20,7 @@ static inline void arch_idle(void) | |||
20 | cpu_do_idle(); | 20 | cpu_do_idle(); |
21 | } | 21 | } |
22 | 22 | ||
23 | static inline void arch_reset(char mode) | 23 | static inline void arch_reset(char mode, const char *cmd) |
24 | { | 24 | { |
25 | #ifdef CONFIG_PROCESSOR_NS9360 | 25 | #ifdef CONFIG_PROCESSOR_NS9360 |
26 | if (processor_is_ns9360()) | 26 | if (processor_is_ns9360()) |
diff --git a/arch/arm/mach-orion5x/include/mach/system.h b/arch/arm/mach-orion5x/include/mach/system.h index 08e430757890..9b8db1dcfa83 100644 --- a/arch/arm/mach-orion5x/include/mach/system.h +++ b/arch/arm/mach-orion5x/include/mach/system.h | |||
@@ -19,7 +19,7 @@ static inline void arch_idle(void) | |||
19 | cpu_do_idle(); | 19 | cpu_do_idle(); |
20 | } | 20 | } |
21 | 21 | ||
22 | static inline void arch_reset(char mode) | 22 | static inline void arch_reset(char mode, const char *cmd) |
23 | { | 23 | { |
24 | /* | 24 | /* |
25 | * Enable and issue soft reset | 25 | * Enable and issue soft reset |
diff --git a/arch/arm/mach-orion5x/lsmini-setup.c b/arch/arm/mach-orion5x/lsmini-setup.c index e0c43b8beb72..c9bf6b81a80d 100644 --- a/arch/arm/mach-orion5x/lsmini-setup.c +++ b/arch/arm/mach-orion5x/lsmini-setup.c | |||
@@ -186,7 +186,7 @@ static struct mv_sata_platform_data lsmini_sata_data = { | |||
186 | 186 | ||
187 | static void lsmini_power_off(void) | 187 | static void lsmini_power_off(void) |
188 | { | 188 | { |
189 | arch_reset(0); | 189 | arch_reset(0, NULL); |
190 | } | 190 | } |
191 | 191 | ||
192 | 192 | ||
diff --git a/arch/arm/mach-pnx4008/include/mach/system.h b/arch/arm/mach-pnx4008/include/mach/system.h index e12e7abfcbcf..5dda2bb55f8d 100644 --- a/arch/arm/mach-pnx4008/include/mach/system.h +++ b/arch/arm/mach-pnx4008/include/mach/system.h | |||
@@ -30,7 +30,7 @@ static void arch_idle(void) | |||
30 | cpu_do_idle(); | 30 | cpu_do_idle(); |
31 | } | 31 | } |
32 | 32 | ||
33 | static inline void arch_reset(char mode) | 33 | static inline void arch_reset(char mode, const char *cmd) |
34 | { | 34 | { |
35 | cpu_reset(0); | 35 | cpu_reset(0); |
36 | } | 36 | } |
diff --git a/arch/arm/mach-pxa/corgi.c b/arch/arm/mach-pxa/corgi.c index 3b89e5010fb3..cdf21dd135b4 100644 --- a/arch/arm/mach-pxa/corgi.c +++ b/arch/arm/mach-pxa/corgi.c | |||
@@ -635,16 +635,16 @@ static void corgi_poweroff(void) | |||
635 | /* Green LED off tells the bootloader to halt */ | 635 | /* Green LED off tells the bootloader to halt */ |
636 | gpio_set_value(CORGI_GPIO_LED_GREEN, 0); | 636 | gpio_set_value(CORGI_GPIO_LED_GREEN, 0); |
637 | 637 | ||
638 | arm_machine_restart('h'); | 638 | arm_machine_restart('h', NULL); |
639 | } | 639 | } |
640 | 640 | ||
641 | static void corgi_restart(char mode) | 641 | static void corgi_restart(char mode, const char *cmd) |
642 | { | 642 | { |
643 | if (!machine_is_corgi()) | 643 | if (!machine_is_corgi()) |
644 | /* Green LED on tells the bootloader to reboot */ | 644 | /* Green LED on tells the bootloader to reboot */ |
645 | gpio_set_value(CORGI_GPIO_LED_GREEN, 1); | 645 | gpio_set_value(CORGI_GPIO_LED_GREEN, 1); |
646 | 646 | ||
647 | arm_machine_restart('h'); | 647 | arm_machine_restart('h', cmd); |
648 | } | 648 | } |
649 | 649 | ||
650 | static void __init corgi_init(void) | 650 | static void __init corgi_init(void) |
diff --git a/arch/arm/mach-pxa/include/mach/system.h b/arch/arm/mach-pxa/include/mach/system.h index 0a587c4ec709..d1fce8b6d105 100644 --- a/arch/arm/mach-pxa/include/mach/system.h +++ b/arch/arm/mach-pxa/include/mach/system.h | |||
@@ -20,4 +20,4 @@ static inline void arch_idle(void) | |||
20 | } | 20 | } |
21 | 21 | ||
22 | 22 | ||
23 | void arch_reset(char mode); | 23 | void arch_reset(char mode, const char *cmd); |
diff --git a/arch/arm/mach-pxa/mioa701.c b/arch/arm/mach-pxa/mioa701.c index 025772785d36..97c93a7a285c 100644 --- a/arch/arm/mach-pxa/mioa701.c +++ b/arch/arm/mach-pxa/mioa701.c | |||
@@ -788,13 +788,13 @@ static void mioa701_machine_exit(void); | |||
788 | static void mioa701_poweroff(void) | 788 | static void mioa701_poweroff(void) |
789 | { | 789 | { |
790 | mioa701_machine_exit(); | 790 | mioa701_machine_exit(); |
791 | arm_machine_restart('s'); | 791 | arm_machine_restart('s', NULL); |
792 | } | 792 | } |
793 | 793 | ||
794 | static void mioa701_restart(char c) | 794 | static void mioa701_restart(char c, const char *cmd) |
795 | { | 795 | { |
796 | mioa701_machine_exit(); | 796 | mioa701_machine_exit(); |
797 | arm_machine_restart('s'); | 797 | arm_machine_restart('s', cmd); |
798 | } | 798 | } |
799 | 799 | ||
800 | struct gpio_ress global_gpios[] = { | 800 | struct gpio_ress global_gpios[] = { |
diff --git a/arch/arm/mach-pxa/poodle.c b/arch/arm/mach-pxa/poodle.c index 572ddec2b3e6..036bbde4d221 100644 --- a/arch/arm/mach-pxa/poodle.c +++ b/arch/arm/mach-pxa/poodle.c | |||
@@ -501,12 +501,12 @@ static struct platform_device *devices[] __initdata = { | |||
501 | 501 | ||
502 | static void poodle_poweroff(void) | 502 | static void poodle_poweroff(void) |
503 | { | 503 | { |
504 | arm_machine_restart('h'); | 504 | arm_machine_restart('h', NULL); |
505 | } | 505 | } |
506 | 506 | ||
507 | static void poodle_restart(char mode) | 507 | static void poodle_restart(char mode, const char *cmd) |
508 | { | 508 | { |
509 | arm_machine_restart('h'); | 509 | arm_machine_restart('h', cmd); |
510 | } | 510 | } |
511 | 511 | ||
512 | static void __init poodle_init(void) | 512 | static void __init poodle_init(void) |
diff --git a/arch/arm/mach-pxa/reset.c b/arch/arm/mach-pxa/reset.c index 867c95c09618..df29d45fb4e7 100644 --- a/arch/arm/mach-pxa/reset.c +++ b/arch/arm/mach-pxa/reset.c | |||
@@ -81,7 +81,7 @@ static void do_hw_reset(void) | |||
81 | OSMR3 = OSCR + 368640; /* ... in 100 ms */ | 81 | OSMR3 = OSCR + 368640; /* ... in 100 ms */ |
82 | } | 82 | } |
83 | 83 | ||
84 | void arch_reset(char mode) | 84 | void arch_reset(char mode, const char *cmd) |
85 | { | 85 | { |
86 | clear_reset_status(RESET_STATUS_ALL); | 86 | clear_reset_status(RESET_STATUS_ALL); |
87 | 87 | ||
diff --git a/arch/arm/mach-pxa/spitz.c b/arch/arm/mach-pxa/spitz.c index f697c492b2ab..7a0a430222cf 100644 --- a/arch/arm/mach-pxa/spitz.c +++ b/arch/arm/mach-pxa/spitz.c | |||
@@ -701,10 +701,10 @@ static struct platform_device *devices[] __initdata = { | |||
701 | 701 | ||
702 | static void spitz_poweroff(void) | 702 | static void spitz_poweroff(void) |
703 | { | 703 | { |
704 | arm_machine_restart('g'); | 704 | arm_machine_restart('g', NULL); |
705 | } | 705 | } |
706 | 706 | ||
707 | static void spitz_restart(char mode) | 707 | static void spitz_restart(char mode, const char *cmd) |
708 | { | 708 | { |
709 | /* Bootloader magic for a reboot */ | 709 | /* Bootloader magic for a reboot */ |
710 | if((MSC0 & 0xffff0000) == 0x7ff00000) | 710 | if((MSC0 & 0xffff0000) == 0x7ff00000) |
diff --git a/arch/arm/mach-pxa/tosa.c b/arch/arm/mach-pxa/tosa.c index 66b13802c99d..4f6f5024884e 100644 --- a/arch/arm/mach-pxa/tosa.c +++ b/arch/arm/mach-pxa/tosa.c | |||
@@ -876,10 +876,10 @@ static struct platform_device *devices[] __initdata = { | |||
876 | 876 | ||
877 | static void tosa_poweroff(void) | 877 | static void tosa_poweroff(void) |
878 | { | 878 | { |
879 | arm_machine_restart('g'); | 879 | arm_machine_restart('g', NULL); |
880 | } | 880 | } |
881 | 881 | ||
882 | static void tosa_restart(char mode) | 882 | static void tosa_restart(char mode, const char *cmd) |
883 | { | 883 | { |
884 | /* Bootloader magic for a reboot */ | 884 | /* Bootloader magic for a reboot */ |
885 | if((MSC0 & 0xffff0000) == 0x7ff00000) | 885 | if((MSC0 & 0xffff0000) == 0x7ff00000) |
diff --git a/arch/arm/mach-realview/include/mach/system.h b/arch/arm/mach-realview/include/mach/system.h index a2f61c78adbf..1a15a441e027 100644 --- a/arch/arm/mach-realview/include/mach/system.h +++ b/arch/arm/mach-realview/include/mach/system.h | |||
@@ -34,7 +34,7 @@ static inline void arch_idle(void) | |||
34 | cpu_do_idle(); | 34 | cpu_do_idle(); |
35 | } | 35 | } |
36 | 36 | ||
37 | static inline void arch_reset(char mode) | 37 | static inline void arch_reset(char mode, const char *cmd) |
38 | { | 38 | { |
39 | void __iomem *hdr_ctrl = __io_address(REALVIEW_SYS_BASE) + REALVIEW_SYS_RESETCTL_OFFSET; | 39 | void __iomem *hdr_ctrl = __io_address(REALVIEW_SYS_BASE) + REALVIEW_SYS_RESETCTL_OFFSET; |
40 | unsigned int val; | 40 | unsigned int val; |
diff --git a/arch/arm/mach-rpc/include/mach/system.h b/arch/arm/mach-rpc/include/mach/system.h index bd7268ba17e2..45c7b935dc45 100644 --- a/arch/arm/mach-rpc/include/mach/system.h +++ b/arch/arm/mach-rpc/include/mach/system.h | |||
@@ -16,7 +16,7 @@ static inline void arch_idle(void) | |||
16 | cpu_do_idle(); | 16 | cpu_do_idle(); |
17 | } | 17 | } |
18 | 18 | ||
19 | static inline void arch_reset(char mode) | 19 | static inline void arch_reset(char mode, const char *cmd) |
20 | { | 20 | { |
21 | iomd_writeb(0, IOMD_ROMCR0); | 21 | iomd_writeb(0, IOMD_ROMCR0); |
22 | 22 | ||
diff --git a/arch/arm/mach-s3c2410/include/mach/system-reset.h b/arch/arm/mach-s3c2410/include/mach/system-reset.h index 7613d0a384ba..b8687f71c304 100644 --- a/arch/arm/mach-s3c2410/include/mach/system-reset.h +++ b/arch/arm/mach-s3c2410/include/mach/system-reset.h | |||
@@ -22,7 +22,7 @@ | |||
22 | extern void (*s3c24xx_reset_hook)(void); | 22 | extern void (*s3c24xx_reset_hook)(void); |
23 | 23 | ||
24 | static void | 24 | static void |
25 | arch_reset(char mode) | 25 | arch_reset(char mode, const char *cmd) |
26 | { | 26 | { |
27 | struct clk *wdtclk; | 27 | struct clk *wdtclk; |
28 | 28 | ||
diff --git a/arch/arm/mach-s3c6400/include/mach/system.h b/arch/arm/mach-s3c6400/include/mach/system.h index 652bbc403f0b..090cfd969bc7 100644 --- a/arch/arm/mach-s3c6400/include/mach/system.h +++ b/arch/arm/mach-s3c6400/include/mach/system.h | |||
@@ -16,7 +16,7 @@ static void arch_idle(void) | |||
16 | /* nothing here yet */ | 16 | /* nothing here yet */ |
17 | } | 17 | } |
18 | 18 | ||
19 | static void arch_reset(char mode) | 19 | static void arch_reset(char mode, const char *cmd) |
20 | { | 20 | { |
21 | /* nothing here yet */ | 21 | /* nothing here yet */ |
22 | } | 22 | } |
diff --git a/arch/arm/mach-sa1100/include/mach/system.h b/arch/arm/mach-sa1100/include/mach/system.h index 63755ca5b1b4..942b153e251d 100644 --- a/arch/arm/mach-sa1100/include/mach/system.h +++ b/arch/arm/mach-sa1100/include/mach/system.h | |||
@@ -10,7 +10,7 @@ static inline void arch_idle(void) | |||
10 | cpu_do_idle(); | 10 | cpu_do_idle(); |
11 | } | 11 | } |
12 | 12 | ||
13 | static inline void arch_reset(char mode) | 13 | static inline void arch_reset(char mode, const char *cmd) |
14 | { | 14 | { |
15 | if (mode == 's') { | 15 | if (mode == 's') { |
16 | /* Jump into ROM at address 0 */ | 16 | /* Jump into ROM at address 0 */ |
diff --git a/arch/arm/mach-shark/core.c b/arch/arm/mach-shark/core.c index 4f3a26512599..358d875ace14 100644 --- a/arch/arm/mach-shark/core.c +++ b/arch/arm/mach-shark/core.c | |||
@@ -26,7 +26,7 @@ | |||
26 | #define ROMCARD_SIZE 0x08000000 | 26 | #define ROMCARD_SIZE 0x08000000 |
27 | #define ROMCARD_START 0x10000000 | 27 | #define ROMCARD_START 0x10000000 |
28 | 28 | ||
29 | void arch_reset(char mode) | 29 | void arch_reset(char mode, const char *cmd) |
30 | { | 30 | { |
31 | short temp; | 31 | short temp; |
32 | local_irq_disable(); | 32 | local_irq_disable(); |
diff --git a/arch/arm/mach-shark/include/mach/system.h b/arch/arm/mach-shark/include/mach/system.h index 0752ca29971a..21c373b30bbc 100644 --- a/arch/arm/mach-shark/include/mach/system.h +++ b/arch/arm/mach-shark/include/mach/system.h | |||
@@ -7,7 +7,7 @@ | |||
7 | #define __ASM_ARCH_SYSTEM_H | 7 | #define __ASM_ARCH_SYSTEM_H |
8 | 8 | ||
9 | /* Found in arch/mach-shark/core.c */ | 9 | /* Found in arch/mach-shark/core.c */ |
10 | extern void arch_reset(char mode); | 10 | extern void arch_reset(char mode, const char *cmd); |
11 | 11 | ||
12 | static inline void arch_idle(void) | 12 | static inline void arch_idle(void) |
13 | { | 13 | { |
diff --git a/arch/arm/mach-versatile/include/mach/system.h b/arch/arm/mach-versatile/include/mach/system.h index c59e6100c7e3..8ffc12a7cb25 100644 --- a/arch/arm/mach-versatile/include/mach/system.h +++ b/arch/arm/mach-versatile/include/mach/system.h | |||
@@ -34,7 +34,7 @@ static inline void arch_idle(void) | |||
34 | cpu_do_idle(); | 34 | cpu_do_idle(); |
35 | } | 35 | } |
36 | 36 | ||
37 | static inline void arch_reset(char mode) | 37 | static inline void arch_reset(char mode, const char *cmd) |
38 | { | 38 | { |
39 | u32 val; | 39 | u32 val; |
40 | 40 | ||
diff --git a/arch/arm/mach-w90x900/include/mach/system.h b/arch/arm/mach-w90x900/include/mach/system.h index 93753f922618..940640066857 100644 --- a/arch/arm/mach-w90x900/include/mach/system.h +++ b/arch/arm/mach-w90x900/include/mach/system.h | |||
@@ -21,7 +21,7 @@ static void arch_idle(void) | |||
21 | { | 21 | { |
22 | } | 22 | } |
23 | 23 | ||
24 | static void arch_reset(char mode) | 24 | static void arch_reset(char mode, const char *cmd) |
25 | { | 25 | { |
26 | cpu_reset(0); | 26 | cpu_reset(0); |
27 | } | 27 | } |
diff --git a/arch/arm/plat-mxc/include/mach/system.h b/arch/arm/plat-mxc/include/mach/system.h index bbfc37465fc5..cd03ebaa49bc 100644 --- a/arch/arm/plat-mxc/include/mach/system.h +++ b/arch/arm/plat-mxc/include/mach/system.h | |||
@@ -26,7 +26,7 @@ static inline void arch_idle(void) | |||
26 | cpu_do_idle(); | 26 | cpu_do_idle(); |
27 | } | 27 | } |
28 | 28 | ||
29 | static inline void arch_reset(char mode) | 29 | static inline void arch_reset(char mode, const char *cmd) |
30 | { | 30 | { |
31 | cpu_reset(0); | 31 | cpu_reset(0); |
32 | } | 32 | } |
diff --git a/arch/arm/plat-omap/include/mach/system.h b/arch/arm/plat-omap/include/mach/system.h index e9b95637f7fc..cb8c0ef30fba 100644 --- a/arch/arm/plat-omap/include/mach/system.h +++ b/arch/arm/plat-omap/include/mach/system.h | |||
@@ -38,7 +38,7 @@ static inline void omap1_arch_reset(char mode) | |||
38 | omap_writew(1, ARM_RSTCT1); | 38 | omap_writew(1, ARM_RSTCT1); |
39 | } | 39 | } |
40 | 40 | ||
41 | static inline void arch_reset(char mode) | 41 | static inline void arch_reset(char mode, const char *cmd) |
42 | { | 42 | { |
43 | if (!cpu_class_is_omap2()) | 43 | if (!cpu_class_is_omap2()) |
44 | omap1_arch_reset(mode); | 44 | omap1_arch_reset(mode); |
diff --git a/arch/arm/plat-s3c24xx/cpu.c b/arch/arm/plat-s3c24xx/cpu.c index 542062f8cbc1..1932b7e0da15 100644 --- a/arch/arm/plat-s3c24xx/cpu.c +++ b/arch/arm/plat-s3c24xx/cpu.c | |||
@@ -182,7 +182,7 @@ static unsigned long s3c24xx_read_idcode_v4(void) | |||
182 | * with the caches enabled. It seems at least the S3C2440 has a problem | 182 | * with the caches enabled. It seems at least the S3C2440 has a problem |
183 | * resetting if there is bus activity interrupted by the reset. | 183 | * resetting if there is bus activity interrupted by the reset. |
184 | */ | 184 | */ |
185 | static void s3c24xx_pm_restart(char mode) | 185 | static void s3c24xx_pm_restart(char mode, const char *cmd) |
186 | { | 186 | { |
187 | if (mode != 's') { | 187 | if (mode != 's') { |
188 | unsigned long flags; | 188 | unsigned long flags; |
@@ -191,12 +191,12 @@ static void s3c24xx_pm_restart(char mode) | |||
191 | __cpuc_flush_kern_all(); | 191 | __cpuc_flush_kern_all(); |
192 | __cpuc_flush_user_all(); | 192 | __cpuc_flush_user_all(); |
193 | 193 | ||
194 | arch_reset(mode); | 194 | arch_reset(mode, cmd); |
195 | local_irq_restore(flags); | 195 | local_irq_restore(flags); |
196 | } | 196 | } |
197 | 197 | ||
198 | /* fallback, or unhandled */ | 198 | /* fallback, or unhandled */ |
199 | arm_machine_restart(mode); | 199 | arm_machine_restart(mode, cmd); |
200 | } | 200 | } |
201 | 201 | ||
202 | void __init s3c24xx_init_io(struct map_desc *mach_desc, int size) | 202 | void __init s3c24xx_init_io(struct map_desc *mach_desc, int size) |