Hi,
[ Background for linux-ide: ide_release_lock() spits out lots of
ide_release_lock: bug
warnings on Atari Falcon ]
On Fri, 27 Jun 2008, Michael Schmitz wrote:
The following patch does, indeed, fix the ide_release_lock imbalance. No more
warnings.
[ ... ]
We release the lock just before hwgroup->busy is cleared, so it should be
logical to get hold of the lock just after hwgroup->busy was set, no?
If hwgroup->busy serves a similar purpose to falconide_intr_lock, what about
moving the setting/clearing of hwgroup->busy into ide_{get,release}_lock()
(and possibly renaming ide_{get,release}_lock() to e.g.
ide_hwgroup_{set,clear}_busy())?
What about the other places where hwgroup->busy is set/cleared?
Uh - that's where it gets a bit sticky again. hwgroup->busy is set
and cleared quite a lot 'preemptively' all over ide-io.c, f.e. in timeout
handling. I'm not sure whether this would just reintroduce the bug
message.
The lock must be held as long as there are any interrupts to be expected
from IDE. If the hwgroup->busy semantics reflects just that, it's worth a
try.
Michael
--
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html