summaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/max98357a.c
Commit message (Collapse)AuthorAgeFilesLines
* ASoC: max98357a: replace codec to componentKuninori Morimoto2018-02-121-14/+15
| | | | | | | | | | | | | | Now we can replace Codec to Component. Let's do it. Note: xxx_codec_xxx() -> xxx_component_xxx() .idle_bias_off = 0 -> .idle_bias_on = 1 .ignore_pmdown_time = 0 -> .use_pmdown_time = 1 - -> .endianness = 1 - -> .non_legacy_dai_naming = 1 Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: codecs: add const to snd_soc_codec_driver structuresBhumika Goyal2017-08-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle: @match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...}; @good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&s@p,...) @bad@ identifier match.s; position p!={match.p,good1.p}; @@ s@p @depends on !bad disable optional_qualifier@ identifier match.s; @@ static +const struct snd_soc_codec_driver s={...}; Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: codec duplicated callback function goes to component on wm98357aKuninori Morimoto2016-08-081-4/+6
| | | | | | | | | | codec driver and component driver has duplicated callback functions, and codec side functions are just copied to component side when register timing. This was quick-hack, but no longer needed. This patch moves these functions from codec driver to component driver. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: max98357a: Add ACPI ID for MaximRohit Ainapure2015-12-181-0/+10
| | | | | | | | | Adding ACPI ID "MX98357A" for the MAXIM 98357A amp. Signed-off-by: Rohit Ainapure <rohit.m.ainapure@intel.com> Signed-off-by: Fang, Yang A <yang.a.fang@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
*-. Merge remote-tracking branches 'asoc/topic/max98090', 'asoc/topic/max98095', ↵Mark Brown2015-08-301-15/+8
|\ \ | | | | | | | | | 'asoc/topic/max98357a', 'asoc/topic/max9877' and 'asoc/topic/max98925' into asoc-next
| | * ASoC: max98357a: Do not print error message on asoc/gpio errorsAnatol Pomozov2015-07-131-12/+3
| | | | | | | | | | | | | | | | | | | | | gpiolib/asoc system already prints enough info if there are any problems. Signed-off-by: Anatol Pomozov <anatol.pomozov@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
| | * ASoC: max98357a: Use DAI input as a dapm widgetAnatol Pomozov2015-07-131-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Spec does not say anything about DAC called SDMode. It makes more sense to use DAI input that created automatically by DAPM and route it to Speaker output. Signed-off-by: Anatol Pomozov <anatol.pomozov@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
| | * ASoC: max98357a: Make 'sdmode-gpios' dts property optionalAnatol Pomozov2015-07-131-1/+4
| |/ | | | | | | | | | | | | | | The option is not needed if chip is always on or managed by some other part of system like platform card driver. Signed-off-by: Anatol Pomozov <anatol.pomozov@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
* | ASoC: Constify snd_soc_dai_ops variablesAxel Lin2015-07-151-1/+1
|/ | | | | | | | The snd_soc_dai_ops variables are not modified after initialization in these drivers, so make them const. Signed-off-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: max98357a: use flags argument of devm_gpiod_get to set directionUwe Kleine-König2015-05-201-2/+1
| | | | | | | | | | | | | Since 39b2bbe3d715 (gpio: add flags argument to gpiod_get*() functions) which appeared in v3.17-rc1, the gpiod_get* functions take an additional parameter that allows to specify direction and initial value for output. Use this to simplify the driver. Furthermore this is one caller less that stops us making the flags argument to gpiod_get*() mandatory. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: Kenneth Westfield <kwestfie@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: max98357a: Use standard DAI namesKenneth Westfield2015-02-261-2/+2
| | | | | | | Use the standard naming convention for the codec DAI. Signed-off-by: Kenneth Westfield <kwestfie@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: max98357a: Remove use of DRV_NAMEKenneth Westfield2015-02-211-7/+4
| | | | | | | Remove use of DRV_NAME define. Signed-off-by: Kenneth Westfield <kwestfie@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: max98357a: Add missing header filesKenneth Westfield2015-02-211-1/+10
| | | | | | | | Add missing header files to avoid implicit declarations and indirect inclusions. Signed-off-by: Kenneth Westfield <kwestfie@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: max98357a: Fix missing includeVincent Stehlé2015-02-121-0/+1
| | | | | | | | | | | | | | | | This fixes the following compilation errors: sound/soc/codecs/max98357a.c: In function ‘max98357a_daiops_trigger’: sound/soc/codecs/max98357a.c:30:3: error: implicit declaration of function ‘gpiod_set_value’ [-Werror=implicit-function-declaration] sound/soc/codecs/max98357a.c: In function ‘max98357a_codec_probe’: sound/soc/codecs/max98357a.c:55:2: error: implicit declaration of function ‘devm_gpiod_get’ [-Werror=implicit-function-declaration] sound/soc/codecs/max98357a.c:61:2: error: implicit declaration of function ‘gpiod_direction_output’ [-Werror=implicit-function-declaration] cc1: some warnings being treated as errors Signed-off-by: Vincent Stehlé <vincent.stehle@laposte.net> Cc: Kenneth Westfield <kwestfie@codeaurora.org> Cc: Mark Brown <broonie@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: max98357a: Fix build in !CONFIG_OF caseMark Brown2015-02-091-1/+1
| | | | | Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Mark Brown <broonie@kernel.org>
* ASoC: max98357a: Add MAX98357A codec driverKenneth Westfield2015-02-071-0/+138
Add codec driver for the Maxim MAX98357A DAC. Signed-off-by: Kenneth Westfield <kwestfie@codeaurora.org> Acked-by: Banajit Goswami <bgoswami@codeaurora.org> Signed-off-by: Mark Brown <broonie@kernel.org>
OpenPOWER on IntegriCloud