All of lore.kernel.org
 help / color / mirror / Atom feed
From: Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
To: Mark Brown <broonie@kernel.org>,
	alsa-devel@alsa-project.org, Rob Herring <robh+dt@kernel.org>,
	devicetree@vger.kernel.org,
	Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: Masami Hiramatsu <masami.hiramatsu@linaro.org>,
	Jassi Brar <jaswinder.singh@linaro.org>,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org,
	Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
Subject: [PATCH 1/8] ASoC: spdif: Add S32_LE support for S/PDIF dummy codec drivers
Date: Wed, 22 Nov 2017 20:43:14 +0900	[thread overview]
Message-ID: <20171122114321.29196-2-suzuki.katsuhiro@socionext.com> (raw)
In-Reply-To: <20171122114321.29196-1-suzuki.katsuhiro@socionext.com>

AIO on UniPhier can output S/PDIF where no codec is needed.
This patch adds S32_LE support for dummy codec drivers.

If one S/PDIF controller has its own limitation, its CPU DAI driver should
set the supported format by its own circumstance, since the soc-pcm driver
will use the intersection of cpu_dai's formats and codec_dai's formats.

Signed-off-by: Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
---
 sound/soc/codecs/spdif_receiver.c    | 5 +++--
 sound/soc/codecs/spdif_transmitter.c | 5 +++--
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/sound/soc/codecs/spdif_receiver.c b/sound/soc/codecs/spdif_receiver.c
index 7acd05140a81..c8fd6367f6c0 100644
--- a/sound/soc/codecs/spdif_receiver.c
+++ b/sound/soc/codecs/spdif_receiver.c
@@ -34,10 +34,11 @@ static const struct snd_soc_dapm_route dir_routes[] = {
 #define STUB_RATES	SNDRV_PCM_RATE_8000_192000
 #define STUB_FORMATS	(SNDRV_PCM_FMTBIT_S16_LE | \
 			SNDRV_PCM_FMTBIT_S20_3LE | \
-			SNDRV_PCM_FMTBIT_S24_LE | \
+			SNDRV_PCM_FMTBIT_S24_LE  | \
+			SNDRV_PCM_FMTBIT_S32_LE | \
 			SNDRV_PCM_FMTBIT_IEC958_SUBFRAME_LE)
 
-static const struct snd_soc_codec_driver soc_codec_spdif_dir = {
+static struct snd_soc_codec_driver soc_codec_spdif_dir = {
 	.component_driver = {
 		.dapm_widgets		= dir_widgets,
 		.num_dapm_widgets	= ARRAY_SIZE(dir_widgets),
diff --git a/sound/soc/codecs/spdif_transmitter.c b/sound/soc/codecs/spdif_transmitter.c
index 063a64ff82d3..037aa1d45559 100644
--- a/sound/soc/codecs/spdif_transmitter.c
+++ b/sound/soc/codecs/spdif_transmitter.c
@@ -27,7 +27,8 @@
 #define STUB_RATES	SNDRV_PCM_RATE_8000_192000
 #define STUB_FORMATS	(SNDRV_PCM_FMTBIT_S16_LE | \
 			SNDRV_PCM_FMTBIT_S20_3LE | \
-			SNDRV_PCM_FMTBIT_S24_LE)
+			SNDRV_PCM_FMTBIT_S24_LE  | \
+			SNDRV_PCM_FMTBIT_S32_LE)
 
 static const struct snd_soc_dapm_widget dit_widgets[] = {
 	SND_SOC_DAPM_OUTPUT("spdif-out"),
@@ -37,7 +38,7 @@ static const struct snd_soc_dapm_route dit_routes[] = {
 	{ "spdif-out", NULL, "Playback" },
 };
 
-static const struct snd_soc_codec_driver soc_codec_spdif_dit = {
+static struct snd_soc_codec_driver soc_codec_spdif_dit = {
 	.component_driver = {
 		.dapm_widgets		= dit_widgets,
 		.num_dapm_widgets	= ARRAY_SIZE(dit_widgets),
-- 
2.15.0

WARNING: multiple messages have this Message-ID (diff)
From: Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
To: Mark Brown <broonie@kernel.org>,
	alsa-devel@alsa-project.org, Rob Herring <robh+dt@kernel.org>,
	devicetree@vger.kernel.org,
	Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>,
	Jassi Brar <jaswinder.singh@linaro.org>,
	linux-arm-kernel@lists.infradead.org,
	Masami Hiramatsu <masami.hiramatsu@linaro.org>,
	linux-kernel@vger.kernel.org
Subject: [PATCH 1/8] ASoC: spdif: Add S32_LE support for S/PDIF dummy codec drivers
Date: Wed, 22 Nov 2017 20:43:14 +0900	[thread overview]
Message-ID: <20171122114321.29196-2-suzuki.katsuhiro@socionext.com> (raw)
In-Reply-To: <20171122114321.29196-1-suzuki.katsuhiro@socionext.com>

AIO on UniPhier can output S/PDIF where no codec is needed.
This patch adds S32_LE support for dummy codec drivers.

If one S/PDIF controller has its own limitation, its CPU DAI driver should
set the supported format by its own circumstance, since the soc-pcm driver
will use the intersection of cpu_dai's formats and codec_dai's formats.

Signed-off-by: Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
---
 sound/soc/codecs/spdif_receiver.c    | 5 +++--
 sound/soc/codecs/spdif_transmitter.c | 5 +++--
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/sound/soc/codecs/spdif_receiver.c b/sound/soc/codecs/spdif_receiver.c
index 7acd05140a81..c8fd6367f6c0 100644
--- a/sound/soc/codecs/spdif_receiver.c
+++ b/sound/soc/codecs/spdif_receiver.c
@@ -34,10 +34,11 @@ static const struct snd_soc_dapm_route dir_routes[] = {
 #define STUB_RATES	SNDRV_PCM_RATE_8000_192000
 #define STUB_FORMATS	(SNDRV_PCM_FMTBIT_S16_LE | \
 			SNDRV_PCM_FMTBIT_S20_3LE | \
-			SNDRV_PCM_FMTBIT_S24_LE | \
+			SNDRV_PCM_FMTBIT_S24_LE  | \
+			SNDRV_PCM_FMTBIT_S32_LE | \
 			SNDRV_PCM_FMTBIT_IEC958_SUBFRAME_LE)
 
-static const struct snd_soc_codec_driver soc_codec_spdif_dir = {
+static struct snd_soc_codec_driver soc_codec_spdif_dir = {
 	.component_driver = {
 		.dapm_widgets		= dir_widgets,
 		.num_dapm_widgets	= ARRAY_SIZE(dir_widgets),
diff --git a/sound/soc/codecs/spdif_transmitter.c b/sound/soc/codecs/spdif_transmitter.c
index 063a64ff82d3..037aa1d45559 100644
--- a/sound/soc/codecs/spdif_transmitter.c
+++ b/sound/soc/codecs/spdif_transmitter.c
@@ -27,7 +27,8 @@
 #define STUB_RATES	SNDRV_PCM_RATE_8000_192000
 #define STUB_FORMATS	(SNDRV_PCM_FMTBIT_S16_LE | \
 			SNDRV_PCM_FMTBIT_S20_3LE | \
-			SNDRV_PCM_FMTBIT_S24_LE)
+			SNDRV_PCM_FMTBIT_S24_LE  | \
+			SNDRV_PCM_FMTBIT_S32_LE)
 
 static const struct snd_soc_dapm_widget dit_widgets[] = {
 	SND_SOC_DAPM_OUTPUT("spdif-out"),
@@ -37,7 +38,7 @@ static const struct snd_soc_dapm_route dit_routes[] = {
 	{ "spdif-out", NULL, "Playback" },
 };
 
-static const struct snd_soc_codec_driver soc_codec_spdif_dit = {
+static struct snd_soc_codec_driver soc_codec_spdif_dit = {
 	.component_driver = {
 		.dapm_widgets		= dit_widgets,
 		.num_dapm_widgets	= ARRAY_SIZE(dit_widgets),
-- 
2.15.0

WARNING: multiple messages have this Message-ID (diff)
From: suzuki.katsuhiro@socionext.com (Katsuhiro Suzuki)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/8] ASoC: spdif: Add S32_LE support for S/PDIF dummy codec drivers
Date: Wed, 22 Nov 2017 20:43:14 +0900	[thread overview]
Message-ID: <20171122114321.29196-2-suzuki.katsuhiro@socionext.com> (raw)
In-Reply-To: <20171122114321.29196-1-suzuki.katsuhiro@socionext.com>

AIO on UniPhier can output S/PDIF where no codec is needed.
This patch adds S32_LE support for dummy codec drivers.

If one S/PDIF controller has its own limitation, its CPU DAI driver should
set the supported format by its own circumstance, since the soc-pcm driver
will use the intersection of cpu_dai's formats and codec_dai's formats.

Signed-off-by: Katsuhiro Suzuki <suzuki.katsuhiro@socionext.com>
---
 sound/soc/codecs/spdif_receiver.c    | 5 +++--
 sound/soc/codecs/spdif_transmitter.c | 5 +++--
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/sound/soc/codecs/spdif_receiver.c b/sound/soc/codecs/spdif_receiver.c
index 7acd05140a81..c8fd6367f6c0 100644
--- a/sound/soc/codecs/spdif_receiver.c
+++ b/sound/soc/codecs/spdif_receiver.c
@@ -34,10 +34,11 @@ static const struct snd_soc_dapm_route dir_routes[] = {
 #define STUB_RATES	SNDRV_PCM_RATE_8000_192000
 #define STUB_FORMATS	(SNDRV_PCM_FMTBIT_S16_LE | \
 			SNDRV_PCM_FMTBIT_S20_3LE | \
-			SNDRV_PCM_FMTBIT_S24_LE | \
+			SNDRV_PCM_FMTBIT_S24_LE  | \
+			SNDRV_PCM_FMTBIT_S32_LE | \
 			SNDRV_PCM_FMTBIT_IEC958_SUBFRAME_LE)
 
-static const struct snd_soc_codec_driver soc_codec_spdif_dir = {
+static struct snd_soc_codec_driver soc_codec_spdif_dir = {
 	.component_driver = {
 		.dapm_widgets		= dir_widgets,
 		.num_dapm_widgets	= ARRAY_SIZE(dir_widgets),
diff --git a/sound/soc/codecs/spdif_transmitter.c b/sound/soc/codecs/spdif_transmitter.c
index 063a64ff82d3..037aa1d45559 100644
--- a/sound/soc/codecs/spdif_transmitter.c
+++ b/sound/soc/codecs/spdif_transmitter.c
@@ -27,7 +27,8 @@
 #define STUB_RATES	SNDRV_PCM_RATE_8000_192000
 #define STUB_FORMATS	(SNDRV_PCM_FMTBIT_S16_LE | \
 			SNDRV_PCM_FMTBIT_S20_3LE | \
-			SNDRV_PCM_FMTBIT_S24_LE)
+			SNDRV_PCM_FMTBIT_S24_LE  | \
+			SNDRV_PCM_FMTBIT_S32_LE)
 
 static const struct snd_soc_dapm_widget dit_widgets[] = {
 	SND_SOC_DAPM_OUTPUT("spdif-out"),
@@ -37,7 +38,7 @@ static const struct snd_soc_dapm_route dit_routes[] = {
 	{ "spdif-out", NULL, "Playback" },
 };
 
-static const struct snd_soc_codec_driver soc_codec_spdif_dit = {
+static struct snd_soc_codec_driver soc_codec_spdif_dit = {
 	.component_driver = {
 		.dapm_widgets		= dit_widgets,
 		.num_dapm_widgets	= ARRAY_SIZE(dit_widgets),
-- 
2.15.0

  reply	other threads:[~2017-11-22 11:43 UTC|newest]

Thread overview: 73+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-22 11:43 [PATCH 0/8] add UniPhier audio system support Katsuhiro Suzuki
2017-11-22 11:43 ` Katsuhiro Suzuki
2017-11-22 11:43 ` Katsuhiro Suzuki [this message]
2017-11-22 11:43   ` [PATCH 1/8] ASoC: spdif: Add S32_LE support for S/PDIF dummy codec drivers Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-12-04 18:48   ` Applied "ASoC: spdif: Add S32_LE support for S/PDIF dummy codec drivers" to the asoc tree Mark Brown
2017-12-04 18:48     ` Mark Brown
2017-12-04 18:48     ` Mark Brown
2017-11-22 11:43 ` [PATCH 2/8] ASoC: uniphier: add DT bindings documentation for UniPhier EVEA Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-11-26 19:02   ` Rob Herring
2017-11-26 19:02     ` Rob Herring
2017-12-04 18:48   ` Applied "ASoC: uniphier: add DT bindings documentation for UniPhier EVEA" to the asoc tree Mark Brown
2017-12-04 18:48     ` Mark Brown
2017-12-04 18:48     ` Mark Brown
2017-11-22 11:43 ` [PATCH 3/8] ASoC: uniphier: add DT bindings documentation for UniPhier AIO Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-11-26 19:04   ` Rob Herring
2017-11-26 19:04     ` Rob Herring
2017-11-26 19:04     ` Rob Herring
2018-02-12 12:54   ` Applied "ASoC: uniphier: add DT bindings documentation for UniPhier AIO" to the asoc tree Mark Brown
2018-02-12 12:54     ` Mark Brown
2018-02-12 12:54     ` Mark Brown
2017-11-22 11:43 ` [PATCH 4/8] ASoC: uniphier: add support for UniPhier EVEA codec Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-12-04 18:20   ` Mark Brown
2017-12-04 18:20     ` Mark Brown
2017-12-04 18:20     ` Mark Brown
2017-12-05  0:58     ` Masahiro Yamada
2017-12-05  0:58       ` Masahiro Yamada
2017-12-05 11:59       ` Mark Brown
2017-12-05 11:59         ` Mark Brown
2017-12-05 11:59         ` Mark Brown
2017-12-04 18:48   ` Applied "ASoC: uniphier: add support for UniPhier EVEA codec" to the asoc tree Mark Brown
2017-12-04 18:48     ` Mark Brown
2017-12-04 18:48     ` Mark Brown
2017-11-22 11:43 ` [PATCH 5/8] ASoC: uniphier: add support for UniPhier AIO driver Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-12-04 18:39   ` Mark Brown
2017-12-04 18:39     ` Mark Brown
2017-12-04 18:39     ` Mark Brown
2017-12-05  4:48     ` Katsuhiro Suzuki
2017-12-05  4:48       ` Katsuhiro Suzuki
2017-12-05  4:48       ` Katsuhiro Suzuki
2017-12-05 12:14       ` Mark Brown
2017-12-05 12:14         ` Mark Brown
2017-12-05 12:14         ` Mark Brown
2017-12-06  6:03         ` Katsuhiro Suzuki
2017-12-06  6:03           ` Katsuhiro Suzuki
2017-12-06 12:58           ` Mark Brown
2017-12-06 12:58             ` Mark Brown
2017-12-06 12:58             ` Mark Brown
2017-12-11  9:21             ` Katsuhiro Suzuki
2017-12-11  9:21               ` Katsuhiro Suzuki
2017-12-11  9:21               ` Katsuhiro Suzuki
2017-12-11 15:16               ` Mark Brown
2017-12-11 15:16                 ` Mark Brown
2017-12-11 17:48                 ` [alsa-devel] " Vinod Koul
2017-12-11 17:48                   ` Vinod Koul
2017-12-12  4:33                   ` Katsuhiro Suzuki
2017-12-12  4:33                     ` Katsuhiro Suzuki
2017-11-22 11:43 ` [PATCH 6/8] ASoC: uniphier: add support for UniPhier LD11/LD20 " Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-11-22 11:43 ` [PATCH 7/8] MAINTAINERS: add entries for UniPhier ASoC sound drivers Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki
2017-12-04 18:48   ` Applied "MAINTAINERS: add entries for UniPhier ASoC sound drivers" to the asoc tree Mark Brown
2017-12-04 18:48     ` Mark Brown
2017-12-04 18:48     ` Mark Brown
2017-11-22 11:43 ` [PATCH 8/8] arm64: dts: uniphier: add sound node for UniPhier Katsuhiro Suzuki
2017-11-22 11:43   ` Katsuhiro Suzuki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171122114321.29196-2-suzuki.katsuhiro@socionext.com \
    --to=suzuki.katsuhiro@socionext.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=jaswinder.singh@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masami.hiramatsu@linaro.org \
    --cc=robh+dt@kernel.org \
    --cc=yamada.masahiro@socionext.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.