From: Dev Jain <dev.jain@arm.com>
To: "Uladzislau Rezki (Sony)" <urezki@gmail.com>,
Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org, LKML <linux-kernel@vger.kernel.org>,
Baoquan He <bhe@redhat.com>,
Christoph Hellwig <hch@infradead.org>,
Oleksiy Avramchenko <oleksiy.avramchenko@sony.com>,
Ryan Roberts <ryan.roberts@arm.com>
Subject: Re: [PATCH 2/4] lib/test_vmalloc.c: Allow built-in execution
Date: Fri, 13 Jun 2025 19:29:23 +0530 [thread overview]
Message-ID: <6c6f1cfa-7f1b-4133-ae2a-c6b1ef2d82e8@arm.com> (raw)
In-Reply-To: <20250417161216.88318-2-urezki@gmail.com>
On 17/04/25 9:42 pm, Uladzislau Rezki (Sony) wrote:
> This patch removes the dependency on module loading ("m")
> for the vmalloc test suite, enabling it to be built directly
> into the kernel, so both ("=m") and ("=y") are supported.
>
> Motivation:
> - Faster debugging/testing of vmalloc code;
> - It allows to configure the test via kernel-boot parameters.
>
> Configuration example:
> test_vmalloc.nr_threads=64
> test_vmalloc.run_test_mask=7
> test_vmalloc.sequential_test_order=1
>
> Signed-off-by: Uladzislau Rezki (Sony) <urezki@gmail.com>
> ---
> lib/Kconfig.debug | 3 +--
> lib/test_vmalloc.c | 5 +++--
> 2 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
> index f9051ab610d54..166b9d830a85a 100644
> --- a/lib/Kconfig.debug
> +++ b/lib/Kconfig.debug
> @@ -2574,8 +2574,7 @@ config TEST_BITOPS
> config TEST_VMALLOC
> tristate "Test module for stress/performance analysis of vmalloc allocator"
> default n
> - depends on MMU
> - depends on m
> + depends on MMU
> help
> This builds the "test_vmalloc" module that should be used for
> stress and performance analysis. So, any new change for vmalloc
> diff --git a/lib/test_vmalloc.c b/lib/test_vmalloc.c
> index 4ab23e5e772d0..6d65ef725d42c 100644
> --- a/lib/test_vmalloc.c
> +++ b/lib/test_vmalloc.c
> @@ -591,10 +591,11 @@ static void do_concurrent_test(void)
> kvfree(tdriver);
> }
>
> -static int vmalloc_test_init(void)
> +static int __init vmalloc_test_init(void)
> {
> do_concurrent_test();
> - return -EAGAIN; /* Fail will directly unload the module */
> + /* Fail will directly unload the module */
> + return IS_BUILTIN(CONFIG_TEST_VMALLOC) ? 0:-EAGAIN;
> }
>
> module_init(vmalloc_test_init)
Hi Uladzislau,
Post this patch I am seeing the following problem: while booting the kernel, this test is
executed and a particular testcase triggers a warning splat from the kernel, then the boot
gets stuck for 3-4 seconds, then proceeds. I am not an expert on modules so I don't know
what happened but I am guessing that when the test fails, the delay is due to module
unloading time...do you suggest a solution? I reverted your patch and then proceeded with
my work, so apologies for not having the dmesg log, if you need it I'll replicate, although
there is some subtest which has consistently been spitting out a warning on my Apple M3 Linux
VM and I have been just ignoring it for long : )
next prev parent reply other threads:[~2025-06-13 14:00 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-17 16:12 [PATCH 1/4] lib/test_vmalloc.c: Replace RWSEM to SRCU for setup Uladzislau Rezki (Sony)
2025-04-17 16:12 ` [PATCH 2/4] lib/test_vmalloc.c: Allow built-in execution Uladzislau Rezki (Sony)
2025-04-18 15:01 ` Baoquan He
2025-04-24 13:37 ` Adrian Huang12
2025-06-13 13:59 ` Dev Jain [this message]
2025-06-13 14:19 ` Uladzislau Rezki
2025-06-13 14:23 ` Dev Jain
2025-06-13 14:37 ` Uladzislau Rezki
2025-06-14 10:27 ` Dev Jain
2025-06-14 15:35 ` Uladzislau Rezki
2025-04-17 16:12 ` [PATCH 3/4] MAINTAINERS: Add test_vmalloc.c to VMALLOC section Uladzislau Rezki (Sony)
2025-04-18 15:01 ` Baoquan He
2025-04-17 16:12 ` [PATCH 4/4] vmalloc: Align nr_vmalloc_pages and vmap_lazy_nr Uladzislau Rezki (Sony)
2025-04-18 13:26 ` Baoquan He
2025-04-24 13:38 ` Adrian Huang12
2025-04-18 18:12 ` [PATCH 1/4] lib/test_vmalloc.c: Replace RWSEM to SRCU for setup kernel test robot
2025-04-22 12:59 ` Uladzislau Rezki
2025-04-24 13:35 ` Adrian Huang12
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6c6f1cfa-7f1b-4133-ae2a-c6b1ef2d82e8@arm.com \
--to=dev.jain@arm.com \
--cc=akpm@linux-foundation.org \
--cc=bhe@redhat.com \
--cc=hch@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=oleksiy.avramchenko@sony.com \
--cc=ryan.roberts@arm.com \
--cc=urezki@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®