summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/st.c
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@pobox.com>2005-08-17 06:51:31 +0200
committerJeff Garzik <jgarzik@pobox.com>2005-08-17 06:51:31 +0200
commita2e30e529a48ef4e106e405f91cf4ae525bb01c4 (patch)
tree2def96ef17c0672c30f1a10287552978bf1d0b1c /drivers/scsi/st.c
parent[PATCH] SATA: rewritten sil24 driver (diff)
parent[PATCH] iSeries build with newer assemblers and compilers (diff)
downloadlinux-a2e30e529a48ef4e106e405f91cf4ae525bb01c4.tar.xz
linux-a2e30e529a48ef4e106e405f91cf4ae525bb01c4.zip
Merge /spare/repo/linux-2.6/
Diffstat (limited to 'drivers/scsi/st.c')
-rw-r--r--drivers/scsi/st.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/scsi/st.c b/drivers/scsi/st.c
index 0291a8fb654d..0a7839db5752 100644
--- a/drivers/scsi/st.c
+++ b/drivers/scsi/st.c
@@ -4149,12 +4149,10 @@ static int __init init_st(void)
do_create_driverfs_files();
return 0;
}
- if (st_sysfs_class)
- class_destroy(st_sysfs_class);
unregister_chrdev_region(MKDEV(SCSI_TAPE_MAJOR, 0),
-
ST_MAX_TAPE_ENTRIES);
}
+ class_destroy(st_sysfs_class);
printk(KERN_ERR "Unable to get major %d for SCSI tapes\n", SCSI_TAPE_MAJOR);
return 1;
@@ -4162,13 +4160,11 @@ static int __init init_st(void)
static void __exit exit_st(void)
{
- if (st_sysfs_class)
- class_destroy(st_sysfs_class);
- st_sysfs_class = NULL;
do_remove_driverfs_files();
scsi_unregister_driver(&st_template.gendrv);
unregister_chrdev_region(MKDEV(SCSI_TAPE_MAJOR, 0),
ST_MAX_TAPE_ENTRIES);
+ class_destroy(st_sysfs_class);
kfree(scsi_tapes);
printk(KERN_INFO "st: Unloaded.\n");
}