Commit Graph

5115 Commits

Author SHA1 Message Date
Takashi Iwai ab1863fc9b ALSA: pcm - Fix update of runtime->hw_ptr_interrupt
The commit 13f040f9e5 made another
regression, the missing update of runtime->hw_ptr_interrupt.
Since this field is only checked in snd_pcmupdate__hw_ptr_interrupt(),
not in snd_pcm_update_hw_ptr(), it must be updated before the hw_ptr
change check.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-07 12:19:33 +02:00
Jaroslav Kysela d86bf92313 ALSA: pcm - Fix a typo in hw_ptr update check
Fix a typo in the commit 13f040f9e5
  ALSA: PCM midlevel: Do not update hw_ptr_jiffies when hw_ptr is not changed
which causes obvious problems with PA.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-06-06 18:32:06 +02:00
Jaroslav Kysela a4444da31e ALSA: PCM midlevel: lower jiffies check margin using runtime->delay value
When hardware has large FIFO, it is necessary to lower jiffies margin
by count of queued samples.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-29 11:47:40 +02:00
Jaroslav Kysela 13f040f9e5 ALSA: PCM midlevel: Do not update hw_ptr_jiffies when hw_ptr is not changed
Some hardware might have bigger FIFOs and DMA pointer value will be updated
in large chunks. Do not update hw_ptr_jiffies and position timestamp when
hw_ptr value was not changed.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-29 11:47:38 +02:00
Jaroslav Kysela c62a01ad6e ALSA: PCM midlevel: introduce mask for xrun_debug() macro
For debugging purposes, it is better to separate actions.

Bit-values:

	1: show bad PCM ring buffer pointer
	2: show also stack (to debug kernel latency issues)
	4: check pointer against system jiffies

Example:

	5: show bad PCM ring buffer pointer and do jiffies check

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-29 11:47:36 +02:00
Jaroslav Kysela 8bea869c5e ALSA: PCM midlevel: improve fifo_size handling
Move the fifo_size assignment to hw->ioctl callback to allow lowlevel
drivers overwrite the default behaviour.

fifo_size is in frames not bytes as specified in asound.h and alsa-lib's
documentation, but most hardware have fixed byte based FIFOs. Introduce
internal SNDRV_PCM_INFO_FIFO_IN_FRAMES.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-29 11:47:33 +02:00
Takashi Iwai e93721a702 Merge branch 'fix/pcm-jiffies-check' into topic/pcm-jiffies-check 2009-05-29 11:46:10 +02:00
Takashi Iwai c87d973200 ALSA: Enable PCM hw_ptr_jiffies check only in xrun_debug mode
The PCM hw_ptr jiffies check results sometimes in problems when a
hardware doesn't give smooth hw_ptr updates.  So far, au88x0 and some
other drivers appear not working due to this strict check.
However, this check is a nice debug tool, and the capability should be
still kept.

Hence, we disable this check now as default unless the user enables it
by setting the xrun_debug mode to the specific stream via a proc file.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-27 11:04:30 +02:00
Takashi Iwai 6af3fb72d2 ALSA: Fix invalid jiffies check after pause
The hw_ptr_jiffies has to be reset properly to avoid the invalid
check of jiffies delta in snd_pcm_update_hw_ptr*() functions.
Especailly this patch fixes the bogus jiffies check after the puase
and resume.

This patch is a modified version of the original patch by Jaroslav.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-27 11:04:18 +02:00
Takashi Iwai 4986cab555 Merge branch 'fix/misc' into for-linus
* fix/misc:
  ALSA: Kill truncate warning by shortening Sigmatel-specific AC97 control name
  ALSA: pcsp - fix printk format warning again
2009-05-22 19:29:08 +02:00
Andreas Mohr afe6d7e3c4 ALSA: Kill truncate warning by shortening Sigmatel-specific AC97 control name
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>
2009-05-22 19:27:13 +02:00
Takashi Iwai 89b7161c48 Merge branch 'fix/hda' into for-linus
* fix/hda:
  ALSA: hda - fix audio on HP TX25xx series notebooks
2009-05-22 08:23:39 +02:00
Adam Williamson 87488957a6 ALSA: hda - fix audio on HP TX25xx series notebooks
Fixes https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4121

Taken from https://bugzilla.redhat.com/show_bug.cgi?id=498060

Signed-off-by: Adam Williamson <awilliam@redhat.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-22 08:22:23 +02:00
Alessandro Rubini 03fbdb15c1 [ARM] 5519/1: amba probe: pass "struct amba_id *" instead of void *
The second argument of the probe method points to the amba_id
structure, so it's better passed with the correct type. None of the
current in-tree drivers uses the pointer, so they have only been
checked for a clean compile.

Change suggested by Russell King.

Signed-off-by: Alessandro Rubini <rubini@unipv.it>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-05-20 23:26:51 +01:00
Takashi Iwai b3b778b387 ALSA: pcsp - fix printk format warning again
The commit 5a641bcd63 changed the
printk format to '%lu', but the value passed seems to be dependent
on the architecture.  On x86-64, I got a new warning now because an
int value is passed actaully.

As a workaround, just cast the value always to unsigned long.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-20 17:08:00 +02:00
Takashi Iwai 60befb97f5 Merge branch 'fix/asoc' into for-linus
* fix/asoc:
  ASoC: DaVinci EVM board support buildfixes
  ASoC: DaVinci I2S updates
  ASoC: davinci-pcm buildfixes
  pxa2xx-ac97: fix reset gpio mode setting
  ASoC: soc-core: fix crash when removing not instantiated card
2009-05-15 15:38:26 +02:00
Takashi Iwai a3d2b755c0 Merge branch 'fix/misc' into for-linus
* fix/misc:
  ALSA: pcsp: fix printk format warning
  ALSA: riptide: postfix increment and off by one
2009-05-15 15:38:20 +02:00
David Brownell f492ec9f02 ASoC: DaVinci EVM board support buildfixes
This is a build fix, resyncing the DaVinci EVM ASoC board code
with the version in the DaVinci tree.  That resync includes
support for the DM355 EVM, although that board isn't yet in
mainline.

(NOTE:  also includes a bugfix to the platform_add_resources
call, recently sent by Chaithrika U S <chaithrika@ti.com> but
not yet merged into the DaVinci tree.)

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-15 08:59:07 +01:00
David Brownell a62114cb90 ASoC: DaVinci I2S updates
This resyncs the DaVinci I2S code with the version in the DaVinci
tree.  The behavioral change uses updated clock interfaces which
recently merged to mainline.  Two other changes include adding a
comment on the ASP/McBSP/McASP confusion, and dropping pdev->id in
order to support more boards than just the DM644x EVM.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-15 08:58:58 +01:00
David Brownell 82075af6cb ASoC: davinci-pcm buildfixes
This is a buildfix for the DaVinci PCM code, resyncing it with
the version in the DaVinci tree.  The notable change is using
current EDMA interfaces, which recently merged to mainline.
(The older interfaces never made it into mainline.)

NOTE:  open issue, the DMA should be to/from SRAM; see chip
errata for more info.  The artifacts are extremely easy to
hear on DM355 hardware (not yet supported in mainline), but
don't seem as audible on DM6446 hardwaare (which does have
mainline support).

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-15 08:58:05 +01:00
Randy Dunlap 5a641bcd63 ALSA: pcsp: fix printk format warning
Fix printk format warning:

sound/drivers/pcsp/pcsp_mixer.c:54: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-14 18:03:10 +02:00
Roel Kluin 1b1cc7f21c ALSA: riptide: postfix increment and off by one
With a postfix increment these variables are incremented beyond
CMDIF_TIMEOUT / MAX_WRITE_RETRY.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-14 08:41:40 +02:00
Mike Rapoport 1ffafeb556 pxa2xx-ac97: fix reset gpio mode setting
Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-11 19:01:51 +01:00
Mike Rapoport 914dc18255 ASoC: soc-core: fix crash when removing not instantiated card
If the card was not instantiated in snd_soc_instantiate_card, calling
soc-remove will crash because some of codec, cpu_dai and card .remove
methods are called twice.
Fix this by returning from soc_remove immediately.

Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-05-11 19:01:51 +01:00
Takashi Iwai bbb2b6829d Merge branch 'fix/asoc' into for-linus
* fix/asoc:
  ASoC: Fix errors in WM8990
2009-05-10 12:06:59 +02:00
Takashi Iwai b40814b8c0 Merge branch 'fix/hda' into for-linus
* fix/hda:
  ALSA: hda - Fix line-in on Mac Mini Core2 Duo
2009-05-10 12:06:55 +02:00
Takashi Iwai 6d05d53f56 Merge branch 'fix/misc' into for-linus
* fix/misc:
  sound: via82xx: fix DXS volume range
  sound: serial-u16550: fix buffer overflow
2009-05-10 12:05:53 +02:00
Takashi Iwai 5dd17cb992 ALSA: hda - Fix line-in on Mac Mini Core2 Duo
BIOS on Mac Mini Core2 Duo sets both INPUT and OUTPUT pinctl bits to
the line-in jack, and it confuses the driver as if it's a valid input.
This patch adds the check of OUTPUT bit so that the driver fixes the
invalid pin setup.

Tested-by: Tino Keitel <tino.keitel@gmx.de>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-08 07:55:10 +02:00
Clemens Ladisch b452e08e73 sound: via82xx: fix DXS volume range
With 5 bits and 1.5 dB per step, the DXS volume range is only 48 dB.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-05 16:01:32 +02:00
Clemens Ladisch bd0185ceac sound: serial-u16550: fix buffer overflow
Remove most of the serial port parameters from the card longname string
because it was way too long and overflowed into the mixername string.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-05 16:01:18 +02:00
Takashi Iwai ae1ec5e1e9 ALSA: usbaudio - Add delay account
Manage the PCM delay account based on the queued URBs.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-05 14:47:21 +02:00
Takashi Iwai 4bbe1ddf89 ALSA: Add extra delay count in PCM
Added runtime->delay field to adjust the delayed samples for snd_pcm_delay().
Typically a hardware FIFO length is stored in this field, so that the
extra delay between hwptr and applptr can be computed.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-05 14:47:21 +02:00
Jinyoung Park 97a775c49c ASoC: Fix errors in WM8990
The mis-typing exist in dapm controller definitions and dapm route definitions,
so happen mis-matched error when snd_soc_dapm_add_routes().

Cc: stable@kernel.org
Signed-off-by: Jinyoung Park <parkjy@mtekvision.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com
2009-05-05 09:56:49 +01:00
Takashi Iwai 5d7ee52f1c Merge branch 'fix/misc' into for-linus
* fix/misc:
  ALSA: indigo-express: add missing 64KHz flags
2009-05-04 16:06:58 +02:00
Takashi Iwai 6574612fbb ASoC: Remove BROKEN from mpc5200 kconfig
The regression was fixed by commit
3e5b50165f, so no need to mark this
driver as BROKEN.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-04 16:03:21 +02:00
Takashi Iwai 3a20ac2c52 Merge branch 'fix/pcm-jiffies-check' into fix/asoc 2009-05-04 16:00:16 +02:00
Joonyoung Shim 18cc8d8d9b ASoC: TWL4030: Fix gain control for earpiece amplifier
The gain control for earpiece amplifier uses 0dB ~ 12dB according to the
TRM, but the present code is implemented to -6dB ~ 6dB.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-28 16:11:22 +01:00
Takashi Iwai 3e5b50165f ALSA: pcm core - Avoid jiffies check for devices with BATCH flag
The hardware devices with SNDRV_PCM_INFO_BATCH flag can't give the
precise current position.  And such hardwares have often big FIFO
in addition to the ring buffer, and it screws up the jiffies check
in pcm_lib.c.

