diff options
author | Andrew Patterson <andrew.patterson@hp.com> | 2009-09-17 13:46:53 -0500 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2009-10-01 21:15:40 +0200 |
commit | c64bebcd7f33a6260b6d4c9999f797a633a3fa1c (patch) | |
tree | 2638cacd891903a765062fb188a66bfcb6e7061b /drivers/block | |
parent | 4d761609471f7e543c880dd47ef5e1669076081b (diff) | |
download | kernel_samsung_smdk4412-c64bebcd7f33a6260b6d4c9999f797a633a3fa1c.zip kernel_samsung_smdk4412-c64bebcd7f33a6260b6d4c9999f797a633a3fa1c.tar.gz kernel_samsung_smdk4412-c64bebcd7f33a6260b6d4c9999f797a633a3fa1c.tar.bz2 |
cciss: Remove sysfs entries for logical drives on driver cleanup.
Sysfs entries for logical drives need to be removed when a drive is
deleted during driver cleanup.
Signed-off-by: Andrew Patterson <andrew.patterson@hp.com>
Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Acked-by: Mike Miller <mike.miller@hp.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'drivers/block')
-rw-r--r-- | drivers/block/cciss.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c index b890f8b..f162f96 100644 --- a/drivers/block/cciss.c +++ b/drivers/block/cciss.c @@ -1978,7 +1978,6 @@ static int rebuild_lun_table(ctlr_info_t *h, int first_time) h->drv[i].busy_configuring = 1; spin_unlock_irqrestore(CCISS_LOCK(h->ctlr), flags); return_code = deregister_disk(h, i, 1); - cciss_destroy_ld_sysfs_entry(&h->drv[i]); h->drv[i].busy_configuring = 0; } } @@ -2119,6 +2118,7 @@ static int deregister_disk(ctlr_info_t *h, int drv_index, * indicate that this element of the drive * array is free. */ + cciss_destroy_ld_sysfs_entry(drv); if (clear_all) { /* check to see if it was the last disk */ @@ -4142,6 +4142,9 @@ static void __devexit cciss_remove_one(struct pci_dev *pdev) if (q) blk_cleanup_queue(q); } + if (hba[i]->drv[j].raid_level != -1) + cciss_destroy_ld_sysfs_entry(&hba[i]->drv[j]); + } #ifdef CONFIG_CISS_SCSI_TAPE |