ide: ide_dev_has_iordy() -> ata_id_has_iordy()

* Remove (id[ATA_ID_FIELD_VALID] & 2) check from ide_dev_has_iordy()
  (it is for validity of words 64-70, IORDY is in word 49).

* ide_dev_has_iordy() -> ata_id_has_iordy()

Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
parent 9fa295e1
...@@ -61,7 +61,7 @@ static unsigned int get_pio_timings(ide_drive_t *drive, u8 pio) ...@@ -61,7 +61,7 @@ static unsigned int get_pio_timings(ide_drive_t *drive, u8 pio)
if (cmd_off == 0) if (cmd_off == 0)
cmd_off = 1; cmd_off = 1;
if (pio > 2 || ide_dev_has_iordy(drive->id)) if (pio > 2 || ata_id_has_iordy(drive->id))
iordy = 0x40; iordy = 0x40;
return (cmd_on - 1) << 8 | (cmd_off - 1) | iordy; return (cmd_on - 1) << 8 | (cmd_off - 1) | iordy;
......
...@@ -1382,11 +1382,6 @@ const char *ide_xfer_verbose(u8 mode); ...@@ -1382,11 +1382,6 @@ const char *ide_xfer_verbose(u8 mode);
extern void ide_toggle_bounce(ide_drive_t *drive, int on); extern void ide_toggle_bounce(ide_drive_t *drive, int on);
extern int ide_set_xfer_rate(ide_drive_t *drive, u8 rate); extern int ide_set_xfer_rate(ide_drive_t *drive, u8 rate);
static inline int ide_dev_has_iordy(u16 *id)
{
return ((id[ATA_ID_FIELD_VALID] & 2) && ata_id_has_iordy(id)) ? 1 : 0;
}
static inline int ide_dev_is_sata(u16 *id) static inline int ide_dev_is_sata(u16 *id)
{ {
/* /*
......
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