ASoC: codecs: lpass-wsa-macro: Add support to WSA Macro

Qualcomm LPASS (Low Power Audio SubSystem) has internal codec
WSA macro block which is used for connecting with WSA Smart
speakers over soundwire.

This patch adds support to the codec part of the WSA Macro block.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20201105113458.12360-3-srinivas.kandagatla@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Srinivas Kandagatla 2020-11-05 11:34:54 +00:00 committed by Mark Brown
parent ccbd847f15
commit 809bcbcece
No known key found for this signature in database
GPG Key ID: 24D68B725D5487D0
4 changed files with 1406 additions and 0 deletions

View File

@ -1789,4 +1789,8 @@ config SND_SOC_TPA6130A2
tristate "Texas Instruments TPA6130A2 headphone amplifier"
depends on I2C
config SND_SOC_LPASS_WSA_MACRO
depends on COMMON_CLK
tristate "Qualcomm WSA Macro in LPASS(Low Power Audio SubSystem)"
endmenu

View File

@ -103,6 +103,7 @@ snd-soc-l3-objs := l3.o
snd-soc-lm4857-objs := lm4857.o
snd-soc-lm49453-objs := lm49453.o
snd-soc-lochnagar-sc-objs := lochnagar-sc.o
snd-soc-lpass-wsa-macro-objs := lpass-wsa-macro.o
snd-soc-madera-objs := madera.o
snd-soc-max9759-objs := max9759.o
snd-soc-max9768-objs := max9768.o
@ -615,3 +616,4 @@ obj-$(CONFIG_SND_SOC_MAX9877) += snd-soc-max9877.o
obj-$(CONFIG_SND_SOC_MAX98504) += snd-soc-max98504.o
obj-$(CONFIG_SND_SOC_SIMPLE_AMPLIFIER) += snd-soc-simple-amplifier.o
obj-$(CONFIG_SND_SOC_TPA6130A2) += snd-soc-tpa6130a2.o
obj-$(CONFIG_SND_SOC_LPASS_WSA_MACRO) += snd-soc-lpass-wsa-macro.o

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,17 @@
/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __LPASS_WSA_MACRO_H__
#define __LPASS_WSA_MACRO_H__
/*
* Selects compander and smart boost settings
* for a given speaker mode
*/
enum {
WSA_MACRO_SPKR_MODE_DEFAULT,
WSA_MACRO_SPKR_MODE_1, /* COMP Gain = 12dB, Smartboost Max = 5.5V */
};
int wsa_macro_set_spkr_mode(struct snd_soc_component *component, int mode);
#endif /* __LPASS_WSA_MACRO_H__ */