Although the vmaster controls are created, they aren't registered thus
they don't appear in the real world. Added the missing snd_ctl_add()
calls.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Cc: <stable@kernel.org>
ALSA sound/core/control.c:232: Control name 'Sigmatel Surround Phase
Inversion Playback Switch' truncated to 'Sigmatel Surround Phase
Inversion Playback ' bootup message by omitting weird Sigmatel prefix
in this case; also fix up the related ca0106 mixer control removal
part by using identical naming there.
Signed-off-by: Andreas Mohr <andi@lisas.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32)
Signed-off-by: Yang Hongyang<yanghy@cn.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
The capture with 44.1kHz on ca0106 seems to cause loud noises on
later playbacks, which doesn't support 44.1kHz. A simple fix is to
disable 44.1kHz, as the "default" PCM with dsnoop is anyway only with
48kHz.
Reference: Novell bnc#447624
https://bugzilla.novell.com/show_bug.cgi?id=447624
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Added "IEC958 PCM Stream" controls for the per-stream IEC958 status
bits. Using this instead of "IEC958 Default" is safer since the status
bits will be recovered to the default states after closing the PCM
stream.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This patch removes an inconsistency that became apparent when I
documented the fields of snd_ca0106_details. spi_dac is always
used in a 'boolean' sense, so this cleanup should make no difference.
[Actually, there is one place checking explicitly spi_dac == 1, so
this will change the behavior. But, supposing it's rather a typo,
I apply this clean-up patch -- tiwai]
Signed-off-by: Ben Stanley <Ben.Stanley@exemail.com.au>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi wrote an email [1] explaining the fields of snd_ca0106_details,
so I captured the information into the ca0106.h header file.
[1] http://article.gmane.org/gmane.linux.alsa.devel/56783/match=takashi+gpio_type
Signed-off-by: Ben Stanley <Ben.Stanley@exemail.com.au>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The return value of pci_enable_device() must be checked even in resume
callback:
sound/pci/ca0106/ca0106_main.c:1779: warning: ignoring return value of ‘pci_enable_device’, declared with attribute warn_unused_result
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Kill snd_assert() in sound/pci/*, either removed or replaced with
if () with snd_BUG_ON().
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Correct a previous patch for the ca0106 onboard the MSI K8N Diamond PLUS
motherboard. Confirmed to have Line/Mic/Aux working for input, and sound
output working as expected.
Signed-off-by: Travis Place <wishie@wishie.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Added an entry for another MSI K8N Diamond mobo with SSID 1102:1009.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
The irq handler of PCI drivers must be released before releasing other
resources since the handler for a shared irq can be still called and
may access the freed resource again.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Change the variable err to _err within the ADD_CTLS macro to avoid
shadowing the local variable.
sound/pci/ca0106/ca0106_mixer.c:710:2: warning: symbol 'err' shadows an earlier one
sound/pci/ca0106/ca0106_mixer.c:663:6: originally declared here
sound/pci/ca0106/ca0106_mixer.c:712:3: warning: symbol 'err' shadows an earlier one
sound/pci/ca0106/ca0106_mixer.c:663:6: originally declared here
sound/pci/ca0106/ca0106_mixer.c:721:3: warning: symbol 'err' shadows an earlier one
sound/pci/ca0106/ca0106_mixer.c:663:6: originally declared here
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
change to intr_enable as per the two functions it is defined in.
sound/pci/ca0106/ca0106_main.c:438:15: warning: symbol 'enable' shadows an earlier one
sound/pci/ca0106/ca0106_main.c:159:12: originally declared here
sound/pci/ca0106/ca0106_main.c:449:15: warning: symbol 'enable' shadows an earlier one
sound/pci/ca0106/ca0106_main.c:159:12: originally declared here
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This header file exists only for some hacks to adapt alsa-driver
tree. It's useless for building in the kernel. Let's move a few
lines in it to sound/core.h and remove it.
With this patch, sound/driver.h isn't removed but has just a single
compile warning to include it. This should be really killed in
future.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Remove line duplications in defines.
Acked-by: Thomas Sailer <sailer@ife.ee.ethz.ch>
Signed-off-by: Nicolas Kaiser <nikai@nikai.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
The driver assigns the write proc callback to read wrongly.
Fixed now.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Check the value ranges in ctl put callbacks properly.
Some callbacks may access a wrong pointer depending on the value passed.
Also, fixed the access to the wrong field for enum values, and fixed
some callbacks to return the proper error code.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Set the SNDRV_PCM_INFO_SYNC_START flag and the substream's sync ID
(only) if the substream actually can be linked to another one.
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
It is possible to have linked substreams that belong to different cards
and/or different drivers. This patch changes some drivers to make sure
that they do not incorrectly try to handle substreams of a different
card.
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
The init sequence set a number of registers more than once to different
values. It's only necessary to set them once to their final values.
It also never actually updated the digital attenuation settings.
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Add more symbol name for SPI register values. Change the SPI_XXX_BIT defines
from the bit number to a mask. Saves having to write (1<<SPI_XXX_BIT) all the
time to convert to mask. We never end up wanting the bit number.
Use all the symbol names for the SPI DAC init sequence. The sequence is
exactly the same as it was before.
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
For cards with an SPI DAC (SB Live 24-bit / Audigy SE), power down channels
0-2 when not in use. They are powered up on PCM open and down again on PCM
close. Channel 4 (== Front) is not powered down, as it is used for capture
feedback. Powering it down would effectively kill line in pass-through.
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Turn a rather long lined for loop that is duplicated multiple times into a
macro.
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Add four mute controls for the analog output channels for cards that use
an SPI DAC, like the SB0570 SB Live! 24-bit / Audigy SE. The Wolfson DAC
doesn't support muting left/right so the controls are mono.
The chip state struct gets a 32-byte array to act as a shadow of the spi
dac registers. Only two registers are used for mute, but more would be
needed for analog gain, de-emphasis, DAC power down, phase inversion, and
other features.
Signed-off-by: Trent Piepho <xyzzy@speakeasy.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Clean up codes using the new common snd_ctl_boolean_*_info() callbacks.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
This card is just a normal SB Live 24bit,
but under a different marketing name.
Signed-off-by: James Courtier-Dutton <James@superbug.co.uk>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Instead of all drivers reading pci config space to get the revision
ID, they can now use the pci_device->revision member.
This exposes some issues where drivers where reading a word or a dword
for the revision number, and adding useless error-handling around the
read. Some drivers even just read it for no purpose of all.
In devices where the revision ID is being copied over and used in what
appears to be the equivalent of hotpath, I have left the copy code
and the cached copy as not to influence the driver's performance.
Compile tested with make all{yes,mod}config on x86_64 and i386.
Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Acked-by: Dave Jones <davej@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>