* [PATCH] ide: call udma_filter() before resorting to the UltraDMA mask
@ 2007-09-15 16:42 Sergei Shtylyov
2007-09-15 17:15 ` Sergei Shtylyov
2007-09-17 10:33 ` Bartlomiej Zolnierkiewicz
0 siblings, 2 replies; 3+ messages in thread
From: Sergei Shtylyov @ 2007-09-15 16:42 UTC (permalink / raw)
To: bzolnier; +Cc: linux-ide
Give the udma_filter() method call taking precedence over using the mode masks.
Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
---
Posting this change separately as have been asked. Should apply to the current
Linus' tree...
drivers/ide/ide-dma.c | 7 +++---
1 files changed, 4 insertions(+), 3 deletions(-)
Index: linux-2.6/drivers/ide/ide-dma.c
===================================================================
--- linux-2.6.orig/drivers/ide/ide-dma.c
+++ linux-2.6/drivers/ide/ide-dma.c
@@ -664,10 +664,11 @@ static unsigned int ide_get_mode_mask(id
if ((id->field_valid & 4) == 0)
break;
- mask = id->dma_ultra & hwif->ultra_mask;
-
if (hwif->udma_filter)
- mask &= hwif->udma_filter(drive);
+ mask = hwif->udma_filter(drive);
+ else
+ mask = hwif->ultra_mask;
+ mask &= id->dma_ultra;
if ((mask & 0x78) && (eighty_ninty_three(drive) == 0))
mask &= 0x07;
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-09-17 11:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-09-15 16:42 [PATCH] ide: call udma_filter() before resorting to the UltraDMA mask Sergei Shtylyov
2007-09-15 17:15 ` Sergei Shtylyov
2007-09-17 10:33 ` Bartlomiej Zolnierkiewicz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).