diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-10-17 12:09:11 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-10-17 12:09:11 -0400 |
commit | 42619d35c7af2f88cad56425fe3981f1f65ff0bd (patch) | |
tree | e2de0bfba684bcb8e2d3fd32c52365ce9055e129 | |
parent | e01286282eef85e4783b06fb2e0ed84fc111eb32 (diff) |
ide: remove IDE_AFLAG_NO_DOORLOCKING
Just use IDE_DFLAG_DOORLOCKING instead.
There should be no functional changes caused by this patch.
Acked-by: Borislav Petkov <petkovbb@gmail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
-rw-r--r-- | drivers/ide/ide-atapi.c | 2 | ||||
-rw-r--r-- | drivers/ide/ide-cd.c | 2 | ||||
-rw-r--r-- | drivers/ide/ide-cd_ioctl.c | 4 | ||||
-rw-r--r-- | drivers/ide/ide-floppy.c | 2 | ||||
-rw-r--r-- | drivers/ide/ide-probe.c | 1 | ||||
-rw-r--r-- | drivers/ide/ide-tape.c | 2 | ||||
-rw-r--r-- | include/linux/ide.h | 2 |
7 files changed, 7 insertions, 8 deletions
diff --git a/drivers/ide/ide-atapi.c b/drivers/ide/ide-atapi.c index 2e305714c209..4e58b9e7a58a 100644 --- a/drivers/ide/ide-atapi.c +++ b/drivers/ide/ide-atapi.c | |||
@@ -191,7 +191,7 @@ int ide_set_media_lock(ide_drive_t *drive, struct gendisk *disk, int on) | |||
191 | { | 191 | { |
192 | struct ide_atapi_pc pc; | 192 | struct ide_atapi_pc pc; |
193 | 193 | ||
194 | if (drive->atapi_flags & IDE_AFLAG_NO_DOORLOCK) | 194 | if ((drive->dev_flags & IDE_DFLAG_DOORLOCKING) == 0) |
195 | return 0; | 195 | return 0; |
196 | 196 | ||
197 | ide_init_pc(&pc); | 197 | ide_init_pc(&pc); |
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c index 7dc1a17a4dd8..2f4cc10391e5 100644 --- a/drivers/ide/ide-cd.c +++ b/drivers/ide/ide-cd.c | |||
@@ -1732,7 +1732,7 @@ static int ide_cdrom_probe_capabilities(ide_drive_t *drive) | |||
1732 | return 0; | 1732 | return 0; |
1733 | 1733 | ||
1734 | if ((buf[8 + 6] & 0x01) == 0) | 1734 | if ((buf[8 + 6] & 0x01) == 0) |
1735 | drive->atapi_flags |= IDE_AFLAG_NO_DOORLOCK; | 1735 | drive->dev_flags &= ~IDE_DFLAG_DOORLOCKING; |
1736 | if (buf[8 + 6] & 0x08) | 1736 | if (buf[8 + 6] & 0x08) |
1737 | drive->atapi_flags &= ~IDE_AFLAG_NO_EJECT; | 1737 | drive->atapi_flags &= ~IDE_AFLAG_NO_EJECT; |
1738 | if (buf[8 + 3] & 0x01) | 1738 | if (buf[8 + 3] & 0x01) |
diff --git a/drivers/ide/ide-cd_ioctl.c b/drivers/ide/ide-cd_ioctl.c index 37d89ead13dd..df3df0041eb6 100644 --- a/drivers/ide/ide-cd_ioctl.c +++ b/drivers/ide/ide-cd_ioctl.c | |||
@@ -136,7 +136,7 @@ int ide_cd_lockdoor(ide_drive_t *drive, int lockflag, | |||
136 | sense = &my_sense; | 136 | sense = &my_sense; |
137 | 137 | ||
138 | /* If the drive cannot lock the door, just pretend. */ | 138 | /* If the drive cannot lock the door, just pretend. */ |
139 | if (drive->atapi_flags & IDE_AFLAG_NO_DOORLOCK) { | 139 | if ((drive->dev_flags & IDE_DFLAG_DOORLOCKING) == 0) { |
140 | stat = 0; | 140 | stat = 0; |
141 | } else { | 141 | } else { |
142 | unsigned char cmd[BLK_MAX_CDB]; | 142 | unsigned char cmd[BLK_MAX_CDB]; |
@@ -157,7 +157,7 @@ int ide_cd_lockdoor(ide_drive_t *drive, int lockflag, | |||
157 | (sense->asc == 0x24 || sense->asc == 0x20)) { | 157 | (sense->asc == 0x24 || sense->asc == 0x20)) { |
158 | printk(KERN_ERR "%s: door locking not supported\n", | 158 | printk(KERN_ERR "%s: door locking not supported\n", |
159 | drive->name); | 159 | drive->name); |
160 | drive->atapi_flags |= IDE_AFLAG_NO_DOORLOCK; | 160 | drive->dev_flags &= ~IDE_DFLAG_DOORLOCKING; |
161 | stat = 0; | 161 | stat = 0; |
162 | } | 162 | } |
163 | 163 | ||
diff --git a/drivers/ide/ide-floppy.c b/drivers/ide/ide-floppy.c index 2cf98b531fd9..791a9d6f371c 100644 --- a/drivers/ide/ide-floppy.c +++ b/drivers/ide/ide-floppy.c | |||
@@ -592,7 +592,7 @@ static void idefloppy_setup(ide_drive_t *drive) | |||
592 | blk_queue_max_sectors(drive->queue, 64); | 592 | blk_queue_max_sectors(drive->queue, 64); |
593 | drive->atapi_flags |= IDE_AFLAG_CLIK_DRIVE; | 593 | drive->atapi_flags |= IDE_AFLAG_CLIK_DRIVE; |
594 | /* IOMEGA Clik! drives do not support lock/unlock commands */ | 594 | /* IOMEGA Clik! drives do not support lock/unlock commands */ |
595 | drive->atapi_flags |= IDE_AFLAG_NO_DOORLOCK; | 595 | drive->dev_flags &= ~IDE_DFLAG_DOORLOCKING; |
596 | } | 596 | } |
597 | 597 | ||
598 | (void) ide_floppy_get_capacity(drive); | 598 | (void) ide_floppy_get_capacity(drive); |
diff --git a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c index 19f8c7770a25..1649ea54f76c 100644 --- a/drivers/ide/ide-probe.c +++ b/drivers/ide/ide-probe.c | |||
@@ -208,6 +208,7 @@ static inline void do_identify (ide_drive_t *drive, u8 cmd) | |||
208 | drive->ready_stat = 0; | 208 | drive->ready_stat = 0; |
209 | if (ata_id_cdb_intr(id)) | 209 | if (ata_id_cdb_intr(id)) |
210 | drive->atapi_flags |= IDE_AFLAG_DRQ_INTERRUPT; | 210 | drive->atapi_flags |= IDE_AFLAG_DRQ_INTERRUPT; |
211 | drive->dev_flags |= IDE_DFLAG_DOORLOCKING; | ||
211 | /* we don't do head unloading on ATAPI devices */ | 212 | /* we don't do head unloading on ATAPI devices */ |
212 | drive->dev_flags |= IDE_DFLAG_NO_UNLOAD; | 213 | drive->dev_flags |= IDE_DFLAG_NO_UNLOAD; |
213 | return; | 214 | return; |
diff --git a/drivers/ide/ide-tape.c b/drivers/ide/ide-tape.c index d879c7797cde..a99e28f45156 100644 --- a/drivers/ide/ide-tape.c +++ b/drivers/ide/ide-tape.c | |||
@@ -2108,7 +2108,7 @@ static void idetape_get_mode_sense_results(ide_drive_t *drive) | |||
2108 | 2108 | ||
2109 | /* device lacks locking support according to capabilities page */ | 2109 | /* device lacks locking support according to capabilities page */ |
2110 | if ((caps[6] & 1) == 0) | 2110 | if ((caps[6] & 1) == 0) |
2111 | drive->atapi_flags |= IDE_AFLAG_NO_DOORLOCK; | 2111 | drive->dev_flags &= ~IDE_DFLAG_DOORLOCKING; |
2112 | 2112 | ||
2113 | if (caps[7] & 0x02) | 2113 | if (caps[7] & 0x02) |
2114 | tape->blk_size = 512; | 2114 | tape->blk_size = 512; |
diff --git a/include/linux/ide.h b/include/linux/ide.h index d111c3ebbbae..ba51a93fa547 100644 --- a/include/linux/ide.h +++ b/include/linux/ide.h | |||
@@ -464,8 +464,6 @@ struct ide_acpi_hwif_link; | |||
464 | /* ATAPI device flags */ | 464 | /* ATAPI device flags */ |
465 | enum { | 465 | enum { |
466 | IDE_AFLAG_DRQ_INTERRUPT = (1 << 0), | 466 | IDE_AFLAG_DRQ_INTERRUPT = (1 << 0), |
467 | /* Drive cannot lock the door. */ | ||
468 | IDE_AFLAG_NO_DOORLOCK = (1 << 2), | ||
469 | 467 | ||
470 | /* ide-cd */ | 468 | /* ide-cd */ |
471 | /* Drive cannot eject the disc. */ | 469 | /* Drive cannot eject the disc. */ |