Push everything through one function for active use cases, should be
no practical effect.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Normally this will have no effect as we set detection up at system startup
before DAPM syncs take effect, this will only be useful if the system
enables and disables detection at runtime.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
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>
Using snd_soc_write() means we always write to the register even if it
already contains the newly calculated value.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
snd_soc_register_card() has been available and strongly preferred since
2.6.38 but we're still seeing new drivers using it and the conversion rate
for older machines has been low. Help address both issues by logging a
warning when the soc-audio device probes.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Make sure we cleanup the platform debugfs when probe fails.
Signed-off-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This patch adds a set of functions which are intended to be used when
implementing a dmaengine based sound PCM driver.
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Acked-by: Vinod Koul <vinod.koul@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
devices. Most of the modern devices will never get shut down normally
with a visible kernel log as the systems they're in tend not to shut
down often and when they do it's usually in form factors that don't have
a user visible console.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
iQIcBAABAgAGBQJPT2d3AAoJEBus8iNuMP3d5Y0P/iM8j26/TQ27/5r9WroKKHXL
BeIt+xT2hB1xuCf8KUMmq4JZUQQQZBz2mhlcR5oG93A5S6QmLXl8bXJ2qdmGb3KW
YmtWo1kCMj44Z/mVt9u9lIy+EnlxrgogwCA/Ph3Fb+GppR+f27rXr87g3OaYEJgu
1W1u9AYrmJ9SkWrjSxlihfQiQ7v4gojGQKrWsG6uFq4ZJIBDah9nqsfpvT1/XdeF
ciijoSk1sRAHOz92MPDRvwPxVaWbyv4ehkE3O7Zckcm+8z0bBWL26U5Nq4thhIjz
CCqhqSP/22XvJxOM6xQwnH3VmxyON+F7bOdmk9fZdwEIJ5zVpvK1gkBQSeykUn6F
Ow6g5L2cH2azmswWCVsUt6+NjfnpaNI/g8+J/Jy9aDQbyx0LWeN89AUJBC+KCGUL
YLAzzsx2e4cKcILx6PiDhDCkoPkszacPrsoWZWr5QvNc+32HQhXX/KEqUcYHhxGR
N/b046oVzLjcAfOFDoSvER5G1Ep6wJCxgNKjo+b4uYk2UYQBt/haYqSjqQwFnRi1
JjkC/FZjHTS4z1dexdSx5SGsRl+dDvr9rlmYtq+u/5SqLb+eq+iDUhberrgP6vGh
P7Nkt9PEHzJ+ifqlmvJXyKf54mlozmS5MzDn9JopGnZjLp5QVHIVqdd+inqGpFSg
wpwymYcKQ3BXeJC0aGQH
=FzOc
-----END PGP SIGNATURE-----
Merge tag 'asoc-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
A small fix for the SSI driver and a fix for system shutdown with modern
devices. Most of the modern devices will never get shut down normally
with a visible kernel log as the systems they're in tend not to shut
down often and when they do it's usually in form factors that don't have
a user visible console.
I moved on from a great employer and the email-id no longer exists.
Update email-id to a personal one, assuming I don't move on from
myself anytime soon. And when I do, people don't get the eulogies
bounced.
Signed-off-by: Jaswinder Singh <jassisinghbrar@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Saves two lines and a hell of a lot of embarrassment looking at the code.
Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
It seems that Lenovo machines (or codec chip itself?) leave the unsol
event tags and the enablement-flag from other pins bogusly even on the
unused pins. Although this shouldn't be too critical, it's better to
clear them up sanely.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Some codecs don't supply the mute amp-capabilities although the lowest
volume gives the mute. It'd be handy if the parser provides the mute
mixers in such a case.
This patch adds an extension amp-cap bit (which is used only in the
driver) to represent the min volume = mute state. Also modified the
amp cache code to support the fake mute feature when this bit is set
but the real mute bit is unset.
In addition, conexant cx5051 parser uses this new feature to implement
the missing mute controls.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=42825
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
A bug report with an old Sony laptop showed that we can't rely on BIOS
setting the pins of headphones but the driver should set always by
itself.
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The docking-station of Thinkpad X200 & co supports also an SPDIF output,
and the corresponding pin 0x1c has to be enabled for using it.
Reported-and-tested-by: Sebastian Glita <sebastian.glita@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Similar to what commit 1e3ad57 (ASoC: Remove redundant -codec from
WM8776 driver name) does for wm8776 driver, this patch does the same
thing for cs4270 driver.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Align mpc8610_hpcd with p1022_ds on getting codec node by just calling
of_parse_phandle. The bonus point of doing that is we can save
exporting get_node_by_phandle_name() when we consolidate the common
bits between mpc8610_hpcd and p1022_ds into a module, which can be
shared by more machine drivers added later.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The second parameter of function get_dma_channel is actually a property
name rather than a compatible string, so rename it for less confusing.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Acked-by: Timur Tabi <timur@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This patch adds a new position_fix option value, 4, as a combo mode
to use LPIB for playbacks and POSBUF for captures. It's the way
recommended by Intel hardware guys.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Enables port E of IDT 92HD91 codec as output and sets correct output
phase between ports E and D and high pass filter.
Signed-off-by: Vitaliy Kulikov <Vitaliy.Kulikov@idt.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This is intended to facilitate the merge of the two jack detection
mechanisms.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Add the obvious header to fix this:
sound/soc/fsl/mpc5200_dma.c:301: error: implicit declaration of function 'DMA_BIT_MASK'
sound/soc/fsl/mpc5200_dma.c:301: error: initializer element is not constant
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
CONFIG_FIQ is only needed when CONFIG_SND_MXC_SOC_FIQ is selected to
build imx-pcm-fiq.c, so let SND_MXC_SOC_FIQ select FIQ.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
When there are multiple input sources, the driver wrongly overwrites with
the value of the last input source on other slots at resume. Thus the
primary input source may be shown wrongly.
Reported-and-tested-by: Julian Sikorski <belegdol@gmail.com>
Cc: <stable@kernel.org> [v3.1+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
SET_SYSTEM_SLEEP_PM_OPS writes .poweroff = *_resume once. Then we overwrite it
again explicitly as .poweroff = snd_soc_poweroff. Even though it works, as the
second one overwrites the first one, this is not the correct way. Fix this by
expanding SET_SYSTEM_SLEEP_PM_OPS in our structure.
Signed-off-by: Viresh Kumar <viresh.kumar@st.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
According to i.MX27 Reference Manual (p 1593) TXBIT0 bit selects
whether the most significant or the less significant part of the
data word written to the FIFO is transmitted.
As DSP_A is the same as DSP_B with a data offset of 1 bit, it
doesn't make any sense to remove TXBIT0 bit here.
Signed-off-by: Javier Martin <javier.martin@vista-silicon.com>
Acked-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
Since the cache is currently open coded this is more of a win than for
most devices.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Daniel Mack <zonque@gmail.com>
Don't use the internal I/O functions directly.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Daniel Mack <zonque@gmail.com>
Recent enhancements in the bias management means that we might not be
in standby when the CODEC is idle and can have active widgets without
being in full power mode but the shutdown functionality assumes these
things. Add checks for the bias level at each stage so that we don't
do transitions other than the ON->PREPARE->STANDBY->OFF ones that the
drivers are expecting.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
Add a stereo volume control for analog input channel pair 1/2.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Add a mute control for every analog output channel.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Add a stereo volume control for every analog output pair 1/2, 3/4, 5/6.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Remove the soft log-conversion and add a dB scale according to
the DAC documentation instead.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Remove unused driver version information from the individual files.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Early revisions of several of the WM8994 variants have register updates
to improve performance. Move these over to using the regmap patch system
instead of open coding them in the audio driver. Since the regmap init
is done by the MFD the code is moved there.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Request the DMA channel in the PCM open callback instead of the hwparams
callback, this allows us to let open fail if no dma channel is available. This
also fixes a bug where the channel will be requested multiple times if hwparams
is called multiple times.
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Request the DMA channel in the pcm open callback. This allows us to let open
fail if there is no dma channel available.
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Move the call to snd_soc_dai_set_dma_data from the hw_params callback to the
startup callback. This allows us to use the dma data in the pcm driver's open
callback.
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Tested-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Added sanity checks in a few places not to assume the pins having the
certain amp caps or the input-source being always assigned to a mux.
No actual bugs have been triggered by these, but surely better to be a
bit more robust.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The driver may create duplicated mic boost controls when there are
multiple mics with the very same type / location, and this leads to
the error at actual kcontrol creation. It needs to check the validity
of the created control and add a proper index if it's duplicated.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Commit 3702b08 added a lock, but did not account for the case of
SNDRV_PCM_POS_XRUN, which would get immediately overwritten.
This could be bundled into one if-else-if statement, but the goto
helps to clarify the 'exceptional' case.
Thanks to Andreas Pape for spotting this.
Signed-off-by: Mark Hills <mark@pogo.org.uk>
Acked-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
on.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
iQIcBAABAgAGBQJPQ/LIAAoJEBus8iNuMP3d3qYQAIW6eCnfrTjTe5s7FpXcSqup
gIIwoibxg6YA2SbXm0l1YBFnZxUl21S9vbAni9ZqYAcYFPlLS/WKb6N7X8bWKA/4
PfzR96VPBum0sZg+1PwIgYd/zh29Mv532hzLAGCG862afW2TIF3dke8bLsdh4GvV
KTbicLBmo7EdnshOOsEIKq0UGNkAFss6V8JvxeUSIlQPY2npv887tbnO29LHNjR7
al4Mg23bLeCWqgUCIihyPz4LwCsyQtM/xm/sL0RBvo8OPsqnPdCvCZ9ZK7vzYQ3n
HAp62oF2QZ1S/cxp9VnpMT/wVaBo2amTFcLybZyuRoIv0YxRNcfxiDXQaKqlIlx6
y80oeVvlpCqnOXek3L+DQ8KheGWutfP/eG6KiFMbtSwlqrJx0YKqAMSRcRcr4lWh
UO+WMlCo59KvqC0wXsQqwRGTznZRNKs/+5yCVhi3VE9tNDKyZuerQG1ParenJNw9
GdNxqaJSC2FTR+gVoxrgCm880pu7AqQJa4VdAglunhgfRFRfng+KBhLRoYdVTGr2
FJ4M2ZLQ/rYxqXRw3MEs2LBOAoUyX0s5yOmUmvzUJzySWE4OHWFd9KFR+I+4oI9g
5/0HW8WgAWmq1t14yvOcmkx/slEtFt41A997Cakvl6ZkNccawY2Npg5l9JxcwL2K
mcG+6To6YU7JJ5RiH9Dk
=i5Ya
-----END PGP SIGNATURE-----
Merge tag 'asoc-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus
A couple of small, driver specific fixes - nothing too exciting going
on.
Chip designers frequently include things like the enable and disable
controls for algorithms in the register blocks which also hold the
coefficients. Since it's desirable to split out the enable/disable
control from userspace the plain SND_SOC_BYTES() isn't optimal for
these devices.
Add a SND_SOC_BYTES_MASK() which allows a bitmask from the first word
of the block to be excluded from the control. This supports the needs
of devices I've looked at and lets us have a reasonably simple API.
Further controls can be added in future if that's needed.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Allow devices to export blocks of registers to the application layer,
intended for use for reading and writing coefficient data which can't
usefully be worked with by the kernel at runtime (for example, due to
requiring complex and expensive calculations or being the results of
callibration procedures). Currently drivers are using platform data to
provide configurations for coefficient blocks which isn't at all
convenient for runtime management or configuration development.
Currently only devices using regmap are supported, an error will be
generated for any attempt to work with a byte control on a non-regmap
device. There's no fundamental block to other devices so support could
be added if required.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Allow us to build infrastructure which needs to know the size of a value
without requiring regmap based drivers to supply this information to both
ASoC and regmap by asking regmap for the value.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
When an external capacitor is connected to MICBIAS2 on devices with
jack detection (which is not required but may be done in some systems)
then the loading may mean that better performance is obtained when
the microphone bias is enabled normally rather than using the low power
mode. Provide platform data allowing systems to indicate if they require
this.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This minimises the chance of any external capacitors that are fitted
being discharged into headphones as they insert.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
A few clean-ups for post-static-quirk time:
- Call alc_auto_init_std() statically in alc_init() instead of setting
spec->init_hook in each caller. spec->init_hook field is left
unused for any future use.
- Move the call of set_capture_mixer() to to alc_parse_auto_config()
instead of each caller.
- Get rid of the ADC-filling and imux check in each parser function.
This is no longer needed since the auto-parser always check ADCs and
imux. It was only for the static quirks.
- Kill unused defines
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When the machine has two speakers but wants to put more multi-io
jacks, the parser shouldn't consider about the shared DAC but try to
assign the individual DACs. Otherwise the channel mapping would be
fairly confused and lead to the wrong DACs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When the multi-io is added to the two speaker output configuration,
the parser would try to add yet another "Bass Speaker" control since
it checks only cfg->line_outs. Add a workaround for it by simply
passing the channel name in the case of multi-io outputs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Even if the outputs are using shared DACs, we can still create individual
mute siwtches since they are assigned per pin. This allows to create,
e.g. Speaker and Bass Speaker mute switches while the single volume is
used for these outputs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When BIOS is damn crazy and gives no pin-config at all, the driver might
lead to a NULL dereference. Let's add a NULL check for such a case.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The below patch fixes some typos "aditional" to "additional", and also fixes
a comment with another word mispelled.
Signed-off-by: Justin P. Mattock <justinmattock@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Similarly in patch_via.c, parse the active analog-loopback connections
and create a list dynamically rather than static arrays.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Resitance is futile. The remaining static model quirks for Apple
machines with ALC882-compatible codecs are converted to the auto-parser
now. We can remove all alc*_quirks.c finally.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Current ak4642 driver had wrong dapm settings for headphone L/R.
If you select headphone L, and select R after that,
headphone L setting was removed by R settings.
This patch fixes it up.
It provides just "Headphone Enable" to user side
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Replace the printk(KERN_ERR* instances with dev_err in the driver.
While we are here clean up some of the debug messages as well.
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The WM8775 is register compatible with the WM8776 so can be supported with
the same driver though it is an ADC only part. Add the device ID to the
WM8776 driver, further updates will be added in the future.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
If anyone wants to debug the driver and avoid the existing fix-ups,
pass model=nofixup option. Then the driver will skip to pick up the
fixup list.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Finally the all static quirks for ALC880 are converted to the
auto-parser. Since we are never sure whether the BIOS on so many old
machines are really correct, the quirk table entries are copied as
they are, but just providing the proper pin-config values
accordingly.
Since alc880_quirks.c is removed, alc882_quirks.c has to be adjusted
slightly to be built again. There might be some compile warnings due
to the remaining alc882 quirks, but these shall be killed sooner or
later, I don't care it much at this point.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
It turned out that BIOS on most of ASUS mobo's set the pin-config tables
reasonably well for the auto-parser. We'd need GPIO setups, but should
work as is other than that.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
ASUS Z71V has a totally broken BIOS setup (at least the info I got),
thus we need to override the whole pin-config table to make the
auto-parser working correctly.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The model=uniwill would work almost as is, but a couple of adjustments
are needed to make the mutli-io working correctly. The headphone and
speaker pins have to be marked properly in pin configs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Uniwill p53 has a sane BIOS setup but just needs the volume-knob handling
like Fujitsu laptops with ALC880.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Similar as the previous patch for model=fujitsu, we can now move the
static quirk for F1734 to the auto-parser. The only difference is the
default pin configurations: F1734 has less pins than Amilo's.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
SND_PCM is already selected by SND_SOC, there is no need for
SND_IMX_SOC and SND_MXS_SOC to select it again.
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Now adding the support for the volume-knob widget, we can move the static
quirk for ALC880 model=fujitsu to the auto-parser completely.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Move the call of alc_apply_fixup() with ALC_FIXUP_ACT_PROBE after the
whole setups of patch_ops & co, so that the fix-up function may override
the default setup. This will be needed for installing the own unsol
event handler (e.g. for volume-knob controls).
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This is a patch to the sound/core/misc.c file that
fixes up a trailing white space issue found by the
checkpatch.pl tool.
Signed-off-by: Jeffrin Jose <ahiliation@yahoo.co.in>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This patch supports DMAEngine to FSI driver.
It supports only Tx case at this point.
If platform/cpu doesn't support DMAEngine, FSI driver will
use PIO transfer.
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.18 (GNU/Linux)
iQEcBAABAgAGBQJPQDoTAAoJEHm+PkMAQRiGMpYH/ibfyIFBrKMD1v/s9oNvp8rS
c7J7E7mHZOylCHrpIS3lX3ZbOfOe33Ln0Z59f1/TcV4CMMz0NrKYcTC8erj/H/DA
8DRYegiczWKqiXRgktwaZXkJcwXYdOOL1WQYxuzzbZcwRrNBY2QpH7Zu8Bj+TPAy
d4fvJHWdlh4sbWVdQmLRbp04UB9J/Z5/uWmSNvVQjLLdRlD+mEBbt7JjiNY6sUVC
2sJoAs9F3UlHu7VaN+JIhMOGZ3GqOpHGBxN/aWxJ/7GsXdXuAfCrxoPxaAe4xzOa
HndN5ZDyg02Vy5uDeUzj+HJPW3M8L4Q0nwxAYb3ZnQ5tbpu1Q2cHfIBealomWCQ=
=R91X
-----END PGP SIGNATURE-----
Merge tag 'v3.3-rc4' into for-3.4 in order to resolve the conflict
resolved below within the FSI driver and allow the application of the
dmaeengine conversion that depends on this resolution.
Linux 3.3-rc4
Conflicts:
sound/soc/sh/fsi.c
This fixes below build warning:
WARNING: vmlinux.o(.text+0x1e632c): Section mismatch in reference from the function pxa2xx_ac97_probe() to the function .devinit.text:pxa2xx_ac97_hw_probe()
The function pxa2xx_ac97_probe() references
the function __devinit pxa2xx_ac97_hw_probe().
This is often because pxa2xx_ac97_probe lacks a __devinit
annotation or the annotation of pxa2xx_ac97_hw_probe is wrong.
Also rename pxa_ac97_dai to pxa_ac97_dai_driver to fix below build warning:
LD sound/soc/pxa/built-in.o
WARNING: sound/soc/pxa/built-in.o(.data+0x18c): Section mismatch in reference from the variable pxa_ac97_dai to the function .devinit.text:pxa2xx_ac97_probe()
The variable pxa_ac97_dai references
the function __devinit pxa2xx_ac97_probe()
If the reference is valid then annotate the
variable with __init* or __refdata (see linux/init.h) or name the variable:
*driver, *_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Showing the returned values on error messages is useful information.
While at it, use pr_err/pr_warn whenever possible.
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
While it matches the current code only bringing the device out of reset
isn't actually doing what the function says so make sure we set the GPIO
high before we pull it low.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Clevo machines with ALC880 are all well with proper BIOS setup.
It seems still requiring the additional COEF setup for the EAPD.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Refactor the DAC filling function to be used for both the primary
line outputs and extra outputs using the individual badness tables.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The Medion W810 with ALC880 has a typical BIOS bug, copying the
pin-defaults without disabling the unused pins. At least, the pin
0x17 must be disabled. Also, it requires GPIO-2 setup.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This means we don't need to walk through every single widget in the system
for each stream event which is a bit less silly.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
In order to allow us to do smarter things with DAI links create DAPM
widgets which directly represent the DAIs in the DAPM graph. These are
automatically created from the DAIs as we probe the card with references
held in both directions between the widget and the DAI.
The widgets are not made available for direct instantiation by drivers,
they are created automatically from the DAIs. Drivers should be updated
to create stream routes using DAPM maps rather than by annotating AIF
and DAC widgets with streams.
In order to ease transition to this model from existing drivers we
automatically create DAPM routes between the DAI widgets and the existing
stream widgets which are started and stopped by the DAI widgets, though
the old stream handling mechanism is still in place. This also has the
nice effect of removing non-DAPM devices as any device with a DAI
acquires a widget automatically which will allow future simplifications
to the core DAPM logic.
The intention is that in future the AIF and DAI widgets will gain the
ability to interact such that we are able to manage activity on
individual channels independantly rather than powering up and down the
entire AIF as we do currently.
Currently we only generate these for CODECs, mostly as I have no systems
with non-CODEC DAPM to integrate with. It should be a simple matter of
programming to add the additional hookup for these.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Neater and avoids warnings when used in other places where const strings
are desired.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
In order to allow us to do something smarter than iterate through widgets
doing strcmp() to work out what to power up for stream events change the
interface used to generate them to be based on the combination of a DAI
and a stream direction rather than just a simple string identifying the
stream.
At some point we'll probably want a set of channels too.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Let the caller fiddle with the widget after we're done in order to
facilitate further refactoring.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Everything now uses snd_soc_dapm_new_controls() instead so we don't need
to make it part of the external API.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
This fixes below build warning:
CC sound/soc/pxa/spitz.o
sound/soc/pxa/spitz.c: In function 'spitz_startup':
sound/soc/pxa/spitz.c:116: warning: passing argument 1 of 'spitz_ext_control' from incompatible pointer type
sound/soc/pxa/spitz.c:47: note: expected 'struct snd_soc_card *' but argument is of type 'struct snd_soc_codec *'
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
ALC880 model=lg could work fine with the auto-parser due to the recent
rewrite, but it still needs the manual adjustment; namely, the BIOS leaves
unused pins as some real active jacks. This confuses the parser.
Thus we just cover these pins and override the pin-configs as a fix-up.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Try harder to fit the multi-io pins also by checking the hard-wired
connections for multi-ios. Also, the badness values are adjusted to
prioritize the multi-ios as more valuable. These changes will enable
the multi-io on some machines without losing the current capability.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The previous fix for the speaker on Acer Aspire 59135 introduced
another problem for surround outputs. It changed the connections on
the line-in/mic pins for limiting the routes, but it left the modified
connections. Thus wrong connection indices were written when set to
4ch or 6ch mode.
This patch fixes it by restoring the right connections just after
parsing the tree but before the initialization.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=42740
Cc: <stable@kernel.org> [v3.2+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This allows userspace control of final power off, allowing policy decisions
for register configuration retention.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Only enable and disable the FLL when explicitly told to, supporting some
additional use cases and making the driver behaviour more standard.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Make sure we update for any changes in cases where we reconfigure while
live (eg, for analogue bypass).
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
So far, the Realtek driver tires to assign the single-connected routes
for all pins only once at the beginning. However, since some DACs have
been already mapped, the rest pins might have also single conections.
In this patch, the driver does the single-connection assignment in a
loop until all possbile single-connections are checked. This will
improve the DAC assignment, e.g. for ASUS G72.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This patch improves the Realtek auto-parser for assigning the DACs and
mixers in more suitable ways by evaluating the assignment with "badness"
calculations.
When assigning a DAC hinders the assignment of individual DACs for
other pins, some badness point is given. Similarly, when it blocks the
assignment of unique mixer controls, another badness point is added.
Also, if no DAC, even shared DAC, can be assigned, more badness is
pointed. Finally, comparing the accumulated badness, the best route is
chosen among several trials.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When the connections from the pin selector contain only two
widgets, a route to DAC and the aa-mixer, it's certainly a
single connection. In such a case, get_dac_if_single() should
return the connected DAC, too.
This will improve the detection of the individual DAC
assignment for each pin.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Machine kcontrols now use card instead of codec for thier "chip".
Signed-off-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The bitmap introduced in the commit [527e4d73: ALSA: hda/realtek - Fix
missing volume controls with ALC260] is too narrow for some codecs,
which may have more NIDs than 0x20, thus it may overflow the bitmap
array on them.
Just double the number to cover all and also add a sanity-check code
to be safer.
Cc: <stable@kernel.org> [v3.2+]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
We've enabled the static fixups for ASUS machines with ALC269 codec,
just for making things compatible during the transition to the auto-
parser. However, it seems that the static configurations do more harmful
than good, as some of entries don't match with the actual hardware setups.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Now we can clean up all static quirks for ALC260.
Also many codes in alc_quirks.c can be ripped off since they have been
used only by ALC260 static quirks.
Signed-off-by: Takashi Iwai <tiwai@suse.de>