summaryrefslogtreecommitdiff
path: root/drivers/media/platform/exynos4-is/fimc-is.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/platform/exynos4-is/fimc-is.c')
-rw-r--r--drivers/media/platform/exynos4-is/fimc-is.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/media/platform/exynos4-is/fimc-is.c b/drivers/media/platform/exynos4-is/fimc-is.c
index 128b73b6cce2..5476dce3ad29 100644
--- a/drivers/media/platform/exynos4-is/fimc-is.c
+++ b/drivers/media/platform/exynos4-is/fimc-is.c
@@ -367,6 +367,9 @@ static void fimc_is_free_cpu_memory(struct fimc_is *is)
{
struct device *dev = &is->pdev->dev;
+ if (is->memory.vaddr == NULL)
+ return;
+
dma_free_coherent(dev, is->memory.size, is->memory.vaddr,
is->memory.paddr);
}