Re: [PATCH] lib/vsprintf: Make no_hash_pointers take effect early
From: Andy Shevchenko
Date: Thu Jun 11 2026 - 03:20:39 EST
On Thu, Jun 11, 2026 at 02:45:15PM +0800, Kaitao Cheng wrote:
> 在 2026/6/10 22:59, Andy Shevchenko 写道:
> > On Wed, Jun 10, 2026 at 08:45:25PM +0800, Kaitao Cheng wrote:
> >
> >> The no_hash_pointers boot parameter is now handled as an alias for
> >> hash_pointers=never. However, hash_pointers=never only records the
> >> selected mode during early parameter parsing, and no_hash_pointers is
> >> not updated until hash_pointers_finalize() runs later from SLUB init.
> >>
> >> This leaves a window during very early boot where %p output is still
> >> hashed even though the user explicitly requested unhashed pointers with
> >> no_hash_pointers or hash_pointers=never.
> >>
> >> Set no_hash_pointers as soon as the "never" mode is parsed. The later
> >> hash_pointers_finalize() call still keeps the final policy decision in
> >> one place, but explicit requests to disable pointer hashing now take
> >> effect for early boot users too.
> >
> > How is it documented now? And if not documented at all, needs to be.
>
> In Documentation/admin-guide/kernel-parameters.txt, the descriptions of
> both no_hash_pointers and hash_pointers= are already marked as [KNL,EARLY],
> which should match the current semantics.
This detail should be also mentioned in the commit message.
--
With Best Regards,
Andy Shevchenko