All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vlastimil Babka <vbabka@suse.cz>
To: imran.f.khan@oracle.com, geert@linux-m68k.org, akpm@linux-foundation.org
Cc: linux-kernel@vger.kernel.org,
	"linux-mm@kvack.org" <linux-mm@kvack.org>,
	Alexander Potapenko <glider@google.com>
Subject: Re: [RFC PATCH 2/2] lib, stackdepot: Add helper to print stack entries.
Date: Thu, 2 Sep 2021 10:00:04 +0200	[thread overview]
Message-ID: <e6f6fb85-1d83-425b-9e36-b5784cc9e69a@suse.cz> (raw)
In-Reply-To: <9527f084-4d60-2a85-f4e3-8e16cf7aad08@oracle.com>

On 9/2/21 02:11, imran.f.khan@oracle.com wrote:
> Hi Vlastimil,
> 
> On 1/9/21 7:07 pm, Vlastimil Babka wrote:
>> On 9/1/21 07:19, Imran Khan wrote:
>>> To print a stack entries, users of stackdepot, first
>>> use stack_depot_fetch to get a list of stack entries
>>> and then use stack_trace_print to print this list.
>>> Provide a helper in stackdepot to print stack entries
>>> based on stackdepot handle.
>>>
>>> Signed-off-by: Imran Khan <imran.f.khan@oracle.com>
>>> Suggested-by: Vlastimil Babka <vbabka@suse.cz>
>>
>> You should convert existing users together with the patch that introduces
>> the helper. I think print_stack() in mm/kasan/report.c, and
>> __dump_page_owner() could use this.
>>
> 
> Okay. I have done this in v2 of the patch set. BTW I also see some users
> (one place in page owner, rest all in some gpu drivers) of stack_depot_fetch
> + stack_trace_snprintf. Could you please let me know if it would be okay to
> add a helper corresponding to stack_trace_snprintf as well.

Yeah looks like that would make sense too, i915 even has this as
__print_depot_stack(). Thanks.

      reply	other threads:[~2021-09-02  8:00 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-01  5:19 [RFC PATCH 0/2] lib, stackdepot: check stackdepot handle before accessing slabs Imran Khan
2021-09-01  5:19 ` [RFC PATCH 1/2] " Imran Khan
2021-09-01  8:58   ` Vlastimil Babka
2021-09-02  0:12     ` imran.f.khan
2021-09-01  5:19 ` [RFC PATCH 2/2] lib, stackdepot: Add helper to print stack entries Imran Khan
2021-09-01  9:07   ` Vlastimil Babka
2021-09-02  0:11     ` imran.f.khan
2021-09-02  8:00       ` Vlastimil Babka [this message]

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=e6f6fb85-1d83-425b-9e36-b5784cc9e69a@suse.cz \
    --to=vbabka@suse.cz \
    --cc=akpm@linux-foundation.org \
    --cc=geert@linux-m68k.org \
    --cc=glider@google.com \
    --cc=imran.f.khan@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.