summaryrefslogtreecommitdiff
path: root/arch/arm
diff options
context:
space:
mode:
authorMarek Szyprowski <m.szyprowski@samsung.com>2014-01-16 15:39:17 +0100
committerJiri Slaby <jslaby@suse.cz>2014-03-05 17:13:40 +0100
commit751d789f6490b7c08ff49dae95509b2be29bac78 (patch)
tree6e6f560870bece60f525da7bf4ba14dd3fb61e7a /arch/arm
parent0fab4fa22023f408f6fc181b5029dcb9b8ff9fe3 (diff)
downloadlinux-stable-751d789f6490b7c08ff49dae95509b2be29bac78.tar.gz
linux-stable-751d789f6490b7c08ff49dae95509b2be29bac78.tar.bz2
linux-stable-751d789f6490b7c08ff49dae95509b2be29bac78.zip
ARM: dma-mapping: fix GFP_ATOMIC macro usage
commit 10c8562f932d89c030083e15f9279971ed637136 upstream. GFP_ATOMIC is not a single gfp flag, but a macro which expands to the other flags and LACK of __GFP_WAIT flag. To check if caller wanted to perform an atomic allocation, the code must test __GFP_WAIT flag presence. This patch fixes the issue introduced in v3.6-rc5 Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mm/dma-mapping.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c
index 1272ed202dde..a2d0f91c5bd7 100644
--- a/arch/arm/mm/dma-mapping.c
+++ b/arch/arm/mm/dma-mapping.c
@@ -1325,7 +1325,7 @@ static void *arm_iommu_alloc_attrs(struct device *dev, size_t size,
*handle = DMA_ERROR_CODE;
size = PAGE_ALIGN(size);
- if (gfp & GFP_ATOMIC)
+ if (!(gfp & __GFP_WAIT))
return __iommu_alloc_atomic(dev, size, handle);
/*