Re: [PATCH 2/2] KVM: s390: Don't use %pK through debug printing
From: Thomas Weißschuh
Date: Mon Nov 23 2026 - 05:01:30 EST
On Mon, Nov 23, 2026 at 10:41:13AM +0100, Christian Borntraeger wrote:
> Am 17.02.25 um 14:13 schrieb Thomas Weißschuh:
> > Restricted pointers ("%pK") are only meant to be used when directly
> > printing to a file from task context.
> > Otherwise it can unintentionally expose security sensitive,
> > raw pointer values.
> >
> > Use regular pointer formatting instead.
> >
> > Link: https://lore.kernel.org/lkml/20250113171731-dc10e3c1-da64-4af0-b767-7c7070468023@xxxxxxxxxxxxx/
> > Signed-off-by: Thomas Weißschuh <thomas.weissschuh@xxxxxxxxxxxxx>
>
> Just realized that will debugging something, but this change was wrong.
> The VM_EVENT, KVM_EVENT are not printks, it will rather populate output
> in debugfs files and this output is populated at read time as the debug
> feature stores the format string and the value. So %pK was actually the
> right thing - I think.
Indeed. OTOH %pK is going away completely anyways. So the change should stay.
(...)