Skip to content

Commit

Permalink
ASoC: max98504: Add max98504 speaker amplifier driver
Browse files Browse the repository at this point in the history
This patch adds driver for the MAX98504 speaker amplifier.  The MAX98504
is a high efficiency mono class D amplifier that features an integrated
boost converter with voltage and current sensing ADCs for Dynamic Speaker
Management.
This driver does not include support for the I2S DAI, as we wouldn't be
able  to test such code in a hardware configuration where the amplifier
has only wired the analogue input.

Signed-off-by: Inha Song <ideal.song@samsung.com>
[k.kozlowski: rebased on 4.1]
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
[s.nawrocki: removed unused macro definitions, rewrote regulator supply
 related parts, rewrote regmap configuration code, added support for speaker
 enable and global chip enable through DAPM, rewritten as component driver,
 added PDM DAI definition and TDM callbacks for PDM channels configuration]
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
--
Changes since v2:
 - added parsing of the VBAT brownout DT properties,
 - removed MAX98504_REG_SPEAKER_SOURCE_SELECT register initialization,
 - removed unused macro definitions.

Changes since v1:
 - none.

Changes since initial version:
 - added regulator supply handling,
 - added DAPM widges for speaker source selection,
 - added PDM DAI definition and TDM callbacks for setting up active
   PDM Tx channels and I/V sense ADC data mapping,
 - removed all optional DT properties, added regulator supply properties
   in the DT binding.
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Sylwester Nawrocki authored and Mark Brown committed Jun 29, 2016
1 parent 1a695a9 commit 4c5d146
Show file tree
Hide file tree
Showing 4 changed files with 448 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sound/soc/codecs/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,10 @@ config SND_SOC_MAX98357A
config SND_SOC_MAX98371
tristate

config SND_SOC_MAX98504
tristate "Maxim MAX98504 speaker amplifier"
depends on I2C

config SND_SOC_MAX9867
tristate

Expand Down
2 changes: 2 additions & 0 deletions sound/soc/codecs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ snd-soc-wm-hubs-objs := wm_hubs.o

# Amp
snd-soc-max9877-objs := max9877.o
snd-soc-max98504-objs := max98504.o
snd-soc-tpa6130a2-objs := tpa6130a2.o
snd-soc-tas2552-objs := tas2552.o

Expand Down Expand Up @@ -419,4 +420,5 @@ obj-$(CONFIG_SND_SOC_WM_HUBS) += snd-soc-wm-hubs.o

# Amp
obj-$(CONFIG_SND_SOC_MAX9877) += snd-soc-max9877.o
obj-$(CONFIG_SND_SOC_MAX98504) += snd-soc-max98504.o
obj-$(CONFIG_SND_SOC_TPA6130A2) += snd-soc-tpa6130a2.o
Loading

0 comments on commit 4c5d146

Please sign in to comment.