[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAGudoHEOTXu_53Cj+6XrS6x=8ouOiiC8bRnerYg39ZjWEoGvNg@mail.gmail.com>
Date: Sun, 8 Oct 2023 22:31:48 +0200
From: Mateusz Guzik <mjguzik@...il.com>
To: "Matthew Wilcox (Oracle)" <willy@...radead.org>
Cc: Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>, Will Deacon <will@...nel.org>,
Waiman Long <longman@...hat.com>, linux-kernel@...r.kernel.org,
linux-mm@...ck.org, Chandan Babu R <chandan.babu@...cle.com>,
"Darrick J . Wong" <djwong@...nel.org>, linux-xfs@...r.kernel.org
Subject: Re: [PATCH v2 0/5] Remove the XFS mrlock
On 10/7/23, Matthew Wilcox (Oracle) <willy@...radead.org> wrote:
> I'm sympathetic to "this will warn twice and dump much the same
> information if you have lockdep enabled". Perhaps somebody has a
> suggestion for not doing that?
>
Well the obvious idea is that lockdep could provide a macro indicating
what's up.
Then you would:
static inline void rwsem_assert_held(const struct rw_semaphore *sem)
{
if (lockdep_works)
lockdep_assert_held(sem);
else
__rwsem_assert_held(sem);
}
Am I missing something? If this is not feasible to achieve, then the
proposed routines need a comment justifying the state.
--
Mateusz Guzik <mjguzik gmail.com>
Powered by blists - more mailing lists