Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-17 Thread Mylene Josserand

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


Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-17 Thread Mylene Josserand

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


Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-16 Thread Mark Brown
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.


signature.asc
Description: PGP signature


Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-16 Thread Mark Brown
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.


signature.asc
Description: PGP signature


Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-15 Thread Chen-Yu Tsai
On Wed, Mar 15, 2017 at 9:43 PM, Mark Brown  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  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


Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-15 Thread Chen-Yu Tsai
On Wed, Mar 15, 2017 at 9:43 PM, Mark Brown  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  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


Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-15 Thread Mark Brown
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  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.


signature.asc
Description: PGP signature


Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-15 Thread Mark Brown
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  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.


signature.asc
Description: PGP signature


Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-13 Thread Chen-Yu Tsai
Hi Mark,

On Wed, Mar 8, 2017 at 9:22 PM, Mark Brown  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?=
>  
> 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 
> Acked-by: Chen-Yu Tsai 
> Signed-off-by: Mark Brown 
> ---
>  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,
> +  

Re: Applied "ASoC: sun8i-codec: Update mixer to use SOC_DAPM_DOUBLE" to the asoc tree

2017-03-13 Thread Chen-Yu Tsai
Hi Mark,

On Wed, Mar 8, 2017 at 9:22 PM, Mark Brown  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?=
>  
> 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 
> Acked-by: Chen-Yu Tsai 
> Signed-off-by: Mark Brown 
> ---
>  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,
> +