summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorRobby Cai <R63905@freescale.com>2010-08-11 09:53:49 +0800
committerRobby Cai <R63905@freescale.com>2010-08-11 10:32:03 +0800
commitadbdf54619c941b7b211e017b7c2a9bccbeec393 (patch)
tree3d75cdd51f5ac9d6ba9554faed0f828cc0c82769 /arch
parenteaf07e7794d67639e7983940ec71965a4081e339 (diff)
ENGR00123707 MX28: make PxP V4L buffer allocated from DMA_ZONE
In pxp v4l2 driver, videobuf_mmap_mapper is called; in turn, __videobuf_mmap_mapper is called. Finally dma_alloc_coherent is called with input parameter GFP_KERNEL, not GFP_DMA. This fix is to let dma_alloc_coherent internally set GFP_DMA flag, and thus use memory from DMA_ZONE, not NORMAL_ZONE. This fix can avoid the issue of calling dma_alloc_coherent failure due to not-enough memory. Signed-off-by: Robby Cai <R63905@freescale.com> (cherry picked from commit 21d753f3ba1519e098070741e7d8bc4ab5d620c5)
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/plat-mxs/device.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/arm/plat-mxs/device.c b/arch/arm/plat-mxs/device.c
index 027408950382..d8e6ccbfba32 100644
--- a/arch/arm/plat-mxs/device.c
+++ b/arch/arm/plat-mxs/device.c
@@ -39,6 +39,7 @@ static struct list_head mxs_device_level[] = {
};
static u64 common_dmamask = DMA_BIT_MASK(32);
+static u64 pxp_dmamask = ISA_DMA_THRESHOLD;
void mxs_nop_release(struct device *dev)
{
@@ -262,8 +263,8 @@ static struct platform_device mxs_pxp = {
.id = 0,
.dev = {
.release = mxs_nop_release,
- .dma_mask = &common_dmamask,
- .coherent_dma_mask = DMA_BIT_MASK(32),
+ .dma_mask = &pxp_dmamask,
+ .coherent_dma_mask = ISA_DMA_THRESHOLD,
},
};
#endif