From patchwork Tue Apr 8 11:41:04 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 28055 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pa0-f72.google.com (mail-pa0-f72.google.com [209.85.220.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 7225120553 for ; Wed, 9 Apr 2014 02:18:36 +0000 (UTC) Received: by mail-pa0-f72.google.com with SMTP id bj1sf5761992pad.7 for ; Tue, 08 Apr 2014 19:18:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:delivered-to:from:to:date :message-id:cc:subject:precedence:list-id:list-unsubscribe :list-archive:list-post:list-help:list-subscribe:mime-version :errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list:content-type :content-transfer-encoding; bh=oxLT71d1TPq8XLQ0z599qez+JJgGrW+e0+yTBQxZwko=; b=LMXC6h/RtBtBYglvvXJQDDyD3cs6LG5yGsPNGCck2rTVjuGbmIucyuDjwiWS/FOjIr Jtcd9KQ0b93Jh09+MjJiJD91XdbRNjfnoREZ7QuJwQTOjf6+294UsRKv6Jl9g9KQ9Uz7 8sqt3fiNc7r1uth4zh6o6DyjZWZ4GZH7yheNL/08k1h4fn34icoLG2cxrNJpcOfU9od9 ZH6WZZmfXEHDUw9eh+e2FKWdLRJvGKyoZJrtO+oytxBt/XFvIeXb2tz8NjpczLyZoZq9 xOh0itVJJlVprVc4fsEPU6TEcKleeRUFMMNIhy2j7WUBbTTKiJ8UvEjijNOk6X7H5Kho /ySw== X-Gm-Message-State: ALoCoQnZMMNIc1Dl6+BG4CYACMUiszijOIlXqVw6ITNaCfmH0Qyn9ieLFDwidrRMHPDkQCQj7JR2 X-Received: by 10.66.189.163 with SMTP id gj3mr3579979pac.32.1397009915362; Tue, 08 Apr 2014 19:18:35 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.101.245 with SMTP id u108ls421706qge.79.gmail; Tue, 08 Apr 2014 19:18:35 -0700 (PDT) X-Received: by 10.58.219.233 with SMTP id pr9mr6426555vec.10.1397009915120; Tue, 08 Apr 2014 19:18:35 -0700 (PDT) Received: from mail-vc0-f169.google.com (mail-vc0-f169.google.com [209.85.220.169]) by mx.google.com with ESMTPS id or7si746712vcb.61.2014.04.08.19.18.35 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 08 Apr 2014 19:18:35 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.169 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.169; Received: by mail-vc0-f169.google.com with SMTP id ik5so1588344vcb.0 for ; Tue, 08 Apr 2014 19:18:35 -0700 (PDT) X-Received: by 10.220.4.132 with SMTP id 4mr6291497vcr.9.1397009914902; Tue, 08 Apr 2014 19:18:34 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.12.8 with SMTP id v8csp292814vcv; Tue, 8 Apr 2014 19:18:34 -0700 (PDT) X-Received: by 10.15.22.201 with SMTP id f49mr8686775eeu.18.1397009913390; Tue, 08 Apr 2014 19:18:33 -0700 (PDT) Received: from alsa0.perex.cz (alsa0.perex.cz. [77.48.224.243]) by mx.google.com with ESMTP id x46si5141422eea.209.2014.04.08.19.18.32 for ; Tue, 08 Apr 2014 19:18:33 -0700 (PDT) Received-SPF: neutral (google.com: 77.48.224.243 is neither permitted nor denied by best guess record for domain of alsa-devel-bounces@alsa-project.org) client-ip=77.48.224.243; Received: by alsa0.perex.cz (Postfix, from userid 1000) id 117312658B4; Wed, 9 Apr 2014 04:18:32 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.2.4 (2008-01-01) on mail1.perex.cz X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.2.4 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id 39099265909; Tue, 8 Apr 2014 23:06:34 +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 A3AD2265909; Tue, 8 Apr 2014 23:06:32 +0200 (CEST) Received: from mail-pb0-f47.google.com (mail-pb0-f47.google.com [209.85.160.47]) by alsa0.perex.cz (Postfix) with ESMTP id 96D3E265903 for ; Tue, 8 Apr 2014 13:41:45 +0200 (CEST) Received: by mail-pb0-f47.google.com with SMTP id up15so911618pbc.34 for ; Tue, 08 Apr 2014 04:41:41 -0700 (PDT) X-Received: by 10.68.236.100 with SMTP id ut4mr3962066pbc.29.1396957301673; Tue, 08 Apr 2014 04:41:41 -0700 (PDT) Received: from linaro.sisodomain.com ([115.113.119.130]) by mx.google.com with ESMTPSA id ci4sm4081652pbb.50.2014.04.08.04.41.38 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 08 Apr 2014 04:41:40 -0700 (PDT) From: Sachin Kamat To: alsa-devel@alsa-project.org Date: Tue, 8 Apr 2014 17:11:04 +0530 Message-Id: <1396957264-2247-1-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.9.5 Cc: sbkim73@samsung.com, sachin.kamat@linaro.org, broonie@kernel.org, lgirdwood@gmail.com Subject: [alsa-devel] [PATCH Resend 1/1] ASoC: Samsung: Fix build on multiplatform X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: 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-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: sachin.kamat@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.169 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 PCM and S/PDIF drivers referenced mach headers for a trivial data structure. This caused build errors on multiplatform builds as machine headers are not accessible from driver files. Move the data structure definition to the driver header and remove the dependency. While at it rename the structure to avoid multiple definition errors as the same structure is also used by the platform code. Signed-off-by: Sachin Kamat --- sound/soc/samsung/ac97.c | 6 +++--- sound/soc/samsung/dma.h | 6 +++++- sound/soc/samsung/i2s.c | 6 +++--- sound/soc/samsung/pcm.c | 5 ++--- sound/soc/samsung/s3c2412-i2s.c | 4 ++-- sound/soc/samsung/s3c24xx-i2s.c | 4 ++-- sound/soc/samsung/spdif.c | 3 +-- 7 files changed, 18 insertions(+), 16 deletions(-) diff --git a/sound/soc/samsung/ac97.c b/sound/soc/samsung/ac97.c index 4a88e36c82ec..76b072bd4ba2 100644 --- a/sound/soc/samsung/ac97.c +++ b/sound/soc/samsung/ac97.c @@ -39,15 +39,15 @@ struct s3c_ac97_info { }; static struct s3c_ac97_info s3c_ac97; -static struct s3c2410_dma_client s3c_dma_client_out = { +static struct s3c_dma_client s3c_dma_client_out = { .name = "AC97 PCMOut" }; -static struct s3c2410_dma_client s3c_dma_client_in = { +static struct s3c_dma_client s3c_dma_client_in = { .name = "AC97 PCMIn" }; -static struct s3c2410_dma_client s3c_dma_client_micin = { +static struct s3c_dma_client s3c_dma_client_micin = { .name = "AC97 MicIn" }; diff --git a/sound/soc/samsung/dma.h b/sound/soc/samsung/dma.h index 225e5378014e..ad7c0f04f00d 100644 --- a/sound/soc/samsung/dma.h +++ b/sound/soc/samsung/dma.h @@ -14,8 +14,12 @@ #include +struct s3c_dma_client { + char *name; +}; + struct s3c_dma_params { - struct s3c2410_dma_client *client; /* stream identifier */ + struct s3c_dma_client *client; /* stream identifier */ int channel; /* Channel ID */ dma_addr_t dma_addr; int dma_size; /* Size of the DMA transfer */ diff --git a/sound/soc/samsung/i2s.c b/sound/soc/samsung/i2s.c index 0a9b44c940ce..048ead967199 100644 --- a/sound/soc/samsung/i2s.c +++ b/sound/soc/samsung/i2s.c @@ -1211,10 +1211,10 @@ static int samsung_i2s_probe(struct platform_device *pdev) pri_dai->dma_playback.dma_addr = regs_base + I2STXD; pri_dai->dma_capture.dma_addr = regs_base + I2SRXD; pri_dai->dma_playback.client = - (struct s3c2410_dma_client *)&pri_dai->dma_playback; + (struct s3c_dma_client *)&pri_dai->dma_playback; pri_dai->dma_playback.ch_name = "tx"; pri_dai->dma_capture.client = - (struct s3c2410_dma_client *)&pri_dai->dma_capture; + (struct s3c_dma_client *)&pri_dai->dma_capture; pri_dai->dma_capture.ch_name = "rx"; pri_dai->dma_playback.dma_size = 4; pri_dai->dma_capture.dma_size = 4; @@ -1233,7 +1233,7 @@ static int samsung_i2s_probe(struct platform_device *pdev) } sec_dai->dma_playback.dma_addr = regs_base + I2STXDS; sec_dai->dma_playback.client = - (struct s3c2410_dma_client *)&sec_dai->dma_playback; + (struct s3c_dma_client *)&sec_dai->dma_playback; sec_dai->dma_playback.ch_name = "tx-sec"; if (!np) { diff --git a/sound/soc/samsung/pcm.c b/sound/soc/samsung/pcm.c index 6a5e4bf6ac96..ab54e297957c 100644 --- a/sound/soc/samsung/pcm.c +++ b/sound/soc/samsung/pcm.c @@ -20,7 +20,6 @@ #include #include -#include #include "dma.h" #include "pcm.h" @@ -132,11 +131,11 @@ struct s3c_pcm_info { struct s3c_dma_params *dma_capture; }; -static struct s3c2410_dma_client s3c_pcm_dma_client_out = { +static struct s3c_dma_client s3c_pcm_dma_client_out = { .name = "PCM Stereo out" }; -static struct s3c2410_dma_client s3c_pcm_dma_client_in = { +static struct s3c_dma_client s3c_pcm_dma_client_in = { .name = "PCM Stereo in" }; diff --git a/sound/soc/samsung/s3c2412-i2s.c b/sound/soc/samsung/s3c2412-i2s.c index d0794458963a..e9bb5d7a71ee 100644 --- a/sound/soc/samsung/s3c2412-i2s.c +++ b/sound/soc/samsung/s3c2412-i2s.c @@ -33,11 +33,11 @@ #include "regs-i2s-v2.h" #include "s3c2412-i2s.h" -static struct s3c2410_dma_client s3c2412_dma_client_out = { +static struct s3c_dma_client s3c2412_dma_client_out = { .name = "I2S PCM Stereo out" }; -static struct s3c2410_dma_client s3c2412_dma_client_in = { +static struct s3c_dma_client s3c2412_dma_client_in = { .name = "I2S PCM Stereo in" }; diff --git a/sound/soc/samsung/s3c24xx-i2s.c b/sound/soc/samsung/s3c24xx-i2s.c index f31e916dd8c4..d7b8457b5650 100644 --- a/sound/soc/samsung/s3c24xx-i2s.c +++ b/sound/soc/samsung/s3c24xx-i2s.c @@ -31,11 +31,11 @@ #include "dma.h" #include "s3c24xx-i2s.h" -static struct s3c2410_dma_client s3c24xx_dma_client_out = { +static struct s3c_dma_client s3c24xx_dma_client_out = { .name = "I2S PCM Stereo out" }; -static struct s3c2410_dma_client s3c24xx_dma_client_in = { +static struct s3c_dma_client s3c24xx_dma_client_in = { .name = "I2S PCM Stereo in" }; diff --git a/sound/soc/samsung/spdif.c b/sound/soc/samsung/spdif.c index 28487dcc4538..cfe63b7bcc9f 100644 --- a/sound/soc/samsung/spdif.c +++ b/sound/soc/samsung/spdif.c @@ -18,7 +18,6 @@ #include #include -#include #include "dma.h" #include "spdif.h" @@ -94,7 +93,7 @@ struct samsung_spdif_info { struct s3c_dma_params *dma_playback; }; -static struct s3c2410_dma_client spdif_dma_client_out = { +static struct s3c_dma_client spdif_dma_client_out = { .name = "S/PDIF Stereo out", };