patch-2.2.4 linux/drivers/block/ide-disk.c
Next file: linux/drivers/block/ide-pmac.c
Previous file: linux/drivers/block/ide-cd.h
Back to the patch index
Back to the overall index
- Lines: 32
- Date:
Wed Mar 10 17:49:43 1999
- Orig file:
v2.2.3/linux/drivers/block/ide-disk.c
- Orig date:
Tue Feb 23 15:21:33 1999
diff -u --recursive --new-file v2.2.3/linux/drivers/block/ide-disk.c linux/drivers/block/ide-disk.c
@@ -670,10 +670,15 @@
if (id == NULL)
return;
- /* check for removable disks (eg. SYQUEST), ignore 'WD' drives */
- if (id->config & (1<<7)) { /* removable disk ? */
+ /*
+ * CompactFlash cards and their brethern look just like hard drives
+ * to us, but they are removable and don't have a doorlock mechanism.
+ */
+ if (drive->removable && !drive_is_flashcard(drive)) {
+ /*
+ * Removable disks (eg. SYQUEST); ignore 'WD' drives
+ */
if (id->model[0] != 'W' || id->model[1] != 'D') {
- drive->removable = 1;
drive->doorlocking = 1;
}
}
@@ -804,12 +809,6 @@
MOD_INC_USE_COUNT;
while ((drive = ide_scan_devices (ide_disk, idedisk_driver.name, NULL, failed++)) != NULL) {
-
- /* SunDisk drives: ignore "second" drive; can mess up non-Sun systems! FIXME */
- struct hd_driveid *id = drive->id;
- if (id && id->model[0] == 'S' && id->model[1] == 'u' && drive->select.b.unit)
- continue;
-
if (ide_register_subdriver (drive, &idedisk_driver, IDE_SUBDRIVER_VERSION)) {
printk (KERN_ERR "ide-disk: %s: Failed to register the driver with ide.c\n", drive->name);
continue;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)