[V4 PATCH 0/2] kexec: crash_kexec_post_notifiers boot option related fixes

2016-08-10 Thread Hidehiro Kawai
for Problem 1 - Drop other patches because they aren't needed anymore V1: https://lkml.org/lkml/2015/7/10/316 --- Hidehiro Kawai (2): x86/panic: Replace smp_send_stop() with kdump friendly version in panic path mips/panic: Replace smp_send_stop() with kdump friendly version in panic

[V4 PATCH 0/2] kexec: crash_kexec_post_notifiers boot option related fixes

2016-08-10 Thread Hidehiro Kawai
for Problem 1 - Drop other patches because they aren't needed anymore V1: https://lkml.org/lkml/2015/7/10/316 --- Hidehiro Kawai (2): x86/panic: Replace smp_send_stop() with kdump friendly version in panic path mips/panic: Replace smp_send_stop() with kdump friendly version in panic

[V4 PATCH 2/2] mips/panic: Replace smp_send_stop() with kdump friendly version in panic path

2016-08-10 Thread Hidehiro Kawai
, and it just call smp_send_stop(). Architecture codes should override it so that kdump can work appropriately. This patch provides MIPS version. Reported-by: Daniel Walker <dwal...@fifo99.com> Fixes: f06e5153f4ae (kernel/panic.c: add "crash_kexec_post_notifiers" option) Signed-off-by

[V4 PATCH 2/2] mips/panic: Replace smp_send_stop() with kdump friendly version in panic path

2016-08-10 Thread Hidehiro Kawai
, and it just call smp_send_stop(). Architecture codes should override it so that kdump can work appropriately. This patch provides MIPS version. Reported-by: Daniel Walker Fixes: f06e5153f4ae (kernel/panic.c: add "crash_kexec_post_notifiers" option) Signed-off-by: Hidehiro Kawai Cc: Ralf B

[V4 PATCH 1/2] x86/panic: Replace smp_send_stop() with kdump friendly version in panic path

2016-08-10 Thread Hidehiro Kawai
Reported-by: Daniel Walker <dwal...@fifo99.com> Fixes: f06e5153f4ae (kernel/panic.c: add "crash_kexec_post_notifiers" option) Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Dave Young <dyo...@redhat.com> Cc: Baoquan He <b...@redhat.com> Cc: Vivek

[V4 PATCH 1/2] x86/panic: Replace smp_send_stop() with kdump friendly version in panic path

2016-08-10 Thread Hidehiro Kawai
Reported-by: Daniel Walker Fixes: f06e5153f4ae (kernel/panic.c: add "crash_kexec_post_notifiers" option) Signed-off-by: Hidehiro Kawai Cc: Dave Young Cc: Baoquan He Cc: Vivek Goyal Cc: Eric Biederman Cc: Masami Hiramatsu Cc: Daniel Walker Cc: Xunlei Pang Cc: Thomas Gleixner Cc: Ingo

[V3 PATCH 1/2] x86/panic: Replace smp_send_stop() with kdump friendly version

2016-07-05 Thread Hidehiro Kawai
smp_send_stop() call with crash_kexec version which saves cpu states and cleans up VMX/SVM - Drop a fix for Problem 1 at this moment Reported-by: Daniel Walker <dwal...@fifo99.com> Fixes: f06e5153f4ae (kernel/panic.c: add "crash_kexec_post_notifiers" option) Signed-off-by: Hidehiro Kawai

[V3 PATCH 1/2] x86/panic: Replace smp_send_stop() with kdump friendly version

2016-07-05 Thread Hidehiro Kawai
smp_send_stop() call with crash_kexec version which saves cpu states and cleans up VMX/SVM - Drop a fix for Problem 1 at this moment Reported-by: Daniel Walker Fixes: f06e5153f4ae (kernel/panic.c: add "crash_kexec_post_notifiers" option) Signed-off-by: Hidehiro Kawai Cc: Dave Young Cc: Baoq

[V3 PATCH 2/2] kexec: Use core_param for crash_kexec_post_notifiers boot option

2016-07-05 Thread Hidehiro Kawai
crash_kexec_post_notifiers ia a boot option which controls whether the 1st kernel calls panic notifiers or not before booting the 2nd kernel. However, there is no need to limit it to being modifiable only at boot time. So, use core_param instead of early_param. Signed-off-by: Hidehiro Kawai

[V3 PATCH 2/2] kexec: Use core_param for crash_kexec_post_notifiers boot option

2016-07-05 Thread Hidehiro Kawai
crash_kexec_post_notifiers ia a boot option which controls whether the 1st kernel calls panic notifiers or not before booting the 2nd kernel. However, there is no need to limit it to being modifiable only at boot time. So, use core_param instead of early_param. Signed-off-by: Hidehiro Kawai Cc

[V3 PATCH 0/2] kexec: crash_kexec_post_notifiers boot option related fixes

2016-07-05 Thread Hidehiro Kawai
- Replace smp_send_stop() call with crash_kexec version which saves cpu states and does cleanups instead of changing execution flow - Drop a fix for Problem 1 - Drop other patches because they aren't needed anymore V1: https://lkml.org/lkml/2015/7/10/316 --- Hidehiro Kawai (2): x86/panic

[V3 PATCH 0/2] kexec: crash_kexec_post_notifiers boot option related fixes

