diff options
| author | Jeff Garzik <jgarzik@pobox.com> | 2004-07-06 02:53:25 -0400 |
|---|---|---|
| committer | Jeff Garzik <jgarzik@pobox.com> | 2004-07-06 02:53:25 -0400 |
| commit | 0c558ca1c216d5eaf7b67ffce9473bac2f0738d2 (patch) | |
| tree | 8d6624c15e62d0d816ed1c7bfddfee00f0510637 /include | |
| parent | 07f0a148b27e12aa11086153ca9425d311e20522 (diff) | |
| parent | 1d6fb7da31f8d134a10e9b55e8d7683bd6bfb1d4 (diff) | |
Merge pobox.com:/spare/repo/linux-2.6
into pobox.com:/spare/repo/libata-2.6
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/ata.h | 7 | ||||
| -rw-r--r-- | include/linux/libata.h | 23 |
2 files changed, 23 insertions, 7 deletions
diff --git a/include/linux/ata.h b/include/linux/ata.h index 7a99d7ee2f89..c8c5a0385414 100644 --- a/include/linux/ata.h +++ b/include/linux/ata.h @@ -42,6 +42,7 @@ enum { ATA_ID_SERNO_OFS = 10, ATA_ID_MAJOR_VER = 80, ATA_ID_PIO_MODES = 64, + ATA_ID_MWDMA_MODES = 63, ATA_ID_UDMA_MODES = 88, ATA_ID_PIO4 = (1 << 1), @@ -133,8 +134,14 @@ enum { XFER_UDMA_2 = 0x42, XFER_UDMA_1 = 0x41, XFER_UDMA_0 = 0x40, + XFER_MW_DMA_2 = 0x22, + XFER_MW_DMA_1 = 0x21, + XFER_MW_DMA_0 = 0x20, XFER_PIO_4 = 0x0C, XFER_PIO_3 = 0x0B, + XFER_PIO_2 = 0x0A, + XFER_PIO_1 = 0x09, + XFER_PIO_0 = 0x08, /* ATAPI stuff */ ATAPI_PKT_DMA = (1 << 0), diff --git a/include/linux/libata.h b/include/linux/libata.h index b646a48345a0..f77a2863c187 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h @@ -32,7 +32,6 @@ /* * compile-time options */ -#undef ATA_FORCE_PIO /* do not configure or use DMA */ #undef ATA_DEBUG /* debugging output */ #undef ATA_VERBOSE_DEBUG /* yet more debugging output */ #undef ATA_IRQ_TRAP /* define to ack screaming irqs */ @@ -140,6 +139,13 @@ enum { PORT_UNKNOWN = 0, PORT_ENABLED = 1, PORT_DISABLED = 2, + + /* encoding various smaller bitmaps into a single + * unsigned long bitmap + */ + ATA_SHIFT_UDMA = 0, + ATA_SHIFT_MWDMA = 8, + ATA_SHIFT_PIO = 11, }; enum pio_task_states { @@ -188,6 +194,7 @@ struct ata_probe_ent { struct ata_ioports port[ATA_MAX_PORTS]; unsigned int n_ports; unsigned int pio_mask; + unsigned int mwdma_mask; unsigned int udma_mask; unsigned int legacy_mode; unsigned long irq; @@ -251,8 +258,10 @@ struct ata_device { unsigned int class; /* ATA_DEV_xxx */ unsigned int devno; /* 0 or 1 */ u16 id[ATA_ID_WORDS]; /* IDENTIFY xxx DEVICE data */ - unsigned int pio_mode; - unsigned int udma_mode; + u8 pio_mode; + u8 dma_mode; + u8 xfer_mode; + unsigned int xfer_shift; /* ATA_SHIFT_xxx */ /* cache info about current transfer mode */ u8 xfer_protocol; /* taskfile xfer protocol */ @@ -277,6 +286,7 @@ struct ata_port { unsigned int bus_state; unsigned int port_state; unsigned int pio_mask; + unsigned int mwdma_mask; unsigned int udma_mask; unsigned int cbl; /* cable type; ATA_CBL_xxx */ @@ -303,10 +313,8 @@ struct ata_port_operations { void (*dev_config) (struct ata_port *, struct ata_device *); - void (*set_piomode) (struct ata_port *, struct ata_device *, - unsigned int); - void (*set_udmamode) (struct ata_port *, struct ata_device *, - unsigned int); + void (*set_piomode) (struct ata_port *, struct ata_device *); + void (*set_dmamode) (struct ata_port *, struct ata_device *); void (*tf_load) (struct ata_port *ap, struct ata_taskfile *tf); void (*tf_read) (struct ata_port *ap, struct ata_taskfile *tf); @@ -342,6 +350,7 @@ struct ata_port_info { Scsi_Host_Template *sht; unsigned long host_flags; unsigned long pio_mask; + unsigned long mwdma_mask; unsigned long udma_mask; struct ata_port_operations *port_ops; }; |