This patch adds a simple check of info flag so that the driver skips
the jiffies check in snd_pcm_period_elapsed() when BATCH flag is set.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-04-28 15:10:16 +02:00
Takashi Iwai 2008f137e9 ALSA: Add missing SNDRV_PCM_INFO_BATCH flag to some drivers
Added SNDRV_PCM_INFO_BATCH flag to PCM info field of some drivers that
really don't give the precise pointer value.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-04-28 15:06:44 +02:00
Giuliano Pochini 3f68165e23 ALSA: indigo-express: add missing 64KHz flags
Indigo-express cards also support 64KHz sampling rate: this patch adds
missing SNDRV_PCM_RATE_64000 flags.

Signed-off-by: Giuliano Pochini <pochini@shiny.it>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-04-28 11:19:39 +02:00
Jon Smirl 0c95de73a7 ASoC: Set the MPC5200 i2s driver to BROKEN status.
Signed-off-by: Jon Smirl <jonsmirl@gmail.com>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-27 20:40:55 +01:00
Mark Brown 5e42336a46 ASoC: Fix logic in WM8350 master clocking check
We need to check only if the WM8350 is master and only when starting
the stream so if either is not true then we can skip the check.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-27 20:40:21 +01:00
Takashi Iwai bac0906484 Merge branch 'fix/misc' into for-linus
* fix/misc:
  ALSA: Fix Trivial Warnining in sound/pci/cmipci.c
2009-04-27 17:15:44 +02:00
Takashi Iwai 5530f41bd2 Merge branch 'fix/caiaq' into for-linus
* fix/caiaq:
  ALSA: snd-usb-caiaq: fix reported elapsed periods
2009-04-27 17:15:41 +02:00
Takashi Iwai 0995f9dbe6 Merge branch 'fix/hda' into for-linus
* fix/hda:
  ALSA: hda - Fix init verbs of AD1884A mobile model
2009-04-27 17:15:35 +02:00
Takashi Iwai f0787f62df Merge branch 'fix/asoc' into for-linus
* fix/asoc:
  ASoC: s3c-i2s-v2 needs to declare a license for modular builds
  ASoC: remove non-existing referece to CONFIG_SND_SOC_CODEC_WM8991
  ASoC: Fix WM8580 volume update handling for large register changes
  ASoC: Fix offset of freqmode in WM8580 PLL configuration
2009-04-27 17:15:32 +02:00
Subrata Modak 395a434e39 ALSA: Fix Trivial Warnining in sound/pci/cmipci.c
Fixed the compile warning below by initializatin iomidi variable properly.
  sound/pci/cmipci.c: In function ‘snd_cmipci_probe’:
  sound/pci/cmipci.c:3017: warning: ‘iomidi’ may be used uninitialized in this function

Signed-off-by: Subrata Modak <subrata@linux.vnet.ibm.com>
Cc: linux-pci <linux-pci@atrey.karlin.mff.cuni.cz>
Cc: Balbir Singh <balbir@linux.vnet.ibm.com>
Cc: Sachin P Sant <sachinp@linux.vnet.ibm.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-04-27 13:53:13 +02:00
Daniel Mack a9b487fa1e ALSA: snd-usb-caiaq: fix reported elapsed periods
Reset the internal period position counter upon stream startup. This
fixes initial aplay underruns and problems related to latency picky
applications such as pulseaudio.

Bumped the version number to 1.3.14.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-04-27 12:32:52 +02:00
Linus Torvalds 6ae85d6db4 Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
  [ARM] 5460/1: Orion: reduce namespace pollution
  [ARM] 5458/1: pcmcia: pxa2xx-sharpsl: check if we do have Scoop config
  [ARM] 5457/1: mach-imx gpio buildfix
  [ARM] 5456/1: add sys_preadv and sys_pwritev
  [ARM] pxa/pcm990: start external GPIOs immediately after built-in ones
  [ARM] pxa/palm27x: General fix for Palm27x aSoC driver
  [ARM] pxa/mioa701: use GPIO95 as AC97 reset line
  [ARM] pxa: merge AC97 platform data structures
  [ARM] pxa/magician: remove un-necessary #include of pxa-regs.h and hardware.h
2009-04-24 08:36:41 -07:00
Mark Brown a396e32ef0 ASoC: s3c-i2s-v2 needs to declare a license for modular builds
It relies on EXPORT_SYMBOL_GPL() symbols.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-04-23 16:06:21 +01:00