2016-07-05 Thread Hidehiro Kawai
- Replace smp_send_stop() call with crash_kexec version which saves cpu states and does cleanups instead of changing execution flow - Drop a fix for Problem 1 - Drop other patches because they aren't needed anymore V1: https://lkml.org/lkml/2015/7/10/316 --- Hidehiro Kawai (2): x86/panic

[v3 PATCH 1/3] panic: Change nmi_panic from macro to function

2016-03-03 Thread Hidehiro Kawai
Change nmi_panic() macro to a normal function for the portability. Also, export it for modules. Changes since v2: - Make nmi_panic receive a single string instead of printf style args Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundatio

[v3 PATCH 1/3] panic: Change nmi_panic from macro to function

2016-03-03 Thread Hidehiro Kawai
Change nmi_panic() macro to a normal function for the portability. Also, export it for modules. Changes since v2: - Make nmi_panic receive a single string instead of printf style args Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Borislav Petkov Cc: Michal Nazarewicz Cc: Michal Hocko

[v3 PATCH 2/3] ipmi/watchdog: Use nmi_panic() when kernel panics in NMI handler

2016-03-03 Thread Hidehiro Kawai
registers even if looping in NMI context"). ipmi_watchdog driver can call panic() from NMI handler, so replace it with nmi_panic(). Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Acked-by: Corey Minyard <cminy...@mvista.com> Acked-by: Guenter Roeck <li...@roeck-us.

[v3 PATCH 2/3] ipmi/watchdog: Use nmi_panic() when kernel panics in NMI handler

2016-03-03 Thread Hidehiro Kawai
registers even if looping in NMI context"). ipmi_watchdog driver can call panic() from NMI handler, so replace it with nmi_panic(). Signed-off-by: Hidehiro Kawai Acked-by: Corey Minyard Acked-by: Guenter Roeck Reviewed-by: Michal Hocko Cc: openipmi-develo...@lists.sourceforge.net --

[v3 PATCH 3/3] hpwdt: Use nmi_panic() when kernel panics in NMI handler

2016-03-03 Thread Hidehiro Kawai
registers even if looping in NMI context"). hpwdt driver can call panic() from NMI handler, so replace it with nmi_panic(). Also, do some cleanups. Changes since V1: - Use direct return instead of goto - Combine the panic message string into a single line Signed-off-by: Hidehiro Kawai <hidehi

[v3 PATCH 0/3] Use nmi_panic() in panic on NMI case

2016-03-03 Thread Hidehiro Kawai
this patch set, some NMI or similar handlers (e.g. MCE handler) remains to use panic(). This is because I can't test them well and actual problems won't happen. For example, the possibility that normal panic and panic on MCE happen simultaneously is very low. Hidehiro Kawai (3): panic: Change

[v3 PATCH 3/3] hpwdt: Use nmi_panic() when kernel panics in NMI handler

2016-03-03 Thread Hidehiro Kawai
registers even if looping in NMI context"). hpwdt driver can call panic() from NMI handler, so replace it with nmi_panic(). Also, do some cleanups. Changes since V1: - Use direct return instead of goto - Combine the panic message string into a single line Signed-off-by: Hidehiro Kawai Cc: T

[v3 PATCH 0/3] Use nmi_panic() in panic on NMI case

2016-03-03 Thread Hidehiro Kawai
this patch set, some NMI or similar handlers (e.g. MCE handler) remains to use panic(). This is because I can't test them well and actual problems won't happen. For example, the possibility that normal panic and panic on MCE happen simultaneously is very low. Hidehiro Kawai (3): panic: Change

[v2 PATCH 0/3] Use nmi_panic() in panic on NMI case

2016-03-02 Thread Hidehiro Kawai
roblems won't happen. For example, the possibility that normal panic and panic on MCE happen simultaneously is very low. Hidehiro Kawai (3): panic: Change nmi_panic from macro to function ipmi/watchdog: Use nmi_panic() when kernel panics in NMI handler hpwdt: Use nmi_panic() when

[v2 PATCH 0/3] Use nmi_panic() in panic on NMI case

2016-03-02 Thread Hidehiro Kawai
roblems won't happen. For example, the possibility that normal panic and panic on MCE happen simultaneously is very low. Hidehiro Kawai (3): panic: Change nmi_panic from macro to function ipmi/watchdog: Use nmi_panic() when kernel panics in NMI handler hpwdt: Use nmi_panic() when

[v2 PATCH 3/3] hpwdt: Use nmi_panic() when kernel panics in NMI handler

2016-03-02 Thread Hidehiro Kawai
registers even if looping in NMI context"). hpwdt driver can call panic() from NMI handler, so replace it with nmi_panic(). Also, do some cleanups. Changes since V1: - Use direct return instead of goto - Combine the panic message string into a single line Signed-off-by: Hidehiro Kawai <hidehi

[v2 PATCH 3/3] hpwdt: Use nmi_panic() when kernel panics in NMI handler

2016-03-02 Thread Hidehiro Kawai
registers even if looping in NMI context"). hpwdt driver can call panic() from NMI handler, so replace it with nmi_panic(). Also, do some cleanups. Changes since V1: - Use direct return instead of goto - Combine the panic message string into a single line Signed-off-by: Hidehiro Kawai Cc: T

[v2 PATCH 2/3] ipmi/watchdog: Use nmi_panic() when kernel panics in NMI handler

2016-03-02 Thread Hidehiro Kawai
registers even if looping in NMI context"). ipmi_watchdog driver can call panic() from NMI handler, so replace it with nmi_panic(). Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Acked-by: Corey Minyard <cminy...@mvista.com> Acked-by: Guenter Roeck <li...@roeck-us.

