From patchwork Thu Aug 4 09:30:27 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Sylwester Nawrocki/Kernel \\(PLT\\) /SRPOL/Staff Engineer/Samsung Electronics" X-Patchwork-Id: 9264367 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 5E37660839 for ; Thu, 4 Aug 2016 21:27:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 50B9A283E7 for ; Thu, 4 Aug 2016 21:27:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 453AE28407; Thu, 4 Aug 2016 21:27:36 +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=unavailable 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 7F3FC283E7 for ; Thu, 4 Aug 2016 21:27:35 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 82B93266FE7; Thu, 4 Aug 2016 23:27:34 +0200 (CEST) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 6C704266FE5; Thu, 4 Aug 2016 13:38:08 +0200 (CEST) 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 B15A526A53C; Thu, 4 Aug 2016 13:38:07 +0200 (CEST) Received: from mailout1.samsung.com (mailout1.samsung.com [203.254.224.24]) by alsa0.perex.cz (Postfix) with ESMTP id 5C6C2266FA7 for ; Thu, 4 Aug 2016 11:30:58 +0200 (CEST) Received: from epcpsbgm2new.samsung.com (epcpsbgm2 [203.254.230.27]) by mailout1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0OBD014VDP3FUR40@mailout1.samsung.com> for alsa-devel@alsa-project.org; Thu, 04 Aug 2016 18:30:56 +0900 (KST) X-AuditID: cbfee61b-f79466d000001e3c-98-57a30b509b3d Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2new.samsung.com (EPCPMTA) with SMTP id 6F.B8.07740.05B03A75; Thu, 4 Aug 2016 02:30:56 -0700 (MST) Received: from AMDC1344.digital.local ([106.116.147.32]) by mmp2.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OBD004EAP35JM30@mmp2.samsung.com>; Thu, 04 Aug 2016 18:30:56 +0900 (KST) From: Sylwester Nawrocki To: broonie@kernel.org Date: Thu, 04 Aug 2016 11:30:27 +0200 Message-id: <1470303032-14582-3-git-send-email-s.nawrocki@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1470303032-14582-1-git-send-email-s.nawrocki@samsung.com> References: <1470303032-14582-1-git-send-email-s.nawrocki@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFmpnluLIzCtJLcpLzFFi42I5/e+xoG4A9+Jwg+2bDS2uXDzEZLFxxnpW i6kPn7BZzDi/j8ni8Jt2VgdWjw2fm9g8Nq3qZPPo27KK0ePzJrkAligum5TUnMyy1CJ9uwSu jAeH+9kLVghXXP42ja2B8apAFyMnh4SAicTJdYcYIWwxiQv31rN1MXJxCAnMYpTYdLUByvnF KLH66XZmkCo2AUOJ3qN9YB0iQB2353QygxQxC3QzSnxtWcAKkhAWiJG4sXAKUBEHB4uAqsTb N7kgJq+Am8SSK4EQy+QkTh6bDFbNKeAuse75KTYQWwiopPHnbeYJjLwLGBlWMUqkFiQXFCel 5xrlpZbrFSfmFpfmpesl5+duYgQHzzPpHYyHd7kfYhTgYFTi4bWYuChciDWxrLgy9xCjBAez kghvPtficCHelMTKqtSi/Pii0pzU4kOM0hwsSuK8j/+vCxMSSE8sSc1OTS1ILYLJMnFwSjUw xsVc+JFtuneRgU7TnDkffWZJLvx8gyEjxFHiu1XSxJgtjze5bOnjULjvOdnD8cpB1/cSZ7qE nM290hQs3zqdj7S8HSTK8WzO4QyjcNPHJ75Inb67VnfFxkMa2zeudJ4SkfZlxg7/rJLdHLMC 138pqP2TeNp84irxRW+4j+db/zm4yNxEbe7z3UosxRmJhlrMRcWJAPQmjO4aAgAA Cc: alsa-devel@alsa-project.org, linux-samsung-soc@vger.kernel.org, Sylwester Nawrocki , b.zolnierkie@samsung.com Subject: [alsa-devel] [PATCH 2/7] ASoC: samsung: Drop usage of struct s3c_dma_params from s3c24xx-i2s.c 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 struct s3c_dma_params already includes struct snd_dmaengine_dai_dma_data, there is no need for such an indirection so switch to using struct snd_dmaengine_dai_dma_data instead of struct s3c_dma_params. This also allows us to use snd_soc_dai_init_dma_data() function instead of the platform specific samsung_asoc_init_dma_data helper. Signed-off-by: Sylwester Nawrocki --- sound/soc/samsung/s3c24xx-i2s.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/sound/soc/samsung/s3c24xx-i2s.c b/sound/soc/samsung/s3c24xx-i2s.c index 3e76f2a..c78a936 100644 --- a/sound/soc/samsung/s3c24xx-i2s.c +++ b/sound/soc/samsung/s3c24xx-i2s.c @@ -32,14 +32,14 @@ #include -static struct s3c_dma_params s3c24xx_i2s_pcm_stereo_out = { - .ch_name = "tx", - .dma_size = 2, +static struct snd_dmaengine_dai_dma_data s3c24xx_i2s_pcm_stereo_out = { + .chan_name = "tx", + .addr_width = 2, }; -static struct s3c_dma_params s3c24xx_i2s_pcm_stereo_in = { - .ch_name = "rx", - .dma_size = 2, +static struct snd_dmaengine_dai_dma_data s3c24xx_i2s_pcm_stereo_in = { + .chan_name = "rx", + .addr_width = 2, }; struct s3c24xx_i2s_info { @@ -360,8 +360,8 @@ static int s3c24xx_i2s_probe(struct snd_soc_dai *dai) { pr_debug("Entered %s\n", __func__); - samsung_asoc_init_dma_data(dai, &s3c24xx_i2s_pcm_stereo_out, - &s3c24xx_i2s_pcm_stereo_in); + snd_soc_dai_init_dma_data(dai, &s3c24xx_i2s_pcm_stereo_out, + &s3c24xx_i2s_pcm_stereo_in); s3c24xx_i2s.iis_clk = devm_clk_get(dai->dev, "iis"); if (IS_ERR(s3c24xx_i2s.iis_clk)) { @@ -469,10 +469,10 @@ static int s3c24xx_iis_dev_probe(struct platform_device *pdev) if (IS_ERR(s3c24xx_i2s.regs)) return PTR_ERR(s3c24xx_i2s.regs); - s3c24xx_i2s_pcm_stereo_out.dma_addr = res->start + S3C2410_IISFIFO; - s3c24xx_i2s_pcm_stereo_out.slave = pdata->dma_playback; - s3c24xx_i2s_pcm_stereo_in.dma_addr = res->start + S3C2410_IISFIFO; - s3c24xx_i2s_pcm_stereo_in.slave = pdata->dma_capture; + s3c24xx_i2s_pcm_stereo_out.addr = res->start + S3C2410_IISFIFO; + s3c24xx_i2s_pcm_stereo_out.filter_data = pdata->dma_playback; + s3c24xx_i2s_pcm_stereo_in.addr = res->start + S3C2410_IISFIFO; + s3c24xx_i2s_pcm_stereo_in.filter_data = pdata->dma_capture; ret = devm_snd_soc_register_component(&pdev->dev, &s3c24xx_i2s_component, &s3c24xx_i2s_dai, 1);