summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/wm_hubs.h
AgeCommit message (Collapse)AuthorFilesLines
2021-03-11ASoC: wm_hubs: align function prototypePierre-Louis Bossart1-1/+1
cppcheck warnings: sound/soc/codecs/wm_hubs.c:1194:11: style:inconclusive: Function 'wm_hubs_handle_analogue_pdata' argument 8 names different: declaration 'micbias1_dly' definition 'micbias1_delay'. [funcArgNamesDifferent] int micbias1_delay, int micbias2_delay, ^ sound/soc/codecs/wm_hubs.h:59:11: note: Function 'wm_hubs_handle_analogue_pdata' argument 8 names different: declaration 'micbias1_dly' definition 'micbias1_delay'. int micbias1_dly, int micbias2_dly, ^ sound/soc/codecs/wm_hubs.c:1194:11: note: Function 'wm_hubs_handle_analogue_pdata' argument 8 names different: declaration 'micbias1_dly' definition 'micbias1_delay'. int micbias1_delay, int micbias2_delay, ^ sound/soc/codecs/wm_hubs.c:1194:31: style:inconclusive: Function 'wm_hubs_handle_analogue_pdata' argument 9 names different: declaration 'micbias2_dly' definition 'micbias2_delay'. [funcArgNamesDifferent] int micbias1_delay, int micbias2_delay, ^ sound/soc/codecs/wm_hubs.h:59:29: note: Function 'wm_hubs_handle_analogue_pdata' argument 9 names different: declaration 'micbias2_dly' definition 'micbias2_delay'. int micbias1_dly, int micbias2_dly, ^ sound/soc/codecs/wm_hubs.c:1194:31: note: Function 'wm_hubs_handle_analogue_pdata' argument 9 names different: declaration 'micbias2_dly' definition 'micbias2_delay'. int micbias1_delay, int micbias2_delay, ^ Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20210311004332.120901-11-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
2020-09-01ASoC: wm8994: Skip setting of the WM8994_MICBIAS register for WM1811Sylwester Nawrocki1-0/+1
The WM8994_MICBIAS register is not available in the WM1811 CODEC so skip initialization of that register for that device. This suppresses an error during boot: "wm8994-codec: ASoC: error at snd_soc_component_update_bits on wm8994-codec" Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Acked-by: Krzysztof Kozlowski <krzk@kernel.org> Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com> Link: https://lore.kernel.org/r/20200827173357.31891-1-s.nawrocki@samsung.com Signed-off-by: Mark Brown <broonie@kernel.org>
2019-06-19treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500Thomas Gleixner1-5/+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: wm8993/wm8994/wm8958: replace codec to componentKuninori Morimoto1-9/+9
Now we can replace Codec to Component. Let's do it. Becase wm8993/wm8994/wm8958 are using wm_hubs feature, we need to update these all related drivers in same time. Otherwise compile error/warning happen wm8993: 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 wm8994: 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>
2012-08-22ASoC: wm_hubs: Allow configuration of MICBIAS power up delay via pdataMark Brown1-0/+4
Sometimes the analogue circuitry connected to the microphone needs some time to settle after power up. Allow systems to configure this delay in the platform data, the driver will then insert the required delay during power up of paths that involve the microphone. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-08-04ASoC: wm_hubs: Move CODEC stored in private data into wm_hubsMark Brown1-0/+2
Further wm_hubs code will use this. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-05-01ASoC: wm_hubs: Cache multiple DCS offsetsMark Brown1-1/+2
Rather than invalidating the cached DCS value every time the headphone gain changes store multiple values, indexed by gain. This allows the optimisation we get from the cache to take effect more often. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-04-27ASoC: wm_hubs: Factor out class W managementMark Brown1-0/+6
Since the analogue portions of the checks for class W are the same over all the devices factor out these checks into wm_hubs and while we're at it also use wm_hubs_dac_hp_direct() to enable class W optimisations on more paths. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-04-27ASoC: wm_hubs: Special case headphones for digital paths in more use casesMark Brown1-3/+2
The optimisations which we can do with caching the headphone DCS result in wm_hubs have only been enabled in cases where class W is enabled. However, there are more use cases which can benefit from the cache, especially with WM8994 series devices with their more advanced digital routing. Rather than keying off the class W information from the CODECs have a check in wm_hubs for a suitable path and use that to determine if we can deploy our headphone optimisations. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-03-04ASoC: wm_hubs: Disable cache of the DC servo calibration for WM1811Mark Brown1-0/+1
The WM1811 DC servo is able to run much faster than previous devices so the benefit of skipping calibration is not useful. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2012-02-12ASoC: wm_hubs: Improve single ended line output enable performanceMark Brown1-0/+11
The enable of the single ended line outputs on wm_hubs devices performs better if the output is enabled prior to starting VMID. Since inactive outputs are held at VMID anyway there is little cost to doing this for unused outputs. Add callbacks into wm_hubs and keep track of which outputs are really active so we can disable them once we're active. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-08-01ASoC: Support separate left and right channel dcs_codes valuesMark Brown1-1/+2
Some devices can have performance optimized by setting different offsets for left and right channels. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
2011-07-13ASoC: Implement DC servo completion IRQ handling for wm_hubs devicesMark Brown1-0/+8
The individual devices should set the flag dcs_done_irq in the hubs shared data structure to indicate that they will flag the interrupt by calling wm_hubs_dcs_done(). Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2011-06-23ASoC: Allow suppression of series updates on wm_hubs devicesMark Brown1-0/+1
Some devices do not support manual updates of the DC servo. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
2011-06-23ASoC: Trigger wm_hubs series update startup off a separate flagMark Brown1-0/+1
Allowing the two to be used independently. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
2010-10-28ASoC: Store DC offset correction for wm_hubs devices in class W modeMark Brown1-0/+3
Providing the analogue configuration of the output path remains the same the DC offset corrected by the DC servo will remain identical so we can skip the callibration, reducing the startup time for the headphone output. Implement this for the wm_hubs devices as has been done for several other CODECs. Don't do this if we have any analogue paths enabled since offsets may be being introduced by the analogue paths which could vary outside the control of the driver. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-04-05ASoC: Support second DC servo readback method for wm_hubsMark Brown1-0/+1
More recent Wolfson hubs devices add the ability to read back the DC servo calibration information from the register used to write offsets, and later still ones remove the old readback registers. Add support for the new scheme, and use it for WM8994 device revisions that support it. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2010-02-01ASoC: Improved wm_hubs headphone handlingMark Brown1-0/+6
Perform DC servo offset calibration using a series update sequence rather than startup update sequence, tuning the configuration of the WM8993 DC servo to make best use of this. Also introduce currently unused data allowing us to correct for any systematic errors in the DC servo calibration results and an alternative startup path for the headphone output which performs better with some chip revisions. The alternative setup sequence is enabled for WM8993. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
2009-09-30ASoC: Factor out analogue platform data from WM8993Mark Brown1-0/+5
This is also shared with newer CODECs. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-08-14ASoC: Factor out shared code from WM8993Mark Brown1-0/+24
The WM8993 analogue control is shared with other devices in the same product line. Since this is a very substantial proportion of the driver move the definitions of these controls into a new wm_hubs module which allows them to be shared between the two. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>