Commit c6d738b8 authored by Jens Axboe's avatar Jens Axboe Committed by Linus Torvalds

[PATCH] make MO drive work with ide-floppy/ide-cd

Resend of the ide-cd buggy debug check removal.

From der.eremit@email.de.
parent 04421ade
......@@ -2871,6 +2871,11 @@ int ide_cdrom_probe_capabilities (ide_drive_t *drive)
struct atapi_capabilities_page cap;
int nslots = 1;
if (drive->media == ide_optical) {
printk("%s: ATAPI magneto-optical drive\n", drive->name);
return nslots;
}
if (CDROM_CONFIG_FLAGS(drive)->nec260) {
CDROM_CONFIG_FLAGS(drive)->no_eject = 0;
CDROM_CONFIG_FLAGS(drive)->audio_play = 1;
......@@ -3337,7 +3342,7 @@ static int ide_cdrom_attach (ide_drive_t *drive)
goto failed;
if (!drive->present)
goto failed;
if (drive->media != ide_cdrom)
if (drive->media != ide_cdrom && drive->media != ide_optical)
goto failed;
/* skip drives that we were told to ignore */
if (ignore != NULL) {
......
......@@ -1235,7 +1235,7 @@ struct gendisk *ata_probe(dev_t dev, int *part, void *data)
(void) request_module("ide-disk");
if (drive->scsi)
(void) request_module("ide-scsi");
if (drive->media == ide_cdrom)
if (drive->media == ide_cdrom || drive->media == ide_optical)
(void) request_module("ide-cd");
if (drive->media == ide_tape)
(void) request_module("ide-tape");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment