From: Pasha Tatashin <pasha.tatashin@soleen.com>
To: "Michał Cłapiński" <mclapinski@google.com>
Cc: Tony Luck <tony.luck@intel.com>,
Pasha Tatashin <pasha.tatashin@soleen.com>,
Kees Cook <kees@kernel.org>,
kexec@lists.infradead.org, linux-kernel@vger.kernel.org,
Alexander Graf <graf@amazon.com>, Mike Rapoport <rppt@kernel.org>,
Pratyush Yadav <pratyush@kernel.org>
Subject: Re: [PATCH v2] pstore: add a KHO backend
Date: Fri, 12 Jun 2026 18:51:43 +0000 [thread overview]
Message-ID: <aixVD7vyjAcJBZDB@plex> (raw)
In-Reply-To: <CAAi7L5fZTvhb5np=xGWnDEmr4bNXqoAcMhR_ePZ4Qga4E-KucQ@mail.gmail.com>
On 06-12 20:49, Michał Cłapiński wrote:
> On Fri, Jun 12, 2026 at 8:38 PM Pasha Tatashin
> <pasha.tatashin@soleen.com> wrote:
> >
> > On 06-12 19:57, Michał Cłapiński wrote:
> > > On Fri, Jun 12, 2026 at 7:21 PM Pasha Tatashin
> > > <pasha.tatashin@soleen.com> wrote:
> > > >
> > > > On 06-12 17:42, Mike Rapoport wrote:
> > > > > Hi,
> > > > >
> > > > > On Fri, Jun 05, 2026 at 02:10:40PM +0200, Michal Clapinski wrote:
> > > > > > Up to this point to preserve late shutdown logs in memory, users had to
> > > > > > predefine a memory region using ramoops. This commit changes this by
> > > > > > preserving a buffer using kexec-handover.
> > > > > >
> > > > > > pstore_kho supports preserving only 1 dmesg buffer.
> > > > > > It gets replaced with the new buffer on every kexec, so the user has to
> > > > > > copy the file out of pstore after every kexec.
> > > > > > There is no erase() support.
> > > > >
> > > > > Sorry I didn't jump at v1.
> > > > >
> > > > > pstore does not really need a KHO backend. It can use ram backend with
> > > > > reserve_mem and reserve_mem can be preserved with KHO already.
> > > >
> > > > I just tested it, and it works well, I think it would be fine for
> > > > Google's requirements:
> > > >
> > > > CONFIG_PSTORE=y
> > > > CONFIG_PSTORE_RAM=y
> > > > CONFIG_PSTORE_CONSOLE=y
> > >
> > > Is it common to write to this console? I think what I typically see in
> > > the console are error logs that are also in dmesg, so if I preserve
> > > console logs and dmesg I just have 2 files where one is a subset of
> > > lines from the other.
> >
> > We need either your KHO backend, or the following patch:
> > https://lore.kernel.org/all/20260612172623.1218280-1-pasha.tatashin@soleen.com/
> >
> > We need all dmesg messages.
>
> We get all of the dmesg messages if you compile with
>
> CONFIG_PSTORE=y
> CONFIG_PSTORE_RAM=y
Ah awesome, thanks! My patch is not needed, I will reply to it.
Pasha
>
> and the cmdline:
> reserve_mem=2M:2M:dmesg_buffer ramoops.mem_name=dmesg_buffer
> ramoops.max_reason=5 ramoops.console_size=0
> ramoops.record_size=2097152 ramoops.ftrace_size=0 ramoops.pmsg_size=0
> (the diff between yours and mine is I set console_size to 0 and
> record_size to 2M, you do it the other way round).
>
> Dmesg is kept in "record_size". We don't need to preserve the console
> at all (unless there is something in console that isn't in dmesg but
> I've never seen that).
>
> > >
> > > > With the following parameters:
> > > > 'reserve_mem=2M:2M:dmesg_buffer ramoops.mem_name=dmesg_buffer ramoops.max_reason=5 ramoops.console_size=2097152 ramoops.record_size=0 ramoops.ftrace_size=0 ramoops.pmsg_size=0'
> > > >
> > > > KHO preserves pstore properly. However, we need one patch that would
> > > > allow for ramoops console to capture the output even when quiet is
> > > > provided.
> > > >
> > > > Pasha
prev parent reply other threads:[~2026-06-12 18:51 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-05 12:10 [PATCH v2] pstore: add a KHO backend Michal Clapinski
2026-06-10 20:34 ` Kees Cook
2026-06-11 9:18 ` Pratyush Yadav
2026-06-11 18:55 ` Pasha Tatashin
2026-06-12 14:42 ` Mike Rapoport
2026-06-12 17:21 ` Pasha Tatashin
2026-06-12 17:57 ` Michał Cłapiński
2026-06-12 18:38 ` Pasha Tatashin
2026-06-12 18:49 ` Michał Cłapiński
2026-06-12 18:51 ` Pasha Tatashin [this message]
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=aixVD7vyjAcJBZDB@plex \
--to=pasha.tatashin@soleen.com \
--cc=graf@amazon.com \
--cc=kees@kernel.org \
--cc=kexec@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mclapinski@google.com \
--cc=pratyush@kernel.org \
--cc=rppt@kernel.org \
--cc=tony.luck@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