[v2 PATCH 2/3] ipmi/watchdog: Use nmi_panic() when kernel panics in NMI handler

2016-03-02 Thread Hidehiro Kawai
registers even if looping in NMI context"). ipmi_watchdog driver can call panic() from NMI handler, so replace it with nmi_panic(). Signed-off-by: Hidehiro Kawai Acked-by: Corey Minyard Acked-by: Guenter Roeck Reviewed-by: Michal Hocko Cc: openipmi-develo...@lists.sourceforge.net --

[v2 PATCH 1/3] panic: Change nmi_panic from macro to function

2016-03-02 Thread Hidehiro Kawai
Change nmi_panic() macro to a normal function for the portability. Also, export it for modules. Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org> Cc: Borislav Petkov <b...@suse.de> Cc: Michal Nazarewicz <min...@mina86.

[v2 PATCH 1/3] panic: Change nmi_panic from macro to function

2016-03-02 Thread Hidehiro Kawai
Change nmi_panic() macro to a normal function for the portability. Also, export it for modules. Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Borislav Petkov Cc: Michal Nazarewicz Cc: Michal Hocko Cc: Rasmus Villemoes Cc: Nicolas Iooss Cc: Javi Merino Cc: Gobinda Charan Maji Cc

[PATCH 0/3] Use nmi_panic() in panic on NMI case

2016-02-29 Thread Hidehiro Kawai
se I can't test them well and actual problems won't happen. For example, the possibility that normal panic and panic on MCE happen simultaneously is very low. Hidehiro Kawai (3): panic: Export panic_cpu and nmi_panic_self_stop ipmi/watchdog: Use nmi_panic() when kernel panics in NMI

[PATCH 1/3] panic: Export panic_cpu and nmi_panic_self_stop

2016-02-29 Thread Hidehiro Kawai
Export panic_cpu and nmi_panic_self_stop symbols for modules which use nmi_panic() macro. Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org> Cc: Borislav Petkov <b...@suse.de> Cc: Thomas Gleixner <t...@linutronix.de&g

[PATCH 0/3] Use nmi_panic() in panic on NMI case

2016-02-29 Thread Hidehiro Kawai
se I can't test them well and actual problems won't happen. For example, the possibility that normal panic and panic on MCE happen simultaneously is very low. Hidehiro Kawai (3): panic: Export panic_cpu and nmi_panic_self_stop ipmi/watchdog: Use nmi_panic() when kernel panics in NMI

[PATCH 1/3] panic: Export panic_cpu and nmi_panic_self_stop

2016-02-29 Thread Hidehiro Kawai
Export panic_cpu and nmi_panic_self_stop symbols for modules which use nmi_panic() macro. Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Borislav Petkov Cc: Thomas Gleixner Cc: Michal Hocko Cc: HATAYAMA Daisuke Cc: Vitaly Kuznetsov Cc: Tejun Heo --- kernel/panic.c |2 ++ 1 file

[PATCH 3/3] hpwdt: Use nmi_panic() when kernel panics in NMI handler

2016-02-29 Thread Hidehiro Kawai
so replace it with nmi_panic(). Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Thomas Mingarelli <thomas.mingare...@hpe.com> Cc: Wim Van Sebroeck <w...@iguana.be> Cc: Guenter Roeck <li...@roeck-us.net> Cc: linux-watch...@vger.kernel.org --- drivers/watchdog/h

[PATCH 3/3] hpwdt: Use nmi_panic() when kernel panics in NMI handler

2016-02-29 Thread Hidehiro Kawai
so replace it with nmi_panic(). Signed-off-by: Hidehiro Kawai Cc: Thomas Mingarelli Cc: Wim Van Sebroeck Cc: Guenter Roeck Cc: linux-watch...@vger.kernel.org --- drivers/watchdog/hpwdt.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/drivers/watchdog/hpwdt.c b/driver

[PATCH 2/3] ipmi/watchdog: Use nmi_panic() when kernel panics in NMI handler

2016-02-29 Thread Hidehiro Kawai
so replace it with nmi_panic(). Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Corey Minyard <miny...@acm.org> Cc: openipmi-develo...@lists.sourceforge.net --- drivers/char/ipmi/ipmi_watchdog.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --g

[PATCH 2/3] ipmi/watchdog: Use nmi_panic() when kernel panics in NMI handler

2016-02-29 Thread Hidehiro Kawai
so replace it with nmi_panic(). Signed-off-by: Hidehiro Kawai Cc: Corey Minyard Cc: openipmi-develo...@lists.sourceforge.net --- drivers/char/ipmi/ipmi_watchdog.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/char/ipmi/ipmi_watchdog.c b/drivers/char/ipmi/ipmi_

[tip:x86/apic] kexec: Fix race between panic() and crash_kexec()

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: 7bbee5ca3896f69f09c68be549cb8997abe6bca6 Gitweb: http://git.kernel.org/tip/7bbee5ca3896f69f09c68be549cb8997abe6bca6 Author: Hidehiro Kawai AuthorDate: Mon, 14 Dec 2015 11:19:11 +0100 Committer: Thomas Gleixner CommitDate: Sat, 19 Dec 2015 11:07:01 +0100 kexec: Fix race

