CVE-2026-142840: mm/zswap: publish the initial pool with list_add_rcu()
In the Linux kernel, the following vulnerability has been resolved:
mm/zswap: publish the initial pool with listaddrcu()
zswapsetup() publishes the pool on the zswappools list with a plain listadd(), but the list is walked by concurrent RCU readers holding nothing but rcureadlock() through zswaptotalpages(), e.g. /proc/meminfo and the shrinker count path.
CPU 0 (writer) CPU 1 (reader) -------------- -------------- zswappoolcreate(): pool->zspool = zscreatepool(); (1) listadd() -> listadd(): WRITEONCE(zswappools.next, &pool->list); (2) zswaptotalpages(): pool = READONCE( (a) zswappools.next); zsgettotalpages( (b) pool->zspool);
If (2) becomes visible to CPU 1 before (1), CPU 1 finds the pool at (a) but dereferences a wild pointer at (b). Publish the node with listaddrcu().