Re: [PATCH] mm/vmalloc: fix KMSAN uninit-value warning in decay_va_pool_node()
From: Qing Wang
Date: Thu Apr 02 2026 - 23:50:48 EST
On Fri, 03 Apr 2026 at 11:30, Morduan Zang <zhangdandan@xxxxxxxxxxxxx> wrote:
> While adding INIT_LIST_HEAD(&va->list) in alloc_vmap_area() would indeed
> silence the KMSAN warning, I'm concerned that it might only be masking
> a deeper issue rather than fixing the root cause.
>
> It seems that the uninitialized access in decay_va_pool_node() suggests
> a potential race condition where nodes from a concurrently repopulated
> pool might be lost or the list structure could be incorrectly overwritten
> during list_replace_init().
>
> Instead of just initializing the list head to satisfy KMSAN, should we
> consider modifying decay_va_pool_node() to avoid using list_replace_init()
> which might drop concurrent repopulate nodes? Perhaps using list_splice()
> or a proper merge of the leftover VAs would be a more robust fix for
> the underlying synchronization issue.
Thank you very much for the reminder. I realized that my patch does not fix
the real issue(concurrent corruption of the list). Please ignore this patch
and let's focus on analyzing this concurrency issue.
---
Best Regards,
Qing