Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

soc: ti: pruss: don't use %pK through printk

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 locks in atomic contexts.

Switch to the regular pointer formatting which is safer and
easier to reason about.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Link: https://lore.kernel.org/r/20250811-restricted-pointers-soc-v2-1-7af7ed993546@linutronix.de
Signed-off-by: Nishanth Menon <nm@ti.com>

authored by

Thomas Weißschuh and committed by
Nishanth Menon
a5039648 8f5ae30d

+1 -1
+1 -1
drivers/soc/ti/pruss.c
··· 449 449 pruss->mem_regions[i].pa = res.start; 450 450 pruss->mem_regions[i].size = resource_size(&res); 451 451 452 - dev_dbg(dev, "memory %8s: pa %pa size 0x%zx va %pK\n", 452 + dev_dbg(dev, "memory %8s: pa %pa size 0x%zx va %p\n", 453 453 mem_names[i], &pruss->mem_regions[i].pa, 454 454 pruss->mem_regions[i].size, pruss->mem_regions[i].va); 455 455 }