[tip:x86/apic] panic, x86: Allow CPUs to save registers even if looping in NMI context

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: 58c5661f2144c089bbc2e5d87c9ec1dc1d2964fe Gitweb: http://git.kernel.org/tip/58c5661f2144c089bbc2e5d87c9ec1dc1d2964fe Author: Hidehiro Kawai AuthorDate: Mon, 14 Dec 2015 11:19:10 +0100 Committer: Thomas Gleixner CommitDate: Sat, 19 Dec 2015 11:07:01 +0100 panic, x86: Allow

[tip:x86/apic] x86/nmi: Save regs in crash dump on external NMI

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: b279d67df88a49c6ca32b3eebd195660254be394 Gitweb: http://git.kernel.org/tip/b279d67df88a49c6ca32b3eebd195660254be394 Author: Hidehiro Kawai AuthorDate: Mon, 14 Dec 2015 11:19:13 +0100 Committer: Thomas Gleixner CommitDate: Sat, 19 Dec 2015 11:07:01 +0100 x86/nmi: Save regs

[tip:x86/apic] Documentation: Document kernel.panic_on_io_nmi sysctl

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: 9f318e3fcb1d4c48c26e8ca2ff2a459b82f36a23 Gitweb: http://git.kernel.org/tip/9f318e3fcb1d4c48c26e8ca2ff2a459b82f36a23 Author: Hidehiro Kawai AuthorDate: Mon, 14 Dec 2015 11:19:14 +0100 Committer: Thomas Gleixner CommitDate: Sat, 19 Dec 2015 11:07:01 +0100 Documentation

[tip:x86/apic] x86/apic: Introduce apic_extnmi command line parameter

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: b7c4948e9881fb38b048269f376fb4bf194ce24a Gitweb: http://git.kernel.org/tip/b7c4948e9881fb38b048269f376fb4bf194ce24a Author: Hidehiro Kawai AuthorDate: Mon, 14 Dec 2015 11:19:12 +0100 Committer: Thomas Gleixner CommitDate: Sat, 19 Dec 2015 11:07:01 +0100 x86/apic: Introduce

[tip:x86/apic] panic, x86: Fix re-entrance problem due to panic on NMI

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: 1717f2096b543cede7a380c858c765c41936bc35 Gitweb: http://git.kernel.org/tip/1717f2096b543cede7a380c858c765c41936bc35 Author: Hidehiro Kawai AuthorDate: Mon, 14 Dec 2015 11:19:09 +0100 Committer: Thomas Gleixner CommitDate: Sat, 19 Dec 2015 11:07:00 +0100 panic, x86: Fix re

[tip:x86/apic] x86/apic: Introduce apic_extnmi command line parameter

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: b7c4948e9881fb38b048269f376fb4bf194ce24a Gitweb: http://git.kernel.org/tip/b7c4948e9881fb38b048269f376fb4bf194ce24a Author: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> AuthorDate: Mon, 14 Dec 2015 11:19:12 +0100 Committer: Thomas Gleixner <t...@linutronix.de>

[tip:x86/apic] panic, x86: Fix re-entrance problem due to panic on NMI

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: 1717f2096b543cede7a380c858c765c41936bc35 Gitweb: http://git.kernel.org/tip/1717f2096b543cede7a380c858c765c41936bc35 Author: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> AuthorDate: Mon, 14 Dec 2015 11:19:09 +0100 Committer: Thomas Gleixner <t...@linutronix.de>

[tip:x86/apic] x86/nmi: Save regs in crash dump on external NMI

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: b279d67df88a49c6ca32b3eebd195660254be394 Gitweb: http://git.kernel.org/tip/b279d67df88a49c6ca32b3eebd195660254be394 Author: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> AuthorDate: Mon, 14 Dec 2015 11:19:13 +0100 Committer: Thomas Gleixner <t...@linutronix.de>

[tip:x86/apic] Documentation: Document kernel.panic_on_io_nmi sysctl

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: 9f318e3fcb1d4c48c26e8ca2ff2a459b82f36a23 Gitweb: http://git.kernel.org/tip/9f318e3fcb1d4c48c26e8ca2ff2a459b82f36a23 Author: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> AuthorDate: Mon, 14 Dec 2015 11:19:14 +0100 Committer: Thomas Gleixner <t...@linutronix.de>

[tip:x86/apic] panic, x86: Allow CPUs to save registers even if looping in NMI context

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: 58c5661f2144c089bbc2e5d87c9ec1dc1d2964fe Gitweb: http://git.kernel.org/tip/58c5661f2144c089bbc2e5d87c9ec1dc1d2964fe Author: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> AuthorDate: Mon, 14 Dec 2015 11:19:10 +0100 Committer: Thomas Gleixner <t...@linutronix.de>

[tip:x86/apic] kexec: Fix race between panic() and crash_kexec()

2015-12-19 Thread tip-bot for Hidehiro Kawai
Commit-ID: 7bbee5ca3896f69f09c68be549cb8997abe6bca6 Gitweb: http://git.kernel.org/tip/7bbee5ca3896f69f09c68be549cb8997abe6bca6 Author: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> AuthorDate: Mon, 14 Dec 2015 11:19:11 +0100 Committer: Thomas Gleixner <t...@linutronix.de>

[V6.1 PATCH 5/6] x86/nmi: Fix to save registers for crash dump on external NMI broadcast

2015-12-09 Thread Hidehiro Kawai
egisters even if they are looping in NMI context' - Fix comments - Remove unneeded UP version of poll_crash_ipi_and_calback - Rename poll_crash_ipi_and_callback to run_crash_ipi_callback Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Pet

[V6 PATCH 1/6] panic/x86: Fix re-entrance problem due to panic on NMI

