lkml.org 
[lkml]   [2002]   [Mar]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] Small fix to pci_alloc_consistent()
Date
Hi,

pci_alloc_consistent() is returning zone DMA memory to highmem
enabled drivers when it really should have been returning zone NORMAL.

Found this while testing qlogicfc driver for > 4GB support.

Thanks,
Badari


diff -Naur -X dontdiff linux/arch/i386/kernel/pci-dma.c linux.2417all/arch/i386/kernel/pci-dma.c
--- linux/arch/i386/kernel/pci-dma.c Thu Mar 14 16:01:42 2002
+++ linux.2417all/arch/i386/kernel/pci-dma.c Thu Mar 14 15:41:40 2002
@@ -19,7 +19,7 @@
void *ret;
int gfp = GFP_ATOMIC;

- if (hwdev == NULL || hwdev->dma_mask != 0xffffffff)
+ if (hwdev == NULL || ((u32)hwdev->dma_mask != 0xffffffff))
gfp |= GFP_DMA;
ret = (void *)__get_free_pages(gfp, get_order(size));

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 13:25    [W:0.063 / U:0.164 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site