Commit Graph

2846 Commits (4a703a8fe562824f269943d995ddff35077253a9)

Author SHA1 Message Date
Takashi Iwai 337b9d02b4 ALSA: hda - Fix capture source selection in patch_via.c
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>
2009-07-07 18:20:23 +02:00
Takashi Iwai d3a11e601a ALSA: hda - Add missing EAPD initialization for VIA codecs
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>
2009-07-07 13:44:29 +02:00
Takashi Iwai 55d1d6c1ef ALSA: hda - Clean up VT170x dig-in initialization code
Minor clean up for initializing the digital-in pin.
No functional changes.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-07-07 13:39:03 +02:00
Takashi Iwai aba6653617 ALSA: hda - Fix error path in the sanity check in azx_pcm_open()
Release resources cleanly after errors in the sanity check in
azx_pcm_open().

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-07-05 11:44:46 +02:00
Herton Ronaldo Krzesinski 02358fcfa5 ALSA: hda - move 8086:fb30 quirk (stac9205) to the proper section
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-07-04 12:20:16 +02:00
Takashi Iwai 854ace9c40 Merge branch 'fix/hda' into for-linus
* 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
2009-07-03 23:50:45 +02:00
Takashi Iwai c470331e69 ALSA: hda - Add sanity check in PCM open callback
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>
2009-07-03 23:10:23 +02:00
Takashi Iwai 70d321e638 ALSA: hda - Call snd_pcm_lib_hw_rates() again after codec open callback
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>
2009-07-03 23:06:45 +02:00
Takashi Iwai 022b466fc3 ALSA: hda - Avoid invalid formats and rates with shared SPDIF
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>
2009-07-03 23:03:30 +02:00
Takashi Iwai aa202455ee ALSA: hda - Improve ASUS eeePC 1000 mixer
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>
2009-07-03 15:00:54 +02:00
Takashi Iwai 099db17e66 ALSA: hda - Add GPIO1 control at muting with HP laptops
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>
2009-07-03 14:58:59 +02:00
Takashi Iwai dbe45d0ce3 Merge branch 'fix/oxygen' into for-linus
* fix/oxygen:
  sound: virtuoso: fix Xonar D1/DX silence after resume
2009-07-02 17:48:34 +02:00
Takashi Iwai 4413c8d2be Merge branch 'fix/hda' into for-linus
* fix/hda:
  ALSA: hda - Add quirk for HP 6930p
  ALSA: hda - Add missing static to patch_ca0110()
2009-07-02 17:48:33 +02:00
Clemens Ladisch 826390796d sound: virtuoso: fix Xonar D1/DX silence after resume
When resuming, we better take the DACs out of the reset state before
trying to use them.

Reference: kernel bug #13599
	http://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>
2009-07-02 10:35:35 +02:00
Takashi Iwai ff84847171 ALSA: hda - Add quirk for HP 6930p
Added a quirk model=laptop for HP 6930p (103c:30dc) with AD1984A codec.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-07-01 18:08:01 +02:00
Takashi Iwai 1e1689536f ALSA: hda - Add missing static to patch_ca0110()
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-07-01 08:34:32 +02:00
Takashi Iwai 580c9d373c Merge branch 'fix/pci-vdevice' into for-linus
* fix/pci-vdevice:
  sound: Use PCI_VDEVICE for CREATIVE and ECTIVA
  sound: Use PCI_VDEVICE
2009-06-29 18:05:09 +02:00
Takashi Iwai e2cb0d95ba Merge branch 'fix/oxygen' into for-linus
* fix/oxygen:
  sound: oxygen: make mic volume control mono
2009-06-29 18:05:07 +02:00
Takashi Iwai 0baddbc895 Merge branch 'fix/lx6464es' into for-linus
* fix/lx6464es:
  ALSA: lx6464es - configure ethersound io channels
