15 Feb, 2008
1 commit
-
The sound drivers and the pnpbios core test for current->root != NULL. This
test seems to be unnecessary since we always have rootfs mounted before
initializing the drivers.Signed-off-by: Jan Blunck
Acked-by: Christoph Hellwig
Cc: Bjorn Helgaas
Cc: Jaroslav Kysela
Acked-by: Takashi Iwai
Cc: Al Viro
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
06 Feb, 2008
1 commit
-
Replace latency.c use with pm_qos_params use.
Signed-off-by: mark gross
Cc: "John W. Linville"
Cc: Len Brown
Cc: Jaroslav Kysela
Cc: Takashi Iwai
Cc: Arjan van de Ven
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
01 Feb, 2008
27 commits
-
The PCM OSS emulation can cause Oops at sync operation due to the wrong
data size calculation. Typically happening on Sparc64:
http://lkml.org/lkml/2008/1/24/426Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
'snd_shutdown_f_ops' is not a pointer so its address will never be NULL.
GCC will complain because 'fops_get' will do an unnecessary check because
'&snd_shutdown_f_ops' is always true.Signed-off-by: Miguel Boton
Signed-off-by: Andrew Morton
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Change semantics for SNDRV_PCM_TSTAMP_MMAP. Doing timestamping only in
the interrupt handler might cause that hw_ptr is not related to actual
timestamp. With this change, grab timestamp at every hw_ptr update to
have always valid timestamp + ring buffer position pair.
With this change, SNDRV_PCM_TSTAMP_MMAP was renamed to
SNDRV_PCM_TSTAMP_ENABLE. It's no regression (I think).Signed-off-by: Jaroslav Kysela
-
snd_rawmidi_kernel_read1/write1 weren't annotated but used
copy_to_user/copy_from_user when one of parameters (kernel) was equal to 0
remove it and add properly annotated parameterSigned-off-by: Marcin Ślusarz
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
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
Signed-off-by: Jaroslav Kysela -
The 'tick' in PCM is set (again) via sw_params. And, nobody uses
this feature at all except for a command line option of aplay.
(This is literally 'nobody', as I checked alsa-lib API calls in all
programs in major distros.)
Above all, if we need finer wake-ups for the position update, it's
basically an issue that the driver should solve, not tuned by each
application.Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Introduce a common helper function for snd_pcm_lib_read and snd_pcm_lib_write
for cleaning up the code.Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
The xfer_align sw_params parameter has never been used in a sane manner,
and no one understands what this does exactly. The current
implementation looks also buggy because it allows write of shorter size
than xfer_align. So, if you do partial writes, the write isn't actually
aligned at all.
Removing this parameter will make some pcm_lib_* code more readable
(and less buggy).Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
The snd_pcm_lib_write1() may block in some weird condition:
- the stream isn't started
- avail_min is big (e.g. period size)
- partial write up to buffer_size - avail_min
The patch fixes this invalid blocking problem.Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
This patch removes the indirect control access to the control elements.
The indirect access has never been used and is even broken on 32bit
ioctl wrapper. Let's clean it up.
The pointers still remain in snd_ctl_elem_* structs just to make sure
that the struct size won't change. Once after checking the size
consistency, we can get rid of them, too.Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
The condition caused that the returned ring buffer position does not match
with timestamp when SNDRV_PCM_TSTAMP_MMAP mode was enabled. Removing
condition makes unified behaviour and interrupt based timestamp can be
accessed via PCM_IOCTL_SYNC_PTR or mmaped status area.Signed-off-by: Jaroslav Kysela
-
The replaced one should be re-added for older alsa-lib.
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Signed-off-by: Jaroslav Kysela
-
sound/core/seq: move declarations of globally visible variables to proper headers
Signed-off-by: Marcin Ślusarz
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
info_oss: move prototype of snd_card_info_read_oss to info.h
Signed-off-by: Marcin Ślusarz
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
pcm_lib: fix sparse warning about different signedness
Signed-off-by: Marcin Ślusarz
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
pcm_lib: fix sparse warning about shadowing 'n' symbol
Signed-off-by: Marcin Ślusarz
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
pcm_native: fix sparse warning about shadowing 'state' symbol
Signed-off-by: Marcin Ślusarz
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
sound/core/control_compat.c: In function 'copy_ctl_value_from_user':
sound/core/control_compat.c:222: warning: 'count' may be used uninitialized in this functionSigned-off-by: Andrew Morton
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Replaced the old SNDRV_PCM_IOCTL_TSTAMP with the new one in
PCM compat_ioctl.Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Convert ALSA from nopage to fault.
Switch from OOM to SIGBUS if the resource is not available.Signed-off-by: Nick Piggin
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Reported by Timur Tabi .
Signed-off-by: Jaroslav Kysela
-
We need an accurate and continuous (monotonic) time sources to do
accurate synchronization among more timing sources. This patch allows
to enable monotonic timestamps for ALSA PCM devices and enables monotonic
timestamps for ALSA timer devices.Signed-off-by: Jaroslav Kysela
-
There should be a pci_dev_put when breaking out of a loop that iterates
over calls to pci_get_device and similar functions.
In this case, the return under the initial if needs a pci_dev_put in the
same way that the return under the subsequent for loop has a pci_dev_put.
This was fixed using the following semantic patch.
//
@@
type T;
identifier d;
expression e;
@@
T *d;
...
while ((d = \(pci_get_device\|pci_get_device_reverse\|pci_get_subsys\|pci_get_class\)(..., d)) != NULL)
{... when != pci_dev_put(d)
when != e = d
(
return d;
|
+ pci_dev_put(d);
? return ...;
)
...}
//Signed-off-by: Julia Lawall
Signed-off-by: Andrew Morton
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
When MMAP time-stamp mode is given, it's supposed to update the time-stamp
only at period boundary. However, it currently updates at each status call
so this is just useless. The patch fixes this misbehavior.
Also it fixes the wrong check of tstamp_mode (don't use bit-and for enum).Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Remove sequencer instrument layer from the tree.
This mechanism hasn't been used much with the actual devices. The only
reasonable user was OPL3 loader, and now it was rewritten to use hwdep
instead. So, let's remove the rest of rotten codes.Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Introduced the global 'slots' option to snd module. This option provides
an alternative way to handle the order of multiple sound card instances.
It's an easier approach to avoid conflict with hotplug devices, and can
be used together with the existing 'order' option of each card driver.Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela
09 Jan, 2008
1 commit
-
Rework this functions so that gcc-3.2 can successfully perform
constant-folding.Signed-off-by: Jean Delvare
Cc: Jaroslav Kysela
Cc: Takashi Iwai
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
23 Oct, 2007
1 commit
-
The lock grabbed in snd_ctl_empty_read_queue() is hardirq-unsafe but we hold
an hardirq-safe one already, so make the &ctl->read_lock also hard-irq-safe.Signed-off-by: Borislav Petkov
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela
20 Oct, 2007
1 commit
-
Fix the various misspellings of "system", controller", "interrupt" and
"[un]necessary".Signed-off-by: Robert P. J. Day
Signed-off-by: Adrian Bunk
16 Oct, 2007
8 commits
-
Signed-off-by: Jaroslav Kysela
-
snd_register_device_for_dev() can oops when device_create() returns
ERR_PTR(err).
Scenario:
preg->dev = device_create(...); /* fails */
if (preg->dev) /* contains ERR_PTR(err) */
dev_set_drvdata(preg->dev, private_data);
and dev_set_drvdata() looks like this:
static inline void
dev_set_drvdata (struct device *dev, void *data)
{
dev->driver_data = data;
Signed-off-by: Andrew Morton
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Replace schedule_timeout() with schedule_timeout_uninterruptible()
to avoid signals in loop.Signed-off-by: Rene Herman
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
snd_ctl_elem_{read,write} no longer have any modular users
Signed-off-by: Adrian Bunk
Signed-off-by: Takashi Iwai
Signed-off-by: Jaroslav Kysela -
Add a snd_pcm_rate_to_rate_bit() function to factor out common code used
by several drivers.Signed-off-by: Clemens Ladisch
Signed-off-by: Jaroslav Kysela -
Merge the rates[] arrays from pcm_misc.c and pcm_native.c because they
are both the same.Signed-off-by: Clemens Ladisch
Signed-off-by: Jaroslav Kysela -
Check for a valid event type when encoding a system real-time message to
prevent the bytes F9 or FD resulting in an empty sequencer message.Signed-off-by: Clemens Ladisch
Signed-off-by: Jaroslav Kysela -
Reorganize the encoder logic to prevent status bytes that appear where
data bytes are expected from being interpreted as data bytes.Signed-off-by: Clemens Ladisch
Signed-off-by: Jaroslav Kysela