Commit Graph

162 Commits

Author SHA1 Message Date
Linus Torvalds bb758e9637 Merge branch 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  hrtimers: fix warning in kernel/hrtimer.c
  x86: make sure we really have an hpet mapping before using it
  x86: enable HPET on Fujitsu u9200
  linux/timex.h: cleanup for userspace
  posix-timers: simplify de_thread()->exit_itimers() path
  posix-timers: check ->it_signal instead of ->it_pid to validate the timer
  posix-timers: use "struct pid*" instead of "struct task_struct*"
  nohz: suppress needless timer reprogramming
  clocksource, acpi_pm.c: put acpi_pm_read_slow() under CONFIG_PCI
  nohz: no softirq pending warnings for offline cpus
  hrtimer: removing all ur callback modes, fix
  hrtimer: removing all ur callback modes, fix hotplug
  hrtimer: removing all ur callback modes
  x86: correct link to HPET timer specification
  rtc-cmos: export second NVRAM bank

Fixed up conflicts in sound/drivers/pcsp/pcsp.c and sound/core/hrtimer.c
manually.
2008-12-30 16:16:21 -08:00
Takashi Iwai 8afabfa74b Merge branch 'topic/convert-tasklet' into to-push 2008-12-25 11:40:27 +01:00
Takashi Iwai 55fa518867 Merge branch 'topic/pcsp-fix' into topic/misc 2008-12-20 23:39:47 +01:00
Takashi Iwai 1f04128a3d ALSA: hda - Convert from takslet_hi_schedule() to tasklet_schedule()
Replace all tasklet_hi_schedule() callers with the normal
tasklet_schedule().  The former often causes troubles with
RT-kernels, and has actually no merit.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-12-18 12:17:55 +01:00
Takashi Iwai 02834f112d ALSA: ac97 - Remove EXPERIMENTAL from CONFIG_SND_AC97_POWER_SAVE
It's mature enough now.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-11-28 15:29:01 +01:00
Takashi Iwai eea0579fc8 ALSA: pcsp - Fix starting the stream with HRTIMER_CB_IRQSAFE_UNLOCK
With the callback mode HRTIMER_CB_IRQSAFE_UNLOCK, the start of the
stream with zero delay doesn't work.  Since IRQSAFE mode is removed,
we have to change the pcsp start-up code.

This patch splits the callback function to two parts, the triggering
of the port and the calculation of the expire time, and the update of
the ALSA PCM core.  The first part is called both from the trigger-start
and the hrtimer callback while the latter is handled only in the
hrtimer callback.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-11-26 14:13:03 +01:00
Takashi Iwai e7dd8c1bda Merge branch 'topic/misc' into topic/pcsp-fix
Conflicts:
	sound/drivers/pcsp/pcsp_lib.c
2008-11-26 14:12:42 +01:00
Peter Zijlstra ca109491f6 hrtimer: removing all ur callback modes
Impact: cleanup, move all hrtimer processing into hardirq context

This is an attempt at removing some of the hrtimer complexity by
reducing the number of callback modes to 1.

This means that all hrtimer callback functions will be ran from HARD-irq
context.

I went through all the 30 odd hrtimer callback functions in the kernel
and saw only one that I'm not quite sure of, which is the one in
net/can/bcm.c - hence I'm CC-ing the folks responsible for that code.

Furthermore, the hrtimer core now calls callbacks directly with IRQs
disabled in case you try to enqueue an expired timer. If this timer is a
periodic timer (which should use hrtimer_forward() to advance its time)
then it might be possible to end up in an inf. recursive loop due to the
fact that hrtimer_forward() doesn't round up to the next timer
granularity, and therefore keeps on calling the callback - obviously
this needs a fix.

Aside from that, this seems to compile and actually boot on my dual core
test box - although I'm sure there are some bugs in, me not hitting any
makes me certain :-)

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2008-11-25 15:45:46 +01:00
Takashi Iwai 8a75f4fb28 ALSA: pcsp - Use HRTIMER_CB_IRQSAFE_UNLOCKED
HRTIMER_CB_IRQSAFE was removed in the upstream.
Try to use HRTIMER_CB_IRQSAFE_UNLOCKED instead.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-11-14 13:58:43 +01:00
Takashi Iwai 63cf123bf5 Merge branch 'topic/fix/misc' into topic/misc 2008-11-07 09:06:05 +01:00
Linus Torvalds 20ebc0073b 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 a STAC_DELL_EQ option
  ALSA: emu10k1 - Add more invert_shared_spdif flag to Audigy models
  ALSA: hda - Add a quirk for another Acer Aspire (1025:0090)
  ALSA: remove direct access of dev->bus_id in sound/isa/*
  sound: struct device - replace bus_id with dev_name(), dev_set_name()
  ALSA: Fix PIT lockup on some chipsets when using the PC-Speaker
  ALSA: rawmidi - Add open check in rawmidi callbacks
  ALSA: hda - Add digital-mic for ALC269 auto-probe mode
  ALSA: hda - Disable broken mic auto-muting in Realtek codes
2008-11-03 10:14:59 -08:00
Kay Sievers bb072bf098 sound: struct device - replace bus_id with dev_name(), dev_set_name()
[stripped sound/isa/* changes, replaced with the next patch -- tiwai]

Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-11-03 08:57:33 +01:00
Zoltan Devai b02555c384 ALSA: Fix PIT lockup on some chipsets when using the PC-Speaker
Fix PIT lockup on some chipsets when using the PC-Speaker.

Signed-off-by: Zoltan Devai <zdevai@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-11-03 08:57:25 +01:00
Takashi Iwai 4fc85e451f Merge branch 'topic/misc-next' into topic/misc 2008-10-27 08:50:43 +01:00
Thomas Gleixner 268a3dcfea Merge branch 'timers/range-hrtimers' into v28-range-hrtimers-for-linus-v2
Conflicts:

	kernel/time/tick-sched.c

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2008-10-22 09:48:06 +02:00
Takashi Iwai 96c7d478ef ALSA: pcsp - Fix locking messes in snd-pcsp
snd-pcsp driver takes chip->substream_lock together with PCM substream
lock.  These are even mixed up with hrtimer's lock, resulting in messy
lock depencies.  Right now, snd-pcsp driver resolves the deadlock by
using HRTIMER_CB_SOFTIRQ.  However, this isn't nice for a really fast
path like bit-flipping.

This patch introduces a tasklet for PCM period handling so that the
hrtimer callback can be handled fast.  This also reduce the use of
chip->substream_lock to avoid deadlocks.  It's still used in pointer
callback, but even this could be removed with a proper barrier.

Another good solution is to introduce async trigger callback.  But,
this will involve with a major rewrite of the PCM core code, so I
take first this easy fix.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-10-20 14:47:15 +02:00
Mariusz Kozlowski e78521f321 ALSA: misc typo fixes
Fixed typos in disabled codes via #if 0.

Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-10-19 10:36:08 +02:00
Arjan van de Ven 651dab4264 Merge commit 'linus/master' into merge-linus
Conflicts:

	arch/x86/kvm/i8254.c
2008-10-17 09:20:26 -07:00
Takashi Iwai 32fe614263 ALSA: mtpav - Fix race in probe
Ingo reported Oops at probing mtpav driver.  It's a race between
the irq handler and the rawmidi instance registration.

This patch fixes the order of registration to avoid the race.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Tested-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-10-10 13:41:58 +02:00
Arjan van de Ven 5c73a7d041 hrtimer: convert sound/ to the new hrtimer apis
In order to be able to do range hrtimers we need to use accessor functions
to the "expire" member of the hrtimer struct.
This patch converts sound/ to these accessors.

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
2008-09-05 21:35:23 -07:00
Jaroslav Kysela 1a11cb6427 ALSA: dummy driver - do not use assignment in if condition
checkpatch.pl does not like assignment in if condition

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-08-15 12:59:02 +02:00
Daniel THOMPSON 54e8e21ed2 sound: Fix esoteric double free in the dummy sound driver.
The dummy driver uses runtime->private_free but still frees
its pcm structures on error paths.

This is esoteric because the error paths in question are
unreachable. Thus the bug is only a problem when someone
copies this code into other drivers.

Signed-off-by: Daniel R Thompson <daniel.thompson@st.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-08-15 12:38:14 +02:00
Takashi Iwai 5e246b850d ALSA: Kill snd_assert() in other places
Kill snd_assert() in other places, 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>
2008-08-13 11:46:40 +02:00
David Woodhouse 751851af7a Merge git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
Conflicts:

	sound/pci/Kconfig
2008-07-14 15:51:11 -07:00
David Howells b561c74ae2 Fix a const pointer usage warning in the Digigram VX soundcard driver
Fix a const pointer usage warning in the Digigram VX soundcard driver.  A
const pointer is being passed to copy_from_user() to load the firmware into.
This is okay in this case because the function has allocated the firmware
struct itself, but the const qualifier will be part of the firmware 
struct - so the patch casts the const away.

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-07-10 14:27:11 +01:00
David Woodhouse 2f0600b639 vx: treat firmware data as const
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-07-10 14:26:10 +01:00
David Howells bd5d06eb8f ALSA: Fix a const pointer usage warning in the Digigram VX soundcard driver
Fix a const pointer usage warning in the Digigram VX soundcard driver.  A
const pointer is being passed to copy_from_user() to load the firmware into.
This is okay in this case because the function has allocated the firmware
struct itself, but the const qualifier is part of the firmware struct - so the
patch casts the const away.

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-07-10 09:32:55 +02:00
Takashi Iwai 6938d6b2a9 [ALSA] Fix AC97 kconfig items
The kconfig items related with AC97-powersave must be outside the
CONFIG_SND_PCI range.  And it'd be better together with CONFIG_SND_AC97.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-27 15:56:20 +02:00
Takashi Iwai 89fe511792 sound: Convert to menuconfig
Convert menu in sound Kconfig files to menuconfig and if.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-27 15:56:20 +02:00
Stas Sergeev 97e08f5d73 [ALSA] snd-pcsp - fix pcsp_treble_info() to honour an item number
This solves the problem with mixers wrongly displaying the PWM freq.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-25 18:21:10 +02:00
Stas Sergeev 4b7afb0d0d snd-pcsp: use HRTIMER_CB_SOFTIRQ
Change HRTIMER_CB_IRQSAFE to HRTIMER_CB_SOFTIRQ,
as suggested by Thomas Gleixner.
That solves the lock dependancy reported in
Bug #10701.
That also allows to call hrtimer_start()
directly, tasklet "stupid hack" removed.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-20 11:56:24 +02:00
Daniel Jacobowitz 87af38dafe [ALSA] ac97 - Add virtual master control to VT1616/VT1617A codec.
Enable VMASTER for VT1616 / VT1617A codec.

Signed-off-by: Daniel Jacobowitz <dan@codesourcery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-05-19 13:19:14 +02:00
Stas Sergeev 42ece6c1f8 snd-pcsp: silent misleading warning
It appears that alsa allows a sound buffer with size not
evenly devided by the period size. This triggers a warning in
snd-pcsp and floods the log. As a quick fix, the warning should
be disabled.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-19 12:06:44 +02:00
Stas Sergeev 2bc536a235 snd-pcsp: depend on CONFIG_EXPERIMENTAL
Considering all the feedbacks I got, depending snd-pcsp on
CONFIG_EXPERIMENTAL looks like the only safe way to get out
of all the troubles at one go. :)

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-19 12:06:43 +02:00
Stas Sergeev 4dfd79546d snd-pcsp: put back the compatibility code for the older alsa-libs
The attached patch adds back the compatibility code, allowing the
driver to work with older alsa-libs.
The removal was premature, it breaks the real-life configs.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-19 12:06:25 +02:00
Stas Sergeev 3ccee69019 snd-pcsp: adjust help texts to frighten users
Added the warning text to the help of snd-pcsp about the possible problem
with this driver so that user can know of the problem in advance.

Also, removed the obsoleted text about ancient pc-speaker patch in
CONFIG_SOUND help.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-19 12:04:35 +02:00
Stas Sergeev e5e1d3cb20 pcspkr: fix dependancies
fix pcspkr dependancies: make the pcspkr platform
drivers to depend on a platform device, and
not the other way around.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Dmitry Torokhov <dtor@mail.ru>
CC: Vojtech Pavlik <vojtech@suse.cz>
CC: Michael Opdenacker <michael-lists@free-electrons.com>
[fixed for 2.6.26-rc1 by tiwai]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-07 12:42:03 +02:00
Johann Felix Soden 983e0972ce [ALSA] pcsp: Fix build with CONFIG_PM=n
sound/drivers/pcsp/pcsp.c: In function 'pcsp_suspend':
sound/drivers/pcsp/pcsp.c:201: error: implicit declaration of function 'snd_pcm_suspend_all'

Signed-off-by: Johann Felix Soden <johfel@users.sourceforge.net>
CC: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-05 14:12:07 +02:00
Takashi Iwai bad7785d4a [ALSA] pcsp - Fix more dependency
Added the missing dependency and select for snd-pcsp driver.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-29 19:01:57 +02:00
Takashi Iwai df7e3fdf83 [ALSA] Add MPU401_INFO_NO_ACK bitflag
Added MPU401_INFO_NO_ACK bitflag to ignore the ACK check for UART
commands.  VT172x doesn't handle ACK commands, for example.

Tested-by: Pavel Hofman <pavel.hofman@insite.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-29 19:01:56 +02:00
Takashi Iwai b415ed45f4 [ALSA] Define MPU401 registers in sound/mpu401_uart.h
Define some MPU401 registers in sound/mpu401_uart.h so that other
drivers can refer to them.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:38:22 +02:00
Stas Sergeev efd89d9dcf [ALSA] pcsp: fix wording in DEBUG_PAGEALLOC warning
Signed-off-by: Stas Sergeev <stsp@aknet.ru>
(fixed invalid KERN_WARNING by tiwai)
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:38:19 +02:00
Takashi Iwai 73bdd2ad7a [ALSA] pcsp - Fix dependency in Kconfig
Added the proper dependency to Kconfig for snd-pcsp driver.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:38:17 +02:00
Roel Kluin 369b240d63 [ALSA] sound/drivers/dummy.c: fix negative snd_pcm_format_width() check
bps is unsigned, a negative snd_pcm_format_width() return value is not noticed

Signed-off-by: Roel Kluin <12o3l@tiscali.nl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:00:38 +02:00
Kay Sievers 8b45a20993 [ALSA] sound: fix platform driver hotplug/coldplug
Since 43cc71eed1, the platform modalias is
prefixed with "platform:".  Add MODULE_ALIAS() to the hotpluggable sound
platform drivers, to re-enable auto loading.

[dbrownell@users.sourceforge.net: more drivers, registration fixes]

Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:00:35 +02:00
Stas Sergeev c81d80cbf6 [ALSA] pcsp: remove downsampling
pcsp: remove S16->U8 downsampling as dmix now supports U8 natively.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:00:30 +02:00
Mariusz Kozlowski 9ecaedae0d [ALSA] sound/drivers/pcsp/pcsp.c build fix
sound/drivers/pcsp/pcsp.c: In function 'snd_pcsp_create':
sound/drivers/pcsp/pcsp.c:54: error: 'loops_per_jiffy' undeclared (first use in\ this function)
sound/drivers/pcsp/pcsp.c:54: error: (Each undeclared identifier is reported on\ ly once
sound/drivers/pcsp/pcsp.c:54: error: for each function it appears in.)

Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:00:26 +02:00
Joachim Foerster 5949d2443d [ALSA] [ML403-AC97CR] Remove duplicate snd_card_set_dev()
We want to have snd_card_set_dev() in _probe(), but not a second one in
snd_ml403_ac97cr_create().

Signed-off-by: Joachim Foerster <JOFT@gmx.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:00:25 +02:00
Stas Sergeev 1bc1f30565 [ALSA] pcsp: locking fix
pcsp: locking fix.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:00:24 +02:00
Stas Sergeev 52337310af [ALSA] pcsp: improve "enable" option handling
Simplify init code.

Signed-off-by: Stas Sergeev <stsp@aknet.ru>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24 12:00:21 +02:00