Re: kunit_test: KASAN: null-ptr-deref in range - kunit_generic_run_threadfn_adapter on qemu_arm64

From: Dan Carpenter
Date: Tue Jun 04 2024 - 04:21:44 EST


On Mon, Jun 03, 2024 at 07:39:24PM +0530, Naresh Kamboju wrote:
> The following kernel null pointer dereference is noticed on qemu-arm64
> while running
> kunit tests with the Linux next-20240603 tag kernel.
>
> This is always reproducible and the system is stable after this.
>
> Reported-by: Linux Kernel Functional Testing <lkft@xxxxxxxxxx>

These are intentional... The function name just changed so it's showing
up as a new bug. I tried to add a big printk before this NULL
dereference but the printk message never showed up in dmesg...

+ kunit_info(test, "Testing that a NULL dereference causes a test failure\n");
+ kunit_info(test, "*** This will lead to an intentional stack trace ***\n");

regards,
dan carpenter