From: Sascha Hauer Date: Fri, 5 Nov 2010 09:26:03 +0000 (-0300) Subject: [media] ARM mx3_camera: check for DMA engine type X-Git-Tag: MMI-PSA29.97-13-9~21491^2~38 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a8de6635799b58b52c610da9ee390a3e900e7bc7;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git [media] ARM mx3_camera: check for DMA engine type We have two dma engines in MX3 systems: The IPU and the SDMA engine. We have to check if we got a channel from the correct engine before proceeding with a channel. Signed-off-by: Sascha Hauer Cc: Guennadi Liakhovetski Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/mx3_camera.c b/drivers/media/video/mx3_camera.c index 29c5fc348133..aa871c2936b3 100644 --- a/drivers/media/video/mx3_camera.c +++ b/drivers/media/video/mx3_camera.c @@ -27,6 +27,7 @@ #include #include +#include #define MX3_CAM_DRV_NAME "mx3-camera" @@ -638,6 +639,9 @@ static bool chan_filter(struct dma_chan *chan, void *arg) struct dma_chan_request *rq = arg; struct mx3_camera_pdata *pdata; + if (!imx_dma_is_ipu(chan)) + return false; + if (!rq) return false;