If we fail, we'll loop into the allocation again,
and then allocate in the DMA zone.
Signed-off-by: Glauber Costa <gcosta@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
if (dma_alloc_from_coherent_mem(dev, size, dma_handle, &ret))
return ret;
if (dma_alloc_from_coherent_mem(dev, size, dma_handle, &ret))
return ret;
- if (dev == NULL || (dev->coherent_dma_mask < 0xffffffff))
- gfp |= GFP_DMA;
-
if (!dev)
dev = &fallback_dev;
if (!dev)
dev = &fallback_dev;