Re: [RFC 1/1] rwsem: Shrink rwsem by one pointer

From: Linus Torvalds

Date: Wed Feb 18 2026 - 17:53:04 EST


On Wed, 18 Feb 2026 at 14:45, Linus Torvalds
<torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:
>
> Anyway, this is all from just looking at the patch, so maybe I missed
> something, but it does look very wrong.

Bah. And immediately after sending, I went "maybe I should look at the
code" more closely.

I think my suggestion to just remove the check was right, but the
return value of rwsem_del_waiter() needs to be fixed to be the "I used
to be the first waiter, but there are other waiters and I updated the
first waiter pointer".

Linus