]> xenbits.xensource.com Git - people/vhanquez/xen.git/commitdiff
Stupidly forgot there is a separate waitqueue for free pending request
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Thu, 6 Apr 2006 10:14:06 +0000 (11:14 +0100)
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Thu, 6 Apr 2006 10:14:06 +0000 (11:14 +0100)
structures in blkback. Fix my changes to blkif_schedule().

Signed-off-by: Keir Fraser <keir@xensource.com>
linux-2.6-xen-sparse/drivers/xen/blkback/blkback.c

index 587f49f0f2bb9c7bc3dd30aadbb826356da2da32..477cab4bc60bcffa288476b4931ad99923f93d89 100644 (file)
@@ -225,8 +225,11 @@ int blkif_schedule(void *arg)
        while (!kthread_should_stop()) {
                wait_event_interruptible(
                        blkif->wq,
-                       (atomic_read(&blkif->io_pending) &&
-                        !list_empty(&pending_free)) ||
+                       atomic_read(&blkif->io_pending) ||
+                       kthread_should_stop());
+               wait_event_interruptible(
+                       pending_free_wq,
+                       !list_empty(&pending_free) ||
                        kthread_should_stop());
 
                atomic_set(&blkif->io_pending, 0);