aboutsummaryrefslogtreecommitdiffstats
path: root/sound
Commit message (Collapse)AuthorAgeFilesLines
...
* ASoC: wm8994: Actively discharge VMID when not in useMark Brown2016-04-301-0/+4
| | | | | | Ensure we're in a known state when we restart. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: wm8994: VMID management improvementsMark Brown2016-04-301-1/+14
| | | | | | | | | Raise the ramp time to 50ms to cover corner cases, use the startup bias generator, explicitly reset the ramp circuit when complete and reorder things all of which should improve performance somewhat for systems that are sensitive to noise from VMID. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: wm_hubs: Improve single ended line output enable performanceMark Brown2016-04-304-8/+125
| | | | | | | | | | 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>
* ASoC: wm_hubs: Convert most output drivers to OUT_DRV widgetsMark Brown2016-04-301-12/+12
| | | | | | | No practical impact but now we have the control type we may as well use it for the slightly nicer sequencing. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: wm8994: Fix typo in VMID ramp settingMark Brown2016-04-301-1/+1
| | | | | | | The VMID ramp rate is supposed to be 0x3, not 11b. Fix that. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@vger.kernel.org
* ASoC: wm_hubs: Push check for idle_bias_off out into driversMark Brown2016-04-303-6/+14
| | | | | | | | For later wm_hubs devices we have much less need to keep the biases up even when using single ended line outputs so flag idle_bias_off for everything except the WM8993 and WM8994. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: wm8994: Enabling VMID should take a runtime PM referenceMark Brown2016-04-301-0/+4
| | | | | | | | We can enable VMID independently of the bias in some use cases so we need to ensure that the core device is powered up. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@vger.kernel.org
* ASoC: Mark WM8994 ADC muxes as virtualMark Brown2016-04-301-6/+6
| | | | | | | | Since they don't actually have power bits but do have events associated with them it's important that we bootstrap their state properly which making them virtual does. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Add platform data for WM8958/WM1811 microphone detection ratesMark Brown2016-04-301-8/+4
| | | | | | | | Allow systems to override the default microphone detection rates using platform data in case the settings are not suitable (eg, due to an unusually noisy jack). Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Ensure we reconfigure WM8958 microphone detection on rate changesMark Brown2016-04-301-4/+2
| | | | | | | | We don't need to rerun DAPM if the clock source is the same but we do need to adjust the microphone detection rate in case we are moving from an audio to a non-audio rate. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Implement support for WM1811A jack detectionMark Brown2016-04-302-19/+249
| | | | | | | | | | | The WM1811A features an advanced low power accessory detection subsystem which allows the device to be maintained in a very low power state while the system is idle without sacrificing any accessory detection features. Implement software support for this, automatically managing the power configuration of the device depending on the detected accessory. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Rename WM8994 detecting flag to mic_detectingMark Brown2016-04-302-7/+7
| | | | | | More specific and avoids confusion with a following change. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Allow more WM8958/WM1811 button levels with default handlerMark Brown2016-04-302-8/+35
| | | | | | | | The WM8958 and WM1811 support detecting a range of buttons. Allow the user to provide platform data enabling more of these levels without having to write a custom detection handler. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Tune down active mode detection rate for WM8958 mic detectionMark Brown2016-04-301-2/+2
| | | | | | Saves a little power. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Provide debug log of accessory status on WM8958Mark Brown2016-04-301-0/+2
| | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Enhance default WM8958 microphone detectionMark Brown2016-04-302-11/+111
| | | | | | | | Actively manage the detection rate for microphones with WM8958, providing improved power consumption and maximising the benefit from the hardware debounce. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Put WM8958 and WM1811 MICBIAS into bypass mode when no audioMark Brown2016-04-301-1/+39
| | | | | | | When we don't have any active audio we can put the microphone biases into bypass mode to save power at the expense of performance. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Ensure SYSCLK is enabled for WM8958 accessory detectionMark Brown2016-04-301-0/+3
| | | | | | | | Ensure SYSCLK is enabled while running accessory detection on WM8958. It is always required so there is no sense in requiring machine drivers to individually do this. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Supply dcs_codes for newer WM1811 revisionsMark Brown2016-04-301-0/+2
| | | | | | Based on initial data. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Ensure we get an impedence reported for WM8958 jack detectMark Brown2016-04-301-11/+26
| | | | | | | | | Occasionally we may see an accessory reported before we have a stable impedance for the accessory. If this happens then reread the status in order to ensure that the handler can take the appropriate action for the status change. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Don't use wm8994->control_data when requesting IRQsMark Brown2016-04-301-2/+2
| | | | | | | | The field is no longer initialised so this will crash if running on wm8958. Reported-by: Thomas Abraham <thomas.abraham@linaro.org> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Update WM1811 DCS codes for latest evaluation resultsMark Brown2016-04-301-2/+2
| | | | | | | | Evaluation of larger quantities of material has provided new DCS codes values to be applied for WM1811. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* ASoC: Remove impossible case from wm8994_hw_paramsAxel Lin2016-04-301-10/+0
| | | | | | | | We set hw_params callback for wm8994_aif3_dai_ops to wm8994_aif3_hw_params. Thus no need to check wm8994-aif3 in wm8994_hw_params. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: wm8994: Slightly optimize configure_clockAxel Lin2016-04-301-7/+4
| | | | | | | | | | snd_soc_update_bits() will only write new register value if the old value is different from the new value. In additional, snd_soc_update_bits() returns 0 for no change. No need to read WM8994_CLOCKING_1 register before calling snd_soc_update_bits(). Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Add WM1811 supportMark Brown2016-04-301-5/+78
| | | | | | | | The WM1811 is mostly register compatible with the WM8994 and WM8958, providing a high performance audio hub CODEC in a small form factor suitable for ultra compact system designs. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Fix backport of WM8994 thermal warningMark Brown2016-04-301-2/+2
| | | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
* ASoC: Implement WM8994 thermal warning and shutdown interrupt supportMark Brown2016-04-301-0/+26
| | | | | | | ALSA doesn't really have good mechanisms for dealing with these so we just log them - the hardware already has automatic shutdown support. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Add WM8958 noise gate supportMark Brown2016-04-302-6/+44
| | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Disable pulls on WM8994 AIF2 when starting itMark Brown2016-04-301-0/+16
| | | | | | | | | | Pull control is availalbe for WM8994 AIF2, generally disabled as part of the GPIO configuration in order to save power after system startup. As on newer devices in the series there is no GPIO functionality on these pins this will happen less naturally so have the driver disable the pulls as the AIF is probed. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Disable WM8994 VMID for digital only pathsMark Brown2016-04-302-56/+129
| | | | | | | | | | | On WM8994 class devices only the analogue portions of the CODEC require VMID so when running digital only paths we can leave VMID disabled. On some earlier devices the FLL uses VMID so we don't use DAPM reference counting alone, we maintain an internal reference count which is also enabled and disabled by the FLL startup. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* ASoC: Handle failed WM8994 FLL lock waitsMark Brown2016-04-301-0/+3
| | | | | | | | Try the completion before we start the FLL so that if an interrupt was delayed long enough for us to miss it we don't wait for the completion it signalled. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Log WM8994 FIFO errors from the interruptMark Brown2016-04-301-0/+14
| | | | | | | We should spot them anyway on state changes but logging them gives us better time information about when the misconfiguration happened. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Don't warn on low WM8994/58 AIFnCLKsMark Brown2016-04-301-4/+0
| | | | | | We can have valid but very low clocks in accessory detection modes. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Use WM8994 FLL lock interruptMark Brown2016-04-302-1/+42
| | | | | | | If we have interrupts then wait for the FLL lock interrupt rather than using dead reckoning when waiting for the FLL to start. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Hook up DC servo completion IRQ for WM8994 and WM8958Mark Brown2016-04-301-0/+11
| | | | Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Conditionalize the enable of WM8994 ADC TDM modeMark Brown2016-04-301-4/+12
| | | | | | | Future devices will not benefit from this. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* ASoC: Add missing break in WM8994 probeMark Brown2016-04-301-0/+1
| | | | | | | | This error would have no effect on current silicon revisions, the fall through case has the same behaviour. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* ASoC: wm_hubs: Enable line out VMID buffer for single ended line outputsMark Brown2016-04-301-0/+2
| | | | | | | | For optimal performance the single ended line outputs require that the line output VMID buffer be enabled. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@vger.kernel.org
* ASoC: Disable thermal shutdown when not using speakers in wm_hubsMark Brown2016-04-301-0/+3
| | | | | | | | | | The thermal shutdown support in wm_hubs devices is tied to the speaker drivers (which are the only high power subsystems within the device). Ensure minimal current usage when the thermal shutdown support is not required by disabling the circuit when the speaker drivers are powered down. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Add VMID widget for wm_hubs devicesMark Brown2016-04-303-0/+23
| | | | | | | | | Currently this does not actually do anything, it is being introduced in order to facilitate additional power optimisations for current generation devices. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* ASoC: Support separate left and right channel dcs_codes valuesMark Brown2016-04-304-9/+13
| | | | | | | | 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>
* ASoC: Implement new DC servo readback mode for late WM8994 revisionsMark Brown2016-04-302-5/+17
| | | | | | | | | Later WM8994 devices implement a new DC servo readback mode with the register used to access the offset moved to register 0x59. Implement support for this and enable it on the appropriate devices. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* ASoC: Disable wm_hubs periodic DC servo updateMark Brown2016-04-301-2/+1
| | | | | | | | | This does not function correctly in all circumstances so disable the periodic updates unconditionally for stable; a future patch will reenable where appropriate. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* ASoC: Handle spurious wm_hubs DC servo done interruptsMark Brown2016-04-301-14/+16
| | | | | | Don't assume the first fire indicates that we're done. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Implement DC servo completion IRQ handling for wm_hubs devicesMark Brown2016-04-302-5/+37
| | | | | | | | 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>
* ASoC: Use late enable handling for direct voice, speaker and headphoneMark Brown2016-04-303-13/+22
| | | | | | | This ensures appropriate clocking for bypass paths to speaker and headphone and direct voice paths on affected revisions. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* ASoC: Correct left/right swap in wm_hubs DC offset correctionMark Brown2016-04-301-8/+8
| | | | | | | | It was consistently wrong for everything except WM8993 so should be no functional change. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.comm>
* ASoC: Allow suppression of series updates on wm_hubs devicesMark Brown2016-04-302-1/+2
| | | | | | | 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>
* ASoC: Trigger wm_hubs series update startup off a separate flagMark Brown2016-04-304-2/+4
| | | | | | | Allowing the two to be used independently. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Liam Girdwood <lrg@ti.com>
* Merge remote-tracking branch 'linux-stable/linux-3.0.y' into ↵Ziyan2015-10-2560-191/+551
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | p-android-omap-3.0-dev-espresso Conflicts: Makefile arch/arm/include/asm/hardware/cache-l2x0.h arch/arm/kernel/smp.c arch/arm/mach-omap2/board-4430sdp.c arch/arm/mach-omap2/board-omap4panda.c arch/arm/mach-omap2/opp.c arch/ia64/include/asm/futex.h drivers/bluetooth/ath3k.c drivers/bluetooth/btusb.c drivers/firmware/efivars.c drivers/gpu/drm/i915/intel_lvds.c drivers/gpu/drm/radeon/radeon_atombios.c drivers/gpu/drm/radeon/radeon_irq_kms.c drivers/hwmon/fam15h_power.c drivers/mfd/twl6030-irq.c drivers/mmc/core/sdio.c drivers/net/tun.c drivers/net/usb/ipheth.c drivers/net/usb/usbnet.c drivers/usb/core/hub.c drivers/usb/host/xhci-mem.c drivers/usb/host/xhci.h drivers/usb/musb/omap2430.c drivers/usb/serial/ftdi_sio.c drivers/usb/serial/ftdi_sio_ids.h drivers/usb/serial/option.c drivers/usb/serial/qcserial.c drivers/usb/serial/ti_usb_3410_5052.c drivers/usb/serial/ti_usb_3410_5052.h drivers/video/omap2/dss/hdmi.c fs/splice.c include/asm-generic/pgtable.h include/net/sch_generic.h kernel/cgroup.c kernel/futex.c kernel/time/timekeeping.c net/ipv4/route.c net/ipv4/syncookies.c net/ipv4/tcp_ipv4.c net/wireless/util.c security/commoncap.c sound/soc/soc-dapm.c