summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aacraid
diff options
context:
space:
mode:
authorMark Haverkamp <markh@osdl.org>2006-03-27 09:44:19 -0800
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-04-13 10:13:19 -0500
commit53926274f24e5c852dbe8f89dea16b7822549472 (patch)
treed468b352dfc8f148a8303e7a0206b8d48df640f8 /drivers/scsi/aacraid
parent95433badf0ff8dbc2caf14bc69c984841539715f (diff)
downloadblackbird-obmc-linux-53926274f24e5c852dbe8f89dea16b7822549472.tar.gz
blackbird-obmc-linux-53926274f24e5c852dbe8f89dea16b7822549472.zip
[SCSI] aacraid: Fix extra unregister_chrdev
Received from Mark Salyzyn If there are no aacraid controllers, we do not create the raid controller chrdev, thus when the driver is unloaded it performs a superfluous deregistration. Signed-off-by: Mark Haverkamp <markh@osdl.org> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/aacraid')
-rw-r--r--drivers/scsi/aacraid/linit.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/aacraid/linit.c b/drivers/scsi/aacraid/linit.c
index fbd4f5538ac1..9437a4c8b64a 100644
--- a/drivers/scsi/aacraid/linit.c
+++ b/drivers/scsi/aacraid/linit.c
@@ -1023,7 +1023,8 @@ static int __init aac_init(void)
static void __exit aac_exit(void)
{
- unregister_chrdev(aac_cfg_major, "aac");
+ if (aac_cfg_major > -1)
+ unregister_chrdev(aac_cfg_major, "aac");
pci_unregister_driver(&aac_pci_driver);
}
OpenPOWER on IntegriCloud