ide: remove obsoleted "hdx=noautotune" kernel parameter

Remove obsoleted "hdx=noautotune" kernel parameter
(it has been obsoleted since 1 Nov 2004).

Then make ide_hwif_t.autotune a single bit flag
and remove no longer needed IDE_TUNE_* defines.
Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
parent ef87f8d0
...@@ -1909,9 +1909,7 @@ static int ide_cdrom_setup(ide_drive_t *drive) ...@@ -1909,9 +1909,7 @@ static int ide_cdrom_setup(ide_drive_t *drive)
/* set correct block size */ /* set correct block size */
blk_queue_hardsect_size(drive->queue, CD_FRAMESIZE); blk_queue_hardsect_size(drive->queue, CD_FRAMESIZE);
if (drive->autotune == IDE_TUNE_DEFAULT || drive->dsc_overlap = (drive->next != drive);
drive->autotune == IDE_TUNE_AUTO)
drive->dsc_overlap = (drive->next != drive);
if (ide_cdrom_register(drive, nslots)) { if (ide_cdrom_register(drive, nslots)) {
printk(KERN_ERR "%s: %s failed to register device with the" printk(KERN_ERR "%s: %s failed to register device with the"
......
...@@ -472,9 +472,7 @@ static int do_probe (ide_drive_t *drive, u8 cmd) ...@@ -472,9 +472,7 @@ static int do_probe (ide_drive_t *drive, u8 cmd)
if (stat == (BUSY_STAT | READY_STAT)) if (stat == (BUSY_STAT | READY_STAT))
return 4; return 4;
if ((rc == 1 && cmd == WIN_PIDENTIFY) && if (rc == 1 && cmd == WIN_PIDENTIFY) {
((drive->autotune == IDE_TUNE_DEFAULT) ||
(drive->autotune == IDE_TUNE_AUTO))) {
printk(KERN_ERR "%s: no response (status = 0x%02x), " printk(KERN_ERR "%s: no response (status = 0x%02x), "
"resetting drive\n", drive->name, stat); "resetting drive\n", drive->name, stat);
msleep(50); msleep(50);
...@@ -829,13 +827,9 @@ static void ide_port_tune_devices(ide_hwif_t *hwif) ...@@ -829,13 +827,9 @@ static void ide_port_tune_devices(ide_hwif_t *hwif)
ide_drive_t *drive = &hwif->drives[unit]; ide_drive_t *drive = &hwif->drives[unit];
if (drive->present) { if (drive->present) {
if (drive->autotune == IDE_TUNE_AUTO) if (drive->autotune)
ide_set_max_pio(drive); ide_set_max_pio(drive);
if (drive->autotune != IDE_TUNE_DEFAULT &&
drive->autotune != IDE_TUNE_AUTO)
continue;
drive->nice1 = 1; drive->nice1 = 1;
if (hwif->dma_ops) if (hwif->dma_ops)
......
...@@ -900,7 +900,7 @@ static int __init ide_setup(char *s) ...@@ -900,7 +900,7 @@ static int __init ide_setup(char *s)
if (s[0] == 'h' && s[1] == 'd' && s[2] >= 'a' && s[2] <= max_drive) { if (s[0] == 'h' && s[1] == 'd' && s[2] >= 'a' && s[2] <= max_drive) {
const char *hd_words[] = { const char *hd_words[] = {
"none", "noprobe", "nowerr", "cdrom", "nodma", "none", "noprobe", "nowerr", "cdrom", "nodma",
"autotune", "noautotune", "-8", "-9", "-10", "autotune", "-7", "-8", "-9", "-10",
"noflush", "remap", "remap63", "scsi", NULL }; "noflush", "remap", "remap63", "scsi", NULL };
unit = s[2] - 'a'; unit = s[2] - 'a';
hw = unit / MAX_DRIVES; hw = unit / MAX_DRIVES;
...@@ -929,10 +929,7 @@ static int __init ide_setup(char *s) ...@@ -929,10 +929,7 @@ static int __init ide_setup(char *s)
drive->nodma = 1; drive->nodma = 1;
goto done; goto done;
case -6: /* "autotune" */ case -6: /* "autotune" */
drive->autotune = IDE_TUNE_AUTO; drive->autotune = 1;
goto obsolete_option;
case -7: /* "noautotune" */
drive->autotune = IDE_TUNE_NOAUTO;
goto obsolete_option; goto obsolete_option;
case -11: /* noflush */ case -11: /* noflush */
drive->noflush = 1; drive->noflush = 1;
......
...@@ -47,13 +47,6 @@ typedef unsigned char byte; /* used everywhere */ ...@@ -47,13 +47,6 @@ typedef unsigned char byte; /* used everywhere */
#define ERROR_RESET 3 /* Reset controller every 4th retry */ #define ERROR_RESET 3 /* Reset controller every 4th retry */
#define ERROR_RECAL 1 /* Recalibrate every 2nd retry */ #define ERROR_RECAL 1 /* Recalibrate every 2nd retry */
/*
* Tune flags
*/
#define IDE_TUNE_NOAUTO 2
#define IDE_TUNE_AUTO 1
#define IDE_TUNE_DEFAULT 0
/* /*
* state flags * state flags
*/ */
...@@ -328,7 +321,7 @@ typedef struct ide_drive_s { ...@@ -328,7 +321,7 @@ typedef struct ide_drive_s {
unsigned atapi_overlap : 1; /* ATAPI overlap (not supported) */ unsigned atapi_overlap : 1; /* ATAPI overlap (not supported) */
unsigned doorlocking : 1; /* for removable only: door lock/unlock works */ unsigned doorlocking : 1; /* for removable only: door lock/unlock works */
unsigned nodma : 1; /* disallow DMA */ unsigned nodma : 1; /* disallow DMA */
unsigned autotune : 2; /* 0=default, 1=autotune, 2=noautotune */ unsigned autotune : 1; /* 0=default, 1=autotune */
unsigned remap_0_to_1 : 1; /* 0=noremap, 1=remap 0->1 (for EZDrive) */ unsigned remap_0_to_1 : 1; /* 0=noremap, 1=remap 0->1 (for EZDrive) */
unsigned blocked : 1; /* 1=powermanagment told us not to do anything, so sleep nicely */ unsigned blocked : 1; /* 1=powermanagment told us not to do anything, so sleep nicely */
unsigned vdma : 1; /* 1=doing PIO over DMA 0=doing normal DMA */ unsigned vdma : 1; /* 1=doing PIO over DMA 0=doing normal DMA */
......
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