2015-12-09 Thread Hidehiro Kawai
of current spin_trylock() to exclude concurrent accesses to the panic routines - Don't introduce no-lock version of panic() Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Peter Zijlstra Cc: Michal Hocko --- arch/x86/ke

[V6 PATCH 2/6] panic/x86: Allow CPUs to save registers even if they are looping in NMI context

2015-12-09 Thread Hidehiro Kawai
V3: - Newly introduced Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Peter Zijlstra Cc: Eric Biederman Cc: Vivek Goyal Cc: Michal Hocko --- arch/x86/kernel/nmi.c|6 +++--- arch/x86/kernel/re

[V6 PATCH 6/6] Documentation: Add documentation for kernel.panic_on_io_nmi sysctl

2015-12-09 Thread Hidehiro Kawai
kernel.panic_on_io_nmi sysctl was introduced by commit 5211a242d0cb ("x86: Add sysctl to allow panic on IOCK NMI error"), but its documentation is missing. So, add it. V6: - Newly added Signed-off-by: Hidehiro Kawai Cc: Jonathan Corbet Cc: Andrew Morton --- Documentation/sysctl/

[V6 PATCH 4/6] x86/apic: Introduce apic_extnmi boot option

2015-12-09 Thread Hidehiro Kawai
mments - Change to use strncmp to parse the value of "apic_extnmi=" - Make apic_set_extnmi() return -EINVAL if the given value is invalid V5: - Rename the option from "noextnmi" to "apic_extnmi" - Add apic_extnmi=all feature - Fix the wrong documentation about "noextn

[V6 PATCH 5/6] x86/nmi: Fix to save registers for crash dump on external NMI broadcast

2015-12-09 Thread Hidehiro Kawai
_and_callback to run_crash_ipi_callback Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Peter Zijlstra Cc: Michal Hocko --- arch/x86/include/asm/reboot.h |1 + arch/x86/kernel/nmi.c | 11 ++- a

[V6 PATCH 3/6] kexec: Fix race between panic() and crash_kexec() called directly

2015-12-09 Thread Hidehiro Kawai
__crash_kexec(), no exclusion check version of crash_kexec(), instead of checking if panic_cpu is the current CPU or not V2: - Use atomic_cmpxchg() instead of spin_trylock() on panic_lock to exclude concurrent accesses - Don't introduce no-lock version of crash_kexec() Signed-off-by: Hidehiro Kawai

[V6 PATCH 0/6] Fix race issues among panic, NMI and crash_kexec

2015-12-09 Thread Hidehiro Kawai
eady panicked V2: https://lkml.org/lkml/2015/7/27/31 - Use atomic_cmpxchg() instead of current spin_trylock() to exclude concurrent accesses to panic() and crash_kexec() - Don't introduce no-lock version of panic() and crash_kexec() V1: https://lkml.org/lkml/2015/7/22/81 --- Hidehiro Kawai

[V6 PATCH 5/6] x86/nmi: Fix to save registers for crash dump on external NMI broadcast

2015-12-09 Thread Hidehiro Kawai
_and_callback to run_crash_ipi_callback Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org> Cc: Thomas Gleixner <t...@linutronix.de> Cc: Ingo Molnar <mi...@redhat.com> Cc: "H. Peter Anvin" <h...@zytor

[V6 PATCH 3/6] kexec: Fix race between panic() and crash_kexec() called directly

2015-12-09 Thread Hidehiro Kawai
__crash_kexec(), no exclusion check version of crash_kexec(), instead of checking if panic_cpu is the current CPU or not V2: - Use atomic_cmpxchg() instead of spin_trylock() on panic_lock to exclude concurrent accesses - Don't introduce no-lock version of crash_kexec() Signed-off-by: Hidehiro Kawai

[V6 PATCH 0/6] Fix race issues among panic, NMI and crash_kexec

2015-12-09 Thread Hidehiro Kawai
eady panicked V2: https://lkml.org/lkml/2015/7/27/31 - Use atomic_cmpxchg() instead of current spin_trylock() to exclude concurrent accesses to panic() and crash_kexec() - Don't introduce no-lock version of panic() and crash_kexec() V1: https://lkml.org/lkml/2015/7/22/81 --- Hidehiro Kawai

[V6 PATCH 4/6] x86/apic: Introduce apic_extnmi boot option

2015-12-09 Thread Hidehiro Kawai
mments - Change to use strncmp to parse the value of "apic_extnmi=" - Make apic_set_extnmi() return -EINVAL if the given value is invalid V5: - Rename the option from "noextnmi" to "apic_extnmi" - Add apic_extnmi=all feature - Fix the wrong documentation about

[V6 PATCH 6/6] Documentation: Add documentation for kernel.panic_on_io_nmi sysctl

2015-12-09 Thread Hidehiro Kawai
kernel.panic_on_io_nmi sysctl was introduced by commit 5211a242d0cb ("x86: Add sysctl to allow panic on IOCK NMI error"), but its documentation is missing. So, add it. V6: - Newly added Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Jonathan Corbet <cor...@

[V6 PATCH 2/6] panic/x86: Allow CPUs to save registers even if they are looping in NMI context

2015-12-09 Thread Hidehiro Kawai
V3: - Newly introduced Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org> Cc: Thomas Gleixner <t...@linutronix.de> Cc: Ingo Molnar <mi...@redhat.com> Cc: "H. Peter Anvin" <h...@zytor.com> Cc: Pet

