Loading Documentation/devicetree/bindings/sound/axentia,tse850-pcm5142.txt 0 → 100644 +88 −0 Original line number Diff line number Diff line Devicetree bindings for the Axentia TSE-850 audio complex Required properties: - compatible: "axentia,tse850-pcm5142" - axentia,ssc-controller: The phandle of the atmel SSC controller used as cpu dai. - axentia,audio-codec: The phandle of the PCM5142 codec. - axentia,add-gpios: gpio specifier that controls the mixer. - axentia,loop1-gpios: gpio specifier that controls loop relays on channel 1. - axentia,loop2-gpios: gpio specifier that controls loop relays on channel 2. - axentia,ana-supply: Regulator that supplies the output amplifier. Must support voltages in the 2V - 20V range, in 1V steps. The schematics explaining the gpios are as follows: loop1 relays IN1 +---o +------------+ o---+ OUT1 \ / + + | / | +--o +--. | | add | | | V | | .---. | DAC +----------->|Sum|---+ | '---' | | | + + IN2 +---o--+------------+--o---+ OUT2 loop2 relays The 'loop1' gpio pin controlls two relays, which are either in loop position, meaning that input and output are directly connected, or they are in mixer position, meaning that the signal is passed through the 'Sum' mixer. Similarly for 'loop2'. In the above, the 'loop1' relays are inactive, thus feeding IN1 to the mixer (if 'add' is active) and feeding the mixer output to OUT1. The 'loop2' relays are active, short-cutting the TSE-850 from channel 2. IN1, IN2, OUT1 and OUT2 are TSE-850 connectors and DAC is the PCB name of the (filtered) output from the PCM5142 codec. Example: &i2c { codec: pcm5142@4c { compatible = "ti,pcm5142"; reg = <0x4c>; AVDD-supply = <®_3v3>; DVDD-supply = <®_3v3>; CPVDD-supply = <®_3v3>; clocks = <&sck>; pll-in = <3>; pll-out = <6>; }; }; ana: ana-reg { compatible = "pwm-regulator"; regulator-name = "ANA"; pwms = <&pwm0 2 1000 PWM_POLARITY_INVERTED>; pwm-dutycycle-unit = <1000>; pwm-dutycycle-range = <100 1000>; regulator-min-microvolt = <2000000>; regulator-max-microvolt = <20000000>; regulator-ramp-delay = <1000>; }; sound { compatible = "axentia,tse850-pcm5142"; axentia,ssc-controller = <&ssc0>; axentia,audio-codec = <&codec>; axentia,add-gpios = <&pioA 8 GPIO_ACTIVE_LOW>; axentia,loop1-gpios = <&pioA 10 GPIO_ACTIVE_LOW>; axentia,loop2-gpios = <&pioA 11 GPIO_ACTIVE_LOW>; axentia,ana-supply = <&ana>; }; MAINTAINERS +7 −0 Original line number Diff line number Diff line Loading @@ -2325,6 +2325,13 @@ F: include/uapi/linux/ax25.h F: include/net/ax25.h F: net/ax25/ AXENTIA ASOC DRIVERS M: Peter Rosin <peda@axentia.se> L: alsa-devel@alsa-project.org (moderated for non-subscribers) S: Maintained F: Documentation/devicetree/bindings/sound/axentia,* F: sound/soc/atmel/tse850-pcm5142.c AZ6007 DVB DRIVER M: Mauro Carvalho Chehab <mchehab@s-opensource.com> M: Mauro Carvalho Chehab <mchehab@kernel.org> Loading include/sound/soc-dai.h +2 −1 Original line number Diff line number Diff line Loading @@ -268,8 +268,9 @@ struct snd_soc_dai { unsigned int symmetric_rates:1; unsigned int symmetric_channels:1; unsigned int symmetric_samplebits:1; unsigned int probed:1; unsigned int active; unsigned char probed:1; struct snd_soc_dapm_widget *playback_widget; struct snd_soc_dapm_widget *capture_widget; Loading include/sound/soc.h +8 −7 Original line number Diff line number Diff line Loading @@ -1029,13 +1029,13 @@ struct snd_soc_dai_link { const struct snd_soc_ops *ops; const struct snd_soc_compr_ops *compr_ops; /* For unidirectional dai links */ bool playback_only; bool capture_only; /* Mark this pcm with non atomic ops */ bool nonatomic; /* For unidirectional dai links */ unsigned int playback_only:1; unsigned int capture_only:1; /* Keep DAI active over suspend */ unsigned int ignore_suspend:1; Loading Loading @@ -1206,14 +1206,11 @@ struct snd_soc_pcm_runtime { enum snd_soc_pcm_subclass pcm_subclass; struct snd_pcm_ops ops; unsigned int dev_registered:1; /* Dynamic PCM BE runtime data */ struct snd_soc_dpcm_runtime dpcm[2]; int fe_compr; long pmdown_time; unsigned char pop_wait:1; /* runtime devices */ struct snd_pcm *pcm; Loading @@ -1234,6 +1231,10 @@ struct snd_soc_pcm_runtime { unsigned int num; /* 0-based and monotonic increasing */ struct list_head list; /* rtd list of the soc card */ /* bit field */ unsigned int dev_registered:1; unsigned int pop_wait:1; }; /* mixer control */ Loading sound/soc/atmel/Kconfig +10 −0 Original line number Diff line number Diff line Loading @@ -78,4 +78,14 @@ config SND_ATMEL_SOC_PDMIC help Say Y if you want to add support for Atmel ASoC driver for boards using PDMIC. config SND_ATMEL_SOC_TSE850_PCM5142 tristate "ASoC driver for the Axentia TSE-850" depends on ARCH_AT91 && OF depends on ATMEL_SSC && I2C select SND_ATMEL_SOC_SSC_DMA select SND_SOC_PCM512x_I2C help Say Y if you want to add support for the ASoC driver for the Axentia TSE-850 with a PCM5142 codec. endif Loading
Documentation/devicetree/bindings/sound/axentia,tse850-pcm5142.txt 0 → 100644 +88 −0 Original line number Diff line number Diff line Devicetree bindings for the Axentia TSE-850 audio complex Required properties: - compatible: "axentia,tse850-pcm5142" - axentia,ssc-controller: The phandle of the atmel SSC controller used as cpu dai. - axentia,audio-codec: The phandle of the PCM5142 codec. - axentia,add-gpios: gpio specifier that controls the mixer. - axentia,loop1-gpios: gpio specifier that controls loop relays on channel 1. - axentia,loop2-gpios: gpio specifier that controls loop relays on channel 2. - axentia,ana-supply: Regulator that supplies the output amplifier. Must support voltages in the 2V - 20V range, in 1V steps. The schematics explaining the gpios are as follows: loop1 relays IN1 +---o +------------+ o---+ OUT1 \ / + + | / | +--o +--. | | add | | | V | | .---. | DAC +----------->|Sum|---+ | '---' | | | + + IN2 +---o--+------------+--o---+ OUT2 loop2 relays The 'loop1' gpio pin controlls two relays, which are either in loop position, meaning that input and output are directly connected, or they are in mixer position, meaning that the signal is passed through the 'Sum' mixer. Similarly for 'loop2'. In the above, the 'loop1' relays are inactive, thus feeding IN1 to the mixer (if 'add' is active) and feeding the mixer output to OUT1. The 'loop2' relays are active, short-cutting the TSE-850 from channel 2. IN1, IN2, OUT1 and OUT2 are TSE-850 connectors and DAC is the PCB name of the (filtered) output from the PCM5142 codec. Example: &i2c { codec: pcm5142@4c { compatible = "ti,pcm5142"; reg = <0x4c>; AVDD-supply = <®_3v3>; DVDD-supply = <®_3v3>; CPVDD-supply = <®_3v3>; clocks = <&sck>; pll-in = <3>; pll-out = <6>; }; }; ana: ana-reg { compatible = "pwm-regulator"; regulator-name = "ANA"; pwms = <&pwm0 2 1000 PWM_POLARITY_INVERTED>; pwm-dutycycle-unit = <1000>; pwm-dutycycle-range = <100 1000>; regulator-min-microvolt = <2000000>; regulator-max-microvolt = <20000000>; regulator-ramp-delay = <1000>; }; sound { compatible = "axentia,tse850-pcm5142"; axentia,ssc-controller = <&ssc0>; axentia,audio-codec = <&codec>; axentia,add-gpios = <&pioA 8 GPIO_ACTIVE_LOW>; axentia,loop1-gpios = <&pioA 10 GPIO_ACTIVE_LOW>; axentia,loop2-gpios = <&pioA 11 GPIO_ACTIVE_LOW>; axentia,ana-supply = <&ana>; };
MAINTAINERS +7 −0 Original line number Diff line number Diff line Loading @@ -2325,6 +2325,13 @@ F: include/uapi/linux/ax25.h F: include/net/ax25.h F: net/ax25/ AXENTIA ASOC DRIVERS M: Peter Rosin <peda@axentia.se> L: alsa-devel@alsa-project.org (moderated for non-subscribers) S: Maintained F: Documentation/devicetree/bindings/sound/axentia,* F: sound/soc/atmel/tse850-pcm5142.c AZ6007 DVB DRIVER M: Mauro Carvalho Chehab <mchehab@s-opensource.com> M: Mauro Carvalho Chehab <mchehab@kernel.org> Loading
include/sound/soc-dai.h +2 −1 Original line number Diff line number Diff line Loading @@ -268,8 +268,9 @@ struct snd_soc_dai { unsigned int symmetric_rates:1; unsigned int symmetric_channels:1; unsigned int symmetric_samplebits:1; unsigned int probed:1; unsigned int active; unsigned char probed:1; struct snd_soc_dapm_widget *playback_widget; struct snd_soc_dapm_widget *capture_widget; Loading
include/sound/soc.h +8 −7 Original line number Diff line number Diff line Loading @@ -1029,13 +1029,13 @@ struct snd_soc_dai_link { const struct snd_soc_ops *ops; const struct snd_soc_compr_ops *compr_ops; /* For unidirectional dai links */ bool playback_only; bool capture_only; /* Mark this pcm with non atomic ops */ bool nonatomic; /* For unidirectional dai links */ unsigned int playback_only:1; unsigned int capture_only:1; /* Keep DAI active over suspend */ unsigned int ignore_suspend:1; Loading Loading @@ -1206,14 +1206,11 @@ struct snd_soc_pcm_runtime { enum snd_soc_pcm_subclass pcm_subclass; struct snd_pcm_ops ops; unsigned int dev_registered:1; /* Dynamic PCM BE runtime data */ struct snd_soc_dpcm_runtime dpcm[2]; int fe_compr; long pmdown_time; unsigned char pop_wait:1; /* runtime devices */ struct snd_pcm *pcm; Loading @@ -1234,6 +1231,10 @@ struct snd_soc_pcm_runtime { unsigned int num; /* 0-based and monotonic increasing */ struct list_head list; /* rtd list of the soc card */ /* bit field */ unsigned int dev_registered:1; unsigned int pop_wait:1; }; /* mixer control */ Loading
sound/soc/atmel/Kconfig +10 −0 Original line number Diff line number Diff line Loading @@ -78,4 +78,14 @@ config SND_ATMEL_SOC_PDMIC help Say Y if you want to add support for Atmel ASoC driver for boards using PDMIC. config SND_ATMEL_SOC_TSE850_PCM5142 tristate "ASoC driver for the Axentia TSE-850" depends on ARCH_AT91 && OF depends on ATMEL_SSC && I2C select SND_ATMEL_SOC_SSC_DMA select SND_SOC_PCM512x_I2C help Say Y if you want to add support for the ASoC driver for the Axentia TSE-850 with a PCM5142 codec. endif