aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-dma.c
diff options
context:
space:
mode:
authorSergei Shtylyov <sshtylyov@ru.mvista.com>2009-03-31 14:15:28 -0400
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2009-03-31 14:15:28 -0400
commit74638c84821c066d02c158bc843c84499ddc9764 (patch)
treecd6f79f34d87d25a621aaf1369ce226923de3c14 /drivers/ide/ide-dma.c
parentc4199930b119eb9c1ffb102ed57eaac4d4424d08 (diff)
ide: add support for CFA specified transfer modes (take 3)
Add support for the CompactFlash specific PIO modes 5/6 and MWDMA modes 3/4. Since there were no PIO5 capable hard drives produced and one would also need 66 MHz IDE clock to actually get the difference WRT the address setup timings programmed, I decided to simply replace the old non-standard PIO mode 5 timings with the CFA specified ones. Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Cc: stf_xl@wp.pl Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-dma.c')
-rw-r--r--drivers/ide/ide-dma.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/ide/ide-dma.c b/drivers/ide/ide-dma.c
index f9c91752f275..a0b8cab1d9a6 100644
--- a/drivers/ide/ide-dma.c
+++ b/drivers/ide/ide-dma.c
@@ -261,6 +261,14 @@ static unsigned int ide_get_mode_mask(ide_drive_t *drive, u8 base, u8 req_mode)
261 break; 261 break;
262 case XFER_MW_DMA_0: 262 case XFER_MW_DMA_0:
263 mask = id[ATA_ID_MWDMA_MODES]; 263 mask = id[ATA_ID_MWDMA_MODES];
264
265 /* Also look for the CF specific MWDMA modes... */
266 if (ata_id_is_cfa(id) && (id[ATA_ID_CFA_MODES] & 0x38)) {
267 u8 mode = ((id[ATA_ID_CFA_MODES] & 0x38) >> 3) - 1;
268
269 mask |= ((2 << mode) - 1) << 3;
270 }
271
264 if (port_ops && port_ops->mdma_filter) 272 if (port_ops && port_ops->mdma_filter)
265 mask &= port_ops->mdma_filter(drive); 273 mask &= port_ops->mdma_filter(drive);
266 else 274 else