[V6 PATCH 1/6] panic/x86: Fix re-entrance problem due to panic on NMI

2015-12-09 Thread Hidehiro Kawai
of current spin_trylock() to exclude concurrent accesses to the panic routines - Don't introduce no-lock version of panic() Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org> Cc: Thomas Gleixner <t...@linutronix.de> C

[V6.1 PATCH 5/6] x86/nmi: Fix to save registers for crash dump on external NMI broadcast

2015-12-09 Thread Hidehiro Kawai
egisters even if they are looping in NMI context' - Fix comments - Remove unneeded UP version of poll_crash_ipi_and_calback - Rename poll_crash_ipi_and_callback to run_crash_ipi_callback Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org&g

[V5 PATCH 1/4] panic/x86: Fix re-entrance problem due to panic on NMI

2015-11-20 Thread Hidehiro Kawai
no-lock version of panic() Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Peter Zijlstra Cc: Michal Hocko --- arch/x86/kernel/nmi.c | 16 include/linux/kernel.h | 13 + kernel/panic.c

[V5 PATCH 3/4] kexec: Fix race between panic() and crash_kexec() called directly

2015-11-20 Thread Hidehiro Kawai
is the current cpu or not V2: - Use atomic_cmpxchg() instead of spin_trylock() on panic_lock to exclude concurrent accesses - Don't introduce no-lock version of crash_kexec() Signed-off-by: Hidehiro Kawai Cc: Eric Biederman Cc: Vivek Goyal Cc: Andrew Morton Cc: Michal Hocko --- include/linux

[V5 PATCH 0/4] Fix race issues among panic, NMI and crash_kexec

2015-11-20 Thread Hidehiro Kawai
ylock() to exclude concurrent accesses to panic() and crash_kexec() - Don't introduce no-lock version of panic() and crash_kexec() V1: https://lkml.org/lkml/2015/7/22/81 --- Hidehiro Kawai (4): panic/x86: Fix re-entrance problem due to panic on NMI panic/x86: Allow cpus to save r

[V5 PATCH 2/4] panic/x86: Allow cpus to save registers even if they are looping in NMI context

2015-11-20 Thread Hidehiro Kawai
V5: - Use WRITE_ONCE() when setting crash_ipi_done to 1 so that the compiler doesn't change the instruction order - Support the case of b in the above description - Add poll_crash_ipi_and_callback() V4: - Rewrite the patch description V3: - Newly introduced Signed-off-by: Hidehiro Kawai Cc

[V5 PATCH 4/4] x86/apic: Introduce apic_extnmi boot option

2015-11-20 Thread Hidehiro Kawai
name the option from "noextnmi" to "apic_extnmi" - Add apic_extnmi=all feature - Fix the wrong documentation about "noextnmi" (apic_extnmi=none) Signed-off-by: Hidehiro Kawai Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Jonathan Corbet --- Docu

[V5 PATCH 0/4] Fix race issues among panic, NMI and crash_kexec

2015-11-20 Thread Hidehiro Kawai
ylock() to exclude concurrent accesses to panic() and crash_kexec() - Don't introduce no-lock version of panic() and crash_kexec() V1: https://lkml.org/lkml/2015/7/22/81 --- Hidehiro Kawai (4): panic/x86: Fix re-entrance problem due to panic on NMI panic/x86: Allow cpus to save r

[V5 PATCH 3/4] kexec: Fix race between panic() and crash_kexec() called directly

2015-11-20 Thread Hidehiro Kawai
is the current cpu or not V2: - Use atomic_cmpxchg() instead of spin_trylock() on panic_lock to exclude concurrent accesses - Don't introduce no-lock version of crash_kexec() Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Eric Biederman <ebied...@xmission.com> Cc:

[V5 PATCH 4/4] x86/apic: Introduce apic_extnmi boot option

2015-11-20 Thread Hidehiro Kawai
name the option from "noextnmi" to "apic_extnmi" - Add apic_extnmi=all feature - Fix the wrong documentation about "noextnmi" (apic_extnmi=none) Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Thomas Gleixner <t...@linutronix.de> Cc: Ingo Molnar <

[V5 PATCH 2/4] panic/x86: Allow cpus to save registers even if they are looping in NMI context

2015-11-20 Thread Hidehiro Kawai
V5: - Use WRITE_ONCE() when setting crash_ipi_done to 1 so that the compiler doesn't change the instruction order - Support the case of b in the above description - Add poll_crash_ipi_and_callback() V4: - Rewrite the patch description V3: - Newly introduced Signed-off-by: Hidehiro Kawai

[V5 PATCH 1/4] panic/x86: Fix re-entrance problem due to panic on NMI

2015-11-20 Thread Hidehiro Kawai
no-lock version of panic() Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org> Cc: Thomas Gleixner <t...@linutronix.de> Cc: Ingo Molnar <mi...@redhat.com> Cc: "H. Peter Anvin" <h...@zytor.com> Cc: Peter Zi

[V4 PATCH 1/4] panic/x86: Fix re-entrance problem due to panic on NMI

2015-09-25 Thread Hidehiro Kawai
no-lock version of panic() Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Peter Zijlstra Cc: Michal Hocko --- arch/x86/kernel/nmi.c | 16 include/linux/kernel.h | 13 + kernel/panic.c

[V4 PATCH 2/4] panic/x86: Allow cpus to save registers even if they are looping in NMI context

