Re: [PATCH 1/3] rwsem: Remove the list_head from struct rw_semaphore
From: Peter Zijlstra
Date: Wed Mar 18 2026 - 16:29:20 EST
On Wed, Mar 18, 2026 at 07:07:24PM +0000, Mark Brown wrote:
> On Thu, Mar 05, 2026 at 07:55:41PM +0000, Matthew Wilcox (Oracle) wrote:
> > Instead of embedding a list_head in struct rw_semaphore, store a pointer
> > to the first waiter. The list of waiters remains a doubly linked list
> > so we can efficiently add to the tail of the list, remove from the front
> > (or middle) of the list.
>
> > Some of the list manipulation becomes more complicated, but it's a
> > reasonable tradeoff on the slow paths to shrink some core data structures
> > like struct inode.
>
> In the past few days we've started seeing lockups when running LTP on
> -next on a range of arm64 platforms which bisect to this patch. It
> looks like corruption of some kind, the exact trigger varies but it's
> very predictable that something goes wrong and we get lots of rwsem
> related backtraces which do seem relevant to this commmit. This one
> seems reasonably typical:
I merged the fix in todays branch:
https://lkml.kernel.org/r/177382097549.1647592.8219974128268935080.tip-bot2@tip-bot2
Attachment:
signature.asc
Description: PGP signature