[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2e44db55-61f1-ad3d-e9e1-a9409ffad31b@redhat.com>
Date: Fri, 26 May 2023 15:04:49 -0400
From: Waiman Long <longman@...hat.com>
To: Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
Peter Zijlstra <peterz@...radead.org>,
torvalds@...ux-foundation.org, keescook@...omium.org,
gregkh@...uxfoundation.org, pbonzini@...hat.com
Cc: linux-kernel@...r.kernel.org, ojeda@...nel.org,
ndesaulniers@...gle.com, mingo@...hat.com, will@...nel.org,
boqun.feng@...il.com, juri.lelli@...hat.com,
vincent.guittot@...aro.org, dietmar.eggemann@....com,
rostedt@...dmis.org, bsegall@...gle.com, mgorman@...e.de,
bristot@...hat.com, vschneid@...hat.com, paulmck@...nel.org,
frederic@...nel.org, quic_neeraju@...cinc.com,
joel@...lfernandes.org, josh@...htriplett.org,
jiangshanlai@...il.com, qiang1.zhang@...el.com,
rcu@...r.kernel.org, tj@...nel.org, tglx@...utronix.de
Subject: Re: [RFC][PATCH 1/2] locking: Introduce __cleanup__ based guards
On 5/26/23 14:58, Mathieu Desnoyers wrote:
> On 5/26/23 14:49, Waiman Long wrote:
> [...]
>>
>> BTW, do we have a use case for double_lock_guard/double_lock_scope? I
>> can envision a nested lock_scope inside a lock_scope, but taking 2
>> auto locks of the same type at init time and then unlock them at exit
>> just doesn't make sense to me.
>
> AFAIU taking both runqueue locks for source and destination runqueues
> on migration is one use-case for double_lock_guard/scope.
>
I see. Thanks for the clarification. I forgot about that special case.
Cheers,
Longman
Powered by blists - more mailing lists