diff options
author | Andrei F <luxneb@gmail.com> | 2012-12-19 21:32:41 +0100 |
---|---|---|
committer | codeworkx <codeworkx@cyanogenmod.org> | 2012-12-20 18:49:09 +0100 |
commit | eaa468eae8c9d87e4c83b30d977e744b3e373613 (patch) | |
tree | fa8b62667639f0eaa635d917b8e2f165a6a1d620 /drivers/char/exynos_mem.c | |
parent | 9c1d0f487d28417858778d094f2eb98eb47ea2f7 (diff) | |
download | kernel_samsung_smdk4412-eaa468eae8c9d87e4c83b30d977e744b3e373613.zip kernel_samsung_smdk4412-eaa468eae8c9d87e4c83b30d977e744b3e373613.tar.gz kernel_samsung_smdk4412-eaa468eae8c9d87e4c83b30d977e744b3e373613.tar.bz2 |
exynos-mem: Add fimc1 to mmap whitelist check
The assumption that only devices which use CONFIG_CMA_DMA use
exynos-mem is wrong. Remove that check.
Newer camera libraries as on Note 2 4.1.2 variants also map fimc directly,
but they are not reserved through kernel CMA allocation in the device file
but through Samsung's S5P framework.
There, the block is called "fimc1", so add that to the whitelist check.
Change-Id: Ib35e9d1c29e977774265f1e123a7ef13353485ad
Conflicts:
drivers/char/exynos_mem.c
Diffstat (limited to 'drivers/char/exynos_mem.c')
-rw-r--r-- | drivers/char/exynos_mem.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/drivers/char/exynos_mem.c b/drivers/char/exynos_mem.c index 707044a..0ec3d84 100644 --- a/drivers/char/exynos_mem.c +++ b/drivers/char/exynos_mem.c @@ -266,12 +266,6 @@ void cma_region_descriptor_add(const char *name, int start, int size) int exynos_mem_mmap(struct file *filp, struct vm_area_struct *vma) { - -/* Devices not having DMA CMA acess shouldn't be using this in any case at all */ -#ifndef CONFIG_DMA_CMA - return -EINVAL; -#endif - struct exynos_mem *mem = (struct exynos_mem *)filp->private_data; bool cacheable = mem->cacheable; dma_addr_t start = 0; @@ -309,8 +303,8 @@ int exynos_mem_mmap(struct file *filp, struct vm_area_struct *vma) * * Add exceptions as we go. */ - - if(strcmp(b->name, "s3c-fimc") == 0) { + if(strcmp(b->name, "s3c-fimc") == 0 || + strcmp(b->name, "fimc1") == 0) { allowed = true; pr_info("[%s] Accessing space 0x%08x/0x%08x for '%s'\n", __func__, b->start, b->size, b->name); |