]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
lib/test_vmalloc: add no_block_alloc_test case
authorUladzislau Rezki (Sony) <urezki@gmail.com>
Tue, 7 Oct 2025 12:20:26 +0000 (14:20 +0200)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 17 Nov 2025 01:27:52 +0000 (17:27 -0800)
commit9ff86ca1cccc071db5ede284852728027412fd88
treeb5e1ba7b3609372ee62518c6ecae35ac685e7105
parent11119b19f62dc8f3aac6e458fb27a468ad5861ce
lib/test_vmalloc: add no_block_alloc_test case

Patch series "__vmalloc()/kvmalloc() and no-block support", v4.

This patch (of 10):

Introduce a new test case "no_block_alloc_test" that verifies non-blocking
allocations using __vmalloc() with GFP_ATOMIC and GFP_NOWAIT flags.

It is recommended to build kernel with CONFIG_DEBUG_ATOMIC_SLEEP enabled
to help catch "sleeping while atomic" issues.  This test ensures that
memory allocation logic under atomic constraints does not inadvertently
sleep.

Link: https://lkml.kernel.org/r/20251007122035.56347-2-urezki@gmail.com
Signed-off-by: Uladzislau Rezki (Sony) <urezki@gmail.com>
Cc: Baoquan He <bhe@redhat.com>
Cc: Michal Hocko <mhocko@kernel.org>
Cc: Alexander Potapenko <glider@google.com>
Cc: Andrey Ryabinin <ryabinin.a.a@gmail.com>
Cc: Marco Elver <elver@google.com>
Cc: Michal Hocko <mhocko@suse.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
lib/test_vmalloc.c