aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block/xen-blkfront.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-06-01 15:06:21 -0400
committerIngo Molnar <mingo@elte.hu>2009-06-01 15:06:21 -0400
commit3d58f48ba05caed9118bce62b3047f8683438835 (patch)
tree94c911034f0e14ded73d3e9e6e9f8e22b6cad822 /drivers/block/xen-blkfront.c
parentabfe0af9813153bae8c85d9bac966bafcb8ddab1 (diff)
parentd9244b5d2fbfe9fa540024b410047af13ceec90f (diff)
Merge branch 'linus' into irq/numa
Conflicts: arch/mips/sibyte/bcm1480/irq.c arch/mips/sibyte/sb1250/irq.c Merge reason: we gathered a few conflicts plus update to latest upstream fixes. Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'drivers/block/xen-blkfront.c')
-rw-r--r--drivers/block/xen-blkfront.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/block/xen-blkfront.c b/drivers/block/xen-blkfront.c
index 8f905089b72b..a6cbf7b808e6 100644
--- a/drivers/block/xen-blkfront.c
+++ b/drivers/block/xen-blkfront.c
@@ -934,8 +934,6 @@ static void blkfront_closing(struct xenbus_device *dev)
934 934
935 spin_lock_irqsave(&blkif_io_lock, flags); 935 spin_lock_irqsave(&blkif_io_lock, flags);
936 936
937 del_gendisk(info->gd);
938
939 /* No more blkif_request(). */ 937 /* No more blkif_request(). */
940 blk_stop_queue(info->rq); 938 blk_stop_queue(info->rq);
941 939
@@ -949,6 +947,8 @@ static void blkfront_closing(struct xenbus_device *dev)
949 blk_cleanup_queue(info->rq); 947 blk_cleanup_queue(info->rq);
950 info->rq = NULL; 948 info->rq = NULL;
951 949
950 del_gendisk(info->gd);
951
952 out: 952 out:
953 xenbus_frontend_closed(dev); 953 xenbus_frontend_closed(dev);
954} 954}
@@ -977,8 +977,10 @@ static void backend_changed(struct xenbus_device *dev,
977 break; 977 break;
978 978
979 case XenbusStateClosing: 979 case XenbusStateClosing:
980 if (info->gd == NULL) 980 if (info->gd == NULL) {
981 xenbus_dev_fatal(dev, -ENODEV, "gd is NULL"); 981 xenbus_frontend_closed(dev);
982 break;
983 }
982 bd = bdget_disk(info->gd, 0); 984 bd = bdget_disk(info->gd, 0);
983 if (bd == NULL) 985 if (bd == NULL)
984 xenbus_dev_fatal(dev, -ENODEV, "bdget failed"); 986 xenbus_dev_fatal(dev, -ENODEV, "bdget failed");