Skip to content
Snippets Groups Projects
Commit 4e1c44b3 authored by Vlastimil Babka's avatar Vlastimil Babka
Browse files

kunit, slub: add test_kfree_rcu() and test_leak_destroy()


Add a test that will create cache, allocate one object, kfree_rcu() it
and attempt to destroy it. As long as the usage of kvfree_rcu_barrier()
in kmem_cache_destroy() works correctly, there should be no warnings in
dmesg and the test should pass.

Additionally add a test_leak_destroy() test that leaks an object on
purpose and verifies that kmem_cache_destroy() catches it.

Signed-off-by: default avatarVlastimil Babka <vbabka@suse.cz>
parent 6c6c47b0
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment