lkml.org 
[lkml]   [2022]   [Jul]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH] mm: percpu: use kmemleak_ignore_phys() instead of kmemleak_free()
On Wed, Jul 6, 2022 at 5:20 AM Andrew Morton <akpm@linux-foundation.org> wrote:
>
> On Tue, 5 Jul 2022 19:31:58 +0800 Patrick Wang <patrick.wang.shcn@gmail.com> wrote:
>
> > Kmemleak recently added a rbtree to store the objects
> > allocted with physical address. Those objects can't be
> > freed with kmemleak_free(). Use kmemleak_ignore_phys()
> > instead of kmemleak_free() for those objects.
>
> Thanks. What are the user-visible runtime effects of this?

According to the comments, percpu allocations are tracked
by kmemleak separately. Kmemleak_free() was used to avoid
the unnecessary tracking. If kmemleak_free() fails, those
objects would be scanned by kmemleak, which is unnecessary
but shouldn't lead to other effects.

I didn't observe any anomaly without this commit on riscv
and arm64.

>
> And are we able to identify a commit for the Fixes: line?

0c24e061196c (mm: kmemleak: add rbtree and store physical
address for objects allocated with PA)
Current in mm-stable.

Thanks,
Patrick

\
 
 \ /
  Last update: 2022-07-06 16:46    [W:0.046 / U:0.868 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site