mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-03-15 19:55:32 +00:00
lib/test_meminit: destroy cache in kmem_cache_alloc_bulk() test
commite073e5ef90
upstream. Make do_kmem_cache_size_bulk() destroy the cache it creates. Link: https://lkml.kernel.org/r/aced20a94bf04159a139f0846e41d38a1537debb.1640018297.git.andreyknvl@google.com Fixes:03a9349ac0
("lib/test_meminit: add a kmem_cache_alloc_bulk() test") Signed-off-by: Andrey Konovalov <andreyknvl@google.com> Reviewed-by: Marco Elver <elver@google.com> Cc: Alexander Potapenko <glider@google.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Andrey Ryabinin <ryabinin.a.a@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
47e7cf4206
commit
ce1b2806dd
1 changed files with 1 additions and 0 deletions
|
@ -337,6 +337,7 @@ static int __init do_kmem_cache_size_bulk(int size, int *total_failures)
|
|||
if (num)
|
||||
kmem_cache_free_bulk(c, num, objects);
|
||||
}
|
||||
kmem_cache_destroy(c);
|
||||
*total_failures += fail;
|
||||
return 1;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue