From: Breno Leitao <leitao@debian.org>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: bhe@redhat.com, linux-kernel@vger.kernel.org,
kernel-team@meta.com, kexec@lists.infradead.org,
dyoung@redhat.com, tony.luck@intel.com,
xueshuai@linux.alibaba.com, vgoyal@redhat.com,
zhiquan1.li@intel.com, olja@meta.com
Subject: Re: [PATCH] vmcore_info: expose hardware error recovery statistics via sysfs
Date: Fri, 30 Jan 2026 03:33:25 -0800 [thread overview]
Message-ID: <aXyVwEocs-uvd69T@gmail.com> (raw)
In-Reply-To: <20260129142801.50781220e3164742a6e21858@linux-foundation.org>
Hello Andrew,
On Thu, Jan 29, 2026 at 02:28:01PM -0800, Andrew Morton wrote:
> On Thu, 29 Jan 2026 05:34:10 -0800 Breno Leitao <leitao@debian.org> wrote:
>
> > Example output:
> > hwerr_recovery:
> > cpu: 0 (0)
> > memory: 2 (1738148257)
> > pci: 1 (1738147000)
> > cxl: 0 (0)
> > other: 0 (0)
>
> sysfs rules (which are widely ignored) say "one value per file".
>
> As a compromise the above could be squished into a single line. Harder
> for humans to read, but it sounds like that isn't the expected use case.
I'm fine with consolidating into a single line, though it would mean
removing the timestamp of the last recovery event. Since the primary
use case is tracking event counts in a time series, this is acceptable.
My proposal:
# cat /sys/kernel/hwerr_stats
cpu:0 memory:2 pci:1 cxl:0 other:0
I suggest keeping the field names rather than dropping them entirely.
While it would make the output more compact, having explicit names
makes the format more maintainable when adding new recovery types in
the future.
Without names, it would look like:
# cat /sys/kernel/hwerr_stats
0 2 1 0 0
What would you say?
Thanks for reviewing it,
--breno
next prev parent reply other threads:[~2026-01-30 11:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-29 13:34 [PATCH] vmcore_info: expose hardware error recovery statistics via sysfs Breno Leitao
2026-01-29 22:28 ` Andrew Morton
2026-01-30 11:33 ` Breno Leitao [this message]
2026-01-30 1:59 ` Baoquan He
2026-01-30 11:07 ` 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=aXyVwEocs-uvd69T@gmail.com \
--to=leitao@debian.org \
--cc=akpm@linux-foundation.org \
--cc=bhe@redhat.com \
--cc=dyoung@redhat.com \
--cc=kernel-team@meta.com \
--cc=kexec@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=olja@meta.com \
--cc=tony.luck@intel.com \
--cc=vgoyal@redhat.com \
--cc=xueshuai@linux.alibaba.com \
--cc=zhiquan1.li@intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox