[PATCH] uml ubd driver: ubd_io_lock usage fixup
authorPaolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Tue, 31 Oct 2006 06:07:08 +0000 (22:07 -0800)
committerLinus Torvalds <torvalds@g5.osdl.org>
Tue, 31 Oct 2006 16:06:59 +0000 (08:06 -0800)
commit33f775eea185e8df7701c4afc2c8fcee85c83282
tree5cbba5e09cba9ab84ddba06cf23e1950ffbec222
parentd7fb2c3865ca0f95d92e2864c3dc9220789d83f5
[PATCH] uml ubd driver: ubd_io_lock usage fixup

Add some comments about requirements for ubd_io_lock and expand its use.

When an irq signals that the "controller" (i.e.  another thread on the host,
which does the actual requests and is the only one blocked on I/O on the host)
has done some work, we call again the request function ourselves
(do_ubd_request).

We now do that with ubd_io_lock held - that's useful to protect against
concurrent calls to elv_next_request and so on.

XXX: Maybe we shouldn't call at all the request function.  Input needed on
this.  Are we supposed to plug and unplug the queue?  That code "indirectly"
does that by setting a flag, called do_ubd, which makes the request function
return (it's a residual of 2.4 block layer interface).

Meanwhile, however, merge this patch, which improves things.

Cc: Jens Axboe <axboe@suse.de>
Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Cc: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/um/drivers/ubd_kern.c