2015-09-25 Thread Hidehiro Kawai
: - Rewrite the patch description V3: - Newly introduced Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Peter Zijlstra Cc: Eric Biederman Cc: Vivek Goyal Cc: Michal Hocko --- arch/x86/kernel/nmi.c|6 +++---

[V4 PATCH 3/4] kexec: Fix race between panic() and crash_kexec() called directly

2015-09-25 Thread Hidehiro Kawai
(), instead of checking if panic_cpu is the current cpu or not V2: - Use atomic_cmpxchg() instead of spin_trylock() on panic_lock to exclude concurrent accesses - Don't introduce no-lock version of crash_kexec() Signed-off-by: Hidehiro Kawai Cc: Eric Biederman Cc: Vivek Goyal Cc: Andrew Morton Cc

[V4 PATCH 4/4] x86/apic: Introduce noextnmi boot option

2015-09-25 Thread Hidehiro Kawai
This patch introduces new boot option "noextnmi" which disables external NMI. This option is useful for the dump capture kernel so that an HA application or administrator wouldn't mistakenly shoot down the kernel by NMI. Currently, only x86 supports this option. Signed-off-by: Hide

[V4 PATCH 0/4] Fix race issues among panic, NMI and crash_kexec

2015-09-25 Thread Hidehiro Kawai
ic_cmpxchg() instead of current spin_trylock() to exclude concurrent accesses to panic() and crash_kexec() - Don't introduce no-lock version of panic() and crash_kexec() V1: https://lkml.org/lkml/2015/7/22/81 --- Hidehiro Kawai (4): panic/x86: Fix re-entrance problem due to panic on NMI

[V4 PATCH 1/4] panic/x86: Fix re-entrance problem due to panic on NMI

2015-09-25 Thread Hidehiro Kawai
no-lock version of panic() Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org> Cc: Thomas Gleixner <t...@linutronix.de> Cc: Ingo Molnar <mi...@redhat.com> Cc: "H. Peter Anvin" <h...@zytor.com> Cc: Peter Zi

[V4 PATCH 3/4] kexec: Fix race between panic() and crash_kexec() called directly

2015-09-25 Thread Hidehiro Kawai
(), instead of checking if panic_cpu is the current cpu or not V2: - Use atomic_cmpxchg() instead of spin_trylock() on panic_lock to exclude concurrent accesses - Don't introduce no-lock version of crash_kexec() Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Eric Biederman

[V4 PATCH 4/4] x86/apic: Introduce noextnmi boot option

2015-09-25 Thread Hidehiro Kawai
This patch introduces new boot option "noextnmi" which disables external NMI. This option is useful for the dump capture kernel so that an HA application or administrator wouldn't mistakenly shoot down the kernel by NMI. Currently, only x86 supports this option. Signed-off-by: Hide

[V4 PATCH 0/4] Fix race issues among panic, NMI and crash_kexec

2015-09-25 Thread Hidehiro Kawai
ic_cmpxchg() instead of current spin_trylock() to exclude concurrent accesses to panic() and crash_kexec() - Don't introduce no-lock version of panic() and crash_kexec() V1: https://lkml.org/lkml/2015/7/22/81 --- Hidehiro Kawai (4): panic/x86: Fix re-entrance problem due to panic on NMI

[V4 PATCH 2/4] panic/x86: Allow cpus to save registers even if they are looping in NMI context

2015-09-25 Thread Hidehiro Kawai
: - Rewrite the patch description V3: - Newly introduced Signed-off-by: Hidehiro Kawai <hidehiro.kawai...@hitachi.com> Cc: Andrew Morton <a...@linux-foundation.org> Cc: Thomas Gleixner <t...@linutronix.de> Cc: Ingo Molnar <mi...@redhat.com> Cc: "H. Peter Anvin" &

[V3 PATCH 1/4] panic/x86: Fix re-entrance problem due to panic on NMI

2015-08-05 Thread Hidehiro Kawai
duplication - In the case of panic on NMI, don't return from NMI handlers if another cpu already panicked V2: - Use atomic_cmpxchg() instead of current spin_trylock() to exclude concurrent accesses to the panic routines - Don't introduce no-lock version of panic() Signed-off-by: Hidehiro Kawai

[V3 PATCH 0/4] Fix race issues among panic, NMI and crash_kexec

2015-08-05 Thread Hidehiro Kawai
to exclude concurrent accesses to panic() and crash_kexec() - Don't introduce no-lock version of panic() and crash_kexec() --- Hidehiro Kawai (4): panic/x86: Fix re-entrance problem due to panic on NMI panic/x86: Allow cpus to save registers even if they are looping in NMI context

[V3 PATCH 3/4] kexec: Fix race between panic() and crash_kexec() called directly

2015-08-05 Thread Hidehiro Kawai
concurrent accesses - Don't introduce no-lock version of crash_kexec() Signed-off-by: Hidehiro Kawai Cc: Eric Biederman Cc: Vivek Goyal Cc: Andrew Morton Cc: Michal Hocko --- kernel/kexec.c | 20 1 file changed, 20 insertions(+) diff --git a/kernel/kexec.c b/kernel

[V3 PATCH 2/4] panic/x86: Allow cpus to save registers even if they are looping in NMI context

2015-08-05 Thread Hidehiro Kawai
thie issue, we wait for the timing of the NMI IPI, then call the NMI handler which saves register states. V3: - Newly introduced Signed-off-by: Hidehiro Kawai Cc: Andrew Morton Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: Peter Zijlstra Cc: Eric Biederman Cc: V

[V3 PATCH 4/4] x86/apic: Introduce noextnmi boot option