2009-06-29 18:05:05 +02:00
Takashi Iwai cdae219cec Merge branch 'fix/hda-samsung-p50' into for-linus
* fix/hda-samsung-p50:
  ALSA: hda - Fix support for Samsung P50 with AD1986A codec
  ALSA: hda - Generalize the pin-detect quirk for Lenovo N100
  ALSA: hda - Simplify AD1986A mixer definitions
2009-06-29 18:05:04 +02:00
Takashi Iwai 1d955ebd4d ALSA: hda - Add missing initializations for ALC268 and ALC269
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>
2009-06-29 11:33:53 +02:00
Tony Vroon 684a88429c ALSA: hda - Line In for Acer Inspire 6530G model
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>
2009-06-29 07:41:08 +02:00
Clemens Ladisch 14744d7da2 sound: oxygen: make mic volume control mono
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>
2009-06-25 15:39:02 +02:00
Tim Blechmann 7e895cfaad ALSA: lx6464es - configure ethersound io channels
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>
2009-06-25 09:41:53 +02:00
Joe Perches 0d7392e544 sound: Use PCI_VDEVICE for CREATIVE and ECTIVA
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>
2009-06-25 08:53:57 +02:00
Joe Perches 28d27aae94 sound: Use PCI_VDEVICE
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-25 08:52:49 +02:00
Takashi Iwai dde6535686 ALSA: hda - Use model=acer-aspire-6530g for Acer Aspire 6930G
For Acer Aspire 6930G (1025:015e), acre-aspire-6530g model matches
obviously better.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-25 08:26:38 +02:00
Emilio López 320d592001 ALSA: hda - Fix acer-aspire-6530g model quirk
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>
2009-06-25 08:25:22 +02:00
Takashi Iwai 261c240740 ALSA: hda - Add pin-sense trigger when needed for Realtek codecs
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>
2009-06-25 08:15:03 +02:00
Takashi Iwai c912e7a580 ALSA: hda - Fix support for Samsung P50 with AD1986A codec
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>
2009-06-24 14:14:34 +02:00
Takashi Iwai 03c405ad31 ALSA: hda - Generalize the pin-detect quirk for Lenovo N100
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>
2009-06-24 14:10:15 +02:00
Takashi Iwai 16d11a829e ALSA: hda - Simplify AD1986A mixer definitions
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>
2009-06-24 14:07:53 +02:00
Linus Torvalds c488eef815 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* '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
2009-06-23 10:45:39 -07:00
Takashi Iwai b61eaa924c Merge branch 'topic/misc' into for-linus
* topic/misc:
  ALSA: via82xx: add option to disable 500ms delay in snd_via82xx_codec_wait
2009-06-22 17:03:52 +02:00
Takashi Iwai 11a93fd940 Merge branch 'topic/hda' into for-linus
* 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
2009-06-22 17:03:48 +02:00
Takashi Iwai 366890df46 Merge branch 'topic/ctxfi' into for-linus
* topic/ctxfi:
  ALSA: ctxfi - Add PM support
  ALSA: ctxfi - Allow unknown PCI SSIDs
2009-06-22 17:03:44 +02:00
Takashi Iwai 8c8145b873 ALSA: hda - Make jack-plug notification selectable
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>
2009-06-22 17:02:03 +02:00
Wai Yew CHAY 29959a09cc ALSA: ctxfi - Add PM support
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>
2009-06-22 14:53:51 +02:00
Takashi Iwai 8c927b4acf ALSA: hda - Add digital-mic support to ALC262 auto model
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>
2009-06-22 11:06:18 +02:00
Takashi Iwai 0169b6b33b ALSA: hda - Fix check of input source type for realtek codecs
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>
2009-06-22 11:06:05 +02:00
Takashi Iwai 376b508ffd ALSA: hda - Add quirk for Sony VAIO Z21MN
It needs model=toshiba-s06 to work with the digital-mic.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Cc: <stable@kernel.org>
2009-06-22 11:05:56 +02:00
Takashi Iwai ae14ef68e8 ALSA: hda - Get back Input Source for ALC262 toshiba-s06 model
The commit f9e336f65b
    ALSA: hda - Unify capture mixer creation in realtek codes
