From patchwork Tue Oct 25 10:56:30 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: 9394317 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 3777F6086B for ; Tue, 25 Oct 2016 10:57:18 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 283FB28BB1 for ; Tue, 25 Oct 2016 10:57:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1C787292C2; Tue, 25 Oct 2016 10:57:18 +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=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9667928F5C for ; Tue, 25 Oct 2016 10:57:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965640AbcJYK5Q (ORCPT ); Tue, 25 Oct 2016 06:57:16 -0400 Received: from mailout1.samsung.com ([203.254.224.24]:53416 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965839AbcJYK5K (ORCPT ); Tue, 25 Oct 2016 06:57:10 -0400 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 <0OFL00GTXNR8CG20@mailout1.samsung.com> for linux-samsung-soc@vger.kernel.org; Tue, 25 Oct 2016 19:57:08 +0900 (KST) X-AuditID: cbfee61b-f793d6d000005a2a-e1-580f3a849a32 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm2new.samsung.com (EPCPMTA) with SMTP id 8A.E6.23082.48A3F085; Tue, 25 Oct 2016 19:57:08 +0900 (KST) Received: from AMDC3061.digital.local ([106.116.147.40]) by mmp1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OFL00LK1NQ8L3C0@mmp1.samsung.com>; Tue, 25 Oct 2016 19:57:08 +0900 (KST) From: Sylwester Nawrocki To: broonie@kernel.org Cc: lgirdwood@gmail.com, krzk@kernel.org, alsa-devel@alsa-project.org, linux-samsung-soc@vger.kernel.org, Sylwester Nawrocki Subject: [PATCH 2/3] ASoC: samsung: s3c24xx-i2s: Don't use platform_data for DMA parameters Date: Tue, 25 Oct 2016 12:56:30 +0200 Message-id: <1477392991-10604-2-git-send-email-s.nawrocki@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1477392991-10604-1-git-send-email-s.nawrocki@samsung.com> References: <1477392991-10604-1-git-send-email-s.nawrocki@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrGLMWRmVeSWpSXmKPExsVy+t9jAd0WK/4Ig64NGhZXLh5ispj68Amb xfnzG9gtvl3pYLKYcX4fk8XhN+2sDmweGz43sXnsnHWX3WPTqk42j74tqxg9Pm+SC2CNcrPJ SE1MSS1SSM1Lzk/JzEu3VQoNcdO1UFLIS8xNtVWK0PUNCVJSKEvMKQXyjAzQgINzgHuwkr5d glvGzDNLmQoaBSoe94Q1MK7n7WLk5JAQMJH4/303G4QtJnHh3nogm4tDSGApo8TZ6xOYIZxf jBJfd1xlBqliEzCU6D3axwhiiwB13J7TCVbELDCdUWJmx2J2kISwQKxE48/vYDaLgKrE6rXP WEBsXgE3icMzHjJBrJOTOHlsMmsXIwcHp4C7xP7PxSCmEFBJy13+CYy8CxgZVjFKpBYkFxQn peca5aWW6xUn5haX5qXrJefnbmIEh/Ez6R2Mh3e5H2IU4GBU4uHN6OaLEGJNLCuuzD3EKMHB rCTCO9uCP0KINyWxsiq1KD++qDQntfgQoynQWROZpUST84ExllcSb2hibmJubGBhbmlpYqQk zts4+1m4kEB6YklqdmpqQWoRTB8TB6dUA6Nhu4j+8zdOi9WfJl40XDN32ezzCyJ/tb3g1VVn n+9wN2vqal6+pjoz/f/T4vpPu6dpHDofM8P2cWeSPAfnI7Fag/vzHjI78y6OnTPL8/TadSkn S9dpPl+qeJrpYtalE7f/p35anHh2W6XO16UbzSo+HVwju1/yS7H9hNc2L/eHJXXWvO7ae+G+ EktxRqKhFnNRcSIAWqMoo3kCAAA= X-MTR: 20000000000000000@CPGS Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Since the s3c24xx-dma is converted to use DMA map we can rely on the DMA subsystem to match DMA channels and slave devices, rather than passing DMA details from platform_data. Signed-off-by: Sylwester Nawrocki --- sound/soc/samsung/s3c24xx-i2s.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/sound/soc/samsung/s3c24xx-i2s.c b/sound/soc/samsung/s3c24xx-i2s.c index d59a47d..29196a9 100644 --- a/sound/soc/samsung/s3c24xx-i2s.c +++ b/sound/soc/samsung/s3c24xx-i2s.c @@ -30,8 +30,6 @@ #include "dma.h" #include "s3c24xx-i2s.h" -#include - static struct snd_dmaengine_dai_dma_data s3c24xx_i2s_pcm_stereo_out = { .addr_width = 2, }; @@ -449,14 +447,8 @@ static int s3c24xx_i2s_resume(struct snd_soc_dai *cpu_dai) static int s3c24xx_iis_dev_probe(struct platform_device *pdev) { - int ret = 0; struct resource *res; - struct s3c_audio_pdata *pdata = dev_get_platdata(&pdev->dev); - - if (!pdata) { - dev_err(&pdev->dev, "missing platform data"); - return -ENXIO; - } + int ret = 0; res = platform_get_resource(pdev, IORESOURCE_MEM, 0); if (!res) { @@ -468,9 +460,7 @@ static int s3c24xx_iis_dev_probe(struct platform_device *pdev) return PTR_ERR(s3c24xx_i2s.regs); 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); @@ -479,8 +469,7 @@ static int s3c24xx_iis_dev_probe(struct platform_device *pdev) return ret; } - ret = samsung_asoc_dma_platform_register(&pdev->dev, - pdata->dma_filter, + ret = samsung_asoc_dma_platform_register(&pdev->dev, NULL, NULL, NULL); if (ret) pr_err("failed to register the dma: %d\n", ret);