diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/ide.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/include/linux/ide.h b/include/linux/ide.h index 08c91e21cf47..95c6e00a72e8 100644 --- a/include/linux/ide.h +++ b/include/linux/ide.h | |||
| @@ -532,7 +532,7 @@ struct ide_drive_s { | |||
| 532 | 532 | ||
| 533 | unsigned int bios_cyl; /* BIOS/fdisk/LILO number of cyls */ | 533 | unsigned int bios_cyl; /* BIOS/fdisk/LILO number of cyls */ |
| 534 | unsigned int cyl; /* "real" number of cyls */ | 534 | unsigned int cyl; /* "real" number of cyls */ |
| 535 | unsigned int drive_data; /* used by set_pio_mode/dev_select() */ | 535 | void *drive_data; /* used by set_pio_mode/dev_select() */ |
| 536 | unsigned int failures; /* current failure count */ | 536 | unsigned int failures; /* current failure count */ |
| 537 | unsigned int max_failures; /* maximum allowed failure count */ | 537 | unsigned int max_failures; /* maximum allowed failure count */ |
| 538 | u64 probed_capacity;/* initial/native media capacity */ | 538 | u64 probed_capacity;/* initial/native media capacity */ |
| @@ -1550,6 +1550,16 @@ static inline ide_drive_t *ide_get_pair_dev(ide_drive_t *drive) | |||
| 1550 | return (peer->dev_flags & IDE_DFLAG_PRESENT) ? peer : NULL; | 1550 | return (peer->dev_flags & IDE_DFLAG_PRESENT) ? peer : NULL; |
| 1551 | } | 1551 | } |
| 1552 | 1552 | ||
| 1553 | static inline void *ide_get_drivedata(ide_drive_t *drive) | ||
| 1554 | { | ||
| 1555 | return drive->drive_data; | ||
| 1556 | } | ||
| 1557 | |||
| 1558 | static inline void ide_set_drivedata(ide_drive_t *drive, void *data) | ||
| 1559 | { | ||
| 1560 | drive->drive_data = data; | ||
| 1561 | } | ||
| 1562 | |||
| 1553 | #define ide_port_for_each_dev(i, dev, port) \ | 1563 | #define ide_port_for_each_dev(i, dev, port) \ |
| 1554 | for ((i) = 0; ((dev) = (port)->devices[i]) || (i) < MAX_DRIVES; (i)++) | 1564 | for ((i) = 0; ((dev) = (port)->devices[i]) || (i) < MAX_DRIVES; (i)++) |
| 1555 | 1565 | ||
