mirror of
https://github.com/torvalds/linux.git
synced 2025-11-30 23:16:01 +07:00
Merge tag 'slab-for-6.18-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/vbabka/slab
Pull slab fix from Vlastimil Babka: - Fix memory leak of objects from remote NUMA node when bulk freeing to a cache with sheaves (Harry Yoo) * tag 'slab-for-6.18-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/vbabka/slab: mm/slub: fix memory leak in free_to_pcs_bulk()
This commit is contained in:
@@ -6336,8 +6336,6 @@ next_remote_batch:
|
||||
|
||||
if (unlikely(!slab_free_hook(s, p[i], init, false))) {
|
||||
p[i] = p[--size];
|
||||
if (!size)
|
||||
goto flush_remote;
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -6352,6 +6350,9 @@ next_remote_batch:
|
||||
i++;
|
||||
}
|
||||
|
||||
if (!size)
|
||||
goto flush_remote;
|
||||
|
||||
next_batch:
|
||||
if (!local_trylock(&s->cpu_sheaves->lock))
|
||||
goto fallback;
|
||||
@@ -6406,6 +6407,9 @@ do_free:
|
||||
goto next_batch;
|
||||
}
|
||||
|
||||
if (remote_nr)
|
||||
goto flush_remote;
|
||||
|
||||
return;
|
||||
|
||||
no_empty:
|
||||
|
||||
Reference in New Issue
Block a user