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

Reply via email to