Re: [PATCH net-next 1/3] ppp: convert rlock to rwlock to improve RX concurrency
From: Qingfang Deng
Date: Fri Jun 27 2025 - 05:25:08 EST
On Fri, Jun 27, 2025 at 2:50 PM Eric Dumazet <edumazet@xxxxxxxxxx> wrote:
> tldr: network maintainers do not want rwlock back.
>
> If you really care about concurrency, do not use rwlock, because it is
> more expensive than a spinlock and very problematic.
>
> Instead use RCU for readers, and spinlock for the parts needing exclusion.
>
> Adding rwlock in network fast path is almost always a very bad choice.
>
> Take a look at commit 0daf07e527095e6 for gory details.
Thanks for the info, I'll see how to refactor it using RCU instead.