]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/x86/include/asm/dma-mapping.h
Merge git://git.infradead.org/mtd-2.6
[linux-2.6-omap-h63xx.git] / arch / x86 / include / asm / dma-mapping.h
index 4a5397bfce276dc11caa1956ac9eebeab4e0c128..7f225a4b2a26aedd2995d8c68c75df6962f19778 100644 (file)
@@ -255,9 +255,11 @@ static inline unsigned long dma_alloc_coherent_mask(struct device *dev,
 
 static inline gfp_t dma_alloc_coherent_gfp_flags(struct device *dev, gfp_t gfp)
 {
-#ifdef CONFIG_X86_64
        unsigned long dma_mask = dma_alloc_coherent_mask(dev, gfp);
 
+       if (dma_mask <= DMA_24BIT_MASK)
+               gfp |= GFP_DMA;
+#ifdef CONFIG_X86_64
        if (dma_mask <= DMA_32BIT_MASK && !(gfp & GFP_DMA))
                gfp |= GFP_DMA32;
 #endif