2015-08-05 Thread Hidehiro Kawai
This patch introduces new boot option "noextnmi" which disables external NMI. This option is useful for the dump capture kernel so that an HA application or administrator wouldn't mistakenly shoot down the kernel by NMI. Currently, only x86 supports this option. Signed-off-by: Hide

[V3 PATCH 2/4] panic/x86: Allow cpus to save registers even if they are looping in NMI context

2015-08-05 Thread Hidehiro Kawai
thie issue, we wait for the timing of the NMI IPI, then call the NMI handler which saves register states. V3: - Newly introduced Signed-off-by: Hidehiro Kawai hidehiro.kawai...@hitachi.com Cc: Andrew Morton a...@linux-foundation.org Cc: Thomas Gleixner t...@linutronix.de Cc: Ingo Molnar mi

[V3 PATCH 4/4] x86/apic: Introduce noextnmi boot option

2015-08-05 Thread Hidehiro Kawai
This patch introduces new boot option noextnmi which disables external NMI. This option is useful for the dump capture kernel so that an HA application or administrator wouldn't mistakenly shoot down the kernel by NMI. Currently, only x86 supports this option. Signed-off-by: Hidehiro Kawai

[V3 PATCH 3/4] kexec: Fix race between panic() and crash_kexec() called directly

2015-08-05 Thread Hidehiro Kawai
to exclude concurrent accesses - Don't introduce no-lock version of crash_kexec() Signed-off-by: Hidehiro Kawai hidehiro.kawai...@hitachi.com Cc: Eric Biederman ebied...@xmission.com Cc: Vivek Goyal vgo...@redhat.com Cc: Andrew Morton a...@linux-foundation.org Cc: Michal Hocko mho...@kernel.org --- kernel

[V3 PATCH 1/4] panic/x86: Fix re-entrance problem due to panic on NMI

2015-08-05 Thread Hidehiro Kawai
duplication - In the case of panic on NMI, don't return from NMI handlers if another cpu already panicked V2: - Use atomic_cmpxchg() instead of current spin_trylock() to exclude concurrent accesses to the panic routines - Don't introduce no-lock version of panic() Signed-off-by: Hidehiro Kawai

[V3 PATCH 0/4] Fix race issues among panic, NMI and crash_kexec

2015-08-05 Thread Hidehiro Kawai
concurrent accesses to panic() and crash_kexec() - Don't introduce no-lock version of panic() and crash_kexec() --- Hidehiro Kawai (4): panic/x86: Fix re-entrance problem due to panic on NMI panic/x86: Allow cpus to save registers even if they are looping in NMI context kexec: Fix

Re: [RFC V2 PATCH 0/1] kexec: crash_kexec_post_notifiers boot option related fixes

2015-08-03 Thread Hidehiro Kawai
Hello Eric and Vivek, Do you have any comments? (2015/07/24 10:16), Hidehiro Kawai wrote: > This is a bugfix patch for crash_kexec_post_notifiers boot option > which allows users to call panic notifiers and kmsg dumpers before > kdump. > > This fixes one of the problems rep

Re: [RFC V2 PATCH 0/1] kexec: crash_kexec_post_notifiers boot option related fixes

2015-08-03 Thread Hidehiro Kawai
Hello Eric and Vivek, Do you have any comments? (2015/07/24 10:16), Hidehiro Kawai wrote: This is a bugfix patch for crash_kexec_post_notifiers boot option which allows users to call panic notifiers and kmsg dumpers before kdump. This fixes one of the problems reported by Daniel Walker

Re: [V2 PATCH 2/3] kexec: Fix race between panic() and crash_kexec() called directly

2015-07-27 Thread Hidehiro Kawai
Hi, (2015/07/27 23:55), Michal Hocko wrote: > On Mon 27-07-15 10:58:50, Hidehiro Kawai wrote: > [...] >> @@ -1472,6 +1472,18 @@ void __weak crash_unmap_reserved_pages(void) >> >> void crash_kexec(struct pt_regs *regs) >> { >> +int old_cpu, this_cpu;

Re: [V2 PATCH 1/3] x86/panic: Fix re-entrance problem due to panic on NMI

2015-07-27 Thread Hidehiro Kawai
Hi, Thanks for the review. (2015/07/27 23:34), Michal Hocko wrote: > On Mon 27-07-15 10:58:50, Hidehiro Kawai wrote: > [...] >> diff --git a/arch/x86/kernel/nmi.c b/arch/x86/kernel/nmi.c >> index d05bd2e..5b32d81 100644 >> --- a/arch/x86/kernel/nmi.c >> +++ b/arch

[PATCH 2/7] ipmi: Factor out message flushing procedure

2015-07-27 Thread Hidehiro Kawai
Factor out message flushing procedure which is used in run-to-completion mode. This patch doesn't change the logic. Signed-off-by: Hidehiro Kawai --- drivers/char/ipmi/ipmi_si_intf.c | 39 ++ 1 file changed, 18 insertions(+), 21 deletions(-) diff --git

[PATCH 1/7] ipmi: Remove unneeded set_run_to_completion call

2015-07-27 Thread Hidehiro Kawai
send_panic_events() calls intf->handlers->set_run_to_completion(), but it has already been done in the caller function panic_event(). Remove it from send_panic_events(). Signed-off-by: Hidehiro Kawai --- drivers/char/ipmi/ipmi_msghandler.c |2 -- 1 file changed, 2 deletions(-) diff

  1   2   3   >