From: Mike Miller Date: Tue, 13 Dec 2005 06:17:14 +0000 (-0800) Subject: [PATCH] cciss: fix for deregister_disk X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=2f6331faf58a4727a9f1138cd6db30d05b124220;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git [PATCH] cciss: fix for deregister_disk This patch adds setting our drv->queue = NULL back in deregister_disk. The drv->queue is part of our controller struct. blk_cleanup_queue works only on the queue in the gendisk struct. Signed-off-by: Mike Miller Cc: Jens Axboe Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c index e34104d32637..c3441b3f086e 100644 --- a/drivers/block/cciss.c +++ b/drivers/block/cciss.c @@ -1464,8 +1464,10 @@ static int deregister_disk(struct gendisk *disk, drive_info_struct *drv, request_queue_t *q = disk->queue; if (disk->flags & GENHD_FL_UP) del_gendisk(disk); - if (q) + if (q) { blk_cleanup_queue(q); + drv->queue = NULL; + } } }