aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-dma.c
diff options
context:
space:
mode:
authorSergei Shtylyov <sshtylyov@ru.mvista.com>2007-10-11 17:53:58 -0400
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2007-10-11 17:53:58 -0400
commitb4e44369a380c1836d0983c2a5011099b7b26eb1 (patch)
treec7be9a68f98d908c7822d65dcec4b3c21d9d7955 /drivers/ide/ide-dma.c
parent7cfa7168f7a7730abf1aa2af4a7596d24edd4c21 (diff)
hpt366: MWDMA filter for SATA cards (take 2)
The Marvell bridge chips used on HighPoint SATA cards do not seem to support the MWDMA modes (at least that could be seen in their so-called drivers :-), so the driver needs to account for this -- to achieve this: - add mdma_filter() method from the original patch by Bartlomiej Zolnierkiewicz with his consent; - install the method for all chips to only return empty mask if a SATA drive is detected on HPT372{AN]/374 chips... Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-dma.c')
-rw-r--r--drivers/ide/ide-dma.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/ide/ide-dma.c b/drivers/ide/ide-dma.c
index ff644a5e12cd..097d6e9865bc 100644
--- a/drivers/ide/ide-dma.c
+++ b/drivers/ide/ide-dma.c
@@ -673,8 +673,13 @@ static unsigned int ide_get_mode_mask(ide_drive_t *drive, u8 base)
673 mask &= 0x07; 673 mask &= 0x07;
674 break; 674 break;
675 case XFER_MW_DMA_0: 675 case XFER_MW_DMA_0:
676 if (id->field_valid & 2) 676 if ((id->field_valid & 2) == 0)
677 mask = id->dma_mword & hwif->mwdma_mask; 677 break;
678 if (hwif->mdma_filter)
679 mask = hwif->mdma_filter(drive);
680 else
681 mask = hwif->mwdma_mask;
682 mask &= id->dma_mword;
678 break; 683 break;
679 case XFER_SW_DMA_0: 684 case XFER_SW_DMA_0:
680 if (id->field_valid & 2) { 685 if (id->field_valid & 2) {