Specify overrun bit in interrupt mask
Add dmaengine specific routines
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
[voice.shen@atmel.com: adapt to soc dmaengine framework]
Signed-off-by: Bo Shen <voice.shen@atmel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This patch is split original atmel-pcm.c into new atmel-pcm.c and
atmel-pcm-pdc.c two files. The new atmel-pcm.c is the share routine
while will be used for pdc or dma transfer.
Using SND_ATMEL_SOC_PDC to select using PDC for audio transfer
Signed-off-by: Bo Shen <voice.shen@atmel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler. There was no explicit
regmap_exit call in this function which was probably a bug.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
enabled. Unfortunately the DMA header patch had to be redone
to avoid adding new multiplatform specific include paths, the
other patches are just trivial compile fixes.
Note that this does not yet contain the necessary Kconfig
changes as we are still waiting for some drivers to get
fixed up first.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
iQIcBAABAgAGBQJQuOZOAAoJEBvUPslcq6Vz9wIQAM/L8NQFGZy8Z5wIMV6MMHRl
maChJfhyHXAP4f/MHKz+bO1CDxUNzbgDvDdrraJl/KLypHClpHMcy8QI2EpsSqBu
EZfBZpwZhChVTExnpcmCOFX7QC5ASP13XPMkz9iA8+gMM8r9gNTiNKYpHbBI24zu
PmyNbsxfXILUdGZgi532+MaEr1szHcyqb5cgQqIg/yPJ5lJ4FIDMCg4d+N4DGrWp
5WIFWt3yZ0bu/W5UTR7sSRuafjHatfoueh6Z31IBQYj556WBjJrl6rkSPZGEzFik
uAsWIJI/QAGyBpH7VYKea9+bZsSOGirF4pZM21yLcyjpgd81ojTygMl63nkaxfyg
3aPm3aljSOtkhOs8xeR9FKhyx9jML6jbxGT3WtCjDsEVeyMgl52ltkfVSJWxmdSt
asgQu+ZZLGvPF/CmQRx0aeOrqZCr+5y+yfSJbNHHHx6Rv3RMFwzTJJESgA9nx9WH
qrY7xEbsXXOSV3d8v9PvI42iFxp9mK6XvA0XewpFRZAN/GfsrAQZGYRK2mrhbWZh
aYv9Hz3W/tXM31/9cQMnel6WI9tWUFCqWIjkJrko1vMFvYZ/XQDCrXg47D4O+z40
+CK2xhcmLtuv1Zr9zahuW0YvXfDdc6eptyDDhYvKKjE2BnxxREdsT7WZoV3sc7qI
rNg1z8rLxFPp+n4buqTe
=w+UN
-----END PGP SIGNATURE-----
Merge tag 'tags/omap-for-v3.8/cleanup-multiplatform-no-clock-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/pm2
From Tony Lindgren:
Remaining patches to allow omap2+ to build with multiplatform
enabled. Unfortunately the DMA header patch had to be redone
to avoid adding new multiplatform specific include paths, the
other patches are just trivial compile fixes.
Note that this does not yet contain the necessary Kconfig
changes as we are still waiting for some drivers to get
fixed up first.
* tag 'tags/omap-for-v3.8/cleanup-multiplatform-no-clock-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
ARM: OMAP: Move plat-omap/dma-omap.h to include/linux/omap-dma.h
ASoC: OMAP: mcbsp fixes for enabling ARM multiplatform support
watchdog: OMAP: fixup for ARM multiplatform support
Conflicts due to surrounding changes in:
arch/arm/mach-omap2/omap_hwmod_2420_data.c
arch/arm/mach-omap2/omap_hwmod_2430_data.c
Signed-off-by: Olof Johansson <olof@lixom.net>
The same type of code is being used in multiple places in various
codec drivers, so put it as a core library.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
We cannot include any plat or mach headers for the multiplatform
support.
Fix the issue by defining local mcbsp_omap1().
cc: Peter Ujfalusi <peter.ujfalusi@ti.com>
cc: Liam Girdwood <lrg@ti.com>
cc: Mark Brown <broonie@opensource.wolfsonmicro.com>
cc: Jaroslav Kysela <perex@perex.cz>
cc: Takashi Iwai <tiwai@suse.de>
cc: alsa-devel@alsa-project.org
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
A lot of headsets/headphones have a "Speaker" mixer control. This confuses
PulseAudio to think it is a speaker instead of a headphone/headset.
Therfore, we rename it to "Headphone".
We determine if something is a headphone similar to how udev determines
form factor (see 78-sound-card.rules).
BugLink: https://bugs.launchpad.net/bugs/1082357
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The playback endpoint uses implicit feedback mode, similar
to the M-Audio FTU. Like with the FTU, we need to associate
the sync pipe ourselves.
Signed-off-by: Eldad Zack <eldad@fogrefinery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Add ranges for various Fast Track C400 controls, as observed
while using the vendor's mixer control software (res values
are an estimation).
Signed-off-by: Eldad Zack <eldad@fogrefinery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Adds the unit ID and the control as parameters to the creation of the
effect unit control for the M-Audio Fast Track Ultra. This allows the
code to be shared with other devices that use different unit ID and
control, such as the M-Audio Fast Track C400.
Signed-off-by: Eldad Zack <eldad@fogrefinery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Current code mishandles the case where the device is a UAC2
and the bDescriptorSubtype is a UAC2 Effect Unit (0x07).
It tries to parse it as a Processing Unit (which is similar to two
other UAC1 units with overlapping subtypes), but since the structure
is different (See: 4.7.2.10, 4.7.2.11 in UAC2 standard), the parsing
is done incorrectly and prevents the device from initializing.
For now, just ignore the unit.
Signed-off-by: Eldad Zack <eldad@fogrefinery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Currently, channel IDs exceeding 31 (0x1f) cannot be used.
The channel ID is derived from the cmask. Extending cmask
to a 64-bit type would only allow it to go up to 63 (0x3f).
Some devices have channel IDs exceeding that as well.
To address that, add an offset to the mixer element which
is then accounted for in the UAC set/get functions.
Signed-off-by: Eldad Zack <eldad@fogrefinery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
For implicit feedback endpoints, the number of bytes for each packet
is matched by the corresponding synchronizing endpoint.
The size is calculated by taking the actual size and dividing it by
the stride - currently by the endpoint's stride, but we should use the
synchronization source's stride.
This is evident when the number of channels differ between the
synchronization source and the implicitly fed-back endpoint, as with
M-Audio Fast Track C400 - the synchronization source (capture)
has 4 channels, while the implicit feedback mode endpoint has 6.
Signed-off-by: Eldad Zack <eldad@fogrefinery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Removed unnecessary labels probably left out of some previous cleanup.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
As the I2S src clks are registered with clkdev using generic
connection id, driver can get the clk name using generic id.
So the variable representing the array of rclk src clks is
deleted.
Signed-off-by: Padmavathi Venna <padma.v@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Handle the jack detection inforamtion as bool from devicetree.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regmap_init_i2c() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regulator_bulk_get() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regulator_bulk_get() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regulator_bulk_get() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devm_regulator_bulk_get() is device managed and makes error
handling and code cleanup simpler.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Some ADSP devices can make use of DVFS to optimise power consumption
depending on the operating frequency of the DSP core. Implement
support for this in the generic ADSP code.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Provide a haptics widget for use by the haptics driver and expose the DAPM
context for it.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Provide a haptics widget for use by the haptics driver and expose the DAPM
context for it.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This is a preliminary patch for introducing a protection to access
races of snd_array instances. Call snd_array_init() appropriately
at the initialization time and don't call it twice.
Also the allocations of codec-spec structs are cleaned up by helper
functions in patch_sigmatel.c and patch_analog.c.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
We cannot include any plat or mach headers for the multiplatform
support.
Fix the issue by defining local mcbsp_omap1().
Signed-off-by: Tony Lindgren <tony@atomide.com>
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Hi Mark,
thanks your insisting on a better description for the patch, I found a
more appropriate solution for the problem:
Compiling the SoC Audio driver for Freescale i.MX as a module
(CONFIG_SND_SOC_IMX_PCM=m) results in a non-functional sound driver
indicated by the error message:
| imx-sgtl5000 sound.1: platform imx-pcm-audio not registered
| imx-sgtl5000 sound.1: snd_soc_register_card failed (-517)
| platform sound.1: Driver imx-sgtl5000 requests probe deferral
instead of the message:
| imx-sgtl5000 sound.1: sgtl5000 <-> 63fcc000.ssi mapping ok
that is to be expected upon loading the snd-soc-imx-pcm.ko module.
The build log reveals, that the file imx-pcm-dma.o (or imx-pcm-fiq.o
depending on the kernel configuration), which should be linked
together with imx-pcm.o into snd-imx-pcm.ko, is not being compiled in
this case.
The make rules for these files shows that the target object imx-pcm.o
is assigned to the variable snd-soc-imx-pcm-y while
imx-pcm-{dma,fiq}.o are added to to
snd-soc-imx-pcm-$(CONFIG_SND_SOC_IMX_PCM_DMA) and
snd-soc-imx-pcm-$(CONFIG_SND_SOC_IMX_PCM_FIQ) which resolve to
snd-soc-imx-pcm-m in this case.
According to Documentation/kbuild/modules.txt:
|When the module is built from multiple sources, an additional line is
|needed listing the files:
|
| <module_name>-y := <src1>.o <src2>.o ...
Thus the type of the config variables CONFIG_SND_SOC_IMX_PCM_DMA and
CONFIG_SND_SOC_IMX_PCM_FIQ should be 'bool' instead of 'tristate' to
resolve to 'y' when selected.
Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Due to a broken make rule, sound/soc/fsl/imx-pcm-dma.c or
sound/soc/fsl/imx-pcm-fiq.c (whatever is selected via Kconfig) will
not be compiled into imx-pcm.o when building as module, i.e.:
CONFIG_SND_SOC_IMX_PCM=m
CONFIG_SND_SOC_IMX_PCM_DMA=m
resulting in a non-functional sound driver.
This gives the error messages:
| imx-sgtl5000 sound.1: platform imx-pcm-audio not registered
| imx-sgtl5000 sound.1: snd_soc_register_card failed (-517)
| platform sound.1: Driver imx-sgtl5000 requests probe deferral
when loading the driver instead of what's to be expected:
| imx-sgtl5000 sound.1: sgtl5000 <-> 63fcc000.ssi mapping ok
Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The device should not be generating interrupts when it does not have power
so ignore incoming interrupts.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Don't rely on the kcontrol for robustness reasons, the widget mechanism
is what the framework uses.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Add the support for channel maps of the PCM streams on USB audio
devices. The channel map information is already found in
ChannelConfig descriptor entries, which haven't been referred until
now.
Each chmap entry is added to audioformat list entry and copied to TLV
dynamically instead of creating a whole chmap array.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.18 (GNU/Linux)
iQEcBAABAgAGBQJQss0FAAoJEHm+PkMAQRiG6cEH/An3PYsWBBy27tzoLyVfJKF1
3m3vR8HS2tnHg6erxms+738jos59vrWXV0Ygnvw0DHbGR0HNb4rkwce/KXu/jgOD
MRYNYhlhMFJTEUFrSrcwKITrAV3kVPWXxPXgAR6Gzpr6NPKKM9TBzEv0ze56TFYz
asOxqeBcPSS7aFZlkoNsy1wG4l0Quo5ke8VZIxo9Me5qlqubAoZ6pING4wAGXqeE
tf81CevSdpe0nqr8/dlYyCvLjrurgpJQczxRCBI3mP6kLWGfUCVzZmcu86PfT9b+
35zNJwDneIoN+D9bVDHy6mrq9uQdmhWnQuhv1joTPn6RDn1nyBRBd+A5qLxSov4=
=CPoy
-----END PGP SIGNATURE-----
Merge tag 'v3.7-rc7' into next/cleanup
Merging in mainline back to next/cleanup since it has collected a few
conflicts between fixes going upstream and some of the cleanup patches.
Git doesn't auto-resolve some of them, and they're mostly noise so let's
take care of it locally.
Conflicts are in:
arch/arm/mach-omap2/omap_hwmod_44xx_data.c
arch/arm/plat-omap/i2c.c
drivers/video/omap2/dss/dss.c
Signed-off-by: Olof Johansson <olof@lixom.net>
I forgot this again... codec->in_pm is in #ifdef CONFIG_PM
Reported-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This is better style and facilitates implementation of device tree support
for the driver.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This device doesn't have a pdata definition for legacy boards, and
unless anyone need to control the reset GPIO, it's not worth adding one.
So this feature is only available to DT users for now.
Signed-off-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
When a playback stream is paused, the stream isn't actually stopped,
thus we still need to take care of the in-flight data amount for the
delay calculation. Otherwise the value of subs->last_delay is no
longer reliable and can give a bogus value after resuming from pause.
This will result in "delay: estimated XX, actual YY" error messages.
Also, during pause after all in flight data are processed
(i.e. last_delay = 0), we don't have to calculate the actual delay
from the current frame. Give a short path in such a case.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
set the 'onwer' field of the registered snd_soc_card object to prevent
removal of the module when its resources are in use.
Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
also set MODULE_AUTHOR and MODULE_DESCRIPTION
Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
It doesn't make sense to calculate the delay for capture streams in
the current implementation. It's always zero, so we should skip the
computation in snd_usb_pcm_pointer() in the case of capture.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Fixes following warning.
sound/soc/codecs/wm8753.c:1594:1-6: WARNING: invalid free of devm_ allocated data
Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Fixes following warning.
sound/soc/codecs/wm8510.c:614:1-6: WARNING: invalid free of devm_ allocated data
Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The PCM is a pseudo-device. It doesn't have any of it's own registers
or hardware. It rather acts as a layer of abstraction for DMA
transfers. Hence, instead of classifying it as a device in its own
right, we call the initialisation from the MSP driver.
Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: Ola LILJA2 <ola.o.lilja@stericsson.com>
Cc: alsa-devel@alsa-project.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The info record at the start of the dsp firmware file has been
expanded to incorporate additional version information. We need
to check the version to make sure we understand the layout of
the information in the record. The srec2image tool is currently
used to create this record during creation of the .dfw file.
Signed-off-by: Scott Ling <sl@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The internal mic on MBP81 gives only the right channel, and the left
channel is static. Add a verb to fix the ADC2 channel mode to expand
mono right to stereo.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=50781
Signed-off-by: Takashi Iwai <tiwai@suse.de>
We forgot to apply the fixup verbs in cs_init().
But adding the fixup verbs will break mbp101 fixup that has been fixed
recently again, since the mbp101 fixup contains the wrong verbs to
override. So these bogus verbs must be removed, too.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jeffrey Barish reported an obvious bug in the pcm part of the usb-audio
driver which causes the code to not initialize the sync endpoint from
configure_endpoint().
Reported-by: Jeffrey Barish <jeff_barish@earthlink.net>
Signed-off-by: Daniel Mack <zonque@gmail.com>
Cc: stable@kernel.org [3.5+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
As the recent firmware code tries to reread and cache the firmware by
itself, it's even better to keep the struct firmware data instead of
keeping a local copy. Also, it makes little sense to disable the fw
loader for this driver, so added the explicit dependency, too.
Last, but not least, allocate the firmware data loaded via ioctl in
vmalloc'ed buffer instead, as the firmware size isn't that small.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The new firmware code tries to re-read the formerly read firmware
files before suspend. Thus it's wiser to keep the "patch" firmware in
the driver for avoiding this unnecessary re-reading.
Of course, this will consume a bit of memory for unused stuff, but
the patch fw is supposed to be fairly small, so it's more benefit in
the end.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Yet again like previous two commits, drop the old hwdep user-space
firmware code from vx driver (snd-vxpocket and snd-vx222).
Signed-off-by: Takashi Iwai <tiwai@suse.de>
It makes no longer sense to keep the old hwdep user-space firmware
loading, which has been deprecated since ages ago.
Just add a hard dependency on CONFIG_FW_LOADER and drop the useless
code.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Since we keep the pin default config values anyway internally, we
don't have to set the values in the codec. This patch removes the
code writing the pincfg values.
As a gratis bonus, we can remove also the code restoring the original
pincfg values at PM resume or module free. This will give us more
benefit, as it can reduce the unnecessary power-up of codecs.
This won't change the driver functionality. The only difference would
be that the codec proc file will show the original pincfg values
instead of the actually referred values. The actually referred values
can be determined from sysfs *_pin_configs files.
(Also hda-emu was updated to follow this change.)
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When lowering SYSCLK to 50kHz for accessory detection also lower the
AIFnCLK divisor to normalise the clocking configuration within the
device. This will not disrupt audio as we cannot support active audio
with such a low SYSCLK.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The free callback is called at the state where no extra verbs are
executed, thus calling *_shutup() is useless, as it's checking the
shutdown flag. Remove such superfluous calls.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Increase timeout to be more reliable and avoid the chance of
missing interrupts during boot.
Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
PCM hw_free and close should wait until all the pending stop
operations have been finished. Basically only PCM trigger callback
should use non-wait calls.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
As we are stopping the endpoints asynchronously now, it's better to
trigger the stop of both data and sync endpoints and wait for pending
stopping operations, instead of the sequential trigger-and-wait
procedure.
So the wait argument in snd_usb_endpoint_stop() is dropped, and it's
expected that the caller synchronizes explicitly by calling
snd_usb_endpoint_sync_pending_stop(). (Actually there is only one
place calling this, so it was safe to change.)
Signed-off-by: Takashi Iwai <tiwai@suse.de>
For further code simplification, drop the conditional call for
usb_kill_urb() with can_wait argument in deactivate_urbs(), and use
only usb_unlink_urb() and wait_clear_urbs() pairs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Reduce the redundant arguments for snd_usb_endpoint_start() and
snd_usb_endpoint_stop(). Also replaced from int to bool.
No functional changes by this commit.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The async unlink behavior has been working over years. The option was
provided only as a workaround for 2.4.x kernel. Let's get rid of it.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
'rt' was dereferenced before the NULL check.
Moved the code after the check.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Return the value obtained from snd_pcm_hw_constraint_minmax() instead
of -EINVAL. Silences the following smatch warning:
sound/core/pcm_native.c:2003 snd_pcm_hw_constraints_complete() info:
why not propagate 'err' from snd_pcm_hw_constraint_minmax() instead of -22?
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
If this array is not cleared, the jack related code later might
fail to create "Internal Speaker Phantom Jack" on Dell Inspiron 3420 and
Dell Vostro 2420.
BugLink: https://bugs.launchpad.net/bugs/1076840
Cc: stable@vger.kernel.org (3.6+)
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Various cleanups and enhancements are made to core Tegra code towards the
aim of including Tegra in a multi-platform ARM kernel:
RTC, timer, and TWD are configured via device tree.
SPARSE_IRQ is enabled.
Tegra's debug_ll options are simplified, and the macros brought into
line with other multi-platform implementations, and moved to the new
common location.
Two headers still need to be eliminated in order to include Tegra in a
multi-platform kernel/ <mach/{clk,powergate}.h>. A new common API needs
to be invented to replace parts of clk.h. powergate.h might be replaced
by regulators; this needs more investigation.
This pull request is based on tegra-for-3.8-dt, followed by a merge of
arm-soc's devel/debug_ll_init branch.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
iQIcBAABAgAGBQJQppQBAAoJEMzrak5tbycxoz0P/REooomHVeI5CNyKMxp0rzQv
dSGfnWD2nuRJ3k36VOdGpa+BYW/xjYuYdIAKNrfAEnfeQRbYp1VGIfyjgMEcx7Yi
TzNmangYj+9f60u1MQq2YQytFFtgfcG1utTIuvKKhuJ/pZEjCkYKBQjNOLFuetaI
oCxNDklcnCn5zxUGsQwpxxMf+A1Ja6tPHkqdN2p+0OQpUpr0i2mCMMrSPEHY0RgV
zRBhsIwwe9eTAOPkZmr6SnCVIAs2rANVnBfZGJC/k9bT7cckhmL/EcGZLBIvRe8L
gD4HtZsltNwbCh/cV4qIvx/nUaW1No/iqvQERtgAGWQtCUp/Jgmy3roV4zzWBiOR
/N88kBaO5fw7crVFDMLTlHVKc2IKWTzSnpEUIllLw/G8ySjW5tjXP57gaxb712BU
KYmcl6KFZ8Uu8OfyDYR6dRPtk+ayqAhSqBql+NveOWLk+nYFFyoob62FPTFq64eu
MwM1BKlFKxLmMUeBTpSJXG/rtVkE+kgocZrB6GEofhIn7gjELqsaWutOJ6LYQ4wY
i4N0NcBA3/oFu7N9T7yY+mKJCwRovyrpqW3Lp62xvns8+Y2ziUNxY4e0NvopzIOi
GYz+ktI3CT1cZv9zkdEI+TOnRrWze8N7Xzt9ii8SD456to5wcaRCjmpATnNIKTTi
uLmNaB6M9+mTjIXR8MDb
=qXVf
-----END PGP SIGNATURE-----
Merge tag 'tegra-for-3.8-single-zimage' of git://git.kernel.org/pub/scm/linux/kernel/git/swarren/linux-tegra into next/multiplatform
From Stephen Warren:
ARM: tegra: single-zImage preparation work
Various cleanups and enhancements are made to core Tegra code towards the
aim of including Tegra in a multi-platform ARM kernel:
RTC, timer, and TWD are configured via device tree.
SPARSE_IRQ is enabled.
Tegra's debug_ll options are simplified, and the macros brought into
line with other multi-platform implementations, and moved to the new
common location.
Two headers still need to be eliminated in order to include Tegra in a
multi-platform kernel/ <mach/{clk,powergate}.h>. A new common API needs
to be invented to replace parts of clk.h. powergate.h might be replaced
by regulators; this needs more investigation.
This pull request is based on tegra-for-3.8-dt, followed by a merge of
arm-soc's devel/debug_ll_init branch.
* tag 'tegra-for-3.8-single-zimage' of git://git.kernel.org/pub/scm/linux/kernel/git/swarren/linux-tegra: (58 commits)
ARM: tegra: move debug-macro.S to include/debug
ARM: tegra: don't include iomap.h from debug-macro.S
ARM: tegra: decouple uncompress.h and debug-macro.S
ARM: tegra: simplify DEBUG_LL UART selection options
ARM: tegra: select SPARSE_IRQ
ARM: tegra: enhance timer.c to get IO address from device tree
ARM: tegra: enhance timer.c to get IRQ info from device tree
ARM: timer: fix checkpatch warnings
ARM: tegra: add TWD to device tree
ARM: tegra: define DT bindings for and instantiate RTC
ARM: tegra: define DT bindings for and instantiate timer
ARM: tegra: whistler: enable HDMI port
ARM: tegra: tec: Enable HDMI output
ARM: tegra: plutux: Enable HDMI output
ARM: tegra: tamonten: Add host1x support
ARM: tegra: trimslice: enable HDMI port
ARM: tegra: harmony: enable HDMI port
ARM: tegra: Add Tegra30 host1x support
ARM: tegra: Add Tegra20 host1x support
ARM: tegra: trimslice: enable SPI flash
...
Various trivial cleanup changes of the Tegra code for 3.8.
Many of the changes simply remove useless #include statements, which
enable those headers to be removed or moved later, as work towards
multi-platform zImage support.
<mach/{iram,io}map.h> are moved up to arch/arm/mach-tegra to prevent
any new code outside mach-tegra from using them.
Finally, the regulator definitions in all board device tree files are
updated to use the new simpler syntax that was agreed upon.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
iQIcBAABAgAGBQJQpo5eAAoJEMzrak5tbycxhpoQAIZPMMXemJP7Hqvtx0iza5jG
LVbBqb+sTEhESpdd43XeMK8n9umjVszseRJYm3vbekJp3crVE/Z0ikTTzmDUiwIj
iz1t9U1i+EsAVZ977DF68InA/lWociKVqaDO4WEN4YZ19zGQJbghFKVic5yVZvNq
hRWNvDUkRi+9FJHS7wBHQNuRIghSDxh90zFoc0UUs12J2z2OjXKPYypU7Ttp6aUY
rBvuDlqRQ9SjFxuE2dYDvEWnB69ONL7LauAkSkoqgXGGP1a6v5pphm+Y3badCOrO
q5hGUpvzO+DTfOncj5dlZedRq9vjS/QEF+qJQFvMPrUpv8QkOulY4nf7w/sYmk9o
Rhm9G6BxFGDMdxruA9SBkqjEzPcI9cT18FRYkMtsHfWwUgu6NUB6bMhc++R6rOJS
JNkH+DoWuEsGP2RyopZZEjKlrCxPv3vNNOz4wkaLH+gEQvE9EZ5mkqy8xNYQbMBb
Yv93TCADrX9tw/3JfWjB6/WhZ9GVBcSie0hcW+2Nm7lUzzQ8q9DKMZobG20+KHBZ
/+L4NmK7DR5u8M6xnZqPat2VAraFxYZFjy3Xd50ul7PphfJnR4c7ITqt4u6lJ6hn
Bnc7/DNM5hgAncH+APon1tffLMqgsJphC4Chn7y7Y/wSYi216IA21pmSrrmpKkh9
OqBOasN9GVmmHVnxNzHn
=aH3p
-----END PGP SIGNATURE-----
Merge tag 'tegra-for-3.8-cleanup' of git://git.kernel.org/pub/scm/linux/kernel/git/swarren/linux-tegra into next/cleanup
From Stephen Warren:
ARM: tegra: cleanup for 3.8
Various trivial cleanup changes of the Tegra code for 3.8.
Many of the changes simply remove useless #include statements, which
enable those headers to be removed or moved later, as work towards
multi-platform zImage support.
<mach/{iram,io}map.h> are moved up to arch/arm/mach-tegra to prevent
any new code outside mach-tegra from using them.
Finally, the regulator definitions in all board device tree files are
updated to use the new simpler syntax that was agreed upon.
* tag 'tegra-for-3.8-cleanup' of git://git.kernel.org/pub/scm/linux/kernel/git/swarren/linux-tegra:
ARM: tegra: move irammap.h to mach-tegra
ARM: tegra: move iomap.h to mach-tegra
ARM: tegra: remove <mach/dma.h>
ARM: tegra: move tegra-ahb.h out of arch/arm/mach-tegra/
ARM: tegra: remove unnecessary includes of <mach/*.h>
iommu: tegra: remove include of <mach/iomap.h>
staging: nvec: remove include of <mach/iomap.h>
crypto: tegra: remove include of <mach/clk.h>
ARM: tegra: update *.dts for regulator-compatible deprecation
usb: phy: tegra remove include of <mach/iomap.h>
usb: host: tegra remove include of <mach/iomap.h>
We found a new codec ID 292, and that just a simple quirk would enable
sound output/input on this ALC292 chip.
BugLink: https://bugs.launchpad.net/bugs/1081466
Cc: stable@vger.kernel.org
Tested-by: Acelan Kao <acelan.kao@canonical.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The biggest batch of fixes here is the Kirkwood DMA fixes, plus a couple
of other small fixes.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
iQIcBAABAgAGBQJQrEALAAoJELSic+t+oim9BHgP/37A90Xw+cLnTNnr4BRYPl0b
eeyaCiYxr1VEg11zz+hyID4dBfca+ijUUmEsL/gSMRXb2L228l7P5FcXEKOVac9d
xqcq59ZFu3QA5m2CcachT0t9QXegFTMMlqJ4G2lp6RDoXeU+RpSxC/M28wdLpOt+
CNV/qgptupEXTQJxLxyQ8B3rNU98yAWNruuZ2NWFeQxbxJZVFEHhQtBgAzOxPu2e
aKMPt7NzV3KSYySOffwCCW0Pj1DC85oSQR0SzI8lcJd8FtmKxJS3wjpZyNwXb3tN
D2o5MEuyHckJE3JHnmtfbj2VtD97EhiewSiAwqh6pCb8/qO7Pte/+5QVBNv0mBnk
TIKN68YTeheNVP8v0C9baBW99bqFofGpA6nOw4v0G3k7B11GxtQ9lp5BdDH3tz8m
lI1zJckAwuSfvC/H9xqS89GKaW3JBpu1nRuICBYGsbWAjPbLKr4i8YMJyVLi3CPN
o+ocfC5ZT/TdICE7VW09+4viiVO+gg7Tvp5VndIZX5/rpJU1vmKc5ag149t+fhRt
rmlGSumO9KyTVxEI8CnGsZJXYOF8kJ5BxvKJI7FFUjLa1pE6FYLa6kaaSDs0HGG9
PdkoplCg7hVSaWSio5tzRfj5ObZWzIoiBBzLTp5PgBTL38YhCvVaK4aw0bjqWSJN
d5ar1sD4uznNqkjYkdbv
=V7+d
-----END PGP SIGNATURE-----
Merge tag 'asoc-3.7' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
ASoC: Fixes for v3.7
The biggest batch of fixes here is the Kirkwood DMA fixes, plus a couple
of other small fixes.
This patch adds the max98090 codec prototype driver.
It supports Headphone only at this point.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This patch removed struct ak4642_priv which had
meaningless variable.
It is no longer needed
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Currently ASoC has a mixture of message prefixes e.g. "ASoC", "asoc"
or none and message types e.g. pr_debug or dev_dbg.
Make sure all ASoC core messages use the same "ASoC" prefix and
convert any component device specific messages to use dev_dbg
instead of pr_debug.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Currently ASoC has a mixture of message prefixes e.g. "ASoC", "asoc"
or none and message types e.g. pr_debug or dev_dbg.
Make sure all ASoC core messages use the same "ASoC" prefix and
convert any component device specific messages to use dev_dbg
instead of pr_debug.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Currently ASoC has a mixture of message prefixes e.g. "ASoC", "asoc"
or none and message types e.g. pr_debug or dev_dbg.
Make sure all ASoC core messages use the same "ASoC" prefix and
convert any component device specific messages to use dev_dbg
instead of pr_debug.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Currently ASoC has a mixture of message prefixes e.g. "ASoC", "asoc"
or none and message types e.g. pr_debug or dev_dbg.
Make sure all ASoC core messages use the same "ASoC" prefix and
convert any component device specific messages to use dev_dbg
instead of pr_debug.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Currently ASoC has a mixture of message prefixes e.g. "ASoC", "asoc"
or none and message types e.g. pr_debug or dev_dbg.
Make sure all ASoC core messages use the same "ASoC" prefix and
convert any component device specific messages to use dev_dbg
instead of pr_debug.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This is part of a patch found in Rabeeh Khoury's git tree for the
cubox.
With SPDIF passthrough, we are not restricted to just two channels of
audio; we can support however many channels the non-audio stream can
itself support. In any case, kirkwood-dma is not involved in the
format selection. So yet rid of this restriction.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This is part of a patch found in Rabeeh Khoury's git tree for the
cubox, and cleaned up by me.
Some platforms provide an external clock which can be used to allow
other sample rates to be selected. Provide support for this.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This is part of a patch found in Rabeeh Khoury's git tree for the
cubox.
The kirkwood DMA hardware for ASoC does not impose any restrictions
on the sample rates available, so it's silly to impose an artificial
set in the DMA code. The restrictions come from the availble clocks
to the I2S module, which are already handled in the I2S part of the
driver.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Simplify the cleanup paths in the driver by using the devm_* APIs,
ensuring that all error paths are correctly checked.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Don't even momentarily set the pause status when starting the channel;
if we do, we should check the busy bit to ensure that we comply with
the spec. In any case, it isn't necessary; we will not active on a
START event so there is no need to pause the DMA.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Stress testing the driver with multiple start/stop events causes
kirkwood-dma to report underrun errors (which used to cause the kernel
to lock up solidly). This is because kirkwood-i2s is not respecting
the restrictions imposed on clearing the 'pause' bit. Follow what the
spec says; the busy bit must be read as being clear twice before the
pause bit can be released. This solves the underruns.
However, it has been noticed that the busy bit occasionally does not
clear itself, hence the waiting is bounded to 5ms maximum to avoid a
new reason for the kernel to lockup.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This is part of a patch found in Rabeeh Khoury's git tree for the
cubox, which is further attributed to Sebastian Hesselbrath.
Rather than masking the KIRKWOOD_DCO_SPCR_STATUS register contents
against the registers virtual address, let's actually use the bit
definition for the locked status, as required in the documentation.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Ignoring the real cause of the interrupt is not a good idea; this
behaviour has been observed to bring Dove platforms to silently
lockup. Instead, on error fall through to the normal interrupt
processing.
This is especially important on Dove platforms as errors are
handled separately, and allows us to clear down the real cause of
the interrupt.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This is part of a patch found in Rabeeh Khoury's git tree for the
cubox.
You can not use virt_to_phys() on the address returned from
dma_alloc_coherent(); it may not be part of the kernel direct-mapped
memory. Fix this to use the DMA address instead.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
It seems WM_ADSP2("DSP1", 0) is added twice to the widgets list, remove
that and in place use ARIZONA_DSP_WIDGETS(DSP1, "DSP1").
We need to make sure that the DSP1 Aux widgets are provided otherwise
we'll see errors such as "Failed to add route DSP1 Aux 1 -> DSP1" etc.
Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
CONFIG_HOTPLUG is going away as an option so __devexit_p is no longer
needed, remove it.
Also fix the indentation for the initialization of the
max98088_i2c_driver struct to make chkpatch happy.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
Cc: Jaroslav Kysela <perex@perex.cz>
Cc: Takashi Iwai <tiwai@suse.de>
Cc: alsa-devel@alsa-project.org
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Current FSI driver is using platform information pointer,
but it is not good design for DT support.
This patch adds SND_SOC_DAIFMT_INV_xxx support,
and it is possible to independent from platform information pointer.
Old type SH_FSI_xxx_INV is still supported,
but it will be removed soon.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Current FSI driver is using platform information pointer,
but it is not good design for DT support.
This patch makes stream mode format
independent from platform information pointer.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Current FSI driver is using platform information pointer,
but it is not good design for DT support.
This patch makes master clock selection
independent from platform information pointer.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Current FSI driver is using platform information pointer,
but it is not good design for DT support.
This patch makes spdif format
independent from platform information pointer.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Current FSI driver is requesting sh_fsi_platform_info pointer from platform,
and it didn't allowed NULL pointer.
This patch fixes it.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This patch tidyup to use fsi pointer for FSIA/B settings
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
CONFIG_HOTPLUG is going away as an option so __devinitconst is no
longer needed.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
We've got a report that the runtime PM may make the codec the
unresponsive on AMD platforms. Since the feature has been tested only
on the recent Intel platforms, it's safer to limit the support to such
devices for now.
This patch adds a new DCAPS bit flag indicating the runtime PM
support, and mark it for Intel controllers.
Reported-and-tested-by: Julian Wollrath <jwollrath@web.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The Acer Aspire AO756 has an analog built-in mic on nid 0x1b and an
external mic on nid 0x19. The BIOS doesn't set this up.
The mic detect on this Acer Aspire netbook and Acer C7 ChromeBook is
only valid when the headphone is plugged. The detect circuit relies on
the tip detect switch being closed on the jack. Tell hda_jack to ignore
the mic sense unless the headphones are plugged.
Signed-off-by: Dylan Reid <dgreid@chromium.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Introduce the concept of a "gated" jack. The gated jack's pin sense
is
only valid when the "gating" jack is plugged. This requires checking
the gating jack when the gated jack changes and re-checking the gated
jack when the gating jack is plugged/unplugged.
This allows handling of devices where the mic jack detect floats when
the headphone jack is unplugged.
[Rewritten for fixing the possible snd_array reallocation, covering
the missing callback calls and jack sync operations, as well as some
code cleanups -- tiwai]
Signed-off-by: Dylan Reid <dgreid@chromium.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
"Asynchronous" is misspelled in some comments. No code changes.
Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
"Whether" is misspelled in various comments across the tree; this
fixes them. No code changes.
Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Some comments misspell "registered"; this fixes them. No code changes.
Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
When the bus reset is performed during the suspend/resume (including
the power-saving too), it calls snd_hda_suspend() and
snd_hda_resume() again, and deadlocks eventually.
For avoiding the recursive call, add a new flag indicating that the PM
is being performed, and don't go to the bus reset mode when it's on.
Reported-and-tested-by: Julian Wollrath <jwollrath@web.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>