From: Jakub Kicinski <kuba@kernel.org>
To: Breno Leitao <leitao@debian.org>
Cc: "David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>, Jonathan Corbet <corbet@lwn.net>,
sergey.senozhatsky@gmail.com, pmladek@suse.com, tj@kernel.org,
stephen@networkplumber.org, Dave Jones <davej@codemonkey.org.uk>,
netdev@vger.kernel.org (open list:NETWORKING [GENERAL]),
linux-doc@vger.kernel.org (open list:DOCUMENTATION),
linux-kernel@vger.kernel.org (open list)
Subject: Re: [PATCH v2] netconsole: Append kernel version to message
Date: Fri, 7 Jul 2023 16:10:50 -0700 [thread overview]
Message-ID: <20230707161050.61ec46a8@kernel.org> (raw)
In-Reply-To: <20230707132911.2033870-1-leitao@debian.org>
On Fri, 7 Jul 2023 06:29:11 -0700 Breno Leitao wrote:
> Create a new netconsole runtime option that prepends the kernel version in
> the netconsole message. This is useful to map kernel messages to kernel
> version in a simple way, i.e., without checking somewhere which kernel
> version the host that sent the message is using.
>
> If this option is selected, then the "<release>," is prepended before the
> netconsole message. This is an example of a netconsole output, with
> release feature enabled:
>
> 6.4.0-01762-ga1ba2ffe946e;12,426,112883998,-;this is a test
>
> Calvin Owens send a RFC about this problem in 2016[1], but his
> approach was a bit more intrusive, changing the printk subsystem. This
> approach is lighter, and just append the information in the last mile,
> just before netconsole push the message to netpoll.
>
> [1] Link: https://lore.kernel.org/all/51047c0f6e86abcb9ee13f60653b6946f8fcfc99.1463172791.git.calvinowens@fb.com/
>
> Cc: Dave Jones <davej@codemonkey.org.uk>
> Signed-off-by: Breno Leitao <leitao@debian.org>
Looks good! net-next is closed for the duration of the merge window
so you'll need to repost next week, and please put [PATCH net-next v3]
as the subject prefix while at it.
> @@ -332,6 +350,11 @@ static ssize_t enabled_store(struct config_item *item,
> }
>
> if (enabled) { /* true */
> + if (nt->release && !nt->extended) {
> + pr_err("release feature requires extended log message\n");
> + goto out_unlock;
> + }
This is the only bit that gave me pause - when parsing the command line
you ignore release if extended is not set (with an error/warning).
Does it make sense to be consistent and do the same thing here?
Or enabling at runtime is fundamentally different?
next prev parent reply other threads:[~2023-07-07 23:10 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-07 13:29 [PATCH v2] netconsole: Append kernel version to message Breno Leitao
2023-07-07 23:10 ` Jakub Kicinski [this message]
2023-07-10 8:49 ` Breno Leitao
2023-07-14 11:41 ` Petr Mladek
2023-07-14 13:49 ` Breno Leitao
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=20230707161050.61ec46a8@kernel.org \
--to=kuba@kernel.org \
--cc=corbet@lwn.net \
--cc=davej@codemonkey.org.uk \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=leitao@debian.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=pmladek@suse.com \
--cc=sergey.senozhatsky@gmail.com \
--cc=stephen@networkplumber.org \
--cc=tj@kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).