Re: [PATCH] spi: Push the BKL down into the drivers

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: David Brownell <david-b@...>
Cc: <linux-kernel@...>, <spi-devel-general@...>
Date: Friday, May 23, 2008 - 7:09 am

On Thu, 22 May 2008 17:40:50 -0700
David Brownell <david-b@pacbell.net> wrote:


There isn't one. The big problem we have is that the ioctl methods were
implicitly called under the big kernel lock. Without pushing them down
into drivers we can't take the step of actually thinking at the driver
level "is this needed". Historically therefore we've never documented
*why* or *if* it was needed - it's just there. Pushing them into the
driver means the subsystem owner gets to see the implicit locking and can
actually ask the right questions with internal driver knowledge.

Whether it is needed is dependant on the internal locking model of the
driver - does it handle parallel ioctls correctly, are there races
against other functions in the driver (eg hot unplugs). That can't be
evaluated at a high level.

It's also made harder by the fact lots of drivers have buggy assumptions
about ioctl locking (watchdog was a fine example).

Alan
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] spi: Push the BKL down into the drivers, Alan Cox, (Thu May 22, 5:45 pm)
Re: [PATCH] spi: Push the BKL down into the drivers, David Brownell, (Thu May 22, 8:40 pm)
Re: [PATCH] spi: Push the BKL down into the drivers, Alan Cox, (Fri May 23, 7:09 am)