From: Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Randy Dunlap <rdunlap@infradead.org>,
David Laight <David.Laight@aculab.com>,
Kees Cook <keescook@chromium.org>,
"Tobin C. Harding" <me@tobin.cc>,
"kernel-hardening@lists.openwall.com"
<kernel-hardening@lists.openwall.com>,
"Jason A. Donenfeld" <Jason@zx2c4.com>,
Theodore Ts'o <tytso@mit.edu>,
Paolo Bonzini <pbonzini@redhat.com>,
Tycho Andersen <tycho@tycho.ws>,
"Roberts, William C" <william.c.roberts@intel.com>,
Tejun Heo <tj@kernel.org>,
Jordan Glover <Golden_Miller83@protonmail.ch>,
Greg KH <gregkh@linuxfoundation.org>,
Petr Mladek <pmladek@suse.com>, Joe Perches <joe@perches.com>,
Ian Campbell <ijc@hellion.org.uk>,
Sergey Senozhatsky <sergey.senozhatsky@gmail.com>,
Catalin Marinas <catalin.marinas@arm.com>,
Will Deacon <wilal.deacon@arm.
Subject: Re: [PATCH V11 4/5] vsprintf: add printk specifier %px
Date: Wed, 6 Dec 2017 10:36:57 +0900 [thread overview]
Message-ID: <20171206013657.GA479@jagdpanzerIV> (raw)
In-Reply-To: <CA+55aFw3AZtzf6KHS4desHJ3CajKs46VQxOi6-+0U8A4y0v6ug@mail.gmail.com>
Hello,
On (12/05/17 13:22), Linus Torvalds wrote:
[..]
> It's not like those hex numbers were really helping people anyway.
> We've turned off most of them on x86 oops reports long ago (and
> entirely independently of the pointer hashing). Having stared at a lot
> of oopses in my time, the only hex numbers that tend to be really
> relevant are (a) the register contents (which aren't %p anyway), and
> things like the faulting address (which is not, and never has been, %p
> on x86, but might be on some other architecture).
I see some %p-s being used in _supposedly_ important output,
like arch/x86/mm/fault.c
show_fault_oops(struct pt_regs *regs, unsigned long error_code,
unsigned long address)
...
printk(KERN_CONT " at %p\n", (void *) address);
printk(KERN_ALERT "IP: %pS\n", (void *)regs->ip);
a quick %p grep gives me the following list:
arch/arm/mm/fault.c: pr_alert("pgd = %p\n", mm->pgd);
arch/arm64/mm/fault.c: pr_alert("%s pgtable: %luk pages, %u-bit VAs, pgd = %p\n",
arch/arm64/mm/fault.c: pr_info_ratelimited("%s[%d]: %s exception: pc=%p sp=%p\n",
arch/m68k/mm/fault.c: pr_debug("send_fault_sig: %p,%d,%d\n", siginfo.si_addr,
arch/m68k/mm/fault.c: pr_cont(" at virtual address %p\n", siginfo.si_addr);
arch/m68k/mm/fault.c: pr_debug("do page fault:\nregs->sr=%#x, regs->pc=%#lx, address=%#lx, %ld, %p\n",
arch/microblaze/mm/fault.c: pr_emerg("Page fault in user mode with faulthandler_disabled(), mm = %p\n",
arch/mn10300/mm/fault.c: printk(KERN_DEBUG "pgd entry %p: %016Lx\n",
arch/mn10300/mm/fault.c: printk(KERN_DEBUG "pmd entry %p: %016Lx\n",
arch/mn10300/mm/fault.c: printk(KERN_DEBUG "pte entry %p: %016Lx\n",
arch/mn10300/mm/fault.c: printk(KERN_DEBUG "--- do_page_fault(%p,%s:%04lx,%08lx)\n",
arch/powerpc/mm/fault.c: " mm=%p\n",
arch/sh/mm/fault.c: printk(KERN_ALERT "pgd = %p\n", pgd);
arch/unicore32/mm/fault.c: printk(KERN_ALERT "pgd = %p\n", mm->pgd);
arch/x86/mm/fault.c: printk(KERN_CONT " at %p\n", (void *) address);
arch/x86/mm/fault.c: printk(KERN_ALERT "IP: %pS\n", (void *)regs->ip);
arch/x86/mm/fault.c: printk("%s%s[%d]: segfault at %lx ip %p sp %p error %lx",
or is it OK to show hashes instead of pgd or pmd pointers?
-ss
next prev parent reply other threads:[~2017-12-06 1:36 UTC|newest]
Thread overview: 48+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-29 2:05 [PATCH V11 0/5] hash addresses printed with %p Tobin C. Harding
2017-11-29 2:05 ` [PATCH V11 1/5] docs: correct documentation for %pK Tobin C. Harding
2017-11-29 2:05 ` [PATCH V11 2/5] vsprintf: refactor %pK code out of pointer() Tobin C. Harding
2017-11-29 2:39 ` Steven Rostedt
2017-11-29 4:27 ` Tobin C. Harding
2017-11-29 11:54 ` Steven Rostedt
2017-11-29 2:05 ` [PATCH V11 3/5] printk: hash addresses printed with %p Tobin C. Harding
2017-11-29 23:21 ` Andrew Morton
2017-12-05 20:20 ` Geert Uytterhoeven
2017-12-05 20:31 ` David Miller
2017-12-06 10:31 ` David Laight
2017-12-06 23:21 ` Kees Cook
2017-12-06 23:28 ` Linus Torvalds
2017-12-05 20:44 ` Tobin C. Harding
2017-12-05 22:57 ` Geert Uytterhoeven
2017-12-05 23:33 ` Linus Torvalds
2017-12-06 8:48 ` Geert Uytterhoeven
2017-11-29 2:05 ` [PATCH V11 4/5] vsprintf: add printk specifier %px Tobin C. Harding
2017-11-29 2:29 ` Linus Torvalds
2017-11-29 4:29 ` Tobin C. Harding
2017-11-29 10:07 ` David Laight
2017-11-29 22:28 ` Kees Cook
2017-11-29 22:36 ` Roberts, William C
2017-11-29 22:47 ` Linus Torvalds
2017-11-30 10:38 ` David Laight
2017-12-05 21:08 ` Randy Dunlap
2017-12-05 21:22 ` Linus Torvalds
2017-12-06 1:36 ` Sergey Senozhatsky [this message]
2017-12-06 1:59 ` Linus Torvalds
2017-12-06 2:15 ` Sergey Senozhatsky
2017-12-06 8:32 ` Geert Uytterhoeven
2017-12-06 8:45 ` Sergey Senozhatsky
2017-12-07 5:17 ` Tobin C. Harding
2017-12-07 5:29 ` Linus Torvalds
2017-12-07 5:37 ` Sergey Senozhatsky
2017-12-07 5:12 ` Tobin C. Harding
2017-11-29 23:20 ` Andrew Morton
2017-11-29 23:26 ` Tobin C. Harding
2017-11-30 3:58 ` Joe Perches
2017-11-30 4:18 ` Tobin C. Harding
2017-11-30 4:41 ` Joe Perches
2017-11-30 5:00 ` Tobin C. Harding
2017-11-29 2:05 ` [PATCH V11 5/5] kasan: use %px to print addresses instead of %p Tobin C. Harding
2017-11-29 23:20 ` [PATCH V11 0/5] hash addresses printed with %p Andrew Morton
2017-11-29 23:34 ` Tobin C. Harding
2017-11-30 10:23 ` David Laight
2017-11-30 10:26 ` Sergey Senozhatsky
2017-12-01 6:15 ` Sergey Senozhatsky
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=20171206013657.GA479@jagdpanzerIV \
--to=sergey.senozhatsky.work@gmail.com \
--cc=David.Laight@aculab.com \
--cc=Golden_Miller83@protonmail.ch \
--cc=Jason@zx2c4.com \
--cc=catalin.marinas@arm.com \
--cc=gregkh@linuxfoundation.org \
--cc=ijc@hellion.org.uk \
--cc=joe@perches.com \
--cc=keescook@chromium.org \
--cc=kernel-hardening@lists.openwall.com \
--cc=me@tobin.cc \
--cc=pbonzini@redhat.com \
--cc=pmladek@suse.com \
--cc=rdunlap@infradead.org \
--cc=sergey.senozhatsky@gmail.com \
--cc=tj@kernel.org \
--cc=torvalds@linux-foundation.org \
--cc=tycho@tycho.ws \
--cc=tytso@mit.edu \
--cc=wilal.deacon@arm. \
--cc=william.c.roberts@intel.com \
/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;
as well as URLs for NNTP newsgroup(s).