Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=851dd33bcf23655eede62730c029e4f608f4084f
Commit:     851dd33bcf23655eede62730c029e4f608f4084f
Parent:     bda7970c27b1033de0afa737cd8e5abf9c55c3d2
Author:     Sergei Shtylyov <[EMAIL PROTECTED]>
AuthorDate: Thu Oct 11 23:53:59 2007 +0200
Committer:  Bartlomiej Zolnierkiewicz <[EMAIL PROTECTED]>
CommitDate: Thu Oct 11 23:53:59 2007 +0200

    ide: call udma_filter() before resorting to the UltraDMA mask
    
    Give the udma_filter() method call precedence over using the mode masks.
    
    Signed-off-by: Sergei Shtylyov <[EMAIL PROTECTED]>
    Signed-off-by: Bartlomiej Zolnierkiewicz <[EMAIL PROTECTED]>
---
 drivers/ide/ide-dma.c |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/ide/ide-dma.c b/drivers/ide/ide-dma.c
index 097d6e9..f073ea3 100644
--- a/drivers/ide/ide-dma.c
+++ b/drivers/ide/ide-dma.c
@@ -664,10 +664,11 @@ static unsigned int ide_get_mode_mask(ide_drive_t *drive, 
u8 base)
                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;
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to