The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Brian Norris <briannorris@chromium.org>
To: "Thomas Weißschuh" <thomas.weissschuh@linutronix.de>
Cc: Francesco Dolcini <francesco@dolcini.it>,
	linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org,
	Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Subject: Re: [PATCH wireless-next] wifi: mwifiex: Don't use %pK through printk
Date: Mon, 21 Apr 2025 16:55:28 -0700	[thread overview]
Message-ID: <aAba8H-8KYZJeezS@google.com> (raw)
In-Reply-To: <20250417-restricted-pointers-wifi-v1-1-b79cdaae5579@linutronix.de>

On Thu, Apr 17, 2025 at 03:21:54PM +0200, Thomas Weißschuh wrote:
> In the past %pK was preferable to %p as it would not leak raw pointer
> values into the kernel log.
> Since commit ad67b74d2469 ("printk: hash addresses printed with %p")
> the regular %p has been improved to avoid this issue.
> Furthermore, restricted pointers ("%pK") were never meant to be used
> through printk(). They can still unintentionally leak raw pointers or
> acquire sleeping looks in atomic contexts.
> 
> Switch to the regular pointer formatting which is safer and
> easier to reason about.
> There are still a few users of %pK left, but these use it through seq_file,
> for which its usage is safe.
> 
> Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
> Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>

FWIW:

Acked-by: Brian Norris <briannorris@chromium.org>

      reply	other threads:[~2025-04-21 23:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-17 13:21 [PATCH wireless-next] wifi: mwifiex: Don't use %pK through printk Thomas Weißschuh
2025-04-21 23:55 ` Brian Norris [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=aAba8H-8KYZJeezS@google.com \
    --to=briannorris@chromium.org \
    --cc=aleksandr.loktionov@intel.com \
    --cc=francesco@dolcini.it \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=thomas.weissschuh@linutronix.de \
    /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