[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <e6f6fb85-1d83-425b-9e36-b5784cc9e69a@suse.cz>
Date: Thu, 2 Sep 2021 10:00:04 +0200
From: Vlastimil Babka <vbabka@...e.cz>
To: imran.f.khan@...cle.com, geert@...ux-m68k.org,
akpm@...ux-foundation.org
Cc: linux-kernel@...r.kernel.org,
"linux-mm@...ck.org" <linux-mm@...ck.org>,
Alexander Potapenko <glider@...gle.com>
Subject: Re: [RFC PATCH 2/2] lib, stackdepot: Add helper to print stack
entries.
On 9/2/21 02:11, imran.f.khan@...cle.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@...cle.com>
>>> Suggested-by: Vlastimil Babka <vbabka@...e.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.
Powered by blists - more mailing lists