From patchwork Fri Jul 4 08:52:59 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tushar Behera X-Patchwork-Id: 4478931 Return-Path: X-Original-To: patchwork-alsa-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 995D29F36A for ; Fri, 4 Jul 2014 08:57:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D4EB420411 for ; Fri, 4 Jul 2014 08:57:00 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id 5C49B203E5 for ; Fri, 4 Jul 2014 08:56:59 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id CA9192659BE; Fri, 4 Jul 2014 10:56:57 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=no version=3.3.1 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id B400F26599B; Fri, 4 Jul 2014 10:56:46 +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 B481626599C; Fri, 4 Jul 2014 10:56:45 +0200 (CEST) Received: from mail-pd0-f176.google.com (mail-pd0-f176.google.com [209.85.192.176]) by alsa0.perex.cz (Postfix) with ESMTP id 6E495265992 for ; Fri, 4 Jul 2014 10:56:37 +0200 (CEST) Received: by mail-pd0-f176.google.com with SMTP id ft15so1666279pdb.35 for ; Fri, 04 Jul 2014 01:56:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id; bh=CQHFhk68gZub5XAhVY9NRLiU9OItKmbeWdJZzNJApBE=; b=QrinDI/sdPie4tR2h99izY1qYpok1dx1+gCAgbOOEgAQ89H9jfQHtvrLuMZ6HtIrbf R71LMvdS6KEclcoQLhcAt+tdkekCCsTq2NqgdoJ9XHg/e4M8hLhcwyBEIFz/sZTEFc9+ JFnTl7Uxq7b8c5rgNh8RJT2LHfw8HQFoBNGy/lrGnmzUOUWas7/ovFHYxtwbr1gZ284h bZrKE/Ay796ln5Mq+DpULeZ+yf2+7NLfL3npz/n06WdDeBFhxVBMQMsnjjqdb2du5OmH FGjbbaHDsOzYz1KmAGXtU66r15h6qXUQ7pQBIlVGjycdh0IzUQ0R/uiKiuDi9jD/Upz+ 9tNw== X-Received: by 10.68.220.137 with SMTP id pw9mr9853481pbc.24.1404464195824; Fri, 04 Jul 2014 01:56:35 -0700 (PDT) Received: from linaro.sisodomain.com ([14.140.216.146]) by mx.google.com with ESMTPSA id nz7sm8005901pdb.48.2014.07.04.01.56.30 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 04 Jul 2014 01:56:35 -0700 (PDT) From: Tushar Behera To: alsa-devel@alsa-project.org, linux-samsung-soc@vger.kernel.org Date: Fri, 4 Jul 2014 14:22:59 +0530 Message-Id: <1404463980-25027-1-git-send-email-tushar.b@samsung.com> X-Mailer: git-send-email 1.7.9.5 Cc: mark.rutland@arm.com, devicetree@vger.kernel.org, dianders@chromium.org, pawel.moll@arm.com, lgirdwood@gmail.com, tiwai@suse.de, ijc+devicetree@hellion.org.uk, linux-kernel@vger.kernel.org, robh+dt@kernel.org, trblinux@gmail.com, broonie@kernel.org, galak@codeaurora.org, kgene.kim@samsung.com Subject: [alsa-devel] [PATCH 1/2] ASoC: samsung: Update sound-card name for Snow 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 Snow sound-card driver supports multiple boards with different audio codecs. Updating the sound card name per board basis would provide some more information to the end-user. Signed-off-by: Tushar Behera --- Documentation/devicetree/bindings/sound/snow.txt | 4 ++++ sound/soc/samsung/snow.c | 3 +++ 2 files changed, 7 insertions(+) diff --git a/Documentation/devicetree/bindings/sound/snow.txt b/Documentation/devicetree/bindings/sound/snow.txt index e0b7a82..6df74f1 100644 --- a/Documentation/devicetree/bindings/sound/snow.txt +++ b/Documentation/devicetree/bindings/sound/snow.txt @@ -8,11 +8,15 @@ Required properties: - samsung,i2s-controller: The phandle of the Samsung I2S controller - samsung,audio-codec: The phandle of the audio codec +Optional: +- samsung,model: The name of the sound-card + Example: sound { compatible = "google,snow-audio-max98095"; + samsung,model = "Snow-I2S-MAX98095"; samsung,i2s-controller = <&i2s0>; samsung,audio-codec = <&max98095>; }; diff --git a/sound/soc/samsung/snow.c b/sound/soc/samsung/snow.c index 8bbd348..0acf5d0 100644 --- a/sound/soc/samsung/snow.c +++ b/sound/soc/samsung/snow.c @@ -92,6 +92,9 @@ static int snow_probe(struct platform_device *pdev) card->dev = &pdev->dev; + /* Update card-name if provided through DT, else use default name */ + snd_soc_of_parse_card_name(card, "samsung,model"); + ret = devm_snd_soc_register_card(&pdev->dev, card); if (ret) { dev_err(&pdev->dev, "snd_soc_register_card failed (%d)\n", ret);