s390/disassembler: don't hide instruction addresses
authorIlya Leoshkevich <iii@linux.ibm.com>
Thu, 31 Oct 2019 17:25:16 +0000 (18:25 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 4 Jan 2020 12:39:54 +0000 (13:39 +0100)
commit6a2af04f171d9e4bc477d502be8e2aca2f0e8568
tree1b54b60c07c4ba5f23d01a4c902dc6fcbbafd78a
parent18305963067d93fc703cbf436b31a562209a535c
s390/disassembler: don't hide instruction addresses

[ Upstream commit 544f1d62e3e6c6e6d17a5e56f6139208acb5ff46 ]

Due to kptr_restrict, JITted BPF code is now displayed like this:

000000000b6ed1b2ebdff0800024  stmg    %r13,%r15,128(%r15)
000000004cde2ba041d0f040      la      %r13,64(%r15)
00000000fbad41b0a7fbffa0      aghi    %r15,-96

Leaking kernel addresses to dmesg is not a concern in this case, because
this happens only when JIT debugging is explicitly activated, which only
root can do.

Use %px in this particular instance, and also to print an instruction
address in show_code and PCREL (e.g. brasl) arguments in print_insn.
While at present functionally equivalent to %016lx, %px is recommended
by Documentation/core-api/printk-formats.rst for such cases.

Signed-off-by: Ilya Leoshkevich <iii@linux.ibm.com>
Reviewed-by: Vasily Gorbik <gor@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
arch/s390/kernel/dis.c