| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit allows to define private alsa-lib's configuration. When
the configuration is present, the device values ("PlaybackCTL",
"CaptureCTL", "PlaybackMixer", "CaptureMixer", "CapturePCM")
are prefixed with '_ucmHEXA.' string where HEXA is replaced by the
unique hexadecimal number identifying the opened ucm manager handle.
Syntax 4
LibraryConfig.a_label.SubstiConfig {
# substituted library configuration like:
usr_share_dir "${ConfLibDir}"
}
LibraryConfig.b_label.Config {
# non-substituted library configuration like:
usr_share_dir "/usr/share/alsa"
}
The File counterparts:
LibraryConfig.c_label.SubstiFile "/some/path"
LibraryConfig.d_label.File "/some/path"
Note that for files the contents is substituted on the request,
but the file name is always substituted (useful for ${ConfDir} etc.).
The private configuration is not saved or preserved. It's life time
belongs to the opened ucm manager handle.
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
|
| | |
|
| |
|
|
|
|
|
|
|
|
| |
snd_dlopen() was recently rewritten to be versioned symbols, and we
have to call it with INTERNAL() wrapper from the library itself.
Add the proper declaration in the local header and fix the callers
appropriately.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
| |
|
|
|
|
|
| |
The dlopen() function might fail also for another reason than
a missing file, thus return the error string from dlerror().
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
|
| |
|
|
| |
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Most of open functions in alsa-lib have the call pattern:
snd_config_update();
return snd_xxx_open(x, snd_config, ...);
This means that the toplevel config gets updated, and passed to a
local open function. Although snd_config_update() itself has a
pthread mutex to be thread safe, the whole procedure above isn't
thread safe. Namely, the global snd_config tree may be deleted and
recreated at any time while the open function is being processed.
This may lead to a data corruption and crash of the program.
For avoiding the corruption, this patch introduces a refcount to
config tree object. A few new helper functions are introduced as
well:
- snd_config_update_ref() does update and take the refcount of the
toplevel tree. The obtained config tree has to be freed via
snd_config_unref() below.
- snd_config_ref() and snd_config_unref() manage the refcount of the
config object. The latter eventually deletes the object when all
references are gone.
Along with these additions, the caller of snd_config_update() and
snd_config global tree in alsa-lib are replaced with the new helpers.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The configure script blindly adds -D_GNU_SOURCE to all build settings,
even on non-GNU systems. This isn't too much of a big deal (even if
it uses the wrong variable -- CFLAGS instead of CPPFLAGS), except that
the alsa-lib source itself determines whether to use GNU features when
this is defined (such as versionsort). So when we build on non-glibc
systems, we get build failures like:
src/ucm/parser.c:1268:18: error: 'versionsort' undeclared (first use in this function)
#define SORTFUNC versionsort
^
src/ucm/parser.c:1272:54: note: in expansion of macro 'SORTFUNC'
err = scandir(filename, &namelist, filename_filter, SORTFUNC);
^
The correct way to add these flags is to use the autoconf helper
AC_USE_SYSTEM_EXTENSIONS. Unfortunately, that triggers some more
bugs in the alsa build. This macro adds defines to config.h and
not directly to CPPFLAGS, so it relies on files correctly including
config.h before anything else. A number of alsa files do not do
this leading to build failures. The fix there is to shuffle the
includes around so that the local ones come first.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
| | |
|
| |
|
|
|
| |
Allow building alsa-lib without libdl and libpthread.
Added new options to configure, --with-libdl and --with-pthread.
|
| |
|
|
|
|
|
| |
this trivial patch initializes dl handle in timer.c and timer_query.c
where it needs to.
Signed-off-by: Benoit Fouet <benoit.fouet@purplelabs.com>
|
| |
|
|
|
| |
Call snd_dlclose() properly for the dlopened handlers in timer
and timer_query closing functions.
|
| |
|
|
|
| |
free() correctly handles NULL pointers, so we can omit explicit checks
for that condition.
|
| |
|
|
|
|
| |
Remove several memory leaks by not aborting prematurely from a
snd_xxx_close() function when some operation fails.
This can happen when a USB device was unplugged.
|
| |
|
|
| |
Fixed compile warnings with gcc-4 about pointer signedness.
|
| |
|
|
|
| |
Fix the warnings of doxygen parsing.
Add some missing documentation.
|
| |
|
|
|
| |
- added snd_async_add_timer_handler and snd_async_handler_get_timer functions
- added async command to test/timer.c
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
More updates to pcm_dmix.c .
|
| | |
|
| | |
|
| |
|
|
| |
Changed GNU LGPL licence from 2.0 to 2.1.
|
| |
|
|
| |
timer); Uros
|
| | |
|
| |
|
|
| |
Some minor changes in config interface documentation.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- changed snd_config_get_id function to follow semantic of other get functions
- added snd_config_test_id
- added runtime pointer type (not persistent)
- added snd_config_make_pointer, snd_config_set_pointer, snd_config_get_pointer
- added type/contents checking for callback functions
- changed 'void *private_data' to 'snd_config_t *private_data'
- renamed card_strtype functions to card_driver
Control:
- fixed passing parameters to snd_ctl_async
Async handlers:
- added public snd_async_handler_get_signo function
Documentation:
- moved all documentation to source files
|
| | |
|
| | |
|
| |
|
|
| |
Removed snd_config_refer_load from confmisc.c and pcm.c.
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
CTL documentation
|
| | |
|
| |
|
|
|
|
|
| |
fds).
Added poll_descriptors_count functions.
Added snd_mixer_elem_count function.
|
| | |
|
| |
|
|
| |
hw_params API. Added missing const.
|
| |
|
|
| |
Completed encapsulation of PCM API. Removed snd_pcm_card(). All copy functions now have the form copy(dst, src).
|
| | |
|
| |
|
|
| |
The device lists use the next device syntax now.
|
| | |
|
| | |
|
| | |
|