Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1769785imm; Thu, 24 May 2018 00:11:04 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpQuawx0hWgWWnMvOG+7MaN1JdzpvtqVo/m4UxB7vt6uHhH2qYdEq66szO8sZ6TwAeT5TWm X-Received: by 2002:a17:902:7598:: with SMTP id j24-v6mr5337203pll.160.1527145864199; Thu, 24 May 2018 00:11:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527145864; cv=none; d=google.com; s=arc-20160816; b=mjpOAmwaFdVt4lpZwyGIUHuaNg35AzUr/el5LLkWvM6onrvKMlUUodrQxWg2TNcQZV zkcr8dmYE1LmMZsGurYEDsGUuS8iqDNQslRQYUKrEkGD21UBLr2xs+K9XdMouNp+OIMO KlR3/08yad0WUvIgnP6wvFsFKHdNfnjujwvuq52tYD/OzCAe5CopPuZwC3f/4MAGmv4W o126NIqNvXWxBXqIF8M/oBjKQGx2QsEJbu+rnPju4QDDscY4JLFUAZ1X7OwSnWH/OksE 52s1QdAMUWzWoZ0vm8gGjgTqDI7lwfIv7fDCtXNeXwpq0Yjimy59E9kpAdJP0i6/g4s3 rEFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=9yNqGZr3ET4f6QLKkzwoBz4DT6D/TnxHqr9vPiUlbJc=; b=CMBvQozhCBBMM7JTF4+8obCuH8k12zXWXH529ocQ2UB4LfEW3SNRax6YNc7Zx8TPeQ 6SUqdh8amE6L4d/Vh2Xf064/LwfKiG6bsFq0NdiNGhcxWC0M+spDxPTwMIKX/i2iHF9I mdJjUozKsLf3IIuJW03WNmsjqBz75Q7Pz2ZYd3mKWFU3kCCb15uvwyKVOwLKiDxMVwK8 /UOo4sihzhwnUkcxQ94f/cBLSFPQZ2KHrcltHjJk1A7hK/+w5gUIrq2WdCt7+lUsVhhS MJmkIK8KIgNdfJHUV5whtnnHAYIbtwoyY7vCLfT1USMS33e1/FTvRVx7WuzgPktYGpVF UTGg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k17-v6si20474970pfj.310.2018.05.24.00.10.49; Thu, 24 May 2018 00:11:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965059AbeEXHJP (ORCPT + 99 others); Thu, 24 May 2018 03:09:15 -0400 Received: from smtp01.smtpout.orange.fr ([80.12.242.123]:38894 "EHLO smtp.smtpout.orange.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755122AbeEXHHc (ORCPT ); Thu, 24 May 2018 03:07:32 -0400 Received: from belgarion.home ([90.55.202.35]) by mwinf5d01 with ME id q77G1x00i0mKt3N0377WTB; Thu, 24 May 2018 09:07:31 +0200 X-ME-Helo: belgarion.home X-ME-Auth: amFyem1pay5yb2JlcnRAb3JhbmdlLmZy X-ME-Date: Thu, 24 May 2018 09:07:31 +0200 X-ME-IP: 90.55.202.35 From: Robert Jarzmik To: Daniel Mack , Haojian Zhuang , Robert Jarzmik , Ezequiel Garcia , Boris Brezillon , David Woodhouse , Brian Norris , Marek Vasut , Richard Weinberger , Liam Girdwood , Mark Brown , Arnd Bergmann Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-ide@vger.kernel.org, dmaengine@vger.kernel.org, linux-media@vger.kernel.org, linux-mmc@vger.kernel.org, linux-mtd@lists.infradead.org, netdev@vger.kernel.org, alsa-devel@alsa-project.org Subject: [PATCH v2 04/13] media: pxa_camera: remove the dmaengine compat need Date: Thu, 24 May 2018 09:06:54 +0200 Message-Id: <20180524070703.11901-5-robert.jarzmik@free.fr> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180524070703.11901-1-robert.jarzmik@free.fr> References: <20180524070703.11901-1-robert.jarzmik@free.fr> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org As the pxa architecture switched towards the dmaengine slave map, the old compatibility mechanism to acquire the dma requestor line number and priority are not needed anymore. This patch simplifies the dma resource acquisition, using the more generic function dma_request_slave_channel(). Signed-off-by: Robert Jarzmik Acked-by: Hans Verkuil Acked-by: Mauro Carvalho Chehab --- drivers/media/platform/pxa_camera.c | 22 +++------------------- 1 file changed, 3 insertions(+), 19 deletions(-) diff --git a/drivers/media/platform/pxa_camera.c b/drivers/media/platform/pxa_camera.c index c71a00736541..4c82d1880753 100644 --- a/drivers/media/platform/pxa_camera.c +++ b/drivers/media/platform/pxa_camera.c @@ -2357,8 +2357,6 @@ static int pxa_camera_probe(struct platform_device *pdev) .src_maxburst = 8, .direction = DMA_DEV_TO_MEM, }; - dma_cap_mask_t mask; - struct pxad_param params; char clk_name[V4L2_CLK_NAME_SIZE]; int irq; int err = 0, i; @@ -2432,34 +2430,20 @@ static int pxa_camera_probe(struct platform_device *pdev) pcdev->base = base; /* request dma */ - dma_cap_zero(mask); - dma_cap_set(DMA_SLAVE, mask); - dma_cap_set(DMA_PRIVATE, mask); - - params.prio = 0; - params.drcmr = 68; - pcdev->dma_chans[0] = - dma_request_slave_channel_compat(mask, pxad_filter_fn, - ¶ms, &pdev->dev, "CI_Y"); + pcdev->dma_chans[0] = dma_request_slave_channel(&pdev->dev, "CI_Y"); if (!pcdev->dma_chans[0]) { dev_err(&pdev->dev, "Can't request DMA for Y\n"); return -ENODEV; } - params.drcmr = 69; - pcdev->dma_chans[1] = - dma_request_slave_channel_compat(mask, pxad_filter_fn, - ¶ms, &pdev->dev, "CI_U"); + pcdev->dma_chans[1] = dma_request_slave_channel(&pdev->dev, "CI_U"); if (!pcdev->dma_chans[1]) { dev_err(&pdev->dev, "Can't request DMA for Y\n"); err = -ENODEV; goto exit_free_dma_y; } - params.drcmr = 70; - pcdev->dma_chans[2] = - dma_request_slave_channel_compat(mask, pxad_filter_fn, - ¶ms, &pdev->dev, "CI_V"); + pcdev->dma_chans[2] = dma_request_slave_channel(&pdev->dev, "CI_V"); if (!pcdev->dma_chans[2]) { dev_err(&pdev->dev, "Can't request DMA for V\n"); err = -ENODEV; -- 2.11.0