[PATCH v2] pstore: add a KHO backend
Pasha Tatashin
pasha.tatashin at soleen.com
Fri Jun 12 10:21:20 PDT 2026
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
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
More information about the kexec
mailing list