aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-generic/dma-contiguous.h
diff options
context:
space:
mode:
authorMarek Szyprowski <m.szyprowski@samsung.com>2012-07-06 06:02:04 -0400
committerMarek Szyprowski <m.szyprowski@samsung.com>2012-07-06 06:02:04 -0400
commitcc2caea5b6152b8ce66dc2bbe83dc72b60612da8 (patch)
treec39d09978bd8f2f7f29771b80b4064e2aabd5d2d /include/asm-generic/dma-contiguous.h
parent6a6dccba2fdc2a69f1f36b8f1c0acc8598e7221b (diff)
mm: cma: fix condition check when setting global cma area
dev_set_cma_area incorrectly assigned cma to global area on first call due to incorrect check. This patch fixes this issue. Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Diffstat (limited to 'include/asm-generic/dma-contiguous.h')
-rw-r--r--include/asm-generic/dma-contiguous.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/asm-generic/dma-contiguous.h b/include/asm-generic/dma-contiguous.h
index c544356b374b..294b1e755ab2 100644
--- a/include/asm-generic/dma-contiguous.h
+++ b/include/asm-generic/dma-contiguous.h
@@ -18,7 +18,7 @@ static inline void dev_set_cma_area(struct device *dev, struct cma *cma)
18{ 18{
19 if (dev) 19 if (dev)
20 dev->cma_area = cma; 20 dev->cma_area = cma;
21 if (!dev || !dma_contiguous_default_area) 21 if (!dev && !dma_contiguous_default_area)
22 dma_contiguous_default_area = cma; 22 dma_contiguous_default_area = cma;
23} 23}
24 24