summaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/max98926.c
AgeCommit message (Collapse)AuthorFilesLines
2022-06-27ASoC: max*: Remove now redundant non_legacy_dai_naming flagCharles Keepax1-1/+0
The ASoC core has now been changed to default to the non-legacy DAI naming, as such drivers using the new scheme no longer need to specify the non_legacy_dai_naming flag. Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20220623125250.2355471-53-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
2022-04-11ASoC: max9*: use simple i2c probe functionStephen Kitt1-3/+2
The i2c probe functions here don't use the id information provided in their second argument, so the single-parameter i2c probe function ("probe_new") can be used instead. This avoids scanning the identifier tables during probes. Signed-off-by: Stephen Kitt <steve@sk2.org> Link: https://lore.kernel.org/r/20220405165836.2165310-6-steve@sk2.org Signed-off-by: Mark Brown <broonie@kernel.org>
2022-02-28ASoC: max98926: Use modern ASoC DAI format terminologyMark Brown1-2/+2
As part of moving to remove the old style defines for the bus clocks update the max98926 driver to use more modern terminology for clocking. Signed-off-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20220222234026.712070-9-broonie@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2020-11-26ASoC: max98926: drop driver pm=NULL assignmentKrzysztof Kozlowski1-1/+0
There is no point to explicitly set driver .pm field to NULL. Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Link: https://lore.kernel.org/r/20201125164452.89239-39-krzk@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2020-11-26ASoC: max98926: skip of_device_id table when !CONFIG_OFKrzysztof Kozlowski1-0/+2
The driver can match by multiple methods. Its of_device_id table is referenced via of_match_ptr() so it will be unused for !CONFIG_OF builds: sound/soc/codecs/max98926.c:574:34: warning: ‘max98926_of_match’ defined but not used [-Wunused-const-variable=] Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Link: https://lore.kernel.org/r/20201125164452.89239-27-krzk@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org>
2019-08-09ASoC: max98926: remove two unused variablesYueHaibing1-9/+0
sound/soc/codecs/max98926.c:28:26: warning: max98926_dai_txt defined but not used [-Wunused-const-variable=] sound/soc/codecs/max98926.c:23:27: warning: max98926_boost_current_txt defined but not used [-Wunused-const-variable=] They are never used, so can be removd. Reported-by: Hulk Robot <hulkci@huawei.com> Signed-off-by: YueHaibing <yuehaibing@huawei.com> Link: https://lore.kernel.org/r/20190808143215.65904-1-yuehaibing@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-19treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500Thomas Gleixner1-3/+1
Based on 2 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation # extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 4122 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Enrico Weigelt <info@metux.net> Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by: Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190604081206.933168790@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-02-12ASoC: max98926: replace codec to componentKuninori Morimoto1-30/+26
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>
2017-11-27ASoC: don't use codec hw_write on max98926Kuninori Morimoto1-1/+1
max98926 driver is using codec hw_write/control_data, but it is redundant code. This patch cleanup these Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-09-01Merge remote-tracking branches 'asoc/topic/kirkwood', 'asoc/topic/max9867', ↵Mark Brown1-2/+2
'asoc/topic/max98926' and 'asoc/topic/max98927' into asoc-next
2017-08-18ASoC: codecs: constify snd_soc_dai_ops structuresArvind Yadav1-1/+1
snd_soc_dai_ops are not supposed to change at runtime. All functions working with snd_soc_dai_ops provided by <sound/soc-dai.h> work with const snd_soc_dai_ops. So mark the non-const structs as const. Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-08-14ASoC: max98926: make max98926_spk_tlv and max98926_current_tlv staticColin Ian King1-2/+2
max98926_spk_tlv and max98926_current_tlv are local to the source and do not need to be in global scope, so make them static. Cleans up sparse warnings: symbol 'max98926_spk_tlv' was not declared. Should it be static? symbol 'max98926_current_tlv' was not declared. Should it be static? Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2017-08-10ASoC: codecs: add const to snd_soc_codec_driver structuresBhumika Goyal1-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>
2017-07-17ASoC: max98926: constify snd_soc_dai_ops structureGustavo A. R. Silva1-1/+1
This structure is only stored in the ops field of a snd_soc_dai_driver structure. That field is declared const, so snd_soc_dai_ops structures that have this property can be declared as const also. Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-09-29Merge remote-tracking branches 'asoc/topic/max98371', 'asoc/topic/max9867', ↵Mark Brown1-3/+3
'asoc/topic/max98926' and 'asoc/topic/mtk' into asoc-next
2016-09-24ASoC: max98926: add missing \n to end of dev_err/dev_dbg messagesColin Ian King1-3/+3
Trival fix, some dev_err and deb_dbg messages are missing a \n, so add it. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-08-08ASoC: codec duplicated callback function goes to component on max98926Kuninori Morimoto1-6/+8
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>
2016-02-21ASoC: max98926: Constify max98926_reg and max98926_regmapAxel Lin1-2/+2
Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: anish kumar <yesanishhere@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-02-17ASoC: max98926: Fix blr_clk_ratio calculationAxel Lin1-2/+4
Current code calculates blr_clk_ratio before setting max98926->ch_size, fix it. Signed-off-by: Axel Lin <axel.lin@ingics.com> Acked-by: anish kumar <yesanishhere@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
2016-01-27ASoC: Add max98926 codec driveranish kumar1-0/+604
Signed-off-by: anish kumar <yesanishhere@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>