[PATCH V3] arm64: Unhash early pointer print plus improve comment

Uwe Kleine-König u.kleine-koenig at pengutronix.de
Tue Dec 21 22:51:25 PST 2021


Hello,


On Tue, Dec 21, 2021 at 12:52:30PM -0300, Guilherme G. Piccoli wrote:
> When facing a really early issue on DT parsing we have currently
> a message that shows both the physical and virtual address of the FDT.
> The printk pointer modifier for the virtual address shows a hashed
> address there unless the user provides "no_hash_pointers" parameter in
> the command-line. The situation in which this message shows-up is a bit
> more serious though: the boot process is broken, nothing can be done
> (even an oops is too much for this early stage) so we have this message
> as a last resort in order to help debug bootloader issues, for example.
> Hence, we hereby change that to "%px" in order to make debugging easy,
> there's not much information leak risk in such early boot failure.
> 
> Also, we tried to improve a bit the commenting on that function, given
> that if kernel fails there, it just hangs forever in a cpu_relax() loop.
> The reason we cannot BUG/panic is that is too early to do so; thanks to
> Mark Brown for pointing that on IRC and thanks Robin Murphy for the good
> pointer hash discussion in the mailing-list.
> 
> Cc: Mark Brown <broonie at kernel.org>
> Cc: Robin Murphy <robin.murphy at arm.com>
> Signed-off-by: Guilherme G. Piccoli <gpiccoli at igalia.com>

not sure why I was Cc:d for this patch, but it looks good to me. If I
had done it, I would have added a comment about the px, but I like it as
is, too.

Acked-by: Uwe Kleine-König <u.kleine-koenig at pengutronix.de>

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | https://www.pengutronix.de/ |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20211222/7b245b8e/attachment-0001.sig>


More information about the linux-arm-kernel mailing list