diff options
author | Alan Cox <alan@lxorguk.ukuu.org.uk> | 2009-04-09 12:31:17 -0400 |
---|---|---|
committer | Jeff Garzik <jgarzik@redhat.com> | 2009-04-16 15:28:23 -0400 |
commit | e3cf95dd6d352954b663d2934110d6e30af2406d (patch) | |
tree | f3245e91c30e0c1e12a169af637373a8b5ff670a /include/linux/libata.h | |
parent | 62afe5d744047df8ff15a369f4c1ebad71c937d4 (diff) |
ata: Report 16/32bit PIO as best we can
The legacy old IDE ioctl API for this is a bit primitive so we try
and map stuff sensibly onto it.
- Set PIO over DMA devices to report 32bit
- Add ability to change the PIO32 settings if the controller permits it
- Add that functionality into the sff drivers
- Add that functionality into the VLB legacy driver
- Turn on the 32bit PIO on the ninja32 and add support there
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'include/linux/libata.h')
-rw-r--r-- | include/linux/libata.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/libata.h b/include/linux/libata.h index b450a2628855..3d501db36a26 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h | |||
@@ -209,6 +209,7 @@ enum { | |||
209 | 209 | ||
210 | /* bits 24:31 of ap->flags are reserved for LLD specific flags */ | 210 | /* bits 24:31 of ap->flags are reserved for LLD specific flags */ |
211 | 211 | ||
212 | |||
212 | /* struct ata_port pflags */ | 213 | /* struct ata_port pflags */ |
213 | ATA_PFLAG_EH_PENDING = (1 << 0), /* EH pending */ | 214 | ATA_PFLAG_EH_PENDING = (1 << 0), /* EH pending */ |
214 | ATA_PFLAG_EH_IN_PROGRESS = (1 << 1), /* EH in progress */ | 215 | ATA_PFLAG_EH_IN_PROGRESS = (1 << 1), /* EH in progress */ |
@@ -225,6 +226,9 @@ enum { | |||
225 | ATA_PFLAG_PM_PENDING = (1 << 18), /* PM operation pending */ | 226 | ATA_PFLAG_PM_PENDING = (1 << 18), /* PM operation pending */ |
226 | ATA_PFLAG_INIT_GTM_VALID = (1 << 19), /* initial gtm data valid */ | 227 | ATA_PFLAG_INIT_GTM_VALID = (1 << 19), /* initial gtm data valid */ |
227 | 228 | ||
229 | ATA_PFLAG_PIO32 = (1 << 20), /* 32bit PIO */ | ||
230 | ATA_PFLAG_PIO32CHANGE = (1 << 21), /* 32bit PIO can be turned on/off */ | ||
231 | |||
228 | /* struct ata_queued_cmd flags */ | 232 | /* struct ata_queued_cmd flags */ |
229 | ATA_QCFLAG_ACTIVE = (1 << 0), /* cmd not yet ack'd to scsi lyer */ | 233 | ATA_QCFLAG_ACTIVE = (1 << 0), /* cmd not yet ack'd to scsi lyer */ |
230 | ATA_QCFLAG_DMAMAP = (1 << 1), /* SG table is DMA mapped */ | 234 | ATA_QCFLAG_DMAMAP = (1 << 1), /* SG table is DMA mapped */ |
@@ -689,7 +693,10 @@ struct ata_port { | |||
689 | struct Scsi_Host *scsi_host; /* our co-allocated scsi host */ | 693 | struct Scsi_Host *scsi_host; /* our co-allocated scsi host */ |
690 | struct ata_port_operations *ops; | 694 | struct ata_port_operations *ops; |
691 | spinlock_t *lock; | 695 | spinlock_t *lock; |
696 | /* Flags owned by the EH context. Only EH should touch these once the | ||
697 | port is active */ | ||
692 | unsigned long flags; /* ATA_FLAG_xxx */ | 698 | unsigned long flags; /* ATA_FLAG_xxx */ |
699 | /* Flags that change dynamically, protected by ap->lock */ | ||
693 | unsigned int pflags; /* ATA_PFLAG_xxx */ | 700 | unsigned int pflags; /* ATA_PFLAG_xxx */ |
694 | unsigned int print_id; /* user visible unique port ID */ | 701 | unsigned int print_id; /* user visible unique port ID */ |
695 | unsigned int port_no; /* 0 based port no. inside the host */ | 702 | unsigned int port_no; /* 0 based port no. inside the host */ |
@@ -1595,6 +1602,7 @@ extern void ata_sff_drain_fifo(struct ata_queued_cmd *qc); | |||
1595 | extern void ata_sff_error_handler(struct ata_port *ap); | 1602 | extern void ata_sff_error_handler(struct ata_port *ap); |
1596 | extern void ata_sff_post_internal_cmd(struct ata_queued_cmd *qc); | 1603 | extern void ata_sff_post_internal_cmd(struct ata_queued_cmd *qc); |
1597 | extern int ata_sff_port_start(struct ata_port *ap); | 1604 | extern int ata_sff_port_start(struct ata_port *ap); |
1605 | extern int ata_sff_port_start32(struct ata_port *ap); | ||
1598 | extern void ata_sff_std_ports(struct ata_ioports *ioaddr); | 1606 | extern void ata_sff_std_ports(struct ata_ioports *ioaddr); |
1599 | extern unsigned long ata_bmdma_mode_filter(struct ata_device *dev, | 1607 | extern unsigned long ata_bmdma_mode_filter(struct ata_device *dev, |
1600 | unsigned long xfer_mask); | 1608 | unsigned long xfer_mask); |