ASoC: meson: add sm1 support
Subsystems (5)
Jerome Brunet
maintainercover ASoC: meson: add sm1 support
This patchset prepare then add the audio support on the amlogic sm1 SoC family in ASoC.
This has been tested on sei610 platform. Since this platform does not have spdif, this patchset does not include the change necessary to support spdif input or output on the sm1.
Jerome Brunet (8):
ASoC: meson: add sm1 compatibles
ASoC: meson: add reset binding
ASoC: meson: axg-frddr: expose all 8 outputs
ASoC: meson: axg-toddr: expose all 8 inputs
ASoC: meson: tdmin: expose all 16 inputs
ASoC: meson: axg-frddr: add sm1 support
ASoC: meson: axg-toddr: add sm1 support
ASoC: meson: tdmout: add sm1 support
.../bindings/sound/amlogic,axg-fifo.txt | 9 +- .../bindings/sound/amlogic,axg-pdm.txt | 6 +- .../bindings/sound/amlogic,axg-spdifin.txt | 6 +- .../bindings/sound/amlogic,axg-spdifout.txt | 6 +- .../sound/amlogic,axg-tdm-formatters.txt | 4 +- .../bindings/sound/amlogic,g12a-tohdmitx.txt | 5 +- sound/soc/meson/axg-fifo.c | 2 +- sound/soc/meson/axg-fifo.h | 1 + sound/soc/meson/axg-frddr.c | 105 ++++++++++++++++-- sound/soc/meson/axg-tdmin.c | 47 +++++--- sound/soc/meson/axg-tdmout.c | 103 +++++++++++++---- sound/soc/meson/axg-toddr.c | 83 ++++++++++++-- 12 files changed, 321 insertions(+), 56 deletions(-)
Signature · 1 line
2.21.0
Jerome Brunet
maintainerPATCH 1/8 ASoC: meson: add sm1 compatibles
Document the compatible strings of the audio devices of the sm1 SoC family
--- Documentation/devicetree/bindings/sound/amlogic,axg-fifo.txt | 4 +++- Documentation/devicetree/bindings/sound/amlogic,axg-pdm.txt | 3 ++- .../devicetree/bindings/sound/amlogic,axg-spdifin.txt | 3 ++- .../devicetree/bindings/sound/amlogic,axg-spdifout.txt | 3 ++- .../devicetree/bindings/sound/amlogic,axg-tdm-formatters.txt | 4 +++- .../devicetree/bindings/sound/amlogic,g12a-tohdmitx.txt | 3 ++- 6 files changed, 14 insertions(+), 6 deletions(-)
Documentation/devicetree/bindings/sound/amlogic,axg-fifo.txt +3 -1
@@ -4,7 +4,9 @@ Required properties: - compatible: 'amlogic,axg-toddr' or 'amlogic,axg-toddr' or 'amlogic,g12a-frddr' or - 'amlogic,g12a-toddr' + 'amlogic,g12a-toddr' or + 'amlogic,sm1-frddr' or + 'amlogic,sm1-toddr' - reg: physical base address of the controller and length of memory mapped region. - interrupts: interrupt specifier for the fifo.
Documentation/devicetree/bindings/sound/amlogic,axg-pdm.txt +2 -1
@@ -2,7 +2,8 @@ Required properties: - compatible: 'amlogic,axg-pdm' or - 'amlogic,g12a-pdm' + 'amlogic,g12a-pdm' or + 'amlogic,sm1-pdm' - reg: physical base address of the controller and length of memory mapped region. - clocks: list of clock phandle, one for each entry clock-names.
Documentation/devicetree/bindings/sound/amlogic,axg-spdifin.txt +2 -1
@@ -2,7 +2,8 @@ Required properties: - compatible: 'amlogic,axg-spdifin' or - 'amlogic,g12a-spdifin' + 'amlogic,g12a-spdifin' or + 'amlogic,sm1-spdifin' - interrupts: interrupt specifier for the spdif input. - clocks: list of clock phandle, one for each entry clock-names. - clock-names: should contain the following:
Documentation/devicetree/bindings/sound/amlogic,axg-spdifout.txt +2 -1
@@ -2,7 +2,8 @@ Required properties: - compatible: 'amlogic,axg-spdifout' or - 'amlogic,g12a-spdifout' + 'amlogic,g12a-spdifout' or + 'amlogic,sm1-spdifout' - clocks: list of clock phandle, one for each entry clock-names. - clock-names: should contain the following: * "pclk" : peripheral clock.
Documentation/devicetree/bindings/sound/amlogic,axg-tdm-formatters.txt +3 -1
@@ -4,7 +4,9 @@ Required properties: - compatible: 'amlogic,axg-tdmin' or 'amlogic,axg-tdmout' or 'amlogic,g12a-tdmin' or - 'amlogic,g12a-tdmout' + 'amlogic,g12a-tdmout' or + 'amlogic,sm1-tdmin' or + 'amlogic,sm1-tdmout - reg: physical base address of the controller and length of memory mapped region. - clocks: list of clock phandle, one for each entry clock-names.
Documentation/devicetree/bindings/sound/amlogic,g12a-tohdmitx.txt +2 -1
@@ -1,7 +1,8 @@ * Amlogic HDMI Tx control glue Required properties: -- compatible: "amlogic,g12a-tohdmitx" +- compatible: "amlogic,g12a-tohdmitx" or + "amlogic,sm1-tohdmitx" - reg: physical base address of the controller and length of memory mapped region. - #sound-dai-cells: should be 1.
Signature · 1 line
2.21.0
Mark Brown
maintainerApplied "ASoC: meson: add sm1 compatibles" to the asoc tree
The patch
ASoC: meson: add sm1 compatibles
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4
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
Quoted 1 line
From
f466309534b6f21304e1ee0573a60df9c4590272Mon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 5 Sep 2019 14:01:13 +0200
Subject: [PATCH] ASoC: meson: add sm1 compatibles
Document the compatible strings of the audio devices of the sm1 SoC family
--- Documentation/devicetree/bindings/sound/amlogic,axg-fifo.txt | 4 +++- Documentation/devicetree/bindings/sound/amlogic,axg-pdm.txt | 3 ++- .../devicetree/bindings/sound/amlogic,axg-spdifin.txt | 3 ++- .../devicetree/bindings/sound/amlogic,axg-spdifout.txt | 3 ++- .../devicetree/bindings/sound/amlogic,axg-tdm-formatters.txt | 4 +++- .../devicetree/bindings/sound/amlogic,g12a-tohdmitx.txt | 3 ++- 6 files changed, 14 insertions(+), 6 deletions(-)
Documentation/devicetree/bindings/sound/amlogic,axg-fifo.txt +3 -1
@@ -4,7 +4,9 @@ Required properties: - compatible: 'amlogic,axg-toddr' or 'amlogic,axg-toddr' or 'amlogic,g12a-frddr' or - 'amlogic,g12a-toddr' + 'amlogic,g12a-toddr' or + 'amlogic,sm1-frddr' or + 'amlogic,sm1-toddr' - reg: physical base address of the controller and length of memory mapped region. - interrupts: interrupt specifier for the fifo.
Documentation/devicetree/bindings/sound/amlogic,axg-pdm.txt +2 -1
@@ -2,7 +2,8 @@ Required properties: - compatible: 'amlogic,axg-pdm' or - 'amlogic,g12a-pdm' + 'amlogic,g12a-pdm' or + 'amlogic,sm1-pdm' - reg: physical base address of the controller and length of memory mapped region. - clocks: list of clock phandle, one for each entry clock-names.
Documentation/devicetree/bindings/sound/amlogic,axg-spdifin.txt +2 -1
@@ -2,7 +2,8 @@ Required properties: - compatible: 'amlogic,axg-spdifin' or - 'amlogic,g12a-spdifin' + 'amlogic,g12a-spdifin' or + 'amlogic,sm1-spdifin' - interrupts: interrupt specifier for the spdif input. - clocks: list of clock phandle, one for each entry clock-names. - clock-names: should contain the following:
Documentation/devicetree/bindings/sound/amlogic,axg-spdifout.txt +2 -1
@@ -2,7 +2,8 @@ Required properties: - compatible: 'amlogic,axg-spdifout' or - 'amlogic,g12a-spdifout' + 'amlogic,g12a-spdifout' or + 'amlogic,sm1-spdifout' - clocks: list of clock phandle, one for each entry clock-names. - clock-names: should contain the following: * "pclk" : peripheral clock.
Documentation/devicetree/bindings/sound/amlogic,axg-tdm-formatters.txt +3 -1
@@ -4,7 +4,9 @@ Required properties: - compatible: 'amlogic,axg-tdmin' or 'amlogic,axg-tdmout' or 'amlogic,g12a-tdmin' or - 'amlogic,g12a-tdmout' + 'amlogic,g12a-tdmout' or + 'amlogic,sm1-tdmin' or + 'amlogic,sm1-tdmout - reg: physical base address of the controller and length of memory mapped region. - clocks: list of clock phandle, one for each entry clock-names.
Documentation/devicetree/bindings/sound/amlogic,g12a-tohdmitx.txt +2 -1
@@ -1,7 +1,8 @@ * Amlogic HDMI Tx control glue Required properties: -- compatible: "amlogic,g12a-tohdmitx" +- compatible: "amlogic,g12a-tohdmitx" or + "amlogic,sm1-tohdmitx" - reg: physical base address of the controller and length of memory mapped region. - #sound-dai-cells: should be 1.
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 2/8 ASoC: meson: add reset binding
In reply to Jerome BrunetThe g12a audio subsystem, which is a derivative of the axg subsystem, provides a dedicated reset line for each of the audio components.
The axg did not provide that and it is unclear if/when these reset are required. The reset already helped solve a channel mapping issue on the tdm formatter devices. Let's add the reset binding for the other components, so we can describe this in DT. We'll use it later on in the driver when/if needed.
--- Documentation/devicetree/bindings/sound/amlogic,axg-fifo.txt | 5 ++++- Documentation/devicetree/bindings/sound/amlogic,axg-pdm.txt | 3 +++ .../devicetree/bindings/sound/amlogic,axg-spdifin.txt | 3 +++ .../devicetree/bindings/sound/amlogic,axg-spdifout.txt | 3 +++ .../devicetree/bindings/sound/amlogic,g12a-tohdmitx.txt | 2 ++ 5 files changed, 15 insertions(+), 1 deletion(-)
Documentation/devicetree/bindings/sound/amlogic,axg-fifo.txt +4 -1
@@ -12,7 +12,10 @@ Required properties: - interrupts: interrupt specifier for the fifo. - clocks: phandle to the fifo peripheral clock provided by the audio clock controller. -- resets: phandle to memory ARB line provided by the arb reset controller. +- resets: list of reset phandle, one for each entry reset-names. +- reset-names: should contain the following: + * "arb" : memory ARB line (required) + * "rst" : dedicated device reset line (optional) - #sound-dai-cells: must be 0. Example of FRDDR A on the A113 SoC:
Documentation/devicetree/bindings/sound/amlogic,axg-pdm.txt +3 -0
@@ -13,6 +13,9 @@ Required properties: * "sysclk" : dsp system clock - #sound-dai-cells: must be 0. +Optional property: +- resets: phandle to the dedicated reset line of the pdm input. + Example of PDM on the A113 SoC: pdm: audio-controller@ff632000 {
Documentation/devicetree/bindings/sound/amlogic,axg-spdifin.txt +3 -0
@@ -11,6 +11,9 @@ Required properties: * "refclk" : spdif input reference clock - #sound-dai-cells: must be 0. +Optional property: +- resets: phandle to the dedicated reset line of the spdif input. + Example on the A113 SoC: spdifin: audio-controller@400 {
Documentation/devicetree/bindings/sound/amlogic,axg-spdifout.txt +3 -0
@@ -10,6 +10,9 @@ Required properties: * "mclk" : master clock - #sound-dai-cells: must be 0. +Optional property: +- resets: phandle to the dedicated reset line of the spdif output. + Example on the A113 SoC: spdifout: audio-controller@480 {
Documentation/devicetree/bindings/sound/amlogic,g12a-tohdmitx.txt +2 -0
@@ -6,6 +6,7 @@ Required properties: - reg: physical base address of the controller and length of memory mapped region. - #sound-dai-cells: should be 1. +- resets: phandle to the dedicated reset line of the hdmitx glue. Example on the S905X2 SoC:
@@ -13,6 +14,7 @@ tohdmitx: audio-controller@744 { compatible = "amlogic,g12a-tohdmitx"; reg = <0x0 0x744 0x0 0x4>; #sound-dai-cells = <1>; + resets = <&clkc_audio AUD_RESET_TOHDMITX>; }; Example of an 'amlogic,axg-sound-card':
Signature · 1 line
2.21.0
Mark Brown
maintainerApplied "ASoC: meson: add reset binding" to the asoc tree
The patch
ASoC: meson: add reset binding
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4
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
Quoted 1 line
From
6b59b8f8222146fc1912e0b783c81e4122e240acMon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 5 Sep 2019 14:01:14 +0200
Subject: [PATCH] ASoC: meson: add reset binding
The g12a audio subsystem, which is a derivative of the axg subsystem, provides a dedicated reset line for each of the audio components.
The axg did not provide that and it is unclear if/when these reset are required. The reset already helped solve a channel mapping issue on the tdm formatter devices. Let's add the reset binding for the other components, so we can describe this in DT. We'll use it later on in the driver when/if needed.
--- Documentation/devicetree/bindings/sound/amlogic,axg-fifo.txt | 5 ++++- Documentation/devicetree/bindings/sound/amlogic,axg-pdm.txt | 3 +++ .../devicetree/bindings/sound/amlogic,axg-spdifin.txt | 3 +++ .../devicetree/bindings/sound/amlogic,axg-spdifout.txt | 3 +++ .../devicetree/bindings/sound/amlogic,g12a-tohdmitx.txt | 2 ++ 5 files changed, 15 insertions(+), 1 deletion(-)
Documentation/devicetree/bindings/sound/amlogic,axg-fifo.txt +4 -1
@@ -12,7 +12,10 @@ Required properties: - interrupts: interrupt specifier for the fifo. - clocks: phandle to the fifo peripheral clock provided by the audio clock controller. -- resets: phandle to memory ARB line provided by the arb reset controller. +- resets: list of reset phandle, one for each entry reset-names. +- reset-names: should contain the following: + * "arb" : memory ARB line (required) + * "rst" : dedicated device reset line (optional) - #sound-dai-cells: must be 0. Example of FRDDR A on the A113 SoC:
Documentation/devicetree/bindings/sound/amlogic,axg-pdm.txt +3 -0
@@ -13,6 +13,9 @@ Required properties: * "sysclk" : dsp system clock - #sound-dai-cells: must be 0. +Optional property: +- resets: phandle to the dedicated reset line of the pdm input. + Example of PDM on the A113 SoC: pdm: audio-controller@ff632000 {
Documentation/devicetree/bindings/sound/amlogic,axg-spdifin.txt +3 -0
@@ -11,6 +11,9 @@ Required properties: * "refclk" : spdif input reference clock - #sound-dai-cells: must be 0. +Optional property: +- resets: phandle to the dedicated reset line of the spdif input. + Example on the A113 SoC: spdifin: audio-controller@400 {
Documentation/devicetree/bindings/sound/amlogic,axg-spdifout.txt +3 -0
@@ -10,6 +10,9 @@ Required properties: * "mclk" : master clock - #sound-dai-cells: must be 0. +Optional property: +- resets: phandle to the dedicated reset line of the spdif output. + Example on the A113 SoC: spdifout: audio-controller@480 {
Documentation/devicetree/bindings/sound/amlogic,g12a-tohdmitx.txt +2 -0
@@ -6,6 +6,7 @@ Required properties: - reg: physical base address of the controller and length of memory mapped region. - #sound-dai-cells: should be 1. +- resets: phandle to the dedicated reset line of the hdmitx glue. Example on the S905X2 SoC:
@@ -13,6 +14,7 @@ tohdmitx: audio-controller@744 { compatible = "amlogic,g12a-tohdmitx"; reg = <0x0 0x744 0x0 0x4>; #sound-dai-cells = <1>; + resets = <&clkc_audio AUD_RESET_TOHDMITX>; }; Example of an 'amlogic,axg-sound-card':
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 3/8 ASoC: meson: axg-frddr: expose all 8 outputs
In reply to Jerome BrunetThe FRDDR component, as it, has a maximum of 8 outputs. Depending on the SoC, these may not all be connected.
Instead of decribing only the connected outputs of each SoC, describe them all and let ASoC routing do the rest.
--- sound/soc/meson/axg-frddr.c | 32 ++++++++++++++++++++++++-------- 1 file changed, 24 insertions(+), 8 deletions(-)
sound/soc/meson/axg-frddr.c +24 -8
@@ -104,7 +104,7 @@ static struct snd_soc_dai_driver axg_frddr_dai_drv = { };static const char *const axg_frddr_sel_texts[] = { -"OUT 0" ,"OUT 1" ,"OUT 2" ,"OUT 3" +"OUT 0" ,"OUT 1" ,"OUT 2" ,"OUT 3" ,"OUT 4" ,"OUT 5" ,"OUT 6" ,"OUT 7" , }; static SOC_ENUM_SINGLE_DECL(axg_frddr_sel_enum, FIFO_CTRL0, CTRL0_SEL_SHIFT,
@@ -120,6 +120,10 @@ static const struct snd_soc_dapm_widget axg_frddr_dapm_widgets[] = {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 ), +SND_SOC_DAPM_AIF_OUT ("OUT 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_OUT ("OUT 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_OUT ("OUT 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), + SND_SOC_DAPM_AIF_OUT("OUT 7", NULL, 0, SND_SOC_NOPM, 0, 0), }; static const struct snd_soc_dapm_route axg_frddr_dapm_routes[] = {
@@ -128,6 +132,10 @@ static const struct snd_soc_dapm_route axg_frddr_dapm_routes[] = { { "OUT 1", "OUT 1", "SINK SEL" }, { "OUT 2", "OUT 2", "SINK SEL" }, { "OUT 3", "OUT 3", "SINK SEL" }, + { "OUT 4", "OUT 4", "SINK SEL" }, + { "OUT 5", "OUT 5", "SINK SEL" }, + { "OUT 6", "OUT 6", "SINK SEL" }, + { "OUT 7", "OUT 7", "SINK SEL" }, }; static const struct snd_soc_component_driver axg_frddr_component_drv = {
@@ -162,16 +170,12 @@ static struct snd_soc_dai_driver g12a_frddr_dai_drv = { .pcm_new = axg_frddr_pcm_new, }; -static const char *const g12a_frddr_sel_texts[] = { -"OUT 0" ,"OUT 1" ,"OUT 2" ,"OUT 3" ,"OUT 4" , -}; - static SOC_ENUM_SINGLE_DECL(g12a_frddr_sel1_enum, FIFO_CTRL0, CTRL0_SEL_SHIFT, - g12a_frddr_sel_texts); + axg_frddr_sel_texts); static SOC_ENUM_SINGLE_DECL(g12a_frddr_sel2_enum, FIFO_CTRL0, CTRL0_SEL2_SHIFT, - g12a_frddr_sel_texts); + axg_frddr_sel_texts); static SOC_ENUM_SINGLE_DECL(g12a_frddr_sel3_enum, FIFO_CTRL0, CTRL0_SEL3_SHIFT, - g12a_frddr_sel_texts); + axg_frddr_sel_texts);static const struct snd_kcontrol_new g12a_frddr_out1_demux =SOC_DAPM_ENUM ("Output Src 1" , g12a_frddr_sel1_enum);
@@ -211,6 +215,9 @@ static const struct snd_soc_dapm_widget g12a_frddr_dapm_widgets[] = {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 ),SND_SOC_DAPM_AIF_OUT ("OUT 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_OUT ("OUT 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_OUT ("OUT 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), + SND_SOC_DAPM_AIF_OUT("OUT 7", NULL, 0, SND_SOC_NOPM, 0, 0), }; static const struct snd_soc_dapm_route g12a_frddr_dapm_routes[] = {
@@ -228,16 +235,25 @@ static const struct snd_soc_dapm_route g12a_frddr_dapm_routes[] = { { "OUT 2", "OUT 2", "SINK 1 SEL" }, { "OUT 3", "OUT 3", "SINK 1 SEL" }, { "OUT 4", "OUT 4", "SINK 1 SEL" }, + { "OUT 5", "OUT 5", "SINK 1 SEL" }, + { "OUT 6", "OUT 6", "SINK 1 SEL" }, + { "OUT 7", "OUT 7", "SINK 1 SEL" }, { "OUT 0", "OUT 0", "SINK 2 SEL" }, { "OUT 1", "OUT 1", "SINK 2 SEL" }, { "OUT 2", "OUT 2", "SINK 2 SEL" }, { "OUT 3", "OUT 3", "SINK 2 SEL" }, { "OUT 4", "OUT 4", "SINK 2 SEL" }, + { "OUT 5", "OUT 5", "SINK 2 SEL" }, + { "OUT 6", "OUT 6", "SINK 2 SEL" }, + { "OUT 7", "OUT 7", "SINK 2 SEL" }, { "OUT 0", "OUT 0", "SINK 3 SEL" }, { "OUT 1", "OUT 1", "SINK 3 SEL" }, { "OUT 2", "OUT 2", "SINK 3 SEL" }, { "OUT 3", "OUT 3", "SINK 3 SEL" }, { "OUT 4", "OUT 4", "SINK 3 SEL" }, + { "OUT 5", "OUT 5", "SINK 3 SEL" }, + { "OUT 6", "OUT 6", "SINK 3 SEL" }, + { "OUT 7", "OUT 7", "SINK 3 SEL" }, }; static const struct snd_soc_component_driver g12a_frddr_component_drv = {
Signature · 1 line
2.21.0
Mark Brown
maintainerApplied "ASoC: meson: axg-frddr: expose all 8 outputs" to the asoc tree
The patch
ASoC: meson: axg-frddr: expose all 8 outputs
has been applied to the asoc tree at
https://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
Quoted 1 line
From
8fcd2d914e786033e589b4eb8cb62d37d0fa9701Mon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 5 Sep 2019 14:01:15 +0200
Subject: [PATCH] ASoC: meson: axg-frddr: expose all 8 outputs
The FRDDR component, as it, has a maximum of 8 outputs. Depending on the SoC, these may not all be connected.
Instead of decribing only the connected outputs of each SoC, describe them all and let ASoC routing do the rest.
--- sound/soc/meson/axg-frddr.c | 32 ++++++++++++++++++++++++-------- 1 file changed, 24 insertions(+), 8 deletions(-)
sound/soc/meson/axg-frddr.c +24 -8
@@ -104,7 +104,7 @@ static struct snd_soc_dai_driver axg_frddr_dai_drv = { };static const char *const axg_frddr_sel_texts[] = { -"OUT 0" ,"OUT 1" ,"OUT 2" ,"OUT 3" +"OUT 0" ,"OUT 1" ,"OUT 2" ,"OUT 3" ,"OUT 4" ,"OUT 5" ,"OUT 6" ,"OUT 7" , }; static SOC_ENUM_SINGLE_DECL(axg_frddr_sel_enum, FIFO_CTRL0, CTRL0_SEL_SHIFT,
@@ -120,6 +120,10 @@ static const struct snd_soc_dapm_widget axg_frddr_dapm_widgets[] = {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 ), +SND_SOC_DAPM_AIF_OUT ("OUT 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_OUT ("OUT 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_OUT ("OUT 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), + SND_SOC_DAPM_AIF_OUT("OUT 7", NULL, 0, SND_SOC_NOPM, 0, 0), }; static const struct snd_soc_dapm_route axg_frddr_dapm_routes[] = {
@@ -128,6 +132,10 @@ static const struct snd_soc_dapm_route axg_frddr_dapm_routes[] = { { "OUT 1", "OUT 1", "SINK SEL" }, { "OUT 2", "OUT 2", "SINK SEL" }, { "OUT 3", "OUT 3", "SINK SEL" }, + { "OUT 4", "OUT 4", "SINK SEL" }, + { "OUT 5", "OUT 5", "SINK SEL" }, + { "OUT 6", "OUT 6", "SINK SEL" }, + { "OUT 7", "OUT 7", "SINK SEL" }, }; static const struct snd_soc_component_driver axg_frddr_component_drv = {
@@ -162,16 +170,12 @@ static struct snd_soc_dai_driver g12a_frddr_dai_drv = { .pcm_new = axg_frddr_pcm_new, }; -static const char *const g12a_frddr_sel_texts[] = { -"OUT 0" ,"OUT 1" ,"OUT 2" ,"OUT 3" ,"OUT 4" , -}; - static SOC_ENUM_SINGLE_DECL(g12a_frddr_sel1_enum, FIFO_CTRL0, CTRL0_SEL_SHIFT, - g12a_frddr_sel_texts); + axg_frddr_sel_texts); static SOC_ENUM_SINGLE_DECL(g12a_frddr_sel2_enum, FIFO_CTRL0, CTRL0_SEL2_SHIFT, - g12a_frddr_sel_texts); + axg_frddr_sel_texts); static SOC_ENUM_SINGLE_DECL(g12a_frddr_sel3_enum, FIFO_CTRL0, CTRL0_SEL3_SHIFT, - g12a_frddr_sel_texts); + axg_frddr_sel_texts);static const struct snd_kcontrol_new g12a_frddr_out1_demux =SOC_DAPM_ENUM ("Output Src 1" , g12a_frddr_sel1_enum);
@@ -211,6 +215,9 @@ static const struct snd_soc_dapm_widget g12a_frddr_dapm_widgets[] = {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 ),SND_SOC_DAPM_AIF_OUT ("OUT 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_OUT ("OUT 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_OUT ("OUT 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), + SND_SOC_DAPM_AIF_OUT("OUT 7", NULL, 0, SND_SOC_NOPM, 0, 0), }; static const struct snd_soc_dapm_route g12a_frddr_dapm_routes[] = {
@@ -228,16 +235,25 @@ static const struct snd_soc_dapm_route g12a_frddr_dapm_routes[] = { { "OUT 2", "OUT 2", "SINK 1 SEL" }, { "OUT 3", "OUT 3", "SINK 1 SEL" }, { "OUT 4", "OUT 4", "SINK 1 SEL" }, + { "OUT 5", "OUT 5", "SINK 1 SEL" }, + { "OUT 6", "OUT 6", "SINK 1 SEL" }, + { "OUT 7", "OUT 7", "SINK 1 SEL" }, { "OUT 0", "OUT 0", "SINK 2 SEL" }, { "OUT 1", "OUT 1", "SINK 2 SEL" }, { "OUT 2", "OUT 2", "SINK 2 SEL" }, { "OUT 3", "OUT 3", "SINK 2 SEL" }, { "OUT 4", "OUT 4", "SINK 2 SEL" }, + { "OUT 5", "OUT 5", "SINK 2 SEL" }, + { "OUT 6", "OUT 6", "SINK 2 SEL" }, + { "OUT 7", "OUT 7", "SINK 2 SEL" }, { "OUT 0", "OUT 0", "SINK 3 SEL" }, { "OUT 1", "OUT 1", "SINK 3 SEL" }, { "OUT 2", "OUT 2", "SINK 3 SEL" }, { "OUT 3", "OUT 3", "SINK 3 SEL" }, { "OUT 4", "OUT 4", "SINK 3 SEL" }, + { "OUT 5", "OUT 5", "SINK 3 SEL" }, + { "OUT 6", "OUT 6", "SINK 3 SEL" }, + { "OUT 7", "OUT 7", "SINK 3 SEL" }, }; static const struct snd_soc_component_driver g12a_frddr_component_drv = {
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 4/8 ASoC: meson: axg-toddr: expose all 8 inputs
In reply to Jerome BrunetThe TODDR component, as it, has a maximum of 8 input. Depending on the SoC, these may not all be connected or some input components may not be supported
Instead of decribing only the connected inputs, describe them all and let ASoC routing do the rest.
--- sound/soc/meson/axg-toddr.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-)
sound/soc/meson/axg-toddr.c +7 -8
@@ -142,16 +142,11 @@ static struct snd_soc_dai_driver axg_toddr_dai_drv = { };static const char *const axg_toddr_sel_texts[] = { -"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 6" +"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 5" ,"IN 6" ,"IN 7" }; -static const unsigned int axg_toddr_sel_values[] = { -0 ,1 ,2 ,3 ,4 ,6 -}; - -static SOC_VALUE_ENUM_SINGLE_DECL(axg_toddr_sel_enum, FIFO_CTRL0, - CTRL0_SEL_SHIFT, CTRL0_SEL_MASK, - axg_toddr_sel_texts, axg_toddr_sel_values); +static SOC_ENUM_SINGLE_DECL(axg_toddr_sel_enum, FIFO_CTRL0, CTRL0_SEL_SHIFT, + axg_toddr_sel_texts);static const struct snd_kcontrol_new axg_toddr_in_mux =SOC_DAPM_ENUM ("Input Source" , axg_toddr_sel_enum);
@@ -163,7 +158,9 @@ static const struct snd_soc_dapm_widget axg_toddr_dapm_widgets[] = {SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_AIF_IN ("IN 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), + SND_SOC_DAPM_AIF_IN("IN 7", NULL, 0, SND_SOC_NOPM, 0, 0), }; static const struct snd_soc_dapm_route axg_toddr_dapm_routes[] = {
@@ -173,7 +170,9 @@ static const struct snd_soc_dapm_route axg_toddr_dapm_routes[] = { { "SRC SEL", "IN 2", "IN 2" }, { "SRC SEL", "IN 3", "IN 3" }, { "SRC SEL", "IN 4", "IN 4" }, + { "SRC SEL", "IN 5", "IN 5" }, { "SRC SEL", "IN 6", "IN 6" }, + { "SRC SEL", "IN 7", "IN 7" }, }; static const struct snd_soc_component_driver axg_toddr_component_drv = {
Signature · 1 line
2.21.0
Mark Brown
maintainerApplied "ASoC: meson: axg-toddr: expose all 8 inputs" to the asoc tree
The patch
ASoC: meson: axg-toddr: expose all 8 inputs
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4
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
Quoted 1 line
From
6beced211c22dd8c3e546c956512fddd8e09884fMon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 5 Sep 2019 14:01:16 +0200
Subject: [PATCH] ASoC: meson: axg-toddr: expose all 8 inputs
The TODDR component, as it, has a maximum of 8 input. Depending on the SoC, these may not all be connected or some input components may not be supported
Instead of decribing only the connected inputs, describe them all and let ASoC routing do the rest.
--- sound/soc/meson/axg-toddr.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-)
sound/soc/meson/axg-toddr.c +7 -8
@@ -142,16 +142,11 @@ static struct snd_soc_dai_driver axg_toddr_dai_drv = { };static const char *const axg_toddr_sel_texts[] = { -"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 6" +"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 5" ,"IN 6" ,"IN 7" }; -static const unsigned int axg_toddr_sel_values[] = { -0 ,1 ,2 ,3 ,4 ,6 -}; - -static SOC_VALUE_ENUM_SINGLE_DECL(axg_toddr_sel_enum, FIFO_CTRL0, - CTRL0_SEL_SHIFT, CTRL0_SEL_MASK, - axg_toddr_sel_texts, axg_toddr_sel_values); +static SOC_ENUM_SINGLE_DECL(axg_toddr_sel_enum, FIFO_CTRL0, CTRL0_SEL_SHIFT, + axg_toddr_sel_texts);static const struct snd_kcontrol_new axg_toddr_in_mux =SOC_DAPM_ENUM ("Input Source" , axg_toddr_sel_enum);
@@ -163,7 +158,9 @@ static const struct snd_soc_dapm_widget axg_toddr_dapm_widgets[] = {SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_AIF_IN ("IN 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), + SND_SOC_DAPM_AIF_IN("IN 7", NULL, 0, SND_SOC_NOPM, 0, 0), }; static const struct snd_soc_dapm_route axg_toddr_dapm_routes[] = {
@@ -173,7 +170,9 @@ static const struct snd_soc_dapm_route axg_toddr_dapm_routes[] = { { "SRC SEL", "IN 2", "IN 2" }, { "SRC SEL", "IN 3", "IN 3" }, { "SRC SEL", "IN 4", "IN 4" }, + { "SRC SEL", "IN 5", "IN 5" }, { "SRC SEL", "IN 6", "IN 6" }, + { "SRC SEL", "IN 7", "IN 7" }, }; static const struct snd_soc_component_driver axg_toddr_component_drv = {
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 5/8 ASoC: meson: tdmin: expose all 16 inputs
In reply to Jerome BrunetThe TDMIN component, as it, has a maximum of 16 input. Depending on the SoC, these may not all be connected.
Instead of decribing only the connected inputs of each SoC, describe them all and let ASoC routing do the rest.
--- sound/soc/meson/axg-tdmin.c | 47 +++++++++++++++++++++++++++---------- 1 file changed, 34 insertions(+), 13 deletions(-)
sound/soc/meson/axg-tdmin.c +34 -13
@@ -43,7 +43,8 @@ static const struct regmap_config axg_tdmin_regmap_cfg = { };static const char *const axg_tdmin_sel_texts[] = { -"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 5" , +"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 5" ,"IN 6" ,"IN 7" , +"IN 8" ,"IN 9" ,"IN 10" ,"IN 11" ,"IN 12" ,"IN 13" ,"IN 14" ,"IN 15" , };/* Change to special mux control to reset dapm */
@@ -164,12 +165,22 @@ static int axg_tdmin_prepare(struct regmap *map, }static const struct snd_soc_dapm_widget axg_tdmin_dapm_widgets[] = { -SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 7" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 8" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 9" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 10" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 11" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 12" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 13" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 14" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 15" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_MUX ("SRC SEL" ,SND_SOC_NOPM ,0 ,0 , &axg_tdmin_in_mux), SND_SOC_DAPM_PGA_E("DEC", SND_SOC_NOPM, 0, 0, NULL, 0, axg_tdm_formatter_event,
@@ -178,12 +189,22 @@ static const struct snd_soc_dapm_widget axg_tdmin_dapm_widgets[] = { };static const struct snd_soc_dapm_route axg_tdmin_dapm_routes[] = { - {"SRC SEL" ,"IN 0" ,"IN 0" }, - {"SRC SEL" ,"IN 1" ,"IN 1" }, - {"SRC SEL" ,"IN 2" ,"IN 2" }, - {"SRC SEL" ,"IN 3" ,"IN 3" }, - {"SRC SEL" ,"IN 4" ,"IN 4" }, - {"SRC SEL" ,"IN 5" ,"IN 5" }, + {"SRC SEL" ,"IN 0" ,"IN 0" }, + {"SRC SEL" ,"IN 1" ,"IN 1" }, + {"SRC SEL" ,"IN 2" ,"IN 2" }, + {"SRC SEL" ,"IN 3" ,"IN 3" }, + {"SRC SEL" ,"IN 4" ,"IN 4" }, + {"SRC SEL" ,"IN 5" ,"IN 5" }, + {"SRC SEL" ,"IN 6" ,"IN 6" }, + {"SRC SEL" ,"IN 7" ,"IN 7" }, + {"SRC SEL" ,"IN 8" ,"IN 8" }, + {"SRC SEL" ,"IN 9" ,"IN 9" }, + {"SRC SEL" ,"IN 10" ,"IN 10" }, + {"SRC SEL" ,"IN 11" ,"IN 11" }, + {"SRC SEL" ,"IN 12" ,"IN 12" }, + {"SRC SEL" ,"IN 13" ,"IN 13" }, + {"SRC SEL" ,"IN 14" ,"IN 14" }, + {"SRC SEL" ,"IN 15" ,"IN 15" }, {"DEC" ,NULL ,"SRC SEL" }, {"OUT" ,NULL ,"DEC" }, };
Signature · 1 line
2.21.0
Mark Brown
maintainerApplied "ASoC: meson: tdmin: expose all 16 inputs" to the asoc tree
The patch
ASoC: meson: tdmin: expose all 16 inputs
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4
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
Quoted 1 line
From
cde9f12e5f0d288d516c810f95c2ee4c171e0245Mon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 5 Sep 2019 14:01:17 +0200
Subject: [PATCH] ASoC: meson: tdmin: expose all 16 inputs
The TDMIN component, as it, has a maximum of 16 input. Depending on the SoC, these may not all be connected.
Instead of decribing only the connected inputs of each SoC, describe them all and let ASoC routing do the rest.
--- sound/soc/meson/axg-tdmin.c | 47 +++++++++++++++++++++++++++---------- 1 file changed, 34 insertions(+), 13 deletions(-)
sound/soc/meson/axg-tdmin.c +34 -13
@@ -43,7 +43,8 @@ static const struct regmap_config axg_tdmin_regmap_cfg = { };static const char *const axg_tdmin_sel_texts[] = { -"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 5" , +"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 5" ,"IN 6" ,"IN 7" , +"IN 8" ,"IN 9" ,"IN 10" ,"IN 11" ,"IN 12" ,"IN 13" ,"IN 14" ,"IN 15" , };/* Change to special mux control to reset dapm */
@@ -164,12 +165,22 @@ static int axg_tdmin_prepare(struct regmap *map, }static const struct snd_soc_dapm_widget axg_tdmin_dapm_widgets[] = { -SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), -SND_SOC_DAPM_AIF_IN ("IN 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 7" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 8" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 9" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 10" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 11" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 12" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 13" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 14" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 15" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_MUX ("SRC SEL" ,SND_SOC_NOPM ,0 ,0 , &axg_tdmin_in_mux), SND_SOC_DAPM_PGA_E("DEC", SND_SOC_NOPM, 0, 0, NULL, 0, axg_tdm_formatter_event,
@@ -178,12 +189,22 @@ static const struct snd_soc_dapm_widget axg_tdmin_dapm_widgets[] = { };static const struct snd_soc_dapm_route axg_tdmin_dapm_routes[] = { - {"SRC SEL" ,"IN 0" ,"IN 0" }, - {"SRC SEL" ,"IN 1" ,"IN 1" }, - {"SRC SEL" ,"IN 2" ,"IN 2" }, - {"SRC SEL" ,"IN 3" ,"IN 3" }, - {"SRC SEL" ,"IN 4" ,"IN 4" }, - {"SRC SEL" ,"IN 5" ,"IN 5" }, + {"SRC SEL" ,"IN 0" ,"IN 0" }, + {"SRC SEL" ,"IN 1" ,"IN 1" }, + {"SRC SEL" ,"IN 2" ,"IN 2" }, + {"SRC SEL" ,"IN 3" ,"IN 3" }, + {"SRC SEL" ,"IN 4" ,"IN 4" }, + {"SRC SEL" ,"IN 5" ,"IN 5" }, + {"SRC SEL" ,"IN 6" ,"IN 6" }, + {"SRC SEL" ,"IN 7" ,"IN 7" }, + {"SRC SEL" ,"IN 8" ,"IN 8" }, + {"SRC SEL" ,"IN 9" ,"IN 9" }, + {"SRC SEL" ,"IN 10" ,"IN 10" }, + {"SRC SEL" ,"IN 11" ,"IN 11" }, + {"SRC SEL" ,"IN 12" ,"IN 12" }, + {"SRC SEL" ,"IN 13" ,"IN 13" }, + {"SRC SEL" ,"IN 14" ,"IN 14" }, + {"SRC SEL" ,"IN 15" ,"IN 15" }, {"DEC" ,NULL ,"SRC SEL" }, {"OUT" ,NULL ,"DEC" }, };
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 6/8 ASoC: meson: axg-frddr: add sm1 support
In reply to Jerome BrunetOn sm1, the output routing bits have moved to CTRL2 register
--- sound/soc/meson/axg-fifo.c | 2 +- sound/soc/meson/axg-fifo.h | 1 + sound/soc/meson/axg-frddr.c | 73 +++++++++++++++++++++++++++++++++++++ 3 files changed, 75 insertions(+), 1 deletion(-)
sound/soc/meson/axg-fifo.c +1 -1
@@ -306,7 +306,7 @@ static const struct regmap_config axg_fifo_regmap_cfg = { .reg_bits = 32, .val_bits = 32, .reg_stride = 4, - .max_register = FIFO_INIT_ADDR, + .max_register = FIFO_CTRL2, };int axg_fifo_probe (struct platform_device *pdev)
sound/soc/meson/axg-fifo.h +1 -0
@@ -61,6 +61,7 @@ struct snd_soc_pcm_runtime;#define STATUS1_INT_STS (x) ((x) << 0)#define FIFO_STATUS2 0x18#define FIFO_INIT_ADDR 0x24 +#define FIFO_CTRL2 0x28struct axg_fifo {struct regmap *map;
sound/soc/meson/axg-frddr.c +73 -0
91 lines not on this page · raw message
Signature · 1 line
2.21.0
Mark Brown
maintainerApplied "ASoC: meson: axg-frddr: add sm1 support" to the asoc tree
The patch
ASoC: meson: axg-frddr: add sm1 support
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4
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
Quoted 1 line
From
52dd80d8f7386483bc60b2b7470e47a2e6f61d7cMon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 5 Sep 2019 14:01:18 +0200
Subject: [PATCH] ASoC: meson: axg-frddr: add sm1 support
On sm1, the output routing bits have moved to CTRL2 register
--- sound/soc/meson/axg-fifo.c | 2 +- sound/soc/meson/axg-fifo.h | 1 + sound/soc/meson/axg-frddr.c | 73 +++++++++++++++++++++++++++++++++++++ 3 files changed, 75 insertions(+), 1 deletion(-)
sound/soc/meson/axg-fifo.c +1 -1
@@ -306,7 +306,7 @@ static const struct regmap_config axg_fifo_regmap_cfg = { .reg_bits = 32, .val_bits = 32, .reg_stride = 4, - .max_register = FIFO_INIT_ADDR, + .max_register = FIFO_CTRL2, };int axg_fifo_probe (struct platform_device *pdev)
sound/soc/meson/axg-fifo.h +1 -0
@@ -61,6 +61,7 @@ struct snd_soc_pcm_runtime;#define STATUS1_INT_STS (x) ((x) << 0)#define FIFO_STATUS2 0x18#define FIFO_INIT_ADDR 0x24 +#define FIFO_CTRL2 0x28struct axg_fifo {struct regmap *map;
sound/soc/meson/axg-frddr.c +73 -0
91 lines not on this page · raw message
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 7/8 ASoC: meson: axg-toddr: add sm1 support
In reply to Jerome BrunetOn sm1, the maximum number TODDR inputs is extended to 16.
--- sound/soc/meson/axg-toddr.c | 68 +++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+)
sound/soc/meson/axg-toddr.c +68 -0
@@ -25,6 +25,7 @@#define CTRL0_TODDR_LSB_POS_MASK GENMASK(7, 3)#define CTRL0_TODDR_LSB_POS (x) ((x) << 3)#define CTRL1_TODDR_FORCE_FINISH BIT(25) +#define CTRL1_SEL_SHIFT 28#define TODDR_MSB_POS 31
@@ -221,6 +222,70 @@ static const struct axg_fifo_match_data g12a_toddr_match_data = { .dai_drv = &g12a_toddr_dai_drv }; +static const char *const sm1_toddr_sel_texts[] = { +"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 5" ,"IN 6" ,"IN 7" , +"IN 8" ,"IN 9" ,"IN 10" ,"IN 11" ,"IN 12" ,"IN 13" ,"IN 14" ,"IN 15" +}; + +static SOC_ENUM_SINGLE_DECL(sm1_toddr_sel_enum, FIFO_CTRL1, CTRL1_SEL_SHIFT, + sm1_toddr_sel_texts); + +static const struct snd_kcontrol_new sm1_toddr_in_mux = +SOC_DAPM_ENUM ("Input Source" , sm1_toddr_sel_enum); + +static const struct snd_soc_dapm_widget sm1_toddr_dapm_widgets[] = { +SND_SOC_DAPM_MUX ("SRC SEL" ,SND_SOC_NOPM ,0 ,0 , &sm1_toddr_in_mux), +SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 7" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 8" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 9" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 10" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 11" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 12" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 13" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 14" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 15" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +}; + +static const struct snd_soc_dapm_route sm1_toddr_dapm_routes[] = { + {"Capture" ,NULL ,"SRC SEL" }, + {"SRC SEL" ,"IN 0" ,"IN 0" }, + {"SRC SEL" ,"IN 1" ,"IN 1" }, + {"SRC SEL" ,"IN 2" ,"IN 2" }, + {"SRC SEL" ,"IN 3" ,"IN 3" }, + {"SRC SEL" ,"IN 4" ,"IN 4" }, + {"SRC SEL" ,"IN 5" ,"IN 5" }, + {"SRC SEL" ,"IN 6" ,"IN 6" }, + {"SRC SEL" ,"IN 7" ,"IN 7" }, + {"SRC SEL" ,"IN 8" ,"IN 8" }, + {"SRC SEL" ,"IN 9" ,"IN 9" }, + {"SRC SEL" ,"IN 10" ,"IN 10" }, + {"SRC SEL" ,"IN 11" ,"IN 11" }, + {"SRC SEL" ,"IN 12" ,"IN 12" }, + {"SRC SEL" ,"IN 13" ,"IN 13" }, + {"SRC SEL" ,"IN 14" ,"IN 14" }, + {"SRC SEL" ,"IN 15" ,"IN 15" }, +}; + +static const struct snd_soc_component_driver sm1_toddr_component_drv = { + .dapm_widgets = sm1_toddr_dapm_widgets, + .num_dapm_widgets =ARRAY_SIZE (sm1_toddr_dapm_widgets), + .dapm_routes = sm1_toddr_dapm_routes, + .num_dapm_routes =ARRAY_SIZE (sm1_toddr_dapm_routes), + .ops = &g12a_fifo_pcm_ops +}; + +static const struct axg_fifo_match_data sm1_toddr_match_data = { + .component_drv = &sm1_toddr_component_drv, + .dai_drv = &g12a_toddr_dai_drv +}; +static const struct of_device_id axg_toddr_of_match[] = { { .compatible ="amlogic,axg-toddr" ,
@@ -228,6 +293,9 @@ static const struct of_device_id axg_toddr_of_match[] = { }, { .compatible = "amlogic,g12a-toddr", .data = &g12a_toddr_match_data, + }, { + .compatible = "amlogic,sm1-toddr", + .data = &sm1_toddr_match_data, }, {} };MODULE_DEVICE_TABLE (of, axg_toddr_of_match);
Signature · 1 line
2.21.0
Mark Brown
maintainerApplied "ASoC: meson: axg-toddr: add sm1 support" to the asoc tree
The patch
ASoC: meson: axg-toddr: add sm1 support
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4
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
Quoted 1 line
From
5ac825c3d85e6c1cb8e43d67d8cb95a2a1e2bc60Mon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 5 Sep 2019 14:01:19 +0200
Subject: [PATCH] ASoC: meson: axg-toddr: add sm1 support
On sm1, the maximum number TODDR inputs is extended to 16.
--- sound/soc/meson/axg-toddr.c | 68 +++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+)
sound/soc/meson/axg-toddr.c +68 -0
@@ -25,6 +25,7 @@#define CTRL0_TODDR_LSB_POS_MASK GENMASK(7, 3)#define CTRL0_TODDR_LSB_POS (x) ((x) << 3)#define CTRL1_TODDR_FORCE_FINISH BIT(25) +#define CTRL1_SEL_SHIFT 28#define TODDR_MSB_POS 31
@@ -221,6 +222,70 @@ static const struct axg_fifo_match_data g12a_toddr_match_data = { .dai_drv = &g12a_toddr_dai_drv }; +static const char *const sm1_toddr_sel_texts[] = { +"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" ,"IN 5" ,"IN 6" ,"IN 7" , +"IN 8" ,"IN 9" ,"IN 10" ,"IN 11" ,"IN 12" ,"IN 13" ,"IN 14" ,"IN 15" +}; + +static SOC_ENUM_SINGLE_DECL(sm1_toddr_sel_enum, FIFO_CTRL1, CTRL1_SEL_SHIFT, + sm1_toddr_sel_texts); + +static const struct snd_kcontrol_new sm1_toddr_in_mux = +SOC_DAPM_ENUM ("Input Source" , sm1_toddr_sel_enum); + +static const struct snd_soc_dapm_widget sm1_toddr_dapm_widgets[] = { +SND_SOC_DAPM_MUX ("SRC SEL" ,SND_SOC_NOPM ,0 ,0 , &sm1_toddr_in_mux), +SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 5" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 6" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 7" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 8" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 9" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 10" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 11" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 12" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 13" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 14" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 15" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +}; + +static const struct snd_soc_dapm_route sm1_toddr_dapm_routes[] = { + {"Capture" ,NULL ,"SRC SEL" }, + {"SRC SEL" ,"IN 0" ,"IN 0" }, + {"SRC SEL" ,"IN 1" ,"IN 1" }, + {"SRC SEL" ,"IN 2" ,"IN 2" }, + {"SRC SEL" ,"IN 3" ,"IN 3" }, + {"SRC SEL" ,"IN 4" ,"IN 4" }, + {"SRC SEL" ,"IN 5" ,"IN 5" }, + {"SRC SEL" ,"IN 6" ,"IN 6" }, + {"SRC SEL" ,"IN 7" ,"IN 7" }, + {"SRC SEL" ,"IN 8" ,"IN 8" }, + {"SRC SEL" ,"IN 9" ,"IN 9" }, + {"SRC SEL" ,"IN 10" ,"IN 10" }, + {"SRC SEL" ,"IN 11" ,"IN 11" }, + {"SRC SEL" ,"IN 12" ,"IN 12" }, + {"SRC SEL" ,"IN 13" ,"IN 13" }, + {"SRC SEL" ,"IN 14" ,"IN 14" }, + {"SRC SEL" ,"IN 15" ,"IN 15" }, +}; + +static const struct snd_soc_component_driver sm1_toddr_component_drv = { + .dapm_widgets = sm1_toddr_dapm_widgets, + .num_dapm_widgets =ARRAY_SIZE (sm1_toddr_dapm_widgets), + .dapm_routes = sm1_toddr_dapm_routes, + .num_dapm_routes =ARRAY_SIZE (sm1_toddr_dapm_routes), + .ops = &g12a_fifo_pcm_ops +}; + +static const struct axg_fifo_match_data sm1_toddr_match_data = { + .component_drv = &sm1_toddr_component_drv, + .dai_drv = &g12a_toddr_dai_drv +}; +static const struct of_device_id axg_toddr_of_match[] = { { .compatible ="amlogic,axg-toddr" ,
@@ -228,6 +293,9 @@ static const struct of_device_id axg_toddr_of_match[] = { }, { .compatible = "amlogic,g12a-toddr", .data = &g12a_toddr_match_data, + }, { + .compatible = "amlogic,sm1-toddr", + .data = &sm1_toddr_match_data, }, {} };MODULE_DEVICE_TABLE (of, axg_toddr_of_match);
Signature · 1 line
2.20.1
Jerome Brunet
maintainerPATCH 8/8 ASoC: meson: tdmout: add sm1 support
In reply to Jerome BrunetOn the sm1, the TDMOUT number of input is extended and the the gain enable bit moved to accommodate this extension
--- sound/soc/meson/axg-tdmout.c | 103 ++++++++++++++++++++++++++++------- 1 file changed, 84 insertions(+), 19 deletions(-)
sound/soc/meson/axg-tdmout.c +84 -19
@@ -24,6 +24,7 @@#define TDMOUT_CTRL1 0x04#define TDMOUT_CTRL1_TYPE_MASK GENMASK(6, 4)#define TDMOUT_CTRL1_TYPE (x) ((x) << 4) +#define SM1_TDMOUT_CTRL1_GAIN_EN 7#define TDMOUT_CTRL1_MSB_POS_MASK GENMASK(12, 8)#define TDMOUT_CTRL1_MSB_POS (x) ((x) << 8)#define TDMOUT_CTRL1_SEL_SHIFT 24
@@ -51,25 +52,6 @@ static const struct regmap_config axg_tdmout_regmap_cfg = { .max_register = TDMOUT_MASK_VAL, }; -static const struct snd_kcontrol_new axg_tdmout_controls[] = { -SOC_DOUBLE ("Lane 0 Volume" ,TDMOUT_GAIN0 ,0 ,8 ,255 ,0 ), -SOC_DOUBLE ("Lane 1 Volume" ,TDMOUT_GAIN0 ,16 ,24 ,255 ,0 ), -SOC_DOUBLE ("Lane 2 Volume" ,TDMOUT_GAIN1 ,0 ,8 ,255 ,0 ), -SOC_DOUBLE ("Lane 3 Volume" ,TDMOUT_GAIN1 ,16 ,24 ,255 ,0 ), -SOC_SINGLE ("Gain Enable Switch" ,TDMOUT_CTRL1 , -TDMOUT_CTRL1_GAIN_EN ,1 ,0 ), -}; - -static const char *const tdmout_sel_texts[] = { -"IN 0" ,"IN 1" ,"IN 2" , -}; - -static SOC_ENUM_SINGLE_DECL(axg_tdmout_sel_enum, TDMOUT_CTRL1, - TDMOUT_CTRL1_SEL_SHIFT, tdmout_sel_texts); - -static const struct snd_kcontrol_new axg_tdmout_in_mux = -SOC_DAPM_ENUM ("Input Source" , axg_tdmout_sel_enum); -static struct snd_soc_dai *axg_tdmout_get_be (struct snd_soc_dapm_widget *w) {
@@ -197,6 +179,25 @@ static int axg_tdmout_prepare(struct regmap *map,return axg_tdm_formatter_set_channel_masks (map, ts,TDMOUT_MASK0 ); } +static const struct snd_kcontrol_new axg_tdmout_controls[] = { +SOC_DOUBLE ("Lane 0 Volume" ,TDMOUT_GAIN0 ,0 ,8 ,255 ,0 ), +SOC_DOUBLE ("Lane 1 Volume" ,TDMOUT_GAIN0 ,16 ,24 ,255 ,0 ), +SOC_DOUBLE ("Lane 2 Volume" ,TDMOUT_GAIN1 ,0 ,8 ,255 ,0 ), +SOC_DOUBLE ("Lane 3 Volume" ,TDMOUT_GAIN1 ,16 ,24 ,255 ,0 ), +SOC_SINGLE ("Gain Enable Switch" ,TDMOUT_CTRL1 , +TDMOUT_CTRL1_GAIN_EN ,1 ,0 ), +}; + +static const char *const axg_tdmout_sel_texts[] = { +"IN 0" ,"IN 1" ,"IN 2" , +}; + +static SOC_ENUM_SINGLE_DECL(axg_tdmout_sel_enum, TDMOUT_CTRL1, + TDMOUT_CTRL1_SEL_SHIFT, axg_tdmout_sel_texts); + +static const struct snd_kcontrol_new axg_tdmout_in_mux = +SOC_DAPM_ENUM ("Input Source" , axg_tdmout_sel_enum); +static const struct snd_soc_dapm_widget axg_tdmout_dapm_widgets[] = {SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),
@@ -252,6 +253,67 @@ static const struct axg_tdm_formatter_driver g12a_tdmout_drv = { }, }; +static const struct snd_kcontrol_new sm1_tdmout_controls[] = { +SOC_DOUBLE ("Lane 0 Volume" ,TDMOUT_GAIN0 ,0 ,8 ,255 ,0 ), +SOC_DOUBLE ("Lane 1 Volume" ,TDMOUT_GAIN0 ,16 ,24 ,255 ,0 ), +SOC_DOUBLE ("Lane 2 Volume" ,TDMOUT_GAIN1 ,0 ,8 ,255 ,0 ), +SOC_DOUBLE ("Lane 3 Volume" ,TDMOUT_GAIN1 ,16 ,24 ,255 ,0 ), +SOC_SINGLE ("Gain Enable Switch" ,TDMOUT_CTRL1 , +SM1_TDMOUT_CTRL1_GAIN_EN ,1 ,0 ), +}; + +static const char *const sm1_tdmout_sel_texts[] = { +"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" , +}; + +static SOC_ENUM_SINGLE_DECL(sm1_tdmout_sel_enum, TDMOUT_CTRL1, + TDMOUT_CTRL1_SEL_SHIFT, sm1_tdmout_sel_texts); + +static const struct snd_kcontrol_new sm1_tdmout_in_mux = +SOC_DAPM_ENUM ("Input Source" , sm1_tdmout_sel_enum); + +static const struct snd_soc_dapm_widget sm1_tdmout_dapm_widgets[] = { +SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_MUX ("SRC SEL" ,SND_SOC_NOPM ,0 ,0 , &sm1_tdmout_in_mux), +SND_SOC_DAPM_PGA_E ("ENC" ,SND_SOC_NOPM ,0 ,0 ,NULL ,0 , + axg_tdm_formatter_event, + (SND_SOC_DAPM_PRE_PMU |SND_SOC_DAPM_PRE_PMD )), +SND_SOC_DAPM_AIF_OUT ("OUT" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +}; + +static const struct snd_soc_dapm_route sm1_tdmout_dapm_routes[] = { + {"SRC SEL" ,"IN 0" ,"IN 0" }, + {"SRC SEL" ,"IN 1" ,"IN 1" }, + {"SRC SEL" ,"IN 2" ,"IN 2" }, + {"SRC SEL" ,"IN 3" ,"IN 3" }, + {"SRC SEL" ,"IN 4" ,"IN 4" }, + {"ENC" ,NULL ,"SRC SEL" }, + {"OUT" ,NULL ,"ENC" }, +}; + +static const struct snd_soc_component_driver sm1_tdmout_component_drv = { + .controls = sm1_tdmout_controls, + .num_controls =ARRAY_SIZE (sm1_tdmout_controls), + .dapm_widgets = sm1_tdmout_dapm_widgets, + .num_dapm_widgets =ARRAY_SIZE (sm1_tdmout_dapm_widgets), + .dapm_routes = sm1_tdmout_dapm_routes, + .num_dapm_routes =ARRAY_SIZE (sm1_tdmout_dapm_routes), +}; + +static const struct axg_tdm_formatter_driver sm1_tdmout_drv = { + .component_drv = &sm1_tdmout_component_drv, + .regmap_cfg = &axg_tdmout_regmap_cfg, + .ops = &axg_tdmout_ops, + .quirks = &(const struct axg_tdm_formatter_hw ) { + .invert_sclk = true, + .skew_offset =2 , + }, +}; +static const struct of_device_id axg_tdmout_of_match[] = { { .compatible ="amlogic,axg-tdmout" ,
@@ -259,6 +321,9 @@ static const struct of_device_id axg_tdmout_of_match[] = { }, { .compatible = "amlogic,g12a-tdmout", .data = &g12a_tdmout_drv, + }, { + .compatible = "amlogic,sm1-tdmout", + .data = &sm1_tdmout_drv, }, {} };MODULE_DEVICE_TABLE (of, axg_tdmout_of_match);
Signature · 1 line
2.21.0
Mark Brown
maintainerApplied "ASoC: meson: tdmout: add sm1 support" to the asoc tree
The patch
ASoC: meson: tdmout: add sm1 support
has been applied to the asoc tree at
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-5.4
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
Quoted 1 line
From
329299d6652fa287a0551ae412cc0227d539a0feMon Sep 17 00:00:00 2001
From: Jerome Brunet <[email protected]>
Date: Thu, 5 Sep 2019 14:01:20 +0200
Subject: [PATCH] ASoC: meson: tdmout: add sm1 support
On the sm1, the TDMOUT number of input is extended and the the gain enable bit moved to accommodate this extension
--- sound/soc/meson/axg-tdmout.c | 103 ++++++++++++++++++++++++++++------- 1 file changed, 84 insertions(+), 19 deletions(-)
sound/soc/meson/axg-tdmout.c +84 -19
@@ -24,6 +24,7 @@#define TDMOUT_CTRL1 0x04#define TDMOUT_CTRL1_TYPE_MASK GENMASK(6, 4)#define TDMOUT_CTRL1_TYPE (x) ((x) << 4) +#define SM1_TDMOUT_CTRL1_GAIN_EN 7#define TDMOUT_CTRL1_MSB_POS_MASK GENMASK(12, 8)#define TDMOUT_CTRL1_MSB_POS (x) ((x) << 8)#define TDMOUT_CTRL1_SEL_SHIFT 24
@@ -51,25 +52,6 @@ static const struct regmap_config axg_tdmout_regmap_cfg = { .max_register = TDMOUT_MASK_VAL, }; -static const struct snd_kcontrol_new axg_tdmout_controls[] = { -SOC_DOUBLE ("Lane 0 Volume" ,TDMOUT_GAIN0 ,0 ,8 ,255 ,0 ), -SOC_DOUBLE ("Lane 1 Volume" ,TDMOUT_GAIN0 ,16 ,24 ,255 ,0 ), -SOC_DOUBLE ("Lane 2 Volume" ,TDMOUT_GAIN1 ,0 ,8 ,255 ,0 ), -SOC_DOUBLE ("Lane 3 Volume" ,TDMOUT_GAIN1 ,16 ,24 ,255 ,0 ), -SOC_SINGLE ("Gain Enable Switch" ,TDMOUT_CTRL1 , -TDMOUT_CTRL1_GAIN_EN ,1 ,0 ), -}; - -static const char *const tdmout_sel_texts[] = { -"IN 0" ,"IN 1" ,"IN 2" , -}; - -static SOC_ENUM_SINGLE_DECL(axg_tdmout_sel_enum, TDMOUT_CTRL1, - TDMOUT_CTRL1_SEL_SHIFT, tdmout_sel_texts); - -static const struct snd_kcontrol_new axg_tdmout_in_mux = -SOC_DAPM_ENUM ("Input Source" , axg_tdmout_sel_enum); -static struct snd_soc_dai *axg_tdmout_get_be (struct snd_soc_dapm_widget *w) {
@@ -197,6 +179,25 @@ static int axg_tdmout_prepare(struct regmap *map,return axg_tdm_formatter_set_channel_masks (map, ts,TDMOUT_MASK0 ); } +static const struct snd_kcontrol_new axg_tdmout_controls[] = { +SOC_DOUBLE ("Lane 0 Volume" ,TDMOUT_GAIN0 ,0 ,8 ,255 ,0 ), +SOC_DOUBLE ("Lane 1 Volume" ,TDMOUT_GAIN0 ,16 ,24 ,255 ,0 ), +SOC_DOUBLE ("Lane 2 Volume" ,TDMOUT_GAIN1 ,0 ,8 ,255 ,0 ), +SOC_DOUBLE ("Lane 3 Volume" ,TDMOUT_GAIN1 ,16 ,24 ,255 ,0 ), +SOC_SINGLE ("Gain Enable Switch" ,TDMOUT_CTRL1 , +TDMOUT_CTRL1_GAIN_EN ,1 ,0 ), +}; + +static const char *const axg_tdmout_sel_texts[] = { +"IN 0" ,"IN 1" ,"IN 2" , +}; + +static SOC_ENUM_SINGLE_DECL(axg_tdmout_sel_enum, TDMOUT_CTRL1, + TDMOUT_CTRL1_SEL_SHIFT, axg_tdmout_sel_texts); + +static const struct snd_kcontrol_new axg_tdmout_in_mux = +SOC_DAPM_ENUM ("Input Source" , axg_tdmout_sel_enum); +static const struct snd_soc_dapm_widget axg_tdmout_dapm_widgets[] = {SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ),
@@ -252,6 +253,67 @@ static const struct axg_tdm_formatter_driver g12a_tdmout_drv = { }, }; +static const struct snd_kcontrol_new sm1_tdmout_controls[] = { +SOC_DOUBLE ("Lane 0 Volume" ,TDMOUT_GAIN0 ,0 ,8 ,255 ,0 ), +SOC_DOUBLE ("Lane 1 Volume" ,TDMOUT_GAIN0 ,16 ,24 ,255 ,0 ), +SOC_DOUBLE ("Lane 2 Volume" ,TDMOUT_GAIN1 ,0 ,8 ,255 ,0 ), +SOC_DOUBLE ("Lane 3 Volume" ,TDMOUT_GAIN1 ,16 ,24 ,255 ,0 ), +SOC_SINGLE ("Gain Enable Switch" ,TDMOUT_CTRL1 , +SM1_TDMOUT_CTRL1_GAIN_EN ,1 ,0 ), +}; + +static const char *const sm1_tdmout_sel_texts[] = { +"IN 0" ,"IN 1" ,"IN 2" ,"IN 3" ,"IN 4" , +}; + +static SOC_ENUM_SINGLE_DECL(sm1_tdmout_sel_enum, TDMOUT_CTRL1, + TDMOUT_CTRL1_SEL_SHIFT, sm1_tdmout_sel_texts); + +static const struct snd_kcontrol_new sm1_tdmout_in_mux = +SOC_DAPM_ENUM ("Input Source" , sm1_tdmout_sel_enum); + +static const struct snd_soc_dapm_widget sm1_tdmout_dapm_widgets[] = { +SND_SOC_DAPM_AIF_IN ("IN 0" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 1" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 2" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 3" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_AIF_IN ("IN 4" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +SND_SOC_DAPM_MUX ("SRC SEL" ,SND_SOC_NOPM ,0 ,0 , &sm1_tdmout_in_mux), +SND_SOC_DAPM_PGA_E ("ENC" ,SND_SOC_NOPM ,0 ,0 ,NULL ,0 , + axg_tdm_formatter_event, + (SND_SOC_DAPM_PRE_PMU |SND_SOC_DAPM_PRE_PMD )), +SND_SOC_DAPM_AIF_OUT ("OUT" ,NULL ,0 ,SND_SOC_NOPM ,0 ,0 ), +}; + +static const struct snd_soc_dapm_route sm1_tdmout_dapm_routes[] = { + {"SRC SEL" ,"IN 0" ,"IN 0" }, + {"SRC SEL" ,"IN 1" ,"IN 1" }, + {"SRC SEL" ,"IN 2" ,"IN 2" }, + {"SRC SEL" ,"IN 3" ,"IN 3" }, + {"SRC SEL" ,"IN 4" ,"IN 4" }, + {"ENC" ,NULL ,"SRC SEL" }, + {"OUT" ,NULL ,"ENC" }, +}; + +static const struct snd_soc_component_driver sm1_tdmout_component_drv = { + .controls = sm1_tdmout_controls, + .num_controls =ARRAY_SIZE (sm1_tdmout_controls), + .dapm_widgets = sm1_tdmout_dapm_widgets, + .num_dapm_widgets =ARRAY_SIZE (sm1_tdmout_dapm_widgets), + .dapm_routes = sm1_tdmout_dapm_routes, + .num_dapm_routes =ARRAY_SIZE (sm1_tdmout_dapm_routes), +}; + +static const struct axg_tdm_formatter_driver sm1_tdmout_drv = { + .component_drv = &sm1_tdmout_component_drv, + .regmap_cfg = &axg_tdmout_regmap_cfg, + .ops = &axg_tdmout_ops, + .quirks = &(const struct axg_tdm_formatter_hw ) { + .invert_sclk = true, + .skew_offset =2 , + }, +}; +static const struct of_device_id axg_tdmout_of_match[] = { { .compatible ="amlogic,axg-tdmout" ,
@@ -259,6 +321,9 @@ static const struct of_device_id axg_tdmout_of_match[] = { }, { .compatible = "amlogic,g12a-tdmout", .data = &g12a_tdmout_drv, + }, { + .compatible = "amlogic,sm1-tdmout", + .data = &sm1_tdmout_drv, }, {} };MODULE_DEVICE_TABLE (of, axg_tdmout_of_match);
Signature · 1 line
2.20.1