lkml.org 
[lkml]   [2017]   [Dec]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH] mm/slab: Do not hash pointers when debugging slab
On Thu, Dec 7, 2017 at 2:17 AM, Geert Uytterhoeven
<geert+renesas@glider.be> wrote:
>
> if (cachep->flags & SLAB_STORE_USER) {
> - pr_err("Last user: [<%p>](%pSR)\n",
> + pr_err("Last user: [<%px>](%pSR)\n",
> *dbg_userword(cachep, objp),
> *dbg_userword(cachep, objp));

Is there actually any point to the %px at all?

Why not remove it? the _real_ information is printed out by %pSR, and
that's both sufficient and useful in ways %px isn't.

> - pr_err("Slab corruption (%s): %s start=%p, len=%d\n",
> + pr_err("Slab corruption (%s): %s start=%px, len=%d\n",
> print_tainted(), cachep->name,
> realobj, size);

and here, is the pointer actually interesting, or should we just give
the offset to the allocation?

But if the pointer is interesting, then ack.

Linus

\
 
 \ /
  Last update: 2017-12-10 21:46    [W:0.080 / U:0.148 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site