BLOCK: Fix bad sharing of tag busy list on queues with shared tag maps
commit0520fb16465a12dda986d51fc7be3eca6e82603b
authorJens Axboe <jens.axboe@oracle.com>
Tue, 30 Oct 2007 10:18:15 +0000 (30 11:18 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 16 Nov 2007 16:12:44 +0000 (16 08:12 -0800)
tree8ae08c4ff48af8606ff423d39088f94f179cfc65
parentbba9d994eb41060c8a6e09207f659cf4e26e9384
BLOCK: Fix bad sharing of tag busy list on queues with shared tag maps

patch 6eca9004dfcb274a502438a591df5b197690afb1 in mainline.

For the locking to work, only the tag map and tag bit map may be shared
(incidentally, I was just explaining this to Nick yesterday, but I
apparently didn't review the code well enough myself). But we also share
the busy list!  The busy_list must be queue private, or we need a
block_queue_tag covering lock as well.

So we have to move the busy_list to the queue. This'll work fine, and
it'll actually also fix a problem with blk_queue_invalidate_tags() which
will invalidate tags across all shared queues. This is a bit confusing,
the low level driver should call it for each queue seperately since
otherwise you cannot kill tags on just a single queue for eg a hard
drive that stops responding. Since the function has no callers
currently, it's not an issue.

This is fixed with commit 6eca9004dfcb274a502438a591df5b197690afb1 in
Linus' tree.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
block/ll_rw_blk.c
include/linux/blkdev.h