[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260128150538.GA1134360@nvidia.com>
Date: Wed, 28 Jan 2026 11:05:38 -0400
From: Jason Gunthorpe <jgg@...dia.com>
To: Wolfram Sang <wsa+renesas@...g-engineering.com>
Cc: Bartosz Golaszewski <brgl@...nel.org>, Johan Hovold <johan@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Danilo Krummrich <dakr@...nel.org>,
"Rafael J . Wysocki" <rafael@...nel.org>,
Tzung-Bi Shih <tzungbi@...nel.org>,
Linus Walleij <linusw@...nel.org>, Jonathan Corbet <corbet@....net>,
Shuah Khan <shuah@...nel.org>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>,
Simona Vetter <simona.vetter@...ll.ch>,
Dan Williams <dan.j.williams@...el.com>, linux-doc@...r.kernel.org,
linux-kselftest@...r.kernel.org, linux-kernel@...r.kernel.org,
Bartosz Golaszewski <bartosz.golaszewski@....qualcomm.com>
Subject: Re: [PATCH 0/3] Revert "revocable: Revocable resource management"
On Wed, Jan 28, 2026 at 11:01:03AM +0100, Wolfram Sang wrote:
>
> > One exception is I2C where the logic is so broken we need to first
> > rework a lot of drivers.
>
> Let's say "bitrotten" instead of broken. People used what was available
> at that time and they prevented the kernel from crashing, at least. And
> up to now, nobody had the bandwidth to improve that part in I2C.
>
> > Wolfram is on board with that though.
>
> Ack. I want to emphasize here that for I2C the SRCU part goes into the
> subsystem, not into the drivers.
I would just gently advise again that SRCU is not a pancea and should
only be used if the read side sections are super performance
critical. I'm not sure that describes I2C. rwsem is often a simpler
and better choice.
> > > The reason cdev keeps coming up is because there are few common ways a
> > > typical driver can actually generate concurrent operations during and
> > > after remove that would be problematic.
>
> Let me point out again that Dan Williams already had a PoC-patch for
> handling the cdev issue generically [1]. Dunno if this fact is present
> in the current discussion.
>
> [1] https://lkml.org/lkml/2021/1/20/999
Yeah, this was brought up a couple drafts of possible options were
exchanged already but nothing was really focused on and polished.
It is a tricky problem to find a storage location for the lock and
revoke so that the fops shim can access it while not disturbing the
actual driver.
Jason
Powered by blists - more mailing lists