[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAHk-=wgtKqZoQZB6VzJr+EQNfsT1r1A9U2zxOrGFb+pqtkTXFA@mail.gmail.com>
Date: Mon, 7 Apr 2025 09:00:10 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Christoph Hellwig <hch@...radead.org>
Cc: Mateusz Guzik <mjguzik@...il.com>,
James Bottomley <James.Bottomley@...senpartnership.com>,
Christian Brauner <brauner@...nel.org>, Leon Romanovsky <leon@...nel.org>, pr-tracker-bot@...nel.org,
linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [GIT PULL] vfs mount
On Mon, 7 Apr 2025 at 01:51, Christoph Hellwig <hch@...radead.org> wrote:
>
> The scoped one with proper indentation is fine. The non-scoped one is
> the one that is really confusing and odd.
Ahh, I misunderstood you.
You're obviously right in a "visually obvious" way - even if it was
the scoped one that caused problems.
But the non-scoped one is *so* convenient when you have a helper
function that just wants to run with some local (or RCU) held.
There's a reason we have more than two _thousand_ uses of it by now in
the kernel (~4x as many as the scoped version). It's just makes code
look so much simpler.
I was nervous about the lock guard macros initially, but it really
does get rid of pointless boilerplate code. Even without error
handling complications it just makes code simpler.
Linus
Powered by blists - more mailing lists