ASoC: max98390: Added Amplifier Driver
PATCH v6 2/2 ASoC: max98390: Added Amplifier Driver
This is the initial amplifier driver for max98390.
---
Changes since V5:
* Fixed warning message reported by kbuild.
* Finalize default register value.
* Update missed AMP_EN register setting during dsm_init.
* Modified SPDEX header style.
Changes since V4:
* Revert return calibration status in max98390_dsm_calib_get:
There is no need to return calibration status in get function because there is mixer control lock protecting mixer control access. And set function of DSM calib finishes calibration synchronously.
* Fix sprintf in max98390_dsm_init func:
Use snprintf to avoid any unreasonable value from DMI.
Changes since V3:
* Add operation at max98390_dsm_calib_get:
Add cal_running variable at max98390_priv structure Add return cal_running at max98390_dsm_calib_get Update cal_running value during calibration
* Update max98390_dsm_init func
Add dsm_param bin name can select upon vendor and product name.
Changes since V2:
* Removed warn massage in max98390_dsm_calib_get func
and add comment.
Changes since V1:
* Updated according to Mark's comments.
* Updated according to Tzung-Bi's comments.
* Removed Enum structure and use TLV data for Volume control
sound/soc/codecs/Kconfig | 5 + sound/soc/codecs/Makefile | 2 + sound/soc/codecs/max98390.c | 1041 +++++++++++++++++++++++++++++++++++ sound/soc/codecs/max98390.h | 663 ++++++++++++++++++++++ 4 files changed, 1711 insertions(+) create mode 100644 sound/soc/codecs/max98390.c create mode 100644 sound/soc/codecs/max98390.h
sound/soc/codecs/Kconfig +5 -0
@@ -116,6 +116,7 @@ config SND_SOC_ALL_CODECS imply SND_SOC_MAX98926 imply SND_SOC_MAX98927 imply SND_SOC_MAX98373 + imply SND_SOC_MAX98390 imply SND_SOC_MAX9850 imply SND_SOC_MAX9860 imply SND_SOC_MAX9759
@@ -867,6 +868,10 @@ config SND_SOC_MAX98373 tristate "Maxim Integrated MAX98373 Speaker Amplifier" depends on I2C +config SND_SOC_MAX98390 + tristate "Maxim Integrated MAX98390 Speaker Amplifier" + depends on I2C + config SND_SOC_MAX9850 tristate depends on I2C
sound/soc/codecs/Makefile +2 -0
@@ -115,6 +115,7 @@ snd-soc-max98925-objs := max98925.o snd-soc-max98926-objs := max98926.o snd-soc-max98927-objs := max98927.o snd-soc-max98373-objs := max98373.o +snd-soc-max98390-objs := max98390.o snd-soc-max9850-objs := max9850.o snd-soc-max9860-objs := max9860.o snd-soc-mc13783-objs := mc13783.o
@@ -415,6 +416,7 @@ obj-$(CONFIG_SND_SOC_MAX98925) += snd-soc-max98925.o obj-$(CONFIG_SND_SOC_MAX98926) += snd-soc-max98926.o obj-$(CONFIG_SND_SOC_MAX98927) += snd-soc-max98927.o obj-$(CONFIG_SND_SOC_MAX98373) += snd-soc-max98373.o +obj-$(CONFIG_SND_SOC_MAX98390) += snd-soc-max98390.o obj-$(CONFIG_SND_SOC_MAX9850) += snd-soc-max9850.o obj-$(CONFIG_SND_SOC_MAX9860) += snd-soc-max9860.o obj-$(CONFIG_SND_SOC_MC13783) += snd-soc-mc13783.o
sound/soc/codecs/max98390.c new file +1041 -0
1,041 lines not on this page · raw message
sound/soc/codecs/max98390.h new file +663 -0
663 lines not on this page · raw message
Signature · 1 line
2.17.1
Mark Brown
maintainerQuoted 1 line · Steve Lee
This is the initial amplifier driver for max98390.
Please do not submit new versions of already applied patches, please submit incremental updates to the existing code. Modifying existing commits creates problems for other users building on top of those commits so it's best practice to only change pubished git commits if absolutely essential.
Quoted 1 line
Reported-by kbuild test robot <[email protected]>
Don't think the lkp bot asked for this driver! :P
Quoted 10 lines · Mark Brown
Quoted 1 line · Steve Lee
This is the initial amplifier driver for max98390.
Please do not submit new versions of already applied patches, please submit incremental updates to the existing code. Modifying existing commits creates problems for other users building on top of those commits so it's best practice to only change pubished git commits if absolutely essential.
Thanks for feedback. I will send incremental patches.
Quoted 3 lines
Quoted 1 line
Reported-by kbuild test robot <[email protected]>Don't think the lkp bot asked for this driver! :P
Thanks, I will send split patch for this.
Mark Brown
maintainerQuoted 7 lines · Steve Lee
Quoted 3 lines · Mark Brown
Quoted 1 line
Reported-by kbuild test robot <[email protected]>Don't think the lkp bot asked for this driver! :P
Thanks, I will send split patch for this.
No, just don't add the line when it's a new driver.
Quoted 11 lines · Mark Brown
Quoted 7 lines · Steve Lee
Quoted 3 lines · Mark Brown
Quoted 1 line
Reported-by kbuild test robot <[email protected]>Don't think the lkp bot asked for this driver! :P
Thanks, I will send split patch for this.
No, just don't add the line when it's a new driver.
Now I understand, thanks for guide.