freenode
Kernel & Low-Level

Futex hash hardening is proposed as maintainers push back on untested LLM patches

A keyed hash is offered to close a published kernel pointer leak, while Greg Kroah-Hartman tells an author to withdraw a pile of compile-only accelerator and serial fixes.

Linux kernel list traffic this window pairs a proposed fix for a published pointer leak with a blunt rejection of machine-drafted patches that were never run on the hardware they change.

Kyle Zeng posted a change to how the kernel picks global futex hash buckets. The table is currently chosen with a public jhash2 of the futex key. For private and shared-anonymous futexes that key includes a pointer to the task's memory descriptor. A task can fill a bucket, issue nonmatching wakes, and time which user addresses collide. File-backed keys have predictable inode sequence numbers, so those timings can be turned into constraints on the pointer. Lukas Maar, Jonas Juffinger, Thomas Steinbauer, Daniel Gruss, and Stefan Mangard described the recovery in KernelSnitch at NDSS 2025: observe the collisions, then evaluate the public hash offline.

A per-process private hash does not close the hole. A task can turn it off through a prctl, and NUMA-routed private futexes plus shared-anonymous keys still use the global table. Zeng's patch switches global bucket selection to SipHash-2-4 with a secret chosen at boot and kept for the life of the tables. Equality checks and the per-process hash, which covers only user addresses and offsets, stay as they are. A follow-up credits the paper's authors. The note is up for review; it has not been described as merged.

Separately, Greg Kroah-Hartman told Praneeth Balasubramanian to ask that a large set of his patches not be applied. Balasubramanian, writing about work at UCSB SecLab, said an automated audit turned comments in the kernel into rules, had several model votes check the code, and drafted fixes that he then reviewed. He also said he had no reproducer, no matching hardware, and only compile-tested the changes.

One of those notes, for the Habana Labs accelerator driver, claims that releasing timestamp records on reset can free a buffer and then read it, can sleep while holding a spinlock with interrupts off, and can leave a record marked in use so a later unregister frees the same buffers again. Kroah-Hartman called the audit poor and said the author should get one patch tested on real hardware and accepted before sending more.

A four-patch serial and tty series from the same author, posted the same morning and likewise untested on hardware, drew the same process objection and concrete technical pushback. It claimed a stack overread in an hvsi version response, a release of a memory region that was never requested in a MEN UART driver, a missing port lock on the Atmel console write path, and a missing termios lock in mxser when serial settings change. After review, Balasubramanian asked that the hvsi patch be dropped, saying the read past the count belongs in the powerpc console put path used by several callers. He also asked that the Atmel patch be dropped: taking the port lock in the console write can deadlock against code that already holds that lock and then prints, including receive and transmit tasklets and the SysRq path. He said the underlying race remains and needs a broader locking change, not a lock grab in the console write. The mxser and MEN notes were not withdrawn in the messages on hand.