From patchwork Tue Jul 17 15:36:27 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 142163 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp3814431ljj; Tue, 17 Jul 2018 08:38:02 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcYcwigZYHmQP/mlYBbCdUhi9BppBF3pBSkRtePGNPnAVDA3WXzqqbb3Z213y3i1/PtXdta X-Received: by 2002:a1c:2094:: with SMTP id g142-v6mr1577499wmg.144.1531841882309; Tue, 17 Jul 2018 08:38:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531841882; cv=none; d=google.com; s=arc-20160816; b=XEROEBNsIpYdV1/LyNSeapdBdn+IXOPYfi/p9ZNHMLs5+u4tjhweM5WD8eLIrjioN/ XRw61PTMYMSFpkouqhMIXtFAcGyc3w53gissCcKST8xJXn+aC+PoAKW1+V7Qtc5nrtE2 3BsQRTn/l9NPRADGQ/jQRaNb/eSDlJohE41KC7z9aiiYfv/w6cIQCingndETChUjfADi 1TB7TZkeH9ZV63/XE4bPt0oseNnTYOTW0nba0CXEU0612sQhPP3IbvtrpkiFPwTjmu/Z 6yjvXWvGPBbiGeUhv02Pq1Zkz4g2jGPDp/ugX6eGxRpWiNAtg0tHj1YYzfDbcDcC3cyb A9MA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:references:in-reply-to:message-id :date:to:from:dkim-signature:delivered-to:arc-authentication-results; bh=qH696FH4BFCfCHVitAccJiO092uJmvQQSmrY6p+iBZI=; b=Dtn4YsLNmOuT4yLoocOhojP55OgYYx18Xq1oJXy6+rh6zF3qDvHXdMdDAClOCt4o5f BcPWSJ8TJFAEMG2t7SmxqB1NYcWWSI/ai7pFHbUe7e5ZmT0iXlX+3vYYn628+ZRgFusF /NuJ4mVG+PP4GOosqQa6HTp4pg33YEiLZFnVgrhCNRQRKvjKbTf3kObPTPf9ndUCv8Us S4+CeLmAEf/sb5pSKWrgVCv1KZkU2sKpV9YbEMlaug9DFs4xDpupLre5CRnGSp2Dhsfh /LqSh68CM50c45T2dX/PuAbijTmYpetXjJVbQa/4cz3yOP8wDUZCVwjsu9Ut5uT+Ulxm HwZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=OE8AARnc; spf=pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) smtp.mailfrom=alsa-devel-bounces@alsa-project.org Return-Path: Received: from alsa0.perex.cz ([77.48.224.243]) by mx.google.com with ESMTP id a18-v6si1075247wrp.365.2018.07.17.08.38.02; Tue, 17 Jul 2018 08:38:02 -0700 (PDT) Received-SPF: pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) client-ip=77.48.224.243; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=OE8AARnc; spf=pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id D95922677F0; Tue, 17 Jul 2018 17:36:57 +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 9354A2677D0; Tue, 17 Jul 2018 17:36:52 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail1.perex.cz X-Spam-Level: X-Spam-Status: No, score=1.0 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_SOFTFAIL,T_DKIMWL_WL_MED autolearn=disabled version=3.4.0 Received: from mail-wr1-f68.google.com (mail-wr1-f68.google.com [209.85.221.68]) by alsa0.perex.cz (Postfix) with ESMTP id 8BD9D2677CE for ; Tue, 17 Jul 2018 17:36:50 +0200 (CEST) Received: by mail-wr1-f68.google.com with SMTP id j5-v6so1696263wrr.8 for ; Tue, 17 Jul 2018 08:36:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=vNkHdoHxDTeCb62fmSaQ1EzoUhqjgTMT8K04+gGWmyw=; b=OE8AARncL8BBkKXTPcPEpLbHqwgyG8fbX4YmII4gVfA92FEBEMxbftrnoQDhkdso8K iB0IOm6vPku/oWTchaHy/is5XtWCOYUjb2dYRCxP/CsDLRag1xGRVeUJsVLZ7IFRyssU 1ytwe7YKhk4SzO3dhzGQoNebml8eKrKCNg1YscMsEZiCp5kvKs2uLq4xGHI2DNplW8lC XG1Y0FEdnO9zgZNBvg+KW76Sq3YICx/rNw1kNAJXTxIpmccwlShSnTpyI0xy97HhykIE ObkDI0VEXgIjXPfdq3Sn8eGwVPq1Yq50jlTHm+SwJQG1IMYKafmRx848i7eUTWlR852l o67w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=vNkHdoHxDTeCb62fmSaQ1EzoUhqjgTMT8K04+gGWmyw=; b=Yfvqngh0QyZtsFdwtGP043OoKiwDYZJRaMcRTm6RqBbBOIA/AhuUJp7DWZbD9q/cZ7 1fqDwKhpT55qK/zYR15XOX9xzaRCLRssMNZvAPG+v28Cte4nsIe3s4AiPHTKgiBW4uvB K+gvd4+cquwcE5ewDqABm1rOt0f1aHQnM9eDdHQxGHL3OKARkU1WT4+BYA9D4VxQuGuu 8mo66JcLITTdR+w87Pn3gTQY1SsXMWLLYS4pEVdTYE9bPXkwMajDXUGr06HtHyIlqCZR ihFQRgP6t6gBEBZ+elBtWzSviJZtPT8dr/hQg65qFL7AzMK277hIcXfK0jZh5K1FNrNk 17Yg== X-Gm-Message-State: AOUpUlHNSMkX3x9WXurZmx/jZOL0DwIJ7VFKZIJVKLpNC1eTHPTszx3z 1KR7XTHnENs0OHNaVt1XlzbYKkR8 X-Received: by 2002:adf:9246:: with SMTP id 64-v6mr1816210wrj.109.1531841810296; Tue, 17 Jul 2018 08:36:50 -0700 (PDT) Received: from boomer.baylibre.local ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id h12-v6sm16971464wmb.3.2018.07.17.08.36.49 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Jul 2018 08:36:49 -0700 (PDT) From: Jerome Brunet To: Mark Brown , Liam Girdwood , Kevin Hilman , Carlo Caione Date: Tue, 17 Jul 2018 17:36:27 +0200 Message-Id: <20180717153643.8806-4-jbrunet@baylibre.com> X-Mailer: git-send-email 2.14.4 In-Reply-To: <20180717153643.8806-1-jbrunet@baylibre.com> References: <20180717153643.8806-1-jbrunet@baylibre.com> Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, linux-amlogic@lists.infradead.org, linux-kernel@vger.kernel.org, Jerome Brunet Subject: [alsa-devel] [PATCH 03/15] ASoC: meson: add axg frddr driver 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 Add the playback memory interface of Amlogic's axg SoCs. This device pulls data from DDR to an internal FIFO. This FIFO is then used to feed TDM and SPDIF Output devices. Signed-off-by: Jerome Brunet --- sound/soc/meson/Kconfig | 7 +++ sound/soc/meson/Makefile | 2 + sound/soc/meson/axg-frddr.c | 141 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 150 insertions(+) create mode 100644 sound/soc/meson/axg-frddr.c -- 2.14.4 _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel diff --git a/sound/soc/meson/Kconfig b/sound/soc/meson/Kconfig index c3eb5e050308..cdd78f62e8d7 100644 --- a/sound/soc/meson/Kconfig +++ b/sound/soc/meson/Kconfig @@ -5,4 +5,11 @@ config SND_MESON_AXG_FIFO tristate select REGMAP_MMIO +config SND_MESON_AXG_FRDDR + tristate "Amlogic AXG Playback FIFO support" + select SND_MESON_AXG_FIFO + help + Select Y or M to add support for the frontend playback interfaces + embedded in the Amlogic AXG SoC family + endmenu diff --git a/sound/soc/meson/Makefile b/sound/soc/meson/Makefile index 75289b6b3ade..9c5d7d4a8e33 100644 --- a/sound/soc/meson/Makefile +++ b/sound/soc/meson/Makefile @@ -1,5 +1,7 @@ # SPDX-License-Identifier: (GPL-2.0 OR MIT) snd-soc-meson-axg-fifo-objs := axg-fifo.o +snd-soc-meson-axg-frddr-objs := axg-frddr.o obj-$(CONFIG_SND_MESON_AXG_FIFO) += snd-soc-meson-axg-fifo.o +obj-$(CONFIG_SND_MESON_AXG_FRDDR) += snd-soc-meson-axg-frddr.o diff --git a/sound/soc/meson/axg-frddr.c b/sound/soc/meson/axg-frddr.c new file mode 100644 index 000000000000..a6f6f6a2eca8 --- /dev/null +++ b/sound/soc/meson/axg-frddr.c @@ -0,0 +1,141 @@ +// SPDX-License-Identifier: (GPL-2.0 OR MIT) +// +// Copyright (c) 2018 BayLibre, SAS. +// Author: Jerome Brunet + +/* This driver implements the frontend playback DAI of AXG based SoCs */ + +#include +#include +#include +#include +#include +#include + +#include "axg-fifo.h" + +#define CTRL0_FRDDR_PP_MODE BIT(30) + +static int axg_frddr_dai_startup(struct snd_pcm_substream *substream, + struct snd_soc_dai *dai) +{ + struct axg_fifo *fifo = snd_soc_dai_get_drvdata(dai); + unsigned int fifo_depth, fifo_threshold; + int ret; + + /* Enable pclk to access registers and clock the fifo ip */ + ret = clk_prepare_enable(fifo->pclk); + if (ret) + return ret; + + /* Apply single buffer mode to the interface */ + regmap_update_bits(fifo->map, FIFO_CTRL0, CTRL0_FRDDR_PP_MODE, 0); + + /* + * TODO: We could adapt the fifo depth and the fifo threshold + * depending on the expected memory throughput and lantencies + * For now, we'll just use the same values as the vendor kernel + * Depth and threshold are zero based. + */ + fifo_depth = AXG_FIFO_MIN_CNT - 1; + fifo_threshold = (AXG_FIFO_MIN_CNT / 2) - 1; + regmap_update_bits(fifo->map, FIFO_CTRL1, + CTRL1_FRDDR_DEPTH_MASK | CTRL1_THRESHOLD_MASK, + CTRL1_FRDDR_DEPTH(fifo_depth) | + CTRL1_THRESHOLD(fifo_threshold)); + + return 0; +} + +static void axg_frddr_dai_shutdown(struct snd_pcm_substream *substream, + struct snd_soc_dai *dai) +{ + struct axg_fifo *fifo = snd_soc_dai_get_drvdata(dai); + + clk_disable_unprepare(fifo->pclk); +} + +static int axg_frddr_pcm_new(struct snd_soc_pcm_runtime *rtd, + struct snd_soc_dai *dai) +{ + return axg_fifo_pcm_new(rtd, SNDRV_PCM_STREAM_PLAYBACK); +} + +static const struct snd_soc_dai_ops axg_frddr_ops = { + .startup = axg_frddr_dai_startup, + .shutdown = axg_frddr_dai_shutdown, +}; + +static struct snd_soc_dai_driver axg_frddr_dai_drv = { + .name = "FRDDR", + .playback = { + .stream_name = "Playback", + .channels_min = 1, + .channels_max = AXG_FIFO_CH_MAX, + .rates = AXG_FIFO_RATES, + .formats = AXG_FIFO_FORMATS, + }, + .ops = &axg_frddr_ops, + .pcm_new = axg_frddr_pcm_new, +}; + +static const char * const axg_frddr_sel_texts[] = { + "OUT 0", "OUT 1", "OUT 2", "OUT 3" +}; + +static SOC_ENUM_SINGLE_DECL(axg_frddr_sel_enum, FIFO_CTRL0, CTRL0_SEL_SHIFT, + axg_frddr_sel_texts); + +static const struct snd_kcontrol_new axg_frddr_out_demux = + SOC_DAPM_ENUM("Output Sink", axg_frddr_sel_enum); + +static const struct snd_soc_dapm_widget axg_frddr_dapm_widgets[] = { + SND_SOC_DAPM_DEMUX("SINK SEL", SND_SOC_NOPM, 0, 0, + &axg_frddr_out_demux), + SND_SOC_DAPM_AIF_OUT("OUT 0", NULL, 0, SND_SOC_NOPM, 0, 0), + SND_SOC_DAPM_AIF_OUT("OUT 1", NULL, 0, SND_SOC_NOPM, 0, 0), + SND_SOC_DAPM_AIF_OUT("OUT 2", NULL, 0, SND_SOC_NOPM, 0, 0), + SND_SOC_DAPM_AIF_OUT("OUT 3", NULL, 0, SND_SOC_NOPM, 0, 0), +}; + +static const struct snd_soc_dapm_route axg_frddr_dapm_routes[] = { + { "SINK SEL", NULL, "Playback" }, + { "OUT 0", "OUT 0", "SINK SEL" }, + { "OUT 1", "OUT 1", "SINK SEL" }, + { "OUT 2", "OUT 2", "SINK SEL" }, + { "OUT 3", "OUT 3", "SINK SEL" }, +}; + +static const struct snd_soc_component_driver axg_frddr_component_drv = { + .dapm_widgets = axg_frddr_dapm_widgets, + .num_dapm_widgets = ARRAY_SIZE(axg_frddr_dapm_widgets), + .dapm_routes = axg_frddr_dapm_routes, + .num_dapm_routes = ARRAY_SIZE(axg_frddr_dapm_routes), + .ops = &axg_fifo_pcm_ops +}; + +static const struct axg_fifo_match_data axg_frddr_match_data = { + .component_drv = &axg_frddr_component_drv, + .dai_drv = &axg_frddr_dai_drv +}; + +static const struct of_device_id axg_frddr_of_match[] = { + { + .compatible = "amlogic,axg-frddr", + .data = &axg_frddr_match_data, + }, {} +}; +MODULE_DEVICE_TABLE(of, axg_frddr_of_match); + +static struct platform_driver axg_frddr_pdrv = { + .probe = axg_fifo_probe, + .driver = { + .name = "axg-frddr", + .of_match_table = axg_frddr_of_match, + }, +}; +module_platform_driver(axg_frddr_pdrv); + +MODULE_DESCRIPTION("Amlogic AXG playback fifo driver"); +MODULE_AUTHOR("Jerome Brunet "); +MODULE_LICENSE("GPL v2"); From patchwork Tue Jul 17 15:36:29 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 142167 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp3815037ljj; Tue, 17 Jul 2018 08:38:30 -0700 (PDT) X-Google-Smtp-Source: AAOMgpctQy/yf9oONsk/h2qCO275bFNCpQfepfLJiBiwQ58HKAfIm3tKXwoJ3s1diUu3shAwnHXO X-Received: by 2002:adf:be8d:: with SMTP id i13-v6mr1770732wrh.86.1531841910688; Tue, 17 Jul 2018 08:38:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531841910; cv=none; d=google.com; s=arc-20160816; b=YkbwswnTLxfKajSWZh3WWCLWUX9WDw0f06rxEOBm74If45P6PL3WasqmX8C5ua2eos u7s03xV3hHPzeBzHXgBcsrExEs9hVydD/RCPdPkF98CtgYGnACgTfXnr22Yk9iBpCrtU vMEAYg9Fchx6Iy6/NhldPQ8xVaxsnKczhTO3fqEE1UMzqsovZeUjpvvubwH1O727+PJf eDy/1OZGjQRdCGhVJe6LTdnE4YBWWbjwazRGrabzDTXhGIdCp1Fhc97AGnyu7RB1gYXA B7g4XZ4ik6/w2DQlI3Qf8jn6JR89XCYeqOsgXEqE9gHJ9dmoxUfNwuQZw+WdJM4yWF33 dGBQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:references:in-reply-to:message-id :date:to:from:dkim-signature:delivered-to:arc-authentication-results; bh=odIDe5n/+nQJjPftI+3i1+qynlFEwXYCXT4y8tqC9Ro=; b=QtTwJXfQFuL+1prIHHbfOw6Shxw69m8+ibwoAd015RMlgZWxI/gBiY1kQ2/9eTD1lC L4m3L+M8by7NxnVUuB2hE4Xw+vih/TY7oKlhVBrETW+KfShCp861/NJ9cLN2C9FXl88p 4A86/DuUtM3qKH7H8O5ME2ONy68lPqwT6whR4sC0JooaSGmh1kAnbNXSOShUrQdwh9oO PEvKE8KODiwztCJ/x0MKyjXuVu7WuSjYW5sn4Sf1m138n8CELmOMjjwSX3T58bZBGPpr prMKuznOlvW8tvZvjbv+qpC6xuiV8OvmmBM+snvRoJwgRZRpE869yMu9/fbM7+UgBo+7 aGoA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=tdgkWRw3; spf=pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) smtp.mailfrom=alsa-devel-bounces@alsa-project.org Return-Path: Received: from alsa0.perex.cz ([77.48.224.243]) by mx.google.com with ESMTP id f22-v6si1208170wmf.153.2018.07.17.08.38.30; Tue, 17 Jul 2018 08:38:30 -0700 (PDT) Received-SPF: pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) client-ip=77.48.224.243; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=tdgkWRw3; spf=pass (google.com: domain of alsa-devel-bounces@alsa-project.org designates 77.48.224.243 as permitted sender) smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 80502267803; Tue, 17 Jul 2018 17:37:01 +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 E34B72677D9; Tue, 17 Jul 2018 17:36:54 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail1.perex.cz X-Spam-Level: X-Spam-Status: No, score=0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_SOFTFAIL, T_DKIMWL_WL_MED autolearn=disabled version=3.4.0 Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by alsa0.perex.cz (Postfix) with ESMTP id 3110F2677D6 for ; Tue, 17 Jul 2018 17:36:52 +0200 (CEST) Received: by mail-wm0-f68.google.com with SMTP id v25-v6so1976425wmc.0 for ; Tue, 17 Jul 2018 08:36:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=vXYXkidVJx381ShSQL8RzCcLiMOwBCQSWCB4qdwObFE=; b=tdgkWRw3qyJqmKwRFAbbe/4QVyxkp5qQbvsv/6HvK/v/8SpQft/qvBWeDBINFE8YQo jx6UYLQCPVx2XdCtzjesBdA9drCTS+K6rJF3QY1ErHeC+R1qhzBYOQnP/u9rnlr/KNOX UEbMNKkX1R6vBVI859iz5EdM5u5S2vYWzKasUyCRoSs94+mj1EzkqW8iJo+S/t5Di4WM xgwGuYNIrslHJWD9t+dAJwkERCKeNOuOlsNDf0iXrz/JIdyocGu46VEL2RJBXkVYDp/B 1IP90ER/YH+pKoBtMDSKDh3tsElqhCi6bAXNGUSMl7YBZUmemZ9qucyOpK2Wkk7pAll1 T8jA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=vXYXkidVJx381ShSQL8RzCcLiMOwBCQSWCB4qdwObFE=; b=Yl/D5FGp78miDSZ7loVIov1QfCgyQxitb22MMczDY2SfGQVap6mU1KbvtDI+bRn66M cuDTbHMZ51h5g3UGLWM4zmDXH6w1fepCtZPI1h0myHiRZoW48dKJH0my0xZFu7pmBGJo uApcADxGuRedKq8wi5KtMAS2pUPoqrTl/CtgmSvQNLQkfSpJ1OiJxPkhJ8LIYLJUX5jc OxqwEX/inIOj25Hf111Hn/Muc0xdM3DhX05xcI0BeycnSMdQsGcoRnILDxq84lMsK0QB 08w81kCqeNixxDwFQm4p795GMLjc/cMaKy4Yy6R+DIxRYjETKvxJYE9n9N4Q60uE+a3u Y4LQ== X-Gm-Message-State: AOUpUlF+1oMGCO9YjkSpGsXY1fFRc3XiBNYMQ2KZY95Sa6hQEchCVRzD e5r/QProAGg8vmysUMuQvUUsQA== X-Received: by 2002:a1c:7506:: with SMTP id o6-v6mr1703579wmc.60.1531841812409; Tue, 17 Jul 2018 08:36:52 -0700 (PDT) Received: from boomer.baylibre.local ([90.63.244.31]) by smtp.googlemail.com with ESMTPSA id h12-v6sm16971464wmb.3.2018.07.17.08.36.51 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Jul 2018 08:36:51 -0700 (PDT) From: Jerome Brunet To: Mark Brown , Liam Girdwood , Kevin Hilman , Carlo Caione Date: Tue, 17 Jul 2018 17:36:29 +0200 Message-Id: <20180717153643.8806-6-jbrunet@baylibre.com> X-Mailer: git-send-email 2.14.4 In-Reply-To: <20180717153643.8806-1-jbrunet@baylibre.com> References: <20180717153643.8806-1-jbrunet@baylibre.com> Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, linux-amlogic@lists.infradead.org, linux-kernel@vger.kernel.org, Jerome Brunet Subject: [alsa-devel] [PATCH 05/15] ASoC: meson: add axg spdif output DT binding documentation 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 Add the DT binding documentation for axg's SPDIF output. Signed-off-by: Jerome Brunet --- .../bindings/sound/amlogic,axg-spdifout.txt | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/amlogic,axg-spdifout.txt -- 2.14.4 _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel diff --git a/Documentation/devicetree/bindings/sound/amlogic,axg-spdifout.txt b/Documentation/devicetree/bindings/sound/amlogic,axg-spdifout.txt new file mode 100644 index 000000000000..521c38ad89e7 --- /dev/null +++ b/Documentation/devicetree/bindings/sound/amlogic,axg-spdifout.txt @@ -0,0 +1,20 @@ +* Amlogic Audio SPDIF Output + +Required properties: +- compatible: 'amlogic,axg-spdifout' +- clocks: list of clock phandle, one for each entry clock-names. +- clock-names: should contain the following: + * "pclk" : peripheral clock. + * "mclk" : master clock +- #sound-dai-cells: must be 0. + +Example on the A113 SoC: + +spdifout: audio-controller@480 { + compatible = "amlogic,axg-spdifout"; + reg = <0x0 0x480 0x0 0x50>; + #sound-dai-cells = <0>; + clocks = <&clkc_audio AUD_CLKID_SPDIFOUT>, + <&clkc_audio AUD_CLKID_SPDIFOUT_CLK>; + clock-names = "pclk", "mclk"; +};