All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bagas Sanjaya <bagasdotme@gmail.com>
To: Randy Dunlap <rdunlap@infradead.org>,
	Jonathan Corbet <corbet@lwn.net>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux Documentation <linux-doc@vger.kernel.org>,
	Linux Serial <linux-serial@vger.kernel.org>
Cc: "Cengiz Can" <cengiz@kernel.wtf>,
	"Tomas Mudrunka" <tomas.mudrunka@gmail.com>,
	"Jiri Slaby" <jirislaby@kernel.org>,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	"Anselm Schüler" <mail@anselmschueler.com>
Subject: Re: [PATCH] Documentation: sysrq: Remove contradicting sentence on extra /proc/sysrq-trigger characters
Date: Wed, 15 Oct 2025 07:11:09 +0700	[thread overview]
Message-ID: <aO7mnXCajeIdUYON@archie.me> (raw)
In-Reply-To: <d6cd375c-dad6-4047-9574-bac7dfc24315@infradead.org>

[-- Attachment #1: Type: text/plain, Size: 2368 bytes --]

On Tue, Oct 14, 2025 at 10:57:45AM -0700, Randy Dunlap wrote:
> 
> 
> On 10/14/25 7:55 AM, Jonathan Corbet wrote:
> > Bagas Sanjaya <bagasdotme@gmail.com> writes:
> > 
> >> /proc/sysrq-trigger documentation states that only first character is
> >> processed and the rest is ignored, yet it is not recommended to write
> >> any extra characters to it. The latter statement is contradictive as
> >> these characters are also ignored as implied by preceding sentence.
> >>
> >> Remove it.
> >>
> >> Link: https://lore.kernel.org/lkml/7ca05672-dc20-413f-a923-f77ce0a9d307@anselmschueler.com/
> >> Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com>
> >> ---
> >>  Documentation/admin-guide/sysrq.rst | 4 +---
> >>  1 file changed, 1 insertion(+), 3 deletions(-)
> >>
> >> diff --git a/Documentation/admin-guide/sysrq.rst b/Documentation/admin-guide/sysrq.rst
> >> index 9c7aa817adc72d..63ff415ce85d66 100644
> >> --- a/Documentation/admin-guide/sysrq.rst
> >> +++ b/Documentation/admin-guide/sysrq.rst
> >> @@ -77,9 +77,7 @@ On other
> >>  On all
> >>  	Write a single character to /proc/sysrq-trigger.
> >>  	Only the first character is processed, the rest of the string is
> >> -	ignored. However, it is not recommended to write any extra characters
> >> -	as the behavior is undefined and might change in the future versions.
> >> -	E.g.::
> >> +	ignored. E.g.::
> > 
> > I'm not sure this is right - there is a warning here that additional
> > characters may acquire a meaning in the future, so one should not
> > develop the habit of writing them now.  After all these years, I think
> > the chances of fundamental sysrq changes are pretty small, but I still
> > don't see why we would take the warning out?
> 
> but the following paragraph says:
> 
> 	Alternatively, write multiple characters prepended by underscore.
> 	This way, all characters will be processed. E.g.::
> 
> 		echo _reisub > /proc/sysrq-trigger
> 
> so it is confuzing.

I guess the whole "On all" description can be rewritten like:

Write a single character to /proc/sysrq-trigger, e.g.::

<snipped>...

If a string (multiple characters) is written instead, only the first character
is processed unless the string is prepended by an underscore, like::

<snipped>...

Thanks.

-- 
An old man doll... just what I always wanted! - Clara

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  reply	other threads:[~2025-10-15  0:11 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-08 11:24 [PATCH] Documentation: sysrq: Remove contradicting sentence on extra /proc/sysrq-trigger characters Bagas Sanjaya
2025-10-09  2:18 ` Randy Dunlap
2025-10-14 14:55 ` Jonathan Corbet
2025-10-14 17:57   ` Randy Dunlap
2025-10-15  0:11     ` Bagas Sanjaya [this message]
2025-10-15  6:18       ` Jiri Slaby
2025-10-15  9:39         ` Bagas Sanjaya
2025-10-16 10:17   ` Tomas Mudrunka
2025-10-16 10:47     ` Bagas Sanjaya
2025-10-16 18:51     ` Randy Dunlap

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aO7mnXCajeIdUYON@archie.me \
    --to=bagasdotme@gmail.com \
    --cc=cengiz@kernel.wtf \
    --cc=corbet@lwn.net \
    --cc=gregkh@linuxfoundation.org \
    --cc=jirislaby@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=mail@anselmschueler.com \
    --cc=rdunlap@infradead.org \
    --cc=tomas.mudrunka@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.