aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-10-17 12:09:11 -0400
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-10-17 12:09:11 -0400
commitfe11edfaabf1787c05d782a7b33e6497d1118b1d (patch)
treebf58cca2c2e635e54acf67079bdb4ed26790a84a
parent6f84083bbb7d206c8555e5834a2c9b887452fd54 (diff)
ide: IDE_AFLAG_MEDIA_CHANGED -> IDE_DFLAG_MEDIA_CHANGED
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-cd.c6
-rw-r--r--drivers/ide/ide-cd_ioctl.c4
-rw-r--r--drivers/ide/ide-floppy.c6
-rw-r--r--include/linux/ide.h4
4 files changed, 10 insertions, 10 deletions
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c
index 3308b1cd3a33..7dc1a17a4dd8 100644
--- a/drivers/ide/ide-cd.c
+++ b/drivers/ide/ide-cd.c
@@ -99,7 +99,7 @@ static void ide_cd_put(struct cdrom_info *cd)
99/* Mark that we've seen a media change and invalidate our internal buffers. */ 99/* Mark that we've seen a media change and invalidate our internal buffers. */
100static void cdrom_saw_media_change(ide_drive_t *drive) 100static void cdrom_saw_media_change(ide_drive_t *drive)
101{ 101{
102 drive->atapi_flags |= IDE_AFLAG_MEDIA_CHANGED; 102 drive->dev_flags |= IDE_DFLAG_MEDIA_CHANGED;
103 drive->atapi_flags &= ~IDE_AFLAG_TOC_VALID; 103 drive->atapi_flags &= ~IDE_AFLAG_TOC_VALID;
104} 104}
105 105
@@ -1986,8 +1986,8 @@ static int ide_cdrom_setup(ide_drive_t *drive)
1986 if (!drive->queue->unplug_delay) 1986 if (!drive->queue->unplug_delay)
1987 drive->queue->unplug_delay = 1; 1987 drive->queue->unplug_delay = 1;
1988 1988
1989 drive->atapi_flags = IDE_AFLAG_MEDIA_CHANGED | IDE_AFLAG_NO_EJECT | 1989 drive->dev_flags |= IDE_DFLAG_MEDIA_CHANGED;
1990 ide_cd_flags(id); 1990 drive->atapi_flags = IDE_AFLAG_NO_EJECT | ide_cd_flags(id);
1991 1991
1992 if ((drive->atapi_flags & IDE_AFLAG_VERTOS_300_SSD) && 1992 if ((drive->atapi_flags & IDE_AFLAG_VERTOS_300_SSD) &&
1993 fw_rev[4] == '1' && fw_rev[6] <= '2') 1993 fw_rev[4] == '1' && fw_rev[6] <= '2')
diff --git a/drivers/ide/ide-cd_ioctl.c b/drivers/ide/ide-cd_ioctl.c
index 74231b41f611..37d89ead13dd 100644
--- a/drivers/ide/ide-cd_ioctl.c
+++ b/drivers/ide/ide-cd_ioctl.c
@@ -86,8 +86,8 @@ int ide_cdrom_check_media_change_real(struct cdrom_device_info *cdi,
86 86
87 if (slot_nr == CDSL_CURRENT) { 87 if (slot_nr == CDSL_CURRENT) {
88 (void) cdrom_check_status(drive, NULL); 88 (void) cdrom_check_status(drive, NULL);
89 retval = (drive->atapi_flags & IDE_AFLAG_MEDIA_CHANGED) ? 1 : 0; 89 retval = (drive->dev_flags & IDE_DFLAG_MEDIA_CHANGED) ? 1 : 0;
90 drive->atapi_flags &= ~IDE_AFLAG_MEDIA_CHANGED; 90 drive->dev_flags &= ~IDE_DFLAG_MEDIA_CHANGED;
91 return retval; 91 return retval;
92 } else { 92 } else {
93 return -EINVAL; 93 return -EINVAL;
diff --git a/drivers/ide/ide-floppy.c b/drivers/ide/ide-floppy.c
index 3271e56d091c..df410c7191ac 100644
--- a/drivers/ide/ide-floppy.c
+++ b/drivers/ide/ide-floppy.c
@@ -689,8 +689,8 @@ static int idefloppy_open(struct inode *inode, struct file *filp)
689 goto out_put_floppy; 689 goto out_put_floppy;
690 } 690 }
691 691
692 drive->atapi_flags |= IDE_AFLAG_MEDIA_CHANGED;
693 ide_set_media_lock(drive, disk, 1); 692 ide_set_media_lock(drive, disk, 1);
693 drive->dev_flags |= IDE_DFLAG_MEDIA_CHANGED;
694 check_disk_change(inode->i_bdev); 694 check_disk_change(inode->i_bdev);
695 } else if (drive->atapi_flags & IDE_AFLAG_FORMAT_IN_PROGRESS) { 695 } else if (drive->atapi_flags & IDE_AFLAG_FORMAT_IN_PROGRESS) {
696 ret = -EBUSY; 696 ret = -EBUSY;
@@ -747,8 +747,8 @@ static int idefloppy_media_changed(struct gendisk *disk)
747 drive->dev_flags &= ~IDE_DFLAG_ATTACH; 747 drive->dev_flags &= ~IDE_DFLAG_ATTACH;
748 return 0; 748 return 0;
749 } 749 }
750 ret = !!(drive->atapi_flags & IDE_AFLAG_MEDIA_CHANGED); 750 ret = !!(drive->dev_flags & IDE_DFLAG_MEDIA_CHANGED);
751 drive->atapi_flags &= ~IDE_AFLAG_MEDIA_CHANGED; 751 drive->dev_flags &= ~IDE_DFLAG_MEDIA_CHANGED;
752 return ret; 752 return ret;
753} 753}
754 754
diff --git a/include/linux/ide.h b/include/linux/ide.h
index c47e371554c1..155a57f55c60 100644
--- a/include/linux/ide.h
+++ b/include/linux/ide.h
@@ -464,7 +464,6 @@ struct ide_acpi_hwif_link;
464/* ATAPI device flags */ 464/* ATAPI device flags */
465enum { 465enum {
466 IDE_AFLAG_DRQ_INTERRUPT = (1 << 0), 466 IDE_AFLAG_DRQ_INTERRUPT = (1 << 0),
467 IDE_AFLAG_MEDIA_CHANGED = (1 << 1),
468 /* Drive cannot lock the door. */ 467 /* Drive cannot lock the door. */
469 IDE_AFLAG_NO_DOORLOCK = (1 << 2), 468 IDE_AFLAG_NO_DOORLOCK = (1 << 2),
470 469
@@ -578,7 +577,8 @@ enum {
578 /* don't unload heads */ 577 /* don't unload heads */
579 IDE_DFLAG_NO_UNLOAD = (1 << 27), 578 IDE_DFLAG_NO_UNLOAD = (1 << 27),
580 /* heads unloaded, please don't reset port */ 579 /* heads unloaded, please don't reset port */
581 IDE_DFLAG_PARKED = (1 << 28) 580 IDE_DFLAG_PARKED = (1 << 28),
581 IDE_DFLAG_MEDIA_CHANGED = (1 << 29),
582}; 582};
583 583
584struct ide_drive_s { 584struct ide_drive_s {