From 6a445d3ba6b90ce13a843ad5d1a0867388b08096 Mon Sep 17 00:00:00 2001
From: Mike Miller <mike.miller@hp.com>
Date: Tue, 13 Sep 2005 01:25:23 -0700
Subject: [PATCH] [PATCH] cciss: bug fix in cciss_remove_one

This patch fixes a bug in cciss_remove_one.  A set of braces was missing for
the if statement causing an Oops on driver unload.

Signed-off-by: Mike Miller <mike.miller@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
---
 drivers/block/cciss.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c
index a12b95eef18..49f05410a11 100644
--- a/drivers/block/cciss.c
+++ b/drivers/block/cciss.c
@@ -3095,9 +3095,10 @@ static void __devexit cciss_remove_one (struct pci_dev *pdev)
 	/* remove it from the disk list */
 	for (j = 0; j < NWD; j++) {
 		struct gendisk *disk = hba[i]->gendisk[j];
-		if (disk->flags & GENHD_FL_UP)
-			blk_cleanup_queue(disk->queue);
+		if (disk->flags & GENHD_FL_UP) {
 			del_gendisk(disk);
+			blk_cleanup_queue(disk->queue);
+		}
 	}
 
 	pci_free_consistent(hba[i]->pdev, NR_CMDS * sizeof(CommandList_struct),
-- 
2.41.3