Re: [bisected] clang 16 built kernel crashes w. "BUG: kernel NULL pointer dereference, address: 00000007", gcc 13 built kernel with same config boots fine (6.7-rc1, x86_32)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Nov 15, 2023 at 01:15:06AM +0100, Erhard Furtner wrote:
> Greetings!

Hello Erhard,

thank you for the report!

Hm, interesting, so the issue is happening only with a kernel built with clang-16
but not gcc? And you use 32-bit kernel? Do you know if it's reproducible on a
64-bit machine?

Completely speculative, but can you please check if the following patch
resolves the problem?

Thank you!

--

diff --git a/kernel/fork.c b/kernel/fork.c
index 10917c3e1f03..a0df246e81f0 100644
--- a/kernel/fork.c
+++ b/kernel/fork.c
@@ -1186,6 +1186,9 @@ static struct task_struct *dup_task_struct(struct task_struct *orig, int node)
 #ifdef CONFIG_MEMCG
        tsk->active_memcg = NULL;
 #endif
+#ifdef CONFIG_MEMCG_KMEM
+       tsk->objcg = NULL;
+#endif

 #ifdef CONFIG_CPU_SUP_INTEL
        tsk->reported_split_lock = 0;




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux