* [PATCH 1/4] ASoC: sun8i-codec: Remove analog "HP" widget
2017-02-10 9:41 [PATCH 0/4] ASoC: sun8i-codec: Clean-up Mylène Josserand
@ 2017-02-10 9:41 ` Mylène Josserand
2017-02-12 6:38 ` Chen-Yu Tsai
` (2 more replies)
2017-02-10 9:41 ` [PATCH 2/4] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE Mylène Josserand
` (2 subsequent siblings)
3 siblings, 3 replies; 20+ messages in thread
From: Mylène Josserand @ 2017-02-10 9:41 UTC (permalink / raw)
To: linux-arm-kernel
The "HP" widget is already present and take part to
the analog part (sun8i-codec-analog).
Remove it from the digital part as it is unnecessary.
Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
---
sound/soc/sunxi/sun8i-codec.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index b92bdc8361af..d60f6fbd36a2 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -321,8 +321,6 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SUN8I_MOD_RST_CTL_AIF1, 0, NULL, 0),
SND_SOC_DAPM_SUPPLY("RST DAC", SUN8I_MOD_RST_CTL,
SUN8I_MOD_RST_CTL_DAC, 0, NULL, 0),
-
- SND_SOC_DAPM_OUTPUT("HP"),
};
static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
@@ -344,10 +342,6 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
/* DAC Mixer Routes */
{ "Left DAC Mixer", "LSlot 0", "Digital Left DAC"},
{ "Right DAC Mixer", "RSlot 0", "Digital Right DAC"},
-
- /* End of route : HP out */
- { "HP", NULL, "Left DAC Mixer" },
- { "HP", NULL, "Right DAC Mixer" },
};
static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread* [PATCH 1/4] ASoC: sun8i-codec: Remove analog "HP" widget
2017-02-10 9:41 ` [PATCH 1/4] ASoC: sun8i-codec: Remove analog "HP" widget Mylène Josserand
@ 2017-02-12 6:38 ` Chen-Yu Tsai
2017-03-08 13:22 ` Applied "ASoC: sun8i-codec: Remove analog "HP" widget" to the asoc tree Mark Brown
2017-03-21 18:45 ` Mark Brown
2 siblings, 0 replies; 20+ messages in thread
From: Chen-Yu Tsai @ 2017-02-12 6:38 UTC (permalink / raw)
To: linux-arm-kernel
On Fri, Feb 10, 2017 at 5:41 PM, Myl?ne Josserand
<mylene.josserand@free-electrons.com> wrote:
> The "HP" widget is already present and take part to
> the analog part (sun8i-codec-analog).
>
> Remove it from the digital part as it is unnecessary.
>
> Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Applied "ASoC: sun8i-codec: Remove analog "HP" widget" to the asoc tree
2017-02-10 9:41 ` [PATCH 1/4] ASoC: sun8i-codec: Remove analog "HP" widget Mylène Josserand
2017-02-12 6:38 ` Chen-Yu Tsai
@ 2017-03-08 13:22 ` Mark Brown
2017-03-21 18:45 ` Mark Brown
2 siblings, 0 replies; 20+ messages in thread
From: Mark Brown @ 2017-03-08 13:22 UTC (permalink / raw)
To: linux-arm-kernel
The patch
ASoC: sun8i-codec: Remove analog "HP" widget
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
>From 4aa8146c89f336230de7f449805bd0edfc878fd4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Myl=C3=A8ne=20Josserand?=
<mylene.josserand@free-electrons.com>
Date: Fri, 10 Feb 2017 10:41:30 +0100
Subject: [PATCH] ASoC: sun8i-codec: Remove analog "HP" widget
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The "HP" widget is already present and take part to
the analog part (sun8i-codec-analog).
Remove it from the digital part as it is unnecessary.
Signed-off-by: Myl??ne Josserand <mylene.josserand@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
sound/soc/sunxi/sun8i-codec.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index b92bdc8361af..d60f6fbd36a2 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -321,8 +321,6 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SUN8I_MOD_RST_CTL_AIF1, 0, NULL, 0),
SND_SOC_DAPM_SUPPLY("RST DAC", SUN8I_MOD_RST_CTL,
SUN8I_MOD_RST_CTL_DAC, 0, NULL, 0),
-
- SND_SOC_DAPM_OUTPUT("HP"),
};
static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
@@ -344,10 +342,6 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
/* DAC Mixer Routes */
{ "Left DAC Mixer", "LSlot 0", "Digital Left DAC"},
{ "Right DAC Mixer", "RSlot 0", "Digital Right DAC"},
-
- /* End of route : HP out */
- { "HP", NULL, "Left DAC Mixer" },
- { "HP", NULL, "Right DAC Mixer" },
};
static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread* Applied "ASoC: sun8i-codec: Remove analog "HP" widget" to the asoc tree
2017-02-10 9:41 ` [PATCH 1/4] ASoC: sun8i-codec: Remove analog "HP" widget Mylène Josserand
2017-02-12 6:38 ` Chen-Yu Tsai
2017-03-08 13:22 ` Applied "ASoC: sun8i-codec: Remove analog "HP" widget" to the asoc tree Mark Brown
@ 2017-03-21 18:45 ` Mark Brown
2 siblings, 0 replies; 20+ messages in thread
From: Mark Brown @ 2017-03-21 18:45 UTC (permalink / raw)
To: linux-arm-kernel
The patch
ASoC: sun8i-codec: Remove analog "HP" widget
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
>From a82f16188a32a3c889916c582ea2d9188e3c2734 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Myl=C3=A8ne=20Josserand?=
<mylene.josserand@free-electrons.com>
Date: Sat, 18 Mar 2017 08:55:05 +0100
Subject: [PATCH] ASoC: sun8i-codec: Remove analog "HP" widget
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The "HP" widget is already present and take part to
the analog part (sun8i-codec-analog).
Remove it from the digital part as it is unnecessary.
Signed-off-by: Myl??ne Josserand <mylene.josserand@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
sound/soc/sunxi/sun8i-codec.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index b92bdc8361af..d60f6fbd36a2 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -321,8 +321,6 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SUN8I_MOD_RST_CTL_AIF1, 0, NULL, 0),
SND_SOC_DAPM_SUPPLY("RST DAC", SUN8I_MOD_RST_CTL,
SUN8I_MOD_RST_CTL_DAC, 0, NULL, 0),
-
- SND_SOC_DAPM_OUTPUT("HP"),
};
static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
@@ -344,10 +342,6 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
/* DAC Mixer Routes */
{ "Left DAC Mixer", "LSlot 0", "Digital Left DAC"},
{ "Right DAC Mixer", "RSlot 0", "Digital Right DAC"},
-
- /* End of route : HP out */
- { "HP", NULL, "Left DAC Mixer" },
- { "HP", NULL, "Right DAC Mixer" },
};
static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH 2/4] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE
2017-02-10 9:41 [PATCH 0/4] ASoC: sun8i-codec: Clean-up Mylène Josserand
2017-02-10 9:41 ` [PATCH 1/4] ASoC: sun8i-codec: Remove analog "HP" widget Mylène Josserand
@ 2017-02-10 9:41 ` Mylène Josserand
2017-02-12 6:39 ` Chen-Yu Tsai
` (2 more replies)
2017-02-10 9:41 ` [PATCH 3/4] ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY Mylène Josserand
2017-02-10 9:41 ` [PATCH 4/4] ASoC: sun8i-codec: Convert to use SND_SOC_DAPM_AIF_IN Mylène Josserand
3 siblings, 3 replies; 20+ messages in thread
From: Mylène Josserand @ 2017-02-10 9:41 UTC (permalink / raw)
To: linux-arm-kernel
Update the driver to use the new SOC_DAPM_DOUBLE definition
on the digital DAC mixer.
Update the names accordingly as, when they are shared, the
controls are not prefixed with the widget's name anymore.
Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
---
sound/soc/sunxi/sun8i-codec.c | 45 ++++++++++++++++++++-----------------------
1 file changed, 21 insertions(+), 24 deletions(-)
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index d60f6fbd36a2..107fa8213600 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -259,25 +259,20 @@ static int sun8i_codec_hw_params(struct snd_pcm_substream *substream,
return 0;
}
-static const struct snd_kcontrol_new sun8i_output_left_mixer_controls[] = {
- SOC_DAPM_SINGLE("LSlot 0", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA0L, 1, 0),
- SOC_DAPM_SINGLE("LSlot 1", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA1L, 1, 0),
- SOC_DAPM_SINGLE("DACL", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF2DACL, 1, 0),
- SOC_DAPM_SINGLE("ADCL", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_ADCL, 1, 0),
-};
-
-static const struct snd_kcontrol_new sun8i_output_right_mixer_controls[] = {
- SOC_DAPM_SINGLE("RSlot 0", SUN8I_DAC_MXR_SRC,
+static const struct snd_kcontrol_new sun8i_dac_mixer_controls[] = {
+ SOC_DAPM_DOUBLE("AIF1 Slot 0 Digital DAC Playback Switch",
+ SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA0L,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF1DA0R, 1, 0),
- SOC_DAPM_SINGLE("RSlot 1", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("AIF1 Slot 1 Digital DAC Playback Switch",
+ SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA1L,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF1DA1R, 1, 0),
- SOC_DAPM_SINGLE("DACR", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("AIF2 Digital DAC Playback Switch", SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF2DACL,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF2DACR, 1, 0),
- SOC_DAPM_SINGLE("ADCR", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("ADC Digital DAC Playback Switch", SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_ADCL,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_ADCR, 1, 0),
};
@@ -293,12 +288,12 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
/* DAC Mixers */
- SND_SOC_DAPM_MIXER("Left DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_output_left_mixer_controls,
- ARRAY_SIZE(sun8i_output_left_mixer_controls)),
- SND_SOC_DAPM_MIXER("Right DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_output_right_mixer_controls,
- ARRAY_SIZE(sun8i_output_right_mixer_controls)),
+ SND_SOC_DAPM_MIXER("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls,
+ ARRAY_SIZE(sun8i_dac_mixer_controls)),
+ SND_SOC_DAPM_MIXER("Right Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls,
+ ARRAY_SIZE(sun8i_dac_mixer_controls)),
/* Clocks */
SND_SOC_DAPM_SUPPLY("MODCLK AFI1", SUN8I_MOD_CLK_ENA,
@@ -340,8 +335,10 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
{ "Digital Right DAC", NULL, "DAC" },
/* DAC Mixer Routes */
- { "Left DAC Mixer", "LSlot 0", "Digital Left DAC"},
- { "Right DAC Mixer", "RSlot 0", "Digital Right DAC"},
+ { "Left Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch",
+ "Digital Left DAC"},
+ { "Right Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch ",
+ "Digital Right DAC"},
};
static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread* [PATCH 2/4] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE
2017-02-10 9:41 ` [PATCH 2/4] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE Mylène Josserand
@ 2017-02-12 6:39 ` Chen-Yu Tsai
2017-03-08 13:22 ` Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree Mark Brown
2017-03-21 18:45 ` Mark Brown
2 siblings, 0 replies; 20+ messages in thread
From: Chen-Yu Tsai @ 2017-02-12 6:39 UTC (permalink / raw)
To: linux-arm-kernel
On Fri, Feb 10, 2017 at 5:41 PM, Myl?ne Josserand
<mylene.josserand@free-electrons.com> wrote:
> Update the driver to use the new SOC_DAPM_DOUBLE definition
> on the digital DAC mixer.
> Update the names accordingly as, when they are shared, the
> controls are not prefixed with the widget's name anymore.
>
> Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree
2017-02-10 9:41 ` [PATCH 2/4] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE Mylène Josserand
2017-02-12 6:39 ` Chen-Yu Tsai
@ 2017-03-08 13:22 ` Mark Brown
2017-03-14 4:31 ` Chen-Yu Tsai
2017-03-21 18:45 ` Mark Brown
2 siblings, 1 reply; 20+ messages in thread
From: Mark Brown @ 2017-03-08 13:22 UTC (permalink / raw)
To: linux-arm-kernel
The patch
ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
>From ca14da6e611674cad275f29ac2aaf1e2eb427c6b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Myl=C3=A8ne=20Josserand?=
<mylene.josserand@free-electrons.com>
Date: Fri, 10 Feb 2017 10:41:31 +0100
Subject: [PATCH] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Update the driver to use the new SOC_DAPM_DOUBLE definition
on the digital DAC mixer.
Update the names accordingly as, when they are shared, the
controls are not prefixed with the widget's name anymore.
Signed-off-by: Myl??ne Josserand <mylene.josserand@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
sound/soc/sunxi/sun8i-codec.c | 45 ++++++++++++++++++++-----------------------
1 file changed, 21 insertions(+), 24 deletions(-)
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index d60f6fbd36a2..107fa8213600 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -259,25 +259,20 @@ static int sun8i_codec_hw_params(struct snd_pcm_substream *substream,
return 0;
}
-static const struct snd_kcontrol_new sun8i_output_left_mixer_controls[] = {
- SOC_DAPM_SINGLE("LSlot 0", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA0L, 1, 0),
- SOC_DAPM_SINGLE("LSlot 1", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA1L, 1, 0),
- SOC_DAPM_SINGLE("DACL", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF2DACL, 1, 0),
- SOC_DAPM_SINGLE("ADCL", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_ADCL, 1, 0),
-};
-
-static const struct snd_kcontrol_new sun8i_output_right_mixer_controls[] = {
- SOC_DAPM_SINGLE("RSlot 0", SUN8I_DAC_MXR_SRC,
+static const struct snd_kcontrol_new sun8i_dac_mixer_controls[] = {
+ SOC_DAPM_DOUBLE("AIF1 Slot 0 Digital DAC Playback Switch",
+ SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA0L,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF1DA0R, 1, 0),
- SOC_DAPM_SINGLE("RSlot 1", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("AIF1 Slot 1 Digital DAC Playback Switch",
+ SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA1L,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF1DA1R, 1, 0),
- SOC_DAPM_SINGLE("DACR", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("AIF2 Digital DAC Playback Switch", SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF2DACL,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF2DACR, 1, 0),
- SOC_DAPM_SINGLE("ADCR", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("ADC Digital DAC Playback Switch", SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_ADCL,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_ADCR, 1, 0),
};
@@ -293,12 +288,12 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
/* DAC Mixers */
- SND_SOC_DAPM_MIXER("Left DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_output_left_mixer_controls,
- ARRAY_SIZE(sun8i_output_left_mixer_controls)),
- SND_SOC_DAPM_MIXER("Right DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_output_right_mixer_controls,
- ARRAY_SIZE(sun8i_output_right_mixer_controls)),
+ SND_SOC_DAPM_MIXER("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls,
+ ARRAY_SIZE(sun8i_dac_mixer_controls)),
+ SND_SOC_DAPM_MIXER("Right Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls,
+ ARRAY_SIZE(sun8i_dac_mixer_controls)),
/* Clocks */
SND_SOC_DAPM_SUPPLY("MODCLK AFI1", SUN8I_MOD_CLK_ENA,
@@ -340,8 +335,10 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
{ "Digital Right DAC", NULL, "DAC" },
/* DAC Mixer Routes */
- { "Left DAC Mixer", "LSlot 0", "Digital Left DAC"},
- { "Right DAC Mixer", "RSlot 0", "Digital Right DAC"},
+ { "Left Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch",
+ "Digital Left DAC"},
+ { "Right Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch ",
+ "Digital Right DAC"},
};
static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread* Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree
2017-03-08 13:22 ` Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree Mark Brown
@ 2017-03-14 4:31 ` Chen-Yu Tsai
2017-03-15 13:43 ` Mark Brown
0 siblings, 1 reply; 20+ messages in thread
From: Chen-Yu Tsai @ 2017-03-14 4:31 UTC (permalink / raw)
To: linux-arm-kernel
Hi Mark,
On Wed, Mar 8, 2017 at 9:22 PM, Mark Brown <broonie@kernel.org> wrote:
> The patch
>
> ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE
>
> has been applied to the asoc tree at
>
> git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
>
> All being well this means that it will be integrated into the linux-next
> tree (usually sometime in the next 24 hours) and sent to Linus during
> the next merge window (or sooner if it is a bug fix), however if
> problems are discovered then the patch may be dropped or reverted.
>
> You may get further e-mails resulting from automated or manual testing
> and review of the tree, please engage with people reporting problems and
> send followup patches addressing any issues that are reported if needed.
>
> If any updates are required or you are submitting further changes they
> should be sent as incremental updates against current git, existing
> patches will not be replaced.
>
> Please add any relevant lists and maintainers to the CCs when replying
> to this mail.
>
> Thanks,
> Mark
>
> From ca14da6e611674cad275f29ac2aaf1e2eb427c6b Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?Myl=C3=A8ne=20Josserand?=
> <mylene.josserand@free-electrons.com>
> Date: Fri, 10 Feb 2017 10:41:31 +0100
> Subject: [PATCH] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE
> MIME-Version: 1.0
> Content-Type: text/plain; charset=UTF-8
> Content-Transfer-Encoding: 8bit
>
> Update the driver to use the new SOC_DAPM_DOUBLE definition
> on the digital DAC mixer.
> Update the names accordingly as, when they are shared, the
> controls are not prefixed with the widget's name anymore.
>
> Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
> Acked-by: Chen-Yu Tsai <wens@csie.org>
> Signed-off-by: Mark Brown <broonie@kernel.org>
> ---
> sound/soc/sunxi/sun8i-codec.c | 45 ++++++++++++++++++++-----------------------
> 1 file changed, 21 insertions(+), 24 deletions(-)
>
> diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
> index d60f6fbd36a2..107fa8213600 100644
> --- a/sound/soc/sunxi/sun8i-codec.c
> +++ b/sound/soc/sunxi/sun8i-codec.c
> @@ -259,25 +259,20 @@ static int sun8i_codec_hw_params(struct snd_pcm_substream *substream,
> return 0;
> }
>
> -static const struct snd_kcontrol_new sun8i_output_left_mixer_controls[] = {
> - SOC_DAPM_SINGLE("LSlot 0", SUN8I_DAC_MXR_SRC,
> - SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA0L, 1, 0),
> - SOC_DAPM_SINGLE("LSlot 1", SUN8I_DAC_MXR_SRC,
> - SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA1L, 1, 0),
> - SOC_DAPM_SINGLE("DACL", SUN8I_DAC_MXR_SRC,
> - SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF2DACL, 1, 0),
> - SOC_DAPM_SINGLE("ADCL", SUN8I_DAC_MXR_SRC,
> - SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_ADCL, 1, 0),
> -};
> -
> -static const struct snd_kcontrol_new sun8i_output_right_mixer_controls[] = {
> - SOC_DAPM_SINGLE("RSlot 0", SUN8I_DAC_MXR_SRC,
> +static const struct snd_kcontrol_new sun8i_dac_mixer_controls[] = {
> + SOC_DAPM_DOUBLE("AIF1 Slot 0 Digital DAC Playback Switch",
> + SUN8I_DAC_MXR_SRC,
> + SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA0L,
> SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF1DA0R, 1, 0),
> - SOC_DAPM_SINGLE("RSlot 1", SUN8I_DAC_MXR_SRC,
> + SOC_DAPM_DOUBLE("AIF1 Slot 1 Digital DAC Playback Switch",
> + SUN8I_DAC_MXR_SRC,
> + SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA1L,
> SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF1DA1R, 1, 0),
> - SOC_DAPM_SINGLE("DACR", SUN8I_DAC_MXR_SRC,
> + SOC_DAPM_DOUBLE("AIF2 Digital DAC Playback Switch", SUN8I_DAC_MXR_SRC,
> + SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF2DACL,
> SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF2DACR, 1, 0),
> - SOC_DAPM_SINGLE("ADCR", SUN8I_DAC_MXR_SRC,
> + SOC_DAPM_DOUBLE("ADC Digital DAC Playback Switch", SUN8I_DAC_MXR_SRC,
> + SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_ADCL,
> SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_ADCR, 1, 0),
> };
>
> @@ -293,12 +288,12 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
> SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
>
> /* DAC Mixers */
> - SND_SOC_DAPM_MIXER("Left DAC Mixer", SND_SOC_NOPM, 0, 0,
> - sun8i_output_left_mixer_controls,
> - ARRAY_SIZE(sun8i_output_left_mixer_controls)),
> - SND_SOC_DAPM_MIXER("Right DAC Mixer", SND_SOC_NOPM, 0, 0,
> - sun8i_output_right_mixer_controls,
> - ARRAY_SIZE(sun8i_output_right_mixer_controls)),
> + SND_SOC_DAPM_MIXER("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
> + sun8i_dac_mixer_controls,
> + ARRAY_SIZE(sun8i_dac_mixer_controls)),
> + SND_SOC_DAPM_MIXER("Right Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
> + sun8i_dac_mixer_controls,
> + ARRAY_SIZE(sun8i_dac_mixer_controls)),
This patch changes the mixer controls exposed to user space.
This driver was just introduced in 4.11-rc1. Would it make sense to
merge these cleanup patches as fixes for 4.11, so we don't affect
userspace across kernel releases?
Thanks
ChenYu
>
> /* Clocks */
> SND_SOC_DAPM_SUPPLY("MODCLK AFI1", SUN8I_MOD_CLK_ENA,
> @@ -340,8 +335,10 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
> { "Digital Right DAC", NULL, "DAC" },
>
> /* DAC Mixer Routes */
> - { "Left DAC Mixer", "LSlot 0", "Digital Left DAC"},
> - { "Right DAC Mixer", "RSlot 0", "Digital Right DAC"},
> + { "Left Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch",
> + "Digital Left DAC"},
> + { "Right Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch ",
> + "Digital Right DAC"},
> };
>
> static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
> --
> 2.11.0
>
^ permalink raw reply [flat|nested] 20+ messages in thread* Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree
2017-03-14 4:31 ` Chen-Yu Tsai
@ 2017-03-15 13:43 ` Mark Brown
2017-03-15 14:15 ` Chen-Yu Tsai
0 siblings, 1 reply; 20+ messages in thread
From: Mark Brown @ 2017-03-15 13:43 UTC (permalink / raw)
To: linux-arm-kernel
On Tue, Mar 14, 2017 at 12:31:22PM +0800, Chen-Yu Tsai wrote:
> On Wed, Mar 8, 2017 at 9:22 PM, Mark Brown <broonie@kernel.org> wrote:
Please delete unneeded context from mails when replying. Doing this
makes it much easier to find your reply in the message, helping ensure
it won't be missed by people scrolling through the irrelevant quoted
material.
> This patch changes the mixer controls exposed to user space.
> This driver was just introduced in 4.11-rc1. Would it make sense to
> merge these cleanup patches as fixes for 4.11, so we don't affect
> userspace across kernel releases?
It would but it doesn't pick over cleanly, it looks like it depends on
some of the other changes.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20170315/e8c39855/attachment-0001.sig>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree
2017-03-15 13:43 ` Mark Brown
@ 2017-03-15 14:15 ` Chen-Yu Tsai
2017-03-16 14:06 ` Mark Brown
0 siblings, 1 reply; 20+ messages in thread
From: Chen-Yu Tsai @ 2017-03-15 14:15 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, Mar 15, 2017 at 9:43 PM, Mark Brown <broonie@kernel.org> wrote:
> On Tue, Mar 14, 2017 at 12:31:22PM +0800, Chen-Yu Tsai wrote:
>> On Wed, Mar 8, 2017 at 9:22 PM, Mark Brown <broonie@kernel.org> wrote:
>> This patch changes the mixer controls exposed to user space.
>
>> This driver was just introduced in 4.11-rc1. Would it make sense to
>> merge these cleanup patches as fixes for 4.11, so we don't affect
>> userspace across kernel releases?
>
> It would but it doesn't pick over cleanly, it looks like it depends on
> some of the other changes.
It depends on the second half of commit 4aa8146c89f3 ("ASoC: sun8i-codec:
Remove analog "HP" widget"), which is also a cleanup. Would it be OK
to pick these two over to fixes then? Or should we send a clean version
instead?
ChenYu
^ permalink raw reply [flat|nested] 20+ messages in thread* Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree
2017-03-15 14:15 ` Chen-Yu Tsai
@ 2017-03-16 14:06 ` Mark Brown
2017-03-17 8:13 ` Mylene Josserand
0 siblings, 1 reply; 20+ messages in thread
From: Mark Brown @ 2017-03-16 14:06 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, Mar 15, 2017 at 10:15:22PM +0800, Chen-Yu Tsai wrote:
> It depends on the second half of commit 4aa8146c89f3 ("ASoC: sun8i-codec:
> Remove analog "HP" widget"), which is also a cleanup. Would it be OK
> to pick these two over to fixes then? Or should we send a clean version
> instead?
That also doesn't pick over cleanly, can you send a new version against
Linus' tree, that'll be easiest and safest I think.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20170316/69d56a4b/attachment.sig>
^ permalink raw reply [flat|nested] 20+ messages in thread* Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree
2017-03-16 14:06 ` Mark Brown
@ 2017-03-17 8:13 ` Mylene Josserand
0 siblings, 0 replies; 20+ messages in thread
From: Mylene Josserand @ 2017-03-17 8:13 UTC (permalink / raw)
To: linux-arm-kernel
Hello,
On 16/03/2017 15:06, Mark Brown wrote:
> On Wed, Mar 15, 2017 at 10:15:22PM +0800, Chen-Yu Tsai wrote:
>
>> It depends on the second half of commit 4aa8146c89f3 ("ASoC: sun8i-codec:
>> Remove analog "HP" widget"), which is also a cleanup. Would it be OK
>> to pick these two over to fixes then? Or should we send a clean version
>> instead?
>
> That also doesn't pick over cleanly, can you send a new version against
> Linus' tree, that'll be easiest and safest I think.
>
No problem, I will do that.
Thank you!
Best regards,
--
Myl?ne Josserand, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 20+ messages in thread
* Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree
2017-02-10 9:41 ` [PATCH 2/4] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE Mylène Josserand
2017-02-12 6:39 ` Chen-Yu Tsai
2017-03-08 13:22 ` Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree Mark Brown
@ 2017-03-21 18:45 ` Mark Brown
2 siblings, 0 replies; 20+ messages in thread
From: Mark Brown @ 2017-03-21 18:45 UTC (permalink / raw)
To: linux-arm-kernel
The patch
ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
>From 649d55436137b397accb6a9d1b6975598c693bcd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Myl=C3=A8ne=20Josserand?=
<mylene.josserand@free-electrons.com>
Date: Sat, 18 Mar 2017 08:55:06 +0100
Subject: [PATCH] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Update the driver to use the new SOC_DAPM_DOUBLE definition
on the digital DAC mixer.
Update the names accordingly as, when they are shared, the
controls are not prefixed with the widget's name anymore.
Signed-off-by: Myl??ne Josserand <mylene.josserand@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
sound/soc/sunxi/sun8i-codec.c | 45 ++++++++++++++++++++-----------------------
1 file changed, 21 insertions(+), 24 deletions(-)
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index d60f6fbd36a2..107fa8213600 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -259,25 +259,20 @@ static int sun8i_codec_hw_params(struct snd_pcm_substream *substream,
return 0;
}
-static const struct snd_kcontrol_new sun8i_output_left_mixer_controls[] = {
- SOC_DAPM_SINGLE("LSlot 0", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA0L, 1, 0),
- SOC_DAPM_SINGLE("LSlot 1", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA1L, 1, 0),
- SOC_DAPM_SINGLE("DACL", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF2DACL, 1, 0),
- SOC_DAPM_SINGLE("ADCL", SUN8I_DAC_MXR_SRC,
- SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_ADCL, 1, 0),
-};
-
-static const struct snd_kcontrol_new sun8i_output_right_mixer_controls[] = {
- SOC_DAPM_SINGLE("RSlot 0", SUN8I_DAC_MXR_SRC,
+static const struct snd_kcontrol_new sun8i_dac_mixer_controls[] = {
+ SOC_DAPM_DOUBLE("AIF1 Slot 0 Digital DAC Playback Switch",
+ SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA0L,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF1DA0R, 1, 0),
- SOC_DAPM_SINGLE("RSlot 1", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("AIF1 Slot 1 Digital DAC Playback Switch",
+ SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF1DA1L,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF1DA1R, 1, 0),
- SOC_DAPM_SINGLE("DACR", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("AIF2 Digital DAC Playback Switch", SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_AIF2DACL,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_AIF2DACR, 1, 0),
- SOC_DAPM_SINGLE("ADCR", SUN8I_DAC_MXR_SRC,
+ SOC_DAPM_DOUBLE("ADC Digital DAC Playback Switch", SUN8I_DAC_MXR_SRC,
+ SUN8I_DAC_MXR_SRC_DACL_MXR_SRC_ADCL,
SUN8I_DAC_MXR_SRC_DACR_MXR_SRC_ADCR, 1, 0),
};
@@ -293,12 +288,12 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
/* DAC Mixers */
- SND_SOC_DAPM_MIXER("Left DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_output_left_mixer_controls,
- ARRAY_SIZE(sun8i_output_left_mixer_controls)),
- SND_SOC_DAPM_MIXER("Right DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_output_right_mixer_controls,
- ARRAY_SIZE(sun8i_output_right_mixer_controls)),
+ SND_SOC_DAPM_MIXER("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls,
+ ARRAY_SIZE(sun8i_dac_mixer_controls)),
+ SND_SOC_DAPM_MIXER("Right Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls,
+ ARRAY_SIZE(sun8i_dac_mixer_controls)),
/* Clocks */
SND_SOC_DAPM_SUPPLY("MODCLK AFI1", SUN8I_MOD_CLK_ENA,
@@ -340,8 +335,10 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
{ "Digital Right DAC", NULL, "DAC" },
/* DAC Mixer Routes */
- { "Left DAC Mixer", "LSlot 0", "Digital Left DAC"},
- { "Right DAC Mixer", "RSlot 0", "Digital Right DAC"},
+ { "Left Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch",
+ "Digital Left DAC"},
+ { "Right Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch ",
+ "Digital Right DAC"},
};
static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH 3/4] ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY
2017-02-10 9:41 [PATCH 0/4] ASoC: sun8i-codec: Clean-up Mylène Josserand
2017-02-10 9:41 ` [PATCH 1/4] ASoC: sun8i-codec: Remove analog "HP" widget Mylène Josserand
2017-02-10 9:41 ` [PATCH 2/4] ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE Mylène Josserand
@ 2017-02-10 9:41 ` Mylène Josserand
2017-02-12 6:40 ` Chen-Yu Tsai
2017-03-08 13:22 ` Applied "ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY" to the asoc tree Mark Brown
2017-02-10 9:41 ` [PATCH 4/4] ASoC: sun8i-codec: Convert to use SND_SOC_DAPM_AIF_IN Mylène Josserand
3 siblings, 2 replies; 20+ messages in thread
From: Mylène Josserand @ 2017-02-10 9:41 UTC (permalink / raw)
To: linux-arm-kernel
SOC_MIXER_ARRAY is a simplified function of SND_SOC_DAPM_MIXER
which handles automatically the ARRAY_SIZE of controls.
Update the driver to use SOC_MIXER_ARRAY.
Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
---
sound/soc/sunxi/sun8i-codec.c | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index 107fa8213600..a75a983974d9 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -288,12 +288,10 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
/* DAC Mixers */
- SND_SOC_DAPM_MIXER("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_dac_mixer_controls,
- ARRAY_SIZE(sun8i_dac_mixer_controls)),
- SND_SOC_DAPM_MIXER("Right Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_dac_mixer_controls,
- ARRAY_SIZE(sun8i_dac_mixer_controls)),
+ SOC_MIXER_ARRAY("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls),
+ SOC_MIXER_ARRAY("Right Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls),
/* Clocks */
SND_SOC_DAPM_SUPPLY("MODCLK AFI1", SUN8I_MOD_CLK_ENA,
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread* [PATCH 3/4] ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY
2017-02-10 9:41 ` [PATCH 3/4] ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY Mylène Josserand
@ 2017-02-12 6:40 ` Chen-Yu Tsai
2017-03-08 13:22 ` Applied "ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY" to the asoc tree Mark Brown
1 sibling, 0 replies; 20+ messages in thread
From: Chen-Yu Tsai @ 2017-02-12 6:40 UTC (permalink / raw)
To: linux-arm-kernel
On Fri, Feb 10, 2017 at 5:41 PM, Myl?ne Josserand
<mylene.josserand@free-electrons.com> wrote:
> SOC_MIXER_ARRAY is a simplified function of SND_SOC_DAPM_MIXER
> which handles automatically the ARRAY_SIZE of controls.
>
> Update the driver to use SOC_MIXER_ARRAY.
>
> Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Applied "ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY" to the asoc tree
2017-02-10 9:41 ` [PATCH 3/4] ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY Mylène Josserand
2017-02-12 6:40 ` Chen-Yu Tsai
@ 2017-03-08 13:22 ` Mark Brown
1 sibling, 0 replies; 20+ messages in thread
From: Mark Brown @ 2017-03-08 13:22 UTC (permalink / raw)
To: linux-arm-kernel
The patch
ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
>From fa22ca4f905d7001ed966bc95bcffb890a1b8d73 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Myl=C3=A8ne=20Josserand?=
<mylene.josserand@free-electrons.com>
Date: Fri, 10 Feb 2017 10:41:32 +0100
Subject: [PATCH] ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
SOC_MIXER_ARRAY is a simplified function of SND_SOC_DAPM_MIXER
which handles automatically the ARRAY_SIZE of controls.
Update the driver to use SOC_MIXER_ARRAY.
Signed-off-by: Myl??ne Josserand <mylene.josserand@free-electrons.com>
Acked-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
---
sound/soc/sunxi/sun8i-codec.c | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index 107fa8213600..a75a983974d9 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -288,12 +288,10 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
/* DAC Mixers */
- SND_SOC_DAPM_MIXER("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_dac_mixer_controls,
- ARRAY_SIZE(sun8i_dac_mixer_controls)),
- SND_SOC_DAPM_MIXER("Right Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
- sun8i_dac_mixer_controls,
- ARRAY_SIZE(sun8i_dac_mixer_controls)),
+ SOC_MIXER_ARRAY("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls),
+ SOC_MIXER_ARRAY("Right Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
+ sun8i_dac_mixer_controls),
/* Clocks */
SND_SOC_DAPM_SUPPLY("MODCLK AFI1", SUN8I_MOD_CLK_ENA,
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread
* [PATCH 4/4] ASoC: sun8i-codec: Convert to use SND_SOC_DAPM_AIF_IN
2017-02-10 9:41 [PATCH 0/4] ASoC: sun8i-codec: Clean-up Mylène Josserand
` (2 preceding siblings ...)
2017-02-10 9:41 ` [PATCH 3/4] ASoC: sun8i-codec: Convert to SOC_MIXER_ARRAY Mylène Josserand
@ 2017-02-10 9:41 ` Mylène Josserand
2017-03-06 9:56 ` Chen-Yu Tsai
3 siblings, 1 reply; 20+ messages in thread
From: Mylène Josserand @ 2017-02-10 9:41 UTC (permalink / raw)
To: linux-arm-kernel
Update the driver to use SND_SOC_DAPM_AIF_IN instead of
SND_SOC_DAPM_DAC.
Set the route names so it must be updated on the device tree too.
Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
---
arch/arm/boot/dts/sun8i-a33.dtsi | 4 ++--
sound/soc/sunxi/sun8i-codec.c | 20 +++++++++++---------
2 files changed, 13 insertions(+), 11 deletions(-)
diff --git a/arch/arm/boot/dts/sun8i-a33.dtsi b/arch/arm/boot/dts/sun8i-a33.dtsi
index 4e34ec6613a0..e9e2e7312460 100644
--- a/arch/arm/boot/dts/sun8i-a33.dtsi
+++ b/arch/arm/boot/dts/sun8i-a33.dtsi
@@ -78,8 +78,8 @@
simple-audio-card,mclk-fs = <512>;
simple-audio-card,aux-devs = <&codec_analog>;
simple-audio-card,routing =
- "Left DAC", "Digital Left DAC",
- "Right DAC", "Digital Right DAC";
+ "Left DAC", "AIF1 Slot 0 Left",
+ "Right DAC", "AIF1 Slot 0 Right";
status = "disabled";
simple-audio-card,cpu {
diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
index a75a983974d9..9b15a5ee235f 100644
--- a/sound/soc/sunxi/sun8i-codec.c
+++ b/sound/soc/sunxi/sun8i-codec.c
@@ -281,11 +281,13 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
SND_SOC_DAPM_SUPPLY("DAC", SUN8I_DAC_DIG_CTRL, SUN8I_DAC_DIG_CTRL_ENDA,
0, NULL, 0),
- /* Analog DAC */
- SND_SOC_DAPM_DAC("Digital Left DAC", "Playback", SUN8I_AIF1_DACDAT_CTRL,
- SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0L_ENA, 0),
- SND_SOC_DAPM_DAC("Digital Right DAC", "Playback", SUN8I_AIF1_DACDAT_CTRL,
- SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
+ /* Analog DAC AIF */
+ SND_SOC_DAPM_AIF_IN("AIF1 Slot 0 Left", "Playback", 0,
+ SUN8I_AIF1_DACDAT_CTRL,
+ SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0L_ENA, 0),
+ SND_SOC_DAPM_AIF_IN("AIF1 Slot 0 Right", "Playback", 0,
+ SUN8I_AIF1_DACDAT_CTRL,
+ SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
/* DAC Mixers */
SOC_MIXER_ARRAY("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
@@ -329,14 +331,14 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
{ "DAC", NULL, "MODCLK DAC" },
/* DAC Routes */
- { "Digital Left DAC", NULL, "DAC" },
- { "Digital Right DAC", NULL, "DAC" },
+ { "AIF1 Slot 0 Right", NULL, "DAC" },
+ { "AIF1 Slot 0 Left", NULL, "DAC" },
/* DAC Mixer Routes */
{ "Left Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch",
- "Digital Left DAC"},
+ "AIF1 Slot 0 Left"},
{ "Right Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch ",
- "Digital Right DAC"},
+ "AIF1 Slot 0 Right"},
};
static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
--
2.11.0
^ permalink raw reply related [flat|nested] 20+ messages in thread* [PATCH 4/4] ASoC: sun8i-codec: Convert to use SND_SOC_DAPM_AIF_IN
2017-02-10 9:41 ` [PATCH 4/4] ASoC: sun8i-codec: Convert to use SND_SOC_DAPM_AIF_IN Mylène Josserand
@ 2017-03-06 9:56 ` Chen-Yu Tsai
2017-03-09 8:20 ` Mylene Josserand
0 siblings, 1 reply; 20+ messages in thread
From: Chen-Yu Tsai @ 2017-03-06 9:56 UTC (permalink / raw)
To: linux-arm-kernel
On Fri, Feb 10, 2017 at 5:41 PM, Myl?ne Josserand
<mylene.josserand@free-electrons.com> wrote:
> Update the driver to use SND_SOC_DAPM_AIF_IN instead of
> SND_SOC_DAPM_DAC.
>
> Set the route names so it must be updated on the device tree too.
>
> Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
> ---
> arch/arm/boot/dts/sun8i-a33.dtsi | 4 ++--
This patch looks OK, but having the DTS changes in the same patch
probably isn't a good idea. I would really like to see this series
merged for 4.11, so we can expose a good mixer interface to userspace
during the first kernel release supporting the A33 codec. That likely
means some breakage between when the asoc bits and the dts bits land
though.
Maxime, any ideas?
Regards
ChenYu
> sound/soc/sunxi/sun8i-codec.c | 20 +++++++++++---------
> 2 files changed, 13 insertions(+), 11 deletions(-)
>
> diff --git a/arch/arm/boot/dts/sun8i-a33.dtsi b/arch/arm/boot/dts/sun8i-a33.dtsi
> index 4e34ec6613a0..e9e2e7312460 100644
> --- a/arch/arm/boot/dts/sun8i-a33.dtsi
> +++ b/arch/arm/boot/dts/sun8i-a33.dtsi
> @@ -78,8 +78,8 @@
> simple-audio-card,mclk-fs = <512>;
> simple-audio-card,aux-devs = <&codec_analog>;
> simple-audio-card,routing =
> - "Left DAC", "Digital Left DAC",
> - "Right DAC", "Digital Right DAC";
> + "Left DAC", "AIF1 Slot 0 Left",
> + "Right DAC", "AIF1 Slot 0 Right";
> status = "disabled";
>
> simple-audio-card,cpu {
> diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
> index a75a983974d9..9b15a5ee235f 100644
> --- a/sound/soc/sunxi/sun8i-codec.c
> +++ b/sound/soc/sunxi/sun8i-codec.c
> @@ -281,11 +281,13 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
> SND_SOC_DAPM_SUPPLY("DAC", SUN8I_DAC_DIG_CTRL, SUN8I_DAC_DIG_CTRL_ENDA,
> 0, NULL, 0),
>
> - /* Analog DAC */
> - SND_SOC_DAPM_DAC("Digital Left DAC", "Playback", SUN8I_AIF1_DACDAT_CTRL,
> - SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0L_ENA, 0),
> - SND_SOC_DAPM_DAC("Digital Right DAC", "Playback", SUN8I_AIF1_DACDAT_CTRL,
> - SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
> + /* Analog DAC AIF */
> + SND_SOC_DAPM_AIF_IN("AIF1 Slot 0 Left", "Playback", 0,
> + SUN8I_AIF1_DACDAT_CTRL,
> + SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0L_ENA, 0),
> + SND_SOC_DAPM_AIF_IN("AIF1 Slot 0 Right", "Playback", 0,
> + SUN8I_AIF1_DACDAT_CTRL,
> + SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
>
> /* DAC Mixers */
> SOC_MIXER_ARRAY("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
> @@ -329,14 +331,14 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
> { "DAC", NULL, "MODCLK DAC" },
>
> /* DAC Routes */
> - { "Digital Left DAC", NULL, "DAC" },
> - { "Digital Right DAC", NULL, "DAC" },
> + { "AIF1 Slot 0 Right", NULL, "DAC" },
> + { "AIF1 Slot 0 Left", NULL, "DAC" },
>
> /* DAC Mixer Routes */
> { "Left Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch",
> - "Digital Left DAC"},
> + "AIF1 Slot 0 Left"},
> { "Right Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch ",
> - "Digital Right DAC"},
> + "AIF1 Slot 0 Right"},
> };
>
> static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
> --
> 2.11.0
>
^ permalink raw reply [flat|nested] 20+ messages in thread* [PATCH 4/4] ASoC: sun8i-codec: Convert to use SND_SOC_DAPM_AIF_IN
2017-03-06 9:56 ` Chen-Yu Tsai
@ 2017-03-09 8:20 ` Mylene Josserand
0 siblings, 0 replies; 20+ messages in thread
From: Mylene Josserand @ 2017-03-09 8:20 UTC (permalink / raw)
To: linux-arm-kernel
Hi Chen-Yu,
Thank you for the review.
On 06/03/2017 10:56, Chen-Yu Tsai wrote:
> On Fri, Feb 10, 2017 at 5:41 PM, Myl?ne Josserand
> <mylene.josserand@free-electrons.com> wrote:
>> Update the driver to use SND_SOC_DAPM_AIF_IN instead of
>> SND_SOC_DAPM_DAC.
>>
>> Set the route names so it must be updated on the device tree too.
>>
>> Signed-off-by: Myl?ne Josserand <mylene.josserand@free-electrons.com>
>> ---
>> arch/arm/boot/dts/sun8i-a33.dtsi | 4 ++--
>
> This patch looks OK, but having the DTS changes in the same patch
> probably isn't a good idea. I would really like to see this series
> merged for 4.11, so we can expose a good mixer interface to userspace
> during the first kernel release supporting the A33 codec. That likely
> means some breakage between when the asoc bits and the dts bits land
> though.
Yes, as it means some breakage, I did not know if 2 patches will be fine
or not.
>
> Maxime, any ideas?
>
I asked him directly and he agrees.
It is fine for me so I will send a v2 with this patch split.
Best regards,
--
Myl?ne Josserand, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
>
> Regards
> ChenYu
>
>> sound/soc/sunxi/sun8i-codec.c | 20 +++++++++++---------
>> 2 files changed, 13 insertions(+), 11 deletions(-)
>>
>> diff --git a/arch/arm/boot/dts/sun8i-a33.dtsi b/arch/arm/boot/dts/sun8i-a33.dtsi
>> index 4e34ec6613a0..e9e2e7312460 100644
>> --- a/arch/arm/boot/dts/sun8i-a33.dtsi
>> +++ b/arch/arm/boot/dts/sun8i-a33.dtsi
>> @@ -78,8 +78,8 @@
>> simple-audio-card,mclk-fs = <512>;
>> simple-audio-card,aux-devs = <&codec_analog>;
>> simple-audio-card,routing =
>> - "Left DAC", "Digital Left DAC",
>> - "Right DAC", "Digital Right DAC";
>> + "Left DAC", "AIF1 Slot 0 Left",
>> + "Right DAC", "AIF1 Slot 0 Right";
>> status = "disabled";
>>
>> simple-audio-card,cpu {
>> diff --git a/sound/soc/sunxi/sun8i-codec.c b/sound/soc/sunxi/sun8i-codec.c
>> index a75a983974d9..9b15a5ee235f 100644
>> --- a/sound/soc/sunxi/sun8i-codec.c
>> +++ b/sound/soc/sunxi/sun8i-codec.c
>> @@ -281,11 +281,13 @@ static const struct snd_soc_dapm_widget sun8i_codec_dapm_widgets[] = {
>> SND_SOC_DAPM_SUPPLY("DAC", SUN8I_DAC_DIG_CTRL, SUN8I_DAC_DIG_CTRL_ENDA,
>> 0, NULL, 0),
>>
>> - /* Analog DAC */
>> - SND_SOC_DAPM_DAC("Digital Left DAC", "Playback", SUN8I_AIF1_DACDAT_CTRL,
>> - SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0L_ENA, 0),
>> - SND_SOC_DAPM_DAC("Digital Right DAC", "Playback", SUN8I_AIF1_DACDAT_CTRL,
>> - SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
>> + /* Analog DAC AIF */
>> + SND_SOC_DAPM_AIF_IN("AIF1 Slot 0 Left", "Playback", 0,
>> + SUN8I_AIF1_DACDAT_CTRL,
>> + SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0L_ENA, 0),
>> + SND_SOC_DAPM_AIF_IN("AIF1 Slot 0 Right", "Playback", 0,
>> + SUN8I_AIF1_DACDAT_CTRL,
>> + SUN8I_AIF1_DACDAT_CTRL_AIF1_DA0R_ENA, 0),
>>
>> /* DAC Mixers */
>> SOC_MIXER_ARRAY("Left Digital DAC Mixer", SND_SOC_NOPM, 0, 0,
>> @@ -329,14 +331,14 @@ static const struct snd_soc_dapm_route sun8i_codec_dapm_routes[] = {
>> { "DAC", NULL, "MODCLK DAC" },
>>
>> /* DAC Routes */
>> - { "Digital Left DAC", NULL, "DAC" },
>> - { "Digital Right DAC", NULL, "DAC" },
>> + { "AIF1 Slot 0 Right", NULL, "DAC" },
>> + { "AIF1 Slot 0 Left", NULL, "DAC" },
>>
>> /* DAC Mixer Routes */
>> { "Left Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch",
>> - "Digital Left DAC"},
>> + "AIF1 Slot 0 Left"},
>> { "Right Digital DAC Mixer", "AIF1 Slot 0 Digital DAC Playback Switch ",
>> - "Digital Right DAC"},
>> + "AIF1 Slot 0 Right"},
>> };
>>
>> static struct snd_soc_dai_ops sun8i_codec_dai_ops = {
>> --
>> 2.11.0
>>
^ permalink raw reply [flat|nested] 20+ messages in thread