public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1] Fix documentation of panic_on_warn
@ 2023-06-30 14:53 Olaf Hering
  2023-06-30 21:58 ` Randy Dunlap
  2023-07-03 14:36 ` Jonathan Corbet
  0 siblings, 2 replies; 3+ messages in thread
From: Olaf Hering @ 2023-06-30 14:53 UTC (permalink / raw)
  To: Jonathan Corbet, Paul E. McKenney, Andrew Morton, Randy Dunlap,
	Catalin Marinas, Steven Rostedt (Google), Kim Phillips,
	Wyes Karny, Tiezhu Yang, Prarit Bhargava, Yasuaki Ishimatsu,
	linux-doc, linux-kernel, rcu, linux-kselftest
  Cc: Josh Triplett, Mathieu Desnoyers, Lai Jiangshan, Shuah Khan

The kernel cmdline option panic_on_warn expects an integer, it is not a
plain option as documented. A number of uses in the tree figured this
already, and use panic_on_warn=1 for their purpose.

Adjust a comment which otherwise may mislead people in the future.

Fixes: 9e3961a097 ("kernel: add panic_on_warn")

Signed-off-by: Olaf Hering <olaf@aepfle.de>
---
 Documentation/admin-guide/kernel-parameters.txt | 2 +-
 tools/testing/selftests/rcutorture/bin/kvm.sh   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index 9e5bab29685f..15196f84df49 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -4049,7 +4049,7 @@
 			extra details on the taint flags that users can pick
 			to compose the bitmask to assign to panic_on_taint.
 
-	panic_on_warn	panic() instead of WARN().  Useful to cause kdump
+	panic_on_warn=1	panic() instead of WARN().  Useful to cause kdump
 			on a WARN().
 
 	parkbd.port=	[HW] Parallel port number the keyboard adapter is
diff --git a/tools/testing/selftests/rcutorture/bin/kvm.sh b/tools/testing/selftests/rcutorture/bin/kvm.sh
index 62f3b0f56e4d..d3cdc2d33d4b 100755
--- a/tools/testing/selftests/rcutorture/bin/kvm.sh
+++ b/tools/testing/selftests/rcutorture/bin/kvm.sh
@@ -655,4 +655,4 @@ fi
 # Control buffer size: --bootargs trace_buf_size=3k
 # Get trace-buffer dumps on all oopses: --bootargs ftrace_dump_on_oops
 # Ditto, but dump only the oopsing CPU: --bootargs ftrace_dump_on_oops=orig_cpu
-# Heavy-handed way to also dump on warnings: --bootargs panic_on_warn
+# Heavy-handed way to also dump on warnings: --bootargs panic_on_warn=1

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH v1] Fix documentation of panic_on_warn
  2023-06-30 14:53 [PATCH v1] Fix documentation of panic_on_warn Olaf Hering
@ 2023-06-30 21:58 ` Randy Dunlap
  2023-07-03 14:36 ` Jonathan Corbet
  1 sibling, 0 replies; 3+ messages in thread
From: Randy Dunlap @ 2023-06-30 21:58 UTC (permalink / raw)
  To: Olaf Hering, Jonathan Corbet, Paul E. McKenney, Andrew Morton,
	Catalin Marinas, Steven Rostedt (Google), Kim Phillips,
	Wyes Karny, Tiezhu Yang, Prarit Bhargava, Yasuaki Ishimatsu,
	linux-doc, linux-kernel, rcu, linux-kselftest
  Cc: Josh Triplett, Mathieu Desnoyers, Lai Jiangshan, Shuah Khan

Hi Olaf,

