Commit b71d47c1 authored by Jason Baron's avatar Jason Baron Committed by Ingo Molnar

powerpc: Clean up panic_timeout usage

Default CONFIG_PANIC_TIMEOUT to 180 seconds on powerpc. The
pSeries continue to set the timeout to 10 seconds at run-time.

Thus, there's a small window where we don't have the correct
value on pSeries, but if this is only run-time discoverable we
don't have a better option. In any case, if the user changes the
default setting of 180 seconds, we honor that user setting.
Signed-off-by: default avatarJason Baron <jbaron@akamai.com>
Cc: benh@kernel.crashing.org
Cc: paulus@samba.org
Cc: ralf@linux-mips.org
Cc: mpe@ellerman.id.au
Cc: felipe.contreras@gmail.com
Cc: linuxppc-dev@lists.ozlabs.org
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/705bbe0f70fb20759151642ba0176a6414ec9f7a.1385418410.git.jbaron@akamai.comSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
parent 7972e966
...@@ -147,6 +147,10 @@ config EARLY_PRINTK ...@@ -147,6 +147,10 @@ config EARLY_PRINTK
bool bool
default y default y
config PANIC_TIMEOUT
int
default 180
config COMPAT config COMPAT
bool bool
default y if PPC64 default y if PPC64
......
...@@ -26,6 +26,7 @@ extern void reloc_got2(unsigned long); ...@@ -26,6 +26,7 @@ extern void reloc_got2(unsigned long);
void check_for_initrd(void); void check_for_initrd(void);
void do_init_bootmem(void); void do_init_bootmem(void);
void setup_panic(void); void setup_panic(void);
#define ARCH_PANIC_TIMEOUT 180
#endif /* !__ASSEMBLY__ */ #endif /* !__ASSEMBLY__ */
......
...@@ -296,9 +296,6 @@ void __init setup_arch(char **cmdline_p) ...@@ -296,9 +296,6 @@ void __init setup_arch(char **cmdline_p)
if (cpu_has_feature(CPU_FTR_UNIFIED_ID_CACHE)) if (cpu_has_feature(CPU_FTR_UNIFIED_ID_CACHE))
ucache_bsize = icache_bsize = dcache_bsize; ucache_bsize = icache_bsize = dcache_bsize;
/* reboot on panic */
panic_timeout = 180;
if (ppc_md.panic) if (ppc_md.panic)
setup_panic(); setup_panic();
......
...@@ -588,9 +588,6 @@ void __init setup_arch(char **cmdline_p) ...@@ -588,9 +588,6 @@ void __init setup_arch(char **cmdline_p)
dcache_bsize = ppc64_caches.dline_size; dcache_bsize = ppc64_caches.dline_size;
icache_bsize = ppc64_caches.iline_size; icache_bsize = ppc64_caches.iline_size;
/* reboot on panic */
panic_timeout = 180;
if (ppc_md.panic) if (ppc_md.panic)
setup_panic(); setup_panic();
......
...@@ -470,7 +470,7 @@ static long pseries_little_endian_exceptions(void) ...@@ -470,7 +470,7 @@ static long pseries_little_endian_exceptions(void)
static void __init pSeries_setup_arch(void) static void __init pSeries_setup_arch(void)
{ {
panic_timeout = 10; set_arch_panic_timeout(10, ARCH_PANIC_TIMEOUT);
/* Discover PIC type and setup ppc_md accordingly */ /* Discover PIC type and setup ppc_md accordingly */
pseries_discover_pic(); pseries_discover_pic();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment