From patchwork Sun Jan 15 12:43:31 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nicolas Iooss X-Patchwork-Id: 9517377 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3D02C60571 for ; Sun, 15 Jan 2017 12:46:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2A8A728391 for ; Sun, 15 Jan 2017 12:46:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1EA2028411; Sun, 15 Jan 2017 12:46:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4782728391 for ; Sun, 15 Jan 2017 12:46:19 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 64ACE266ECE; Sun, 15 Jan 2017 13:46:12 +0100 (CET) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id A7EC32654AD; Sun, 15 Jan 2017 13:43:53 +0100 (CET) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 569A4266DB0; Sun, 15 Jan 2017 13:43:44 +0100 (CET) Received: from mx1.polytechnique.org (mx1.polytechnique.org [129.104.30.34]) by alsa0.perex.cz (Postfix) with ESMTP id A53DE2654AD for ; Sun, 15 Jan 2017 13:43:42 +0100 (CET) Received: from localhost.localdomain (32.206.133.77.rev.sfr.net [77.133.206.32]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ssl.polytechnique.org (Postfix) with ESMTPSA id DEE33560790; Sun, 15 Jan 2017 13:43:38 +0100 (CET) From: Nicolas Iooss To: Timur Tabi , Nicolin Chen , Xiubo Li , Fabio Estevam , alsa-devel@alsa-project.org, linuxppc-dev@lists.ozlabs.org Date: Sun, 15 Jan 2017 13:43:31 +0100 Message-Id: <20170115124331.3546-1-nicolas.iooss_linux@m4x.org> X-Mailer: git-send-email 2.11.0 X-AV-Checked: ClamAV using ClamSMTP at svoboda.polytechnique.org (Sun Jan 15 13:43:39 2017 +0100 (CET)) Cc: Nicolas Iooss , linux-kernel@vger.kernel.org Subject: [alsa-devel] [PATCH 1/1] ASoC: fsl_asrc: use dma_transfer_direction enum when calling dmaengine_prep_dma_cyclic X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP When fsl_asrc_dma_prepare_and_submit() calls dmaengine_prep_dma_cyclic(), it uses either DMA_TO_DEVICE or DMA_FROM_DEVICE. These values are both items of dma_data_direction enum, not of dma_data_direction enum, which is the type expected by dmaengine_prep_dma_cyclic(). Replace DMA_TO_DEVICE with DMA_MEM_TO_DEV and DMA_FROM_DEVICE with DMA_DEV_TO_MEM to fix this type mismatch issue. Signed-off-by: Nicolas Iooss Reviewed-by: Fabio Estevam Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_asrc_dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/fsl/fsl_asrc_dma.c b/sound/soc/fsl/fsl_asrc_dma.c index dc30d780f874..282d841840b1 100644 --- a/sound/soc/fsl/fsl_asrc_dma.c +++ b/sound/soc/fsl/fsl_asrc_dma.c @@ -76,7 +76,7 @@ static int fsl_asrc_dma_prepare_and_submit(struct snd_pcm_substream *substream) pair->dma_chan[!dir], runtime->dma_addr, snd_pcm_lib_buffer_bytes(substream), snd_pcm_lib_period_bytes(substream), - dir == OUT ? DMA_TO_DEVICE : DMA_FROM_DEVICE, flags); + dir == OUT ? DMA_MEM_TO_DEV : DMA_DEV_TO_MEM, flags); if (!pair->desc[!dir]) { dev_err(dev, "failed to prepare slave DMA for Front-End\n"); return -ENOMEM;