On 6/30/23 07:53, Olaf Hering wrote:
> The kernel cmdline option panic_on_warn expects an integer, it is not a
> plain option as documented. A number of uses in the tree figured this
> already, and use panic_on_warn=1 for their purpose.
> 
> Adjust a comment which otherwise may mislead people in the future.
> 
> Fixes: 9e3961a097 ("kernel: add panic_on_warn")
> 
> Signed-off-by: Olaf Hering <olaf@aepfle.de>
> ---
>  Documentation/admin-guide/kernel-parameters.txt | 2 +-
>  tools/testing/selftests/rcutorture/bin/kvm.sh   | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
> index 9e5bab29685f..15196f84df49 100644
> --- a/Documentation/admin-guide/kernel-parameters.txt
> +++ b/Documentation/admin-guide/kernel-parameters.txt
> @@ -4049,7 +4049,7 @@
>  			extra details on the taint flags that users can pick
>  			to compose the bitmask to assign to panic_on_taint.
>  
> -	panic_on_warn	panic() instead of WARN().  Useful to cause kdump
> +	panic_on_warn=1	panic() instead of WARN().  Useful to cause kdump
>  			on a WARN().
>  

It's declared as an int instead of a boolean, but it's only tested for 0 or
non-0.

In any case, this update needs to be done. Thanks.

Reviewed-by: Randy Dunlap <rdunlap@infradead.org>

>  	parkbd.port=	[HW] Parallel port number the keyboard adapter is
> diff --git a/tools/testing/selftests/rcutorture/bin/kvm.sh b/tools/testing/selftests/rcutorture/bin/kvm.sh
> index 62f3b0f56e4d..d3cdc2d33d4b 100755
> --- a/tools/testing/selftests/rcutorture/bin/kvm.sh
> +++ b/tools/testing/selftests/rcutorture/bin/kvm.sh
> @@ -655,4 +655,4 @@ fi
>  # Control buffer size: --bootargs trace_buf_size=3k
>  # Get trace-buffer dumps on all oopses: --bootargs ftrace_dump_on_oops
>  # Ditto, but dump only the oopsing CPU: --bootargs ftrace_dump_on_oops=orig_cpu
> -# Heavy-handed way to also dump on warnings: --bootargs panic_on_warn
> +# Heavy-handed way to also dump on warnings: --bootargs panic_on_warn=1

-- 
~Randy

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v1] Fix documentation of panic_on_warn
  2023-06-30 14:53 [PATCH v1] Fix documentation of panic_on_warn Olaf Hering
  2023-06-30 21:58 ` Randy Dunlap
@ 2023-07-03 14:36 ` Jonathan Corbet
  1 sibling, 0 replies; 3+ messages in thread
From: Jonathan Corbet @ 2023-07-03 14:36 UTC (permalink / raw)
  To: Olaf Hering, Paul E. McKenney, Andrew Morton, Randy Dunlap,
	Catalin Marinas, Steven Rostedt (Google), Kim Phillips,
	Wyes Karny, Tiezhu Yang, Prarit Bhargava, Yasuaki Ishimatsu,
	linux-doc, linux-kernel, rcu, linux-kselftest
  Cc: Josh Triplett, Mathieu Desnoyers, Lai Jiangshan, Shuah Khan

Olaf Hering <olaf@aepfle.de> writes:

> The kernel cmdline option panic_on_warn expects an integer, it is not a
> plain option as documented. A number of uses in the tree figured this
> already, and use panic_on_warn=1 for their purpose.
>
> Adjust a comment which otherwise may mislead people in the future.
>
> Fixes: 9e3961a097 ("kernel: add panic_on_warn")
>
> Signed-off-by: Olaf Hering <olaf@aepfle.de>
> ---
>  Documentation/admin-guide/kernel-parameters.txt | 2 +-
>  tools/testing/selftests/rcutorture/bin/kvm.sh   | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
> index 9e5bab29685f..15196f84df49 100644
> --- a/Documentation/admin-guide/kernel-parameters.txt
> +++ b/Documentation/admin-guide/kernel-parameters.txt
> @@ -4049,7 +4049,7 @@
>  			extra details on the taint flags that users can pick
>  			to compose the bitmask to assign to panic_on_taint.
>  
> -	panic_on_warn	panic() instead of WARN().  Useful to cause kdump
> +	panic_on_warn=1	panic() instead of WARN().  Useful to cause kdump
>  			on a WARN().

Applied, thanks.

jon

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-07-03 14:36 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-06-30 14:53 [PATCH v1] Fix documentation of panic_on_warn Olaf Hering
2023-06-30 21:58 ` Randy Dunlap
2023-07-03 14:36 ` Jonathan Corbet

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox