Fix a few uninitialized error checks that were introduced recently
mistakenlly during the clean-up:
sound/pci/ctxfi/ctamixer.c: In function ‘get_amixer_rsc’:
sound/pci/ctxfi/ctamixer.c:261: warning: ‘err’ may be used uninitialized in this function
sound/pci/ctxfi/ctamixer.c: In function ‘get_sum_rsc’:
sound/pci/ctxfi/ctamixer.c:415: warning: ‘err’ may be used uninitialized in this function
sound/pci/ctxfi/ctsrc.c: In function ‘get_srcimp_rsc’:
sound/pci/ctxfi/ctsrc.c:742: warning: ‘err’ may be used uninitialized in this function
Signed-off-by: Takashi Iwai <tiwai@suse.de>
On Soundblaster X-FI Titanium with emu20k2 the SIDE and SURROUND
channels were swapped and wrong.
I double checked it with connector colors and creative soundblaster
windows drivers.
So I swapped them to the true order.
Now "speaker-test -c6" and "speaker-test -c8" are working fine.
Signed-off-by: Frank Roth <frashman@freenet.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Simplify ALC882_TARGA and return gpio3 to ALC883_TARGA_DIG and
ALC883_TARGA_2ch_DIG, which I accidentally removed in commit id
64a8be7435
Signed-off-by: David Heidelberger <d.okias@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
In the beep tone calculation for IDT/STAC codecs, lower numbers correspond
to higher frequencies and vice versa. The current code has this backwards,
resulting in beep frequencies which are way too high (and sound bad on
tinny laptop speakers, resulting in complaints).
[Also added hz <= 0 check by tiwai]
Signed-off-by: Paul Vojta <vojta@math.berkeley.edu>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Commit 5fd29d6ccb ("printk: clean up
handling of log-levels and newlines") changed printk semantics. printk
lines with multiple KERN_<level> prefixes are no longer emitted as
before the patch.
<level> is now included in the output on each additional use.
Remove all uses of multiple KERN_<level>s in formats.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
There is a regression, introduced in aa202455ee
(in alsa-kernel) which I noticed when trying to use the headphone socket on
my EeeCPC 901: the output was *very* quiet, practically silent.
This patch corrects the control types to that which was obviously intended in
the referenced commit.
Signed-off-by: Darren Salt <linux@youmustbejoking.demon.co.uk>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
HDA driver disabled HD audio 64bit address support for all AMD
SB600/SB700/SB800 platforms with commit
09240cf429 due to one SB600 issue
reported by community, but we do not see the similar issue on
SB700/SB800 platforms.
This patch is to refine the workaround for SB600 only.
Signed-off-by: Andiry Xu <andiry.xu@amd.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Check the widget type and don't take invalid widgets while parsing
the capture source in patch_via.c.
Also, fixed some compile warnings introduced in the previous commit.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The fixed widget NIDs in patch_via.c seem wrong for some codecs,
and it resulted in the invalid capture source selection.
This patch adds the code to parse the topology instead of using
fixed numbers in order to get the right MUX widget id corresponding
to the ADCs.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
If the output pin is used and EAPD capability is present, turn on
the EAPD bit. This fixes the silent output problem on ASUS laptops
with VT1708S codec.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
* fix/hda:
ALSA: hda - Add sanity check in PCM open callback
ALSA: hda - Call snd_pcm_lib_hw_rates() again after codec open callback
ALSA: hda - Avoid invalid formats and rates with shared SPDIF
ALSA: hda - Improve ASUS eeePC 1000 mixer
ALSA: hda - Add GPIO1 control at muting with HP laptops
Add some sanity checks of struct snd_pcm_hardware fields in the PCM
open callback of hda driver. This makes a bit easier to debug any PCM
setup errors in the codec side.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The PCM rates bit field may have been changed by the codec open callback.
In that case, we need to reset rate_min and rate_max. So, simply call
snd_pcm_lib_hw_rates() again after the codec open callback.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Check whether formats and rates don't result in zero due to the
restriction of SPDIF sharing. If any of them can be zero, disable
the SPDIF sharing mode instead. Otherwise it will lead to a PCM
configuration error.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The mixer elements created for ASUS eeePC 1000 with ALC269 aren't
standard but strange words like "LineOut". Rename the element names
to follow the standard one like "Headphone" and "Speaker".
Also, split the volumes to each so that the virtual master can control
them.
The alc269_fujitsu_mixer is removed because it's now identical with
the new eeepc mixer.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
HP laptops with AD1984A codecs (at least mobile models) need to set
GPIO1 appropriately to indicate the mute state. The BIOS checks this
bit to judge whether the mute on or off is sent via F8 key.
Without changing this bit, the BIOS can be confused and may toggle
the mute wrongly.
Reference: Novell bnc#515266
https://bugzilla.novell.com/show_bug.cgi?id=515266
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When resuming, we better take the DACs out of the reset state before
trying to use them.
Reference: kernel bug #13599http://bugzilla.kernel.org/show_bug.cgi?id=13599
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
During the changes to clean up / fix the realtek codec initialization
routines in commit 4a79ba34ca,
I forgot to add the check for ALC268 and ALC269.
This resulted in the missing EAPD and COEF setup for these codecs.
This patch adds the missing checks for these codecs.
Reference: bko#13633
http://bugzilla.kernel.org/show_bug.cgi?id=13633
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The Line In connector is set up as PIN_IN by default, using
VREF_HIZ. It is connected to both ADCs, so add it to both
input selectors.
Also add the ability to use the input mix (on a SoundBlaster
one would call this "What You Hear").
Signed-off-by: Tony Vroon <tony@linx.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The microphone input and its volume register have only one channel, so
we have to make the corresponding mixer control a mono control.
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
as long as the io channel number is not set by the driver, the card
is not visible from the ethersound network
Signed-off-by: Tim Blechmann <tim@klingt.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Here's a patch on top of the others to use CREATIVE and ECTIVA
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Fix the following bugs of acer-aspire-6530g model with ALC888:
- HP jack to mute all speaker outputs including LFE
- Make digital built-in mic working
Signed-off-by: Emilio López <buhitoescolar@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Realtek codecs require the pin-sense trigger call before actually
reading the pin-sense. Without this, the pin-detection might not be
done accurately.
This patch adds the pin-capability check and issues the trigger call
if required.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Samsung P50 requires the HP auto-muting unlike other Samsung models.
Added a new model=samsung-p50 to support this.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Add a new flag to ad_spec struct so that the same hack can be used for
any other models (if any). This also allows other models to reuse the
auto-mute functions.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Split mixer element arrays of AD1986A models to several pieces so that
each model can share the same mixer arrays.
This removes lots of duplicated data.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
ALSA: hda - Make jack-plug notification selectable
ALSA: ctxfi - Add PM support
sound: seq_midi_event: fix decoding of (N)RPN events
ALSA: hda - Add digital-mic support to ALC262 auto model
ALSA: hda - Fix check of input source type for realtek codecs
ALSA: hda - Add quirk for Sony VAIO Z21MN
ALSA: hda - Get back Input Source for ALC262 toshiba-s06 model
ALSA: hda - Fix unsigned comparison in patch_sigmatel.c
ALSA: via82xx: add option to disable 500ms delay in snd_via82xx_codec_wait
sound: fix check for return value in snd_pcm_hw_refine
ALSA: ctxfi - Allow unknown PCI SSIDs
ASoC: Blackfin: update the bf5xx_i2s_resume parameters
ASoC: Blackfin: keep better track of SPORT configuration state
* topic/hda:
ALSA: hda - Make jack-plug notification selectable
ALSA: hda - Add digital-mic support to ALC262 auto model
ALSA: hda - Fix check of input source type for realtek codecs
ALSA: hda - Add quirk for Sony VAIO Z21MN
ALSA: hda - Get back Input Source for ALC262 toshiba-s06 model
ALSA: hda - Fix unsigned comparison in patch_sigmatel.c
Make the jack-plug notification via input layer selectable via Kconfig.
This is often unnecessary, and the similr function will be provided
using the ALSA control API in near future anyway.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Added the suspend/resume support to ctxfi driver.
The team tested on the following seems ok:
AMD Athlon 64 3500+ / ASUS A8N-E / 512MB DDR ATI / Radeon X1300
20k1 & 20k2 cards
Signed-off-by: Wai Yew CHAY <wychay@ctl.creative.com>
Singed-off-by: Ryan RICHARDS <ryan_richards@creativelabs.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Add the digital-mic support with ALC262 auto model.
The new ALC262 models have the digital mic at NID 0x12. This widget
isn't checked in the current alc262_auto_create_analog_input_ctls()
since it's under 0x18. So, just reuse the routine for alc269 to fix
the behavior.
But, it doesn't suffice: the digital mic is supported only with the
ADC0, we have to exclude other ADCs when d-mic is detected.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Fix the check of the input-source type by checking the widget type of
each capture-source item. Since some codecs can have both the mixer
and selector types depending on the ADC, alc_mux_enum_put() needs to
check each widget.
With this change, spec->capture_style gets unneeded, so it's removed,
too.
Signed-off-by: Takashi Iwai <tiwai@suse.de>