remoteproc: Use %p for pointer formatting

Commit 276ec99342 ("remoteproc: replace "%p" with "%pK"") introduced
the %pK in order to not leak kernel pointers.
Since commit ad67b74d24 ("printk: hash addresses printed with
%p") pointers are hashed by default and the behaviour can be controller
by `hash_pointers' boot argument.
The policy on %p is to not introduce new ones.
Removing %pK makes it possible to remove its handling from the library.

I doubt printing the address of struct fw_rsc_hdr with an unknown type
brings any value. The va is printed already in debug output in other
places as %p so it makes probably no difference to remove it from
rproc_carveouts_show().

Use %p instead %pK for rproc_mem_entry::va, remove the address of the
unknown type.

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Link: https://lore.kernel.org/r/20260918104628.jqQhAlF-@linutronix.de
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
This commit is contained in:
Sebastian Andrzej Siewior 2026-09-18 12:46:28 +02:00 committed by Mathieu Poirier
parent 957cf58a19
commit f1474f0cb5

View File

@ -347,8 +347,8 @@ static int rproc_rsc_table_show(struct seq_file *seq, void *p)
}
break;
default:
seq_printf(seq, "Unknown resource type found: %d [hdr: %pK]\n",
hdr->type, hdr);
seq_printf(seq, "Unknown resource type found: %d\n",
hdr->type);
break;
}
}
@ -367,7 +367,7 @@ static int rproc_carveouts_show(struct seq_file *seq, void *p)
list_for_each_entry(carveout, &rproc->carveouts, node) {
seq_puts(seq, "Carveout memory entry:\n");
seq_printf(seq, "\tName: %s\n", carveout->name);
seq_printf(seq, "\tVirtual address: %pK\n", carveout->va);
seq_printf(seq, "\tVirtual address: %p\n", carveout->va);
seq_printf(seq, "\tDMA address: %pad\n", &carveout->dma);
seq_printf(seq, "\tDevice address: 0x%x\n", carveout->da);
seq_printf(seq, "\tLength: 0x%zx Bytes\n\n", carveout->len);