From patchwork Thu Aug 4 13:38:42 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: 9263665 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 37D106048F for ; Thu, 4 Aug 2016 13:40:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2A30F28406 for ; Thu, 4 Aug 2016 13:40:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1EB2A28409; Thu, 4 Aug 2016 13:40:29 +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 A39F628407 for ; Thu, 4 Aug 2016 13:40:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933737AbcHDNkX (ORCPT ); Thu, 4 Aug 2016 09:40:23 -0400 Received: from mailout3.samsung.com ([203.254.224.33]:43534 "EHLO mailout3.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933618AbcHDNkV (ORCPT ); Thu, 4 Aug 2016 09:40:21 -0400 Received: from epcpsbgm1new.samsung.com (epcpsbgm1 [203.254.230.26]) by mailout3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTP id <0OBE013KD0GKDQE0@mailout3.samsung.com> for linux-samsung-soc@vger.kernel.org; Thu, 04 Aug 2016 22:39:23 +0900 (KST) X-AuditID: cbfee61a-f78ff6d000001462-75-57a3458a3de3 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm1new.samsung.com (EPCPMTA) with SMTP id 73.E8.05218.A8543A75; Thu, 4 Aug 2016 22:39:23 +0900 (KST) Received: from AMDC1344.digital.local ([106.116.147.32]) by mmp1.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0OBE000Y20L4R530@mmp1.samsung.com>; Thu, 04 Aug 2016 22:39:22 +0900 (KST) From: Sylwester Nawrocki To: broonie@kernel.org Cc: krzk@kernel.org, alsa-devel@alsa-project.org, b.zolnierkie@samsung.com, linux-samsung-soc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Sylwester Nawrocki Subject: [PATCH 2/8] ARM: S3C24XX: Specify audio codec platform_data for mini2440 board Date: Thu, 04 Aug 2016 15:38:42 +0200 Message-id: <1470317928-25365-3-git-send-email-s.nawrocki@samsung.com> X-Mailer: git-send-email 1.9.1 In-reply-to: <1470317928-25365-1-git-send-email-s.nawrocki@samsung.com> References: <1470317928-25365-1-git-send-email-s.nawrocki@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprCLMWRmVeSWpSXmKPExsVy+t9jAd1u18XhBndSLa5cPMRksXHGelaL qQ+fsFmcP7+B3WLT42usFjPO72OyOPymndWB3WPD5yY2j02rOtk8Ni+p9+jbsorR4/MmuQDW KC6blNSczLLUIn27BK6MtVd3MhYs56r4taeJqYFxA0cXIyeHhICJxIwn/YwQtpjEhXvr2boY uTiEBJYySty6f4IJwvnFKLFr/g5mkCo2AUOJ3qN9YB0iQB2353SCxZkFjjBK7F3LDmILC0RK TFm9HayGRUBVomnBbFYQm1fATWL/zjdQ2+QkTh6bDBTn4OAUcJd4scUDJCwEVPL11THWCYy8 CxgZVjFKpBYkFxQnpeca5qWW6xUn5haX5qXrJefnbmIEh9UzqR2MB3e5H2IU4GBU4uG9YLoo XIg1say4MvcQowQHs5II72+nxeFCvCmJlVWpRfnxRaU5qcWHGKU5WJTEeR//XxcmJJCeWJKa nZpakFoEk2Xi4JRqYLQ87Zu2o0VsIZ/J7HSn9C6BRYcOOVQcLf5ef07zZmPx3eWaL5scllTH 1G+505rdqvns0ZTODxa6InPTtX+/Opa/cf0XqUSfWIbAo78XZbb9XKbMzbrHmc/psHbqqp3O HF6VnZev100SexX0lEXSXU5xk3n16/WbH9ZyhE1zqYx9VDXndLHeIiWW4oxEQy3mouJEAD+e 5MEnAgAA 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 The L3 bus GPIOs are specified in the board file rather than through the sound card's device platform_data. This allows to ensure the codec driver doesn't get probed with uninitialized platform_data field of its corresponding platform device. Signed-off-by: Sylwester Nawrocki --- arch/arm/mach-s3c24xx/mach-mini2440.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/arch/arm/mach-s3c24xx/mach-mini2440.c b/arch/arm/mach-s3c24xx/mach-mini2440.c index a852168..13999c1 100644 --- a/arch/arm/mach-s3c24xx/mach-mini2440.c +++ b/arch/arm/mach-s3c24xx/mach-mini2440.c @@ -497,9 +497,28 @@ static struct i2c_board_info mini2440_i2c_devs[] __initdata = { }, }; +static struct uda134x_platform_data s3c24xx_uda134x = { + .l3 = { + .gpio_clk = S3C2410_GPB(4), + .gpio_data = S3C2410_GPB(3), + .gpio_mode = S3C2410_GPB(2), + .use_gpios = 1, + .data_hold = 1, + .data_setup = 1, + .clock_high = 1, + .mode_hold = 1, + .mode = 1, + .mode_setup = 1, + }, + .model = UDA134X_UDA1341, +}; + static struct platform_device uda1340_codec = { .name = "uda134x-codec", .id = -1, + .dev = { + .platform_data = &s3c24xx_uda134x, + }, }; static struct platform_device *mini2440_devices[] __initdata = {