Re: [PATCH 1/5] seqlock: simplify SEQCOUNT_LOCKNAME()

From: Oleg Nesterov
Date: Thu Sep 21 2023 - 17:16:07 EST


On 09/16, Peter Zijlstra wrote:
>
> On Wed, Sep 13, 2023 at 05:49:53PM +0200, Oleg Nesterov wrote:
> > 1. Kill the "lockmember" argument. It is always s->lock plus
> > __seqprop_##lockname##_sequence() already uses s->lock and
> > ignores "lockmember".
> >
> > 2. Kill the "lock_acquire" argument. __seqprop_##lockname##_sequence()
> > can use the same "lockbase" prefix for _lock and _unlock.
> >
> > Apart from line numbers, gcc -E outputs the same code.
>
> With seqlock_ww_mutex gone, yes this is a nice cleanup.

Thanks.

Can you look at 2/5? To me it looks like a good cleanup too.
I am going to resend 1/5 and 2/5, as no one is interested in
stats_lock change.

Oleg.