Don't pass the advanced position to strlcat() but just gives the buffer
head position so that the max size limit can be checked correctly.
Introduced a new helper function to standaralize strlcat() calls.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The remove callback has to be marked as __devexit, as the dynamic unbind
is possible.
Reported-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The auto-parser for ALC662/663/272 codecs doesn't work properly when
a speaker is connected to mono NID 0x17, and doesn't handle the dynamic
DAC assignment properly.
This patch fixes the issues and also improves the assignment of DACs
so that HP and speakers can have independent volume controls.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
On Soundblaster X-FI Titenium with emu20k2 the SIDE and SURROUND mute
functions are swapped.
It was checked with 'speaker-test -c 8 -s 3' and (un)mute surround or
'speaker-test -c 8 -s 7' and (un)mute side. The volume seems not
to be affected and works as expected.
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
I can't see any reason for struct i2c_driver keywest_driver to not be
static.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
BugLink: https://bugs.launchpad.net/bugs/410933
This Sony VAIO model also needs External Amplifier unmuted for audible
playback, so make sure we set the inv_eapd quirk.
Signed-off-by: Daniel T Chen <crimsun@ubuntu.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When the auto-mic switching between an analog and a digital mic is
needed with IDT codecs, the current driver doesn't reset the connection
of the digital mux.
This patch fixes the behavior by checking both mux connections properly.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Some of the Blackfin options don't directly follow the kconfig options
they depend on, so kconfig is unable to display the proper tree. So sort
the options such they expand/collapse properly.
Signed-off-by: Barry Song <barry.song@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Patch was tested on Toshiba NB200 and is found to enable sound.
Signed-off-by: Manoj Iyer <manoj.iyer@canonical.com>
Cc: stable@kernel.org
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The client->driver pointer can be NULL when i2c-device probing fails
in i2c_new_device(). This patch adds the NULL checks for client->driver
and return the error instead of blind assumption of driver availability.
Reported-by: Tim Shepard <shep@alum.mit.edu>
Cc: Jean Delvare <khali@linux-fr.org>
Cc: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
BugLink: https://bugs.launchpad.net/bugs/410933
This Sony VAIO model needs External Amplifier unmuted for audible
playback, so make sure we set the inv_eapd quirk.
Signed-off-by: Daniel T Chen <crimsun@ubuntu.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Mia has an undocumented line-out control, and it has to be exposed.
Signed-off-by: Giuliano Pochini <pochini@shiny.it>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
In the commit fdbc66266c, I mistakenly
replaced the capture mixer array for ALC268_ACER to nosrc version
although this should be kept to alt_mixer. Now fixed back.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Reference: ALSA bug #0004614https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4614
port-A (0x11) - front hp-out
port-D (0x12) - rear line out
port-E (0x1c) - front mic-in
port-F (0x16) - Internal speakers
digital-mic (0x17) - Internal mic
init verbs, mixers, jack sensing and PCI_QUIRK to support this hardware
Signed-off-by: Miguel de Barros <miguel.de.barros@bluewin.ch>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
* mark struct vm_area_struct::vm_ops as const
* mark vm_ops in AGP code
But leave TTM code alone, something is fishy there with global vm_ops
being used.
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
After puting a cd-audio inside my laptop there was no sound out here,
so I decided to install alsa-driver with debug level and setup a
model=test, it didn't help, but then I look at source code and added
this few lines, now cd-audio is working both when playback/recording.
[Additional minor fixes of mixer element/item names by tiwai]
Signed-off-by: Lukasz Marcinowski <nowymarluk@wp.pl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
McASP write FIFO registers should be modified for playback and read FIFO
registers for capture. Check the PCM mode before manipulating the
FIFO registers. Currently, irrespective of playback/capture both the
FIFOs are enabled or disbaled. This resulted in errors in audio loopback
mode.
Signed-off-by: Chaithrika U S <chaithrika@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This patch removes references to cpu_dai->dma_data.
It makes struct davinci_pcm_dma_params part of
struct davinci_mcbsp_dev or struct davinci_audio_dev.
It removes the unused name variable from davinci_pcm_dma_params.
Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
When both playback and capture stream were open
davinci_i2s_hw_params was setting parameters for
the wrong stream. The fix for davinci_i2s_hw_params
is sufficient, but it looks like a race still happens
in davici_pcm_open. This patch also makes the race smaller
but the next patch provides a better fix.
Signed-off-by: Troy Kisky <troy.kisky@boundarydevices.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* 'fix/asoc' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
ASoC: wm8753: fix mapping when MONOMIX is set to Stereo
ASoC: some minor changes for AD1836 and AD1938 codec drivers
ASoC: DaVinci: Fixes to McASP configuration
ASoC: Blackfin I2S: fix resuming when device hasn't been used
ASoC: Blackfin I2S: add lost platform_device parameter to resume function
ASoC: fix typos in Blackfin headers
ASoC: bf5xx-sport: the irq save/restore funcs take an unsigned long
ASoC: Blackfin AC97: add a few missing multichannel define handling
Signed-off-by: Cliff Cai <cliff.cai@analog.com>
Signed-off-by: Barry Song <barry.song@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
When MONOMIX is set to Stereo, Left PGA was not powered on but should be.
Add a mapping from Capture Left Mux to Capture Left Mixer to fix the issue.
Signed-off-by: Phil Vandry <vandry@TZoNE.ORG>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
1. delete redundant assignment to bus field in spi_driver structure
2. fix lost assignment to set_bias_level entry in ad1938 codec dai
3. change spi driver name of ad1836 from "ad1836-spi" to "ad1836"
Signed-off-by: Barry Song <barry.song@analog.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Get rid of that commented usage of the now defunct MODULE_PARM macro.
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
we cannot set the sampling rate of the device, but can only read it
from the board, so we don't need the member for it.
Signed-off-by: Tim Blechmann <tim@klingt.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
the rmh bus is not used asynchronously, so it is safe to remove the
specific code pieces.
Signed-off-by: Tim Blechmann <tim@klingt.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Simplify snd_pcm_drain() implementation and avoid unneeded array-
allocation for waitqueues. Instead, one waitqueue is used for the
first draining stream, and wait until all streams finished.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This allows subsytems to provide devtmpfs with non-default permissions
for the device node. Instead of the default mode of 0600, null, zero,
random, urandom, full, tty, ptmx now have a mode of 0666, which allows
non-privileged processes to access standard device nodes in case no
other userspace process applies the expected permissions.
This also fixes a wrong assignment in pktcdvd and a checkpatch.pl complain.
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* 'davinci-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-davinci: (62 commits)
DaVinci: DM646x - platform changes for vpif capture and display drivers
davinci: DM355 - platform changes for vpfe capture
davinci: DM644x platform changes for vpfe capture
davinci: audio: move tlv320aic33 i2c setup into board files
DaVinci: EDMA: Adding 2 new APIs for allocating/freeing PARAMs
DaVinci: DM365: Adding entries for DM365 IRQ's
DaVinci: DM355: Adding PINMUX entries for DM355 Display
davinci: Handle pinmux conflict between mmc/sd and nor flash
davinci: Add NOR flash support for da850/omap-l138
davinci: Add NAND flash support for DA850/OMAP-L138
davinci: Add MMC/SD support for da850/omap-l138
davinci: Add platform support for da850/omap-l138 GLCD
davinci: Macro to convert GPIO signal to GPIO pin number
davinci: Audio support for DA850/OMAP-L138 EVM
davinci: Audio support for DA830 EVM
davinci: Correct the number of GPIO pins for da850/omap-l138
davinci: Configure MDIO pins for EMAC
DaVinci: DM365: Add Support for new Revision of silicon
DaVinci: DM365: Fix Compilation issue due to PINMUX entry
DaVinci: EDMA: Updating default queue handling
...
McASP register settings are not correct for DSP mode of operation.
There is a channel swap initally. This patch provides fixes to
the register values for proper working.
Tested on DA830/OMAP-L137 EVM, DM6467 EVM.
Signed-off-by: Chaithrika U S <chaithrika@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
If the sound system hasn't been utilized yet and we suspend, then we
attempt to save/restore using state that doesn't exist. So use a global
handle instead to reconfigure properly.
Signed-off-by: Cliff Cai <cliff.cai@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* fix/asoc:
ASoC: remove unused #include <linux/version.h>
ASoC: S3C lrsync function made to work with IRQs disabled.
ASoC: Fix display of stream name in DAPM debugfs
ASoC: Clean up error handling in MPC5200 DMA setup
The headphone and speaker mixer elements aren't properly set for
MSI GX620 with targa-8ch-dig quirk.
Also fixed the speaker volume control for other ALC883-targa quirks,
too.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Commit dc7d7b830e trimmed the platform_device parameter from all of the
suspend functions, but it also accidentally removed it from the resume
function in the Blackfin I2S driver. So restore it.
Signed-off-by: Barry Song <barry.song@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Barry Song <barry.song@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Somewhere along the line, most of SND_BF5XX_MULTICHAN_SUPPORT handling was
merged, but two places were missed (the probe/resume functions). Restore
handling of this option so it gets initialized properly.
Signed-off-by: Cliff Cai <cliff.cai@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>