removed the "Input Source" mixer element creation for toshiba-s06 model
because it contains a digital-mic input.

This patch take the control back.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Cc: <stable@kernel.org>
2009-06-22 10:13:36 +02:00
Takashi Iwai b8621516cc ALSA: hda - Fix unsigned comparison in patch_sigmatel.c
Fix the comparison of unsigned int that causes a compile warning below
by changing to the right signed type:
  patch_sigmatel.c: In function ‘stac92xx_vref_set’:
  patch_sigmatel.c:658: warning: comparison of unsigned expression < 0 is always false

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-22 08:03:38 +02:00
Simon Arlott 115551d98e ALSA: via82xx: add option to disable 500ms delay in snd_via82xx_codec_wait
There's a large 500ms delay in snd_via82xx_codec_wait() that, at least
on my hardware, appears to be unnecessary. The rest of the init of
the card works without logging any warnings or errors and both audio
and mixer settings work.

This adds an "nodelay" parameter to disable this (undocumented in the
code) large delay improving bootup time by 489-500ms.

[    1.034217] initcall alsa_card_via82xx_init+0x0/0x16 returned 0 after 505757 usecs
vs.
[    0.533136] initcall alsa_card_via82xx_init+0x0/0x16 returned 0 after 15915 usecs

Signed-off-by: Simon Arlott <simon@fire.lp0.eu>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-22 07:54:58 +02:00
Takashi Iwai a8f4310be5 ALSA: ctxfi - Allow unknown PCI SSIDs
Allow unknown PCI SSIDs for emu20k1 and emu20k2 as "unknown" model.
Also, add a black-list check in case any device has to be listed
as "unsupported".  It has a negative value in the pci quirk entry.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-22 07:36:52 +02:00
Linus Torvalds 413318444f Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ALSA: hda - Add model=6530g option
  ALSA: hda - Acer Inspire 6530G model for Realtek ALC888
  ALSA: snd_usb_caiaq: fix legacy input streaming
  ASoC: Kill BUS_ID_SIZE
  ALSA: HDA - Correct trivial typos in comments.
  ALSA: HDA - Name-fixes in code (tagra/targa)
  ALSA: HDA - Add pci-quirk for MSI MS-7350 motherboard.
  ALSA: hda - Fix memory leak at codec creation
2009-06-21 13:13:08 -07:00
Takashi Iwai 47166281d2 Merge branch 'topic/hda' into for-linus
* topic/hda:
  ALSA: hda - Add model=6530g option
  ALSA: hda - Acer Inspire 6530G model for Realtek ALC888
  ALSA: HDA - Correct trivial typos in comments.
  ALSA: HDA - Name-fixes in code (tagra/targa)
  ALSA: HDA - Add pci-quirk for MSI MS-7350 motherboard.
  ALSA: hda - Fix memory leak at codec creation
2009-06-21 10:59:12 +02:00
Takashi Iwai b1a914690c ALSA: hda - Add model=6530g option
Add the new model string corresponding to the previous Acer Aspire
6530G support.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-21 10:57:16 +02:00
Tony Vroon d2fd4b09c0 ALSA: hda - Acer Inspire 6530G model for Realtek ALC888
The selected 4930G model seemed to keep the subwoofer 'tuba'
function from operating correctly. Removing the existing PCI
ID match made this work again, but it was mapped to 'Side'
instead of to LFE as one would expect.
This attempts to enable all functionality and keep the amount
of available mixer sliders low. Any slider that had no audible
effect on the output audio has been removed, and as such EAPD
is not currently enabled.

Signed-off-by: Tony Vroon <tony@linx.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-21 10:52:14 +02:00
Andrew Morton 8e20ce94ce convert some DMA_nnBIT_MASK() callers
We're about to make DMA_nnBIT_MASK() emit `deprecated' warnings.  Convert the
remaining stragglers which are visible to the x86_64 build.

Cc: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
Cc: Eric Moore <Eric.Moore@lsil.com>
Cc: Takashi Iwai <tiwai@suse.de>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Alexander Duyck <alexander.h.duyck@intel.com>
Cc: Yi Zou <yi.zou@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-06-19 16:46:06 -07:00
Sasha Alexandr def319f9e9 ALSA: HDA - Correct trivial typos in comments.
Correct some trivial typos in comments.

Signed-off-by: Sasha Alexandr <brina_keith@ns.sympatico.ca>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-17 08:33:43 +02:00
Sasha Alexandr c259249f7d ALSA: HDA - Name-fixes in code (tagra/targa)
Correct some cut+paste typos from 'tagra' to 'targa'.

Signed-off-by: Sasha Alexandr <brina_keith@ns.sympatico.ca>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-17 08:33:34 +02:00
Sasha Alexandr df01b8af56 ALSA: HDA - Add pci-quirk for MSI MS-7350 motherboard.
Add pci-quirk for MSI MS-7350 motherboard with Realtek ALC888.

Signed-off-by: Sasha Alexandr <brina_keith@ns.sympatico.ca>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-17 08:33:13 +02:00
Takashi Iwai f75dcc87fe ALSA: hda - Fix memory leak at codec creation
The codec->modelname field is allocated twice in snd_hda_codec_new().

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-17 08:22:32 +02:00
Linus Torvalds 661adc423d Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
  ALSA: ctxfi - Fix deadlock with xfi-timer
  ALSA: intel8x0 - Fix PCM position craziness
  ALSA: usb-audio - rework quirk for TerraTec Aureon USB 5.1 MkII
  ASoC: magician: fix PXA SSP clock polarity
  ASoC: Instantiate any forgotten DAPM widgets
  ASoC: Revert duplicated code in SSM2602 driver
  ALSA: hda - Add quirk for Acer Aspire 6935G
  ALSA: ctxfi - Replace atc lock to mutex
  ASoC: Remove odd bit clock ratios for WM8903
2009-06-16 12:10:31 -07:00
Takashi Iwai b909005ce1 Merge branch 'topic/intel8x0' into for-linus
* topic/intel8x0:
  ALSA: intel8x0 - Fix PCM position craziness
2009-06-16 17:38:46 +02:00
Takashi Iwai 7998d90a14 Merge branch 'topic/hda' into for-linus
* topic/hda:
  ALSA: hda - Add quirk for Acer Aspire 6935G
2009-06-16 17:38:43 +02:00
Takashi Iwai 3d2aa66dda Merge branch 'topic/ctxfi' into for-linus
* topic/ctxfi:
  ALSA: ctxfi - Fix deadlock with xfi-timer
  ALSA: ctxfi - Replace atc lock to mutex
2009-06-16 17:38:40 +02:00
Takashi Iwai 8dca419721 ALSA: ctxfi - Fix deadlock with xfi-timer
The PCM x-fi native update routine can cause deadlocks when the
trigger(START) is called while the stream is running.

This patch fixes the deadlock by just postponing the pcm period update
to the next possible wake-up.  Also it adds the flip of ti->running
flag (just to be sure as now).

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-15 14:52:55 +02:00
Takashi Iwai f708eb1d71 ALSA: intel8x0 - Fix PCM position craziness
The PCM pointer callback sometimes returns invalid positions and this
screws up the hw_ptr updater in PCM core.  Especially since now the
jiffies check is optional with xrun_debug, the invalid position is
handled as is, and causes serious sound skips, etc.

This patch simplifies the position-fix strategy in intel8x0 to be more
robust:
- just falls back to the last position if bogus position is detected
- another sanity check for the backward move of the position due to
  a race of register update and the base-index update

This patch is applicable also for 2.6.30.

Tested-by: David Miller <davem@davemloft.net>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-15 12:36:06 +02:00
Linus Torvalds 489f7ab6c1 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (31 commits)
  trivial: remove the trivial patch monkey's name from SubmittingPatches
  trivial: Fix a typo in comment of addrconf_dad_start()
  trivial: usb: fix missing space typo in doc
  trivial: pci hotplug: adding __init/__exit macros to sgi_hotplug
  trivial: Remove the hyphen from git commands
  trivial: fix ETIMEOUT -> ETIMEDOUT typos
  trivial: Kconfig: .ko is normally not included in module names
  trivial: SubmittingPatches: fix typo
  trivial: Documentation/dell_rbu.txt: fix typos
  trivial: Fix Pavel's address in MAINTAINERS
  trivial: ftrace:fix description of trace directory
  trivial: unnecessary (void*) cast removal in sound/oss/msnd.c
  trivial: input/misc: Fix typo in Kconfig
  trivial: fix grammo in bus_for_each_dev() kerneldoc
  trivial: rbtree.txt: fix rb_entry() parameters in sample code
  trivial: spelling fix in ppc code comments
  trivial: fix typo in bio_alloc kernel doc
  trivial: Documentation/rbtree.txt: cleanup kerneldoc of rbtree.txt
  trivial: Miscellaneous documentation typo fixes
  trivial: fix typo milisecond/millisecond for documentation and source comments.
  ...
2009-06-14 13:46:25 -07:00
Takashi Iwai e46b0c8c08 ALSA: hda - Add quirk for Acer Aspire 6935G
Added model=acer-aspire-8930g for Acer Aspire 6935G (1025:0146).

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-13 10:16:43 +02:00
Takashi Iwai 635c265f32 ALSA: ctxfi - Replace atc lock to mutex
The spinlock in atc can cause a sleep in lock:

Kernel failure message 1:
BUG: sleeping function called from invalid context at mm/slub.c:1599
in_atomic(): 0, irqs_disabled(): 1, pid: 2537, name: gstreamer-prope
Pid: 2537, comm: gstreamer-prope Tainted: P
2.6.29.4-167.fc11.x86_64 #1
Call Trace:
  [<ffffffff8103ff0f>] __might_sleep+0x10b/0x110
  [<ffffffff810cd734>] __kmalloc+0x73/0x130
  [<ffffffffa0b4b142>] ? daio_rsc_init+0xaa/0x125 [snd_ctxfi]
  [<ffffffffa0b4b212>] dao_rsc_init+0x55/0x1c0 [snd_ctxfi]
  [<ffffffffa0b4b3d2>] dao_rsc_reinit+0x55/0x5d [snd_ctxfi]
  [<ffffffff813abd6c>] ? _spin_lock_irqsave+0x32/0x3b
  [<ffffffffa0b454fe>] atc_spdif_out_passthru+0x92/0x136 [snd_ctxfi]
  ...

Since the lock path is no critical path, it can be gracefully
replaced with a mutex.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-13 10:12:59 +02:00
Takashi Iwai 31d496aaee Merge branch 'topic/lx6464es' into for-linus
* topic/lx6464es:
  ALSA: lx6464es - support standard alsa module parameters
2009-06-12 20:03:11 +02:00
Takashi Iwai f8be792d51 Merge branch 'topic/hda' into for-linus
* topic/hda:
  ALSA: hda - add quirk for STAC92xx (SigmaTel STAC9205)
2009-06-12 20:03:09 +02:00
Martin Olsson 19af5cdb7c trivial: fix typo milisecond/millisecond for documentation and source comments.
Signed-off-by: Martin Olsson <martin@minimum.se>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2009-06-12 18:01:46 +02:00
Martin Olsson 98a1708de1 trivial: fix typos s/paramter/parameter/ and s/excute/execute/ in documentation and source comments.
Signed-off-by: Martin Olsson <martin@minimum.se>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2009-06-12 18:01:46 +02:00
Thadeu Lima de Souza Cascardo 4b512d26f4 trivial: typo (en|dis|avail|remove)bale -> (en|dis|avail|remove)able
Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2009-06-12 18:01:45 +02:00
Tim Blechmann de0525ca34 ALSA: lx6464es - support standard alsa module parameters
trivial patch to support the alsa module parameters `index', `id'
and `enable'

Signed-off-by: Tim Blechmann <tim@klingt.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-11 16:03:34 +02:00
Simos Xenitellis a5c0f88678 ALSA: hda - add quirk for STAC92xx (SigmaTel STAC9205)
A quirk is required for 8086:284b (rev 03) [Subsystem: 161f:2073].
The following has been tested with Alsa 1.0.20 (git master).

Background details can be found at
https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4561
http://forum.ubuntu-gr.org/viewtopic.php?f=38&t=5290

Tested-by: Theodora Iliopoulou <th30dr@gmail.com>
Signed-off-by: Simos Xenitellis <simos@gnome.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-10 19:54:24 +02:00
Takashi Iwai 4ef279205a Merge branch 'topic/seq-kconfig-cleanup' into for-linus
* topic/seq-kconfig-cleanup:
  ALSA: clean up the logic for building sequencer modules
2009-06-10 07:26:48 +02:00
Takashi Iwai 87cb14a5f4 Merge branch 'topic/riptide' into for-linus
* topic/riptide:
  ALSA: riptide - Fix joystick resource handling
  ALSA: riptide - Code clean up
2009-06-10 07:26:44 +02:00
Takashi Iwai 4ad75433c2 Merge branch 'topic/pcm-subclass-fix' into for-linus
* topic/pcm-subclass-fix:
  ALSA: Remove invalid GENERIC_MIX PCM sublass
2009-06-10 07:26:43 +02:00
Takashi Iwai 9dea75c709 Merge branch 'topic/oxygen' into for-linus
* topic/oxygen:
  sound: virtuoso: add Xonar Essence ST support
  sound: virtuoso: enable HDAV S/PDIF input
  sound: virtuoso: add another DX PCI ID
  sound: oxygen: reset DMA when stream is closed
2009-06-10 07:26:39 +02:00
Takashi Iwai 8c3ff3a7fb Merge branch 'topic/misc' into for-linus
* topic/misc:
  ALSA: sgio2audio.c: clean up checking
  ALSA: burgundy: timeout message is off by one.
  ALSA: bt87x - Add a quirk entry for Askey Computer Corp. MagicTView'99
  ALSA: parisc/harmony: fix printk format warning
  ALSA: keywest: Get rid of useless i2c_device_name() macro
2009-06-10 07:26:37 +02:00
Takashi Iwai ed8cc176c9 Merge branch 'topic/maya44' into for-linus
* topic/maya44:
  ALSA: ice1724 - Add ESI Maya44 support
  ALSA: ice1724 - Allow spec driver to create own routing controls
  ALSA: ice1724 - Add PCI postint to reset sequence
  ALSA: ice1724 - Clean up definitions of DMA records
  ALSA: ice1724 - Check error in set_rate function
2009-06-10 07:26:36 +02:00
Takashi Iwai 03cece06c4 Merge branch 'topic/lx6464es' into for-linus
* topic/lx6464es:
  ALSA: Add missing description of lx6464es to ALSA-Configuration.txt
  ALSA: lx6464es - Disable lx_message_send()
  ALSA: lx6464es - Use snd_card_create()
  ALSA: lx6464es - driver for the digigram lx6464es interface
2009-06-10 07:26:34 +02:00
Takashi Iwai 3c2fcf36d7 Merge branch 'topic/hdsp' into for-linus
* topic/hdsp:
  ALSA: hdsp - Add a comment about external firmwares for hdsp
  ALSA: hdsp: allow firmware loading from inside the kernel
2009-06-10 07:26:32 +02:00
Takashi Iwai 81ad969dbf Merge branch 'topic/hda' into for-linus
* topic/hda: (51 commits)
  ALSA: hda - Fix the previous tagra-8ch patch
  ALSA: hda - Add 7.1 support for MSI GX620
  ALSA: support Sony Vaio TT
  ALSA: hda_intel: fix build error when !PM
  ALSA: hda - More Aspire 8930G fixes
  ALSA: hda - Acer Aspire 8930G support
  ALSA: hda - Limit codec-verb retry to limited hardwares
  ALSA: hda - Add codec bus reset and verb-retry at critical errors
  ALSA: hda - Reorder and clean-up ALC268 quirk table
  ALSA: hda - fix audio on LG R510
  ALSA: hda - Macbook[Pro] 5 6ch support
  ALSA: hda-intel: improve initialization for ALC262_HP_BPC model
  ALSA: hda - Jack Mode changes for Sigmatel boards
  ALSA: hda - Support NVIDIA 8 channel HDMI audio
  ALSA: hda - Fix a typo in the previous patch
  ALSA: hda - Fix reverted LED setup for HP
  ALSA: hda - Add more register bits definitions
  ALSA: hda - Always sync writes in single_cmd mode
  ALSA: hda - Support sync after writing a verb
  ALSA: hda - Allow concurrent RIRB access in single_cmd mode
  ...
2009-06-10 07:26:31 +02:00
Takashi Iwai 2f0dabcc5f Merge branch 'topic/emu10k1' into for-linus
* topic/emu10k1:
  ALSA: emu10k1 - Fix minimum periods for efx playback
2009-06-10 07:26:29 +02:00
Takashi Iwai 19b1a15a3d Merge branch 'topic/div64-cleanup' into for-linus
* topic/div64-cleanup:
  ALSA: Clean up 64bit division functions
2009-06-10 07:26:28 +02:00
Takashi Iwai e618a5609e Merge branch 'topic/ctxfi' into for-linus
* topic/ctxfi: (35 commits)
  ALSA: ctxfi - Clear PCM resources at hw_params and hw_free
  ALSA: ctxfi - Check the presence of SRC instance in PCM pointer callbacks
  ALSA: ctxfi - Add missing start check in atc_pcm_playback_start()
  ALSA: ctxfi - Add use_system_timer module option
  ALSA: ctxfi - Fix wrong model id for UAA
  ALSA: ctxfi - Clean up probe routines
  ALSA: ctxfi - Fix / clean up hw20k2 chip code
  ALSA: ctxfi - Fix possible buffer pointer overrun
  ALSA: ctxfi - Remove useless initializations and cast
  ALSA: ctxfi - Fix DMA mask for emu20k2 chip
  ALSA: ctxfi - Make volume controls more intuitive
  ALSA: ctxfi - Optimize the native timer handling using wc counter
  ALSA: ctxfi - Add missing inclusion of linux/math64.h
  ALSA: ctxfi - Set device 0 for mixer control elements
  ALSA: ctxfi - Clean up / optimize
  ALSA: ctxfi - Set periods_min to 2
  ALSA: ctxfi - Use native timer interrupt on emu20k1
  ALSA: ctxfi - Fix previous fix for 64bit DMA
  ALSA: ctxfi - Fix endian-dependent codes
  ALSA: ctxfi - Allow 64bit DMA
  ...
2009-06-10 07:26:27 +02:00
Takashi Iwai a963203c18 Merge branch 'topic/ca0106' into for-linus
* topic/ca0106:
  ALSA: ca0106 - Fix master volume scale
  ALSA: ca0106 - Add missing card->mixername field setup
  ALSA: ca0106 - Add missing registrations of vmaster controls
2009-06-10 07:26:22 +02:00
Takashi Iwai 1d479f89ec Merge branch 'topic/au88x0' into for-linus
* topic/au88x0:
  ALSA: au88x0: fix wrong period_elapsed() call
  ALSA: au88x0: fix .pointer callback
2009-06-10 07:26:21 +02:00
Takashi Iwai a5990dc5b9 ALSA: ctxfi - Clear PCM resources at hw_params and hw_free
Currently the PCM resources are allocated only once and ever in prepare
callback, assuming that the PCM parameters are never changed.  But it's
not true.

This patch adds the call of atc->pcm_release_resources() at hw_params
and hw_free callbacks to assure that the PCM setup is done correctly
for each h/w parameter changes.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-09 08:19:02 +02:00
Takashi Iwai 5242bc7613 ALSA: ctxfi - Check the presence of SRC instance in PCM pointer callbacks
The SRC instances may not exist when PCM pointer callback is called at
the state before initialization is finished.  Add the NULL check just
to be sure.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-09 08:17:14 +02:00
Takashi Iwai c399f3be82 ALSA: ctxfi - Add missing start check in atc_pcm_playback_start()
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-09 08:16:20 +02:00
Takashi Iwai 04145f2bfb ALSA: ctxfi - Add use_system_timer module option
Added use_system_timer module option to force to use the system timer
instead of emu20k1 timer irq for debugging.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 21:32:26 +02:00
Takashi Iwai 09521d2e3e ALSA: ctxfi - Fix wrong model id for UAA
CTUAA should be checked instead of CTHENDRIX.  The latter is for 20k2 chip.
Also, fixed the detection of UAA/HENDRIX models by fixing the mask bits.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 18:30:37 +02:00
Takashi Iwai 9470195a9c ALSA: ctxfi - Clean up probe routines
Clean up probe routines and model detection routines so that the driver
won't call and check the PCI subsystem id at each time.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 18:10:32 +02:00
Takashi Iwai f03ecf5053 ALSA: hda - Fix the previous tagra-8ch patch
- Fix a typo in the patch
- Adapted to follow the recent change for unsol event handling

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 16:38:17 +02:00
David Heidelberger 64a8be7435 ALSA: hda - Add 7.1 support for MSI GX620
Added 7.1 support for MSI GX620 and jack quirk.

Reference: kernel bug#13430
	http://bugzilla.kernel.org/show_bug.cgi?id=13430

Signed-off-by: David Heidelberger <d.okias@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 16:18:31 +02:00
Takashi Iwai 806d31d738 ALSA: emu10k1 - Fix minimum periods for efx playback
EFX playback stream should have periods_min = 2 to avoid the buffer
position overflow (due to restrictions of the pcm-indirect helper).

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 15:50:42 +02:00
Takashi Iwai d362af62ed ALSA: ctxfi - Fix / clean up hw20k2 chip code
- Clean up Hungarian coding style
- Don't use static variables for I2C information; this unables to use
  multiple instances.  Now they are stored in struct hw20k2 fields.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 15:31:22 +02:00
Takashi Iwai af8500bbbd ALSA: ctxfi - Fix possible buffer pointer overrun
Fix possible buffer pointer overruns.  Back to zero when it's equal
or over the buffer size.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 15:07:46 +02:00
Takashi Iwai 514eef9c2a ALSA: ctxfi - Remove useless initializations and cast
Remove useless variable initializations and cast at the beginning of
functions.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 14:57:57 +02:00
Takashi Iwai 4836ac6554 ALSA: ctxfi - Fix DMA mask for emu20k2 chip
Allow 64bit DMA mask for emu20k2 chip, too.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 14:51:24 +02:00
Takashi Iwai d436dd063b ALSA: ctxfi - Make volume controls more intuitive
Change the volume control to dB scale (as the raw data seems so).
Also added the TLV dB-scale information.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 13:50:18 +02:00
Takashi Iwai c4865679df ALSA: ca0106 - Fix master volume scale
The master volume dB scale was wrongly defined as 0.50dB setp while
it must be 0.25dB step.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 12:57:17 +02:00
Takashi Iwai 54de6bc8b2 ALSA: ctxfi - Optimize the native timer handling using wc counter
Optimize the timer update routine to look up wall clock once instead of
checking the position of each stream at each timer update.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-08 12:38:54 +02:00