diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2009-03-13 17:44:51 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2009-03-13 17:44:51 -0400 |
commit | 97fb44eb6bc01f4ffed4300e475aa15e44877375 (patch) | |
tree | 481ed6efd0babe7185cae04f2fd295426b36411d /drivers/block/nbd.c | |
parent | e4707dd3e9d0cb57597b6568a5e51fea5d6fca41 (diff) | |
parent | 148854c65ea8046b045672fd49f4333aefaa3ab5 (diff) |
Merge branch 'for-rmk' of git://git.pengutronix.de/git/imx/linux-2.6 into devel
Conflicts:
arch/arm/mach-at91/gpio.c
Diffstat (limited to 'drivers/block/nbd.c')
-rw-r--r-- | drivers/block/nbd.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c index 34f80fa6fed1..8299e2d3b611 100644 --- a/drivers/block/nbd.c +++ b/drivers/block/nbd.c | |||
@@ -549,6 +549,15 @@ static void do_nbd_request(struct request_queue * q) | |||
549 | 549 | ||
550 | BUG_ON(lo->magic != LO_MAGIC); | 550 | BUG_ON(lo->magic != LO_MAGIC); |
551 | 551 | ||
552 | if (unlikely(!lo->sock)) { | ||
553 | printk(KERN_ERR "%s: Attempted send on closed socket\n", | ||
554 | lo->disk->disk_name); | ||
555 | req->errors++; | ||
556 | nbd_end_request(req); | ||
557 | spin_lock_irq(q->queue_lock); | ||
558 | continue; | ||
559 | } | ||
560 | |||
552 | spin_lock_irq(&lo->queue_lock); | 561 | spin_lock_irq(&lo->queue_lock); |
553 | list_add_tail(&req->queuelist, &lo->waiting_queue); | 562 | list_add_tail(&req->queuelist, &lo->waiting_queue); |
554 | spin_unlock_irq(&lo->queue_lock); | 563 | spin_unlock_irq(&lo->queue_lock); |