OSDN Git Service
Ken Benoit [Thu, 17 Sep 2015 19:06:38 +0000 (15:06 -0400)]
speaker-test: fix option ordering
The -c and -s options needed to be provided in a specific order for the -s option to work correctly.
This pulls the speaker option check outside of the option parsing so that all the options have been parsed before checking to see if the parameter to -s is correct.
Signed-off-by: Ken Benoit <kbenoit@redhat.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Takashi Iwai [Mon, 10 Aug 2015 12:42:24 +0000 (14:42 +0200)]
alsactl: Add path condition to alsa-store and alsa-restore services
With alsa-restore.service and alsa-store.service, systemd invokes
alsactl at boot and shutdown times. When this is invoked on a system
without sound cards, it results in an ugly error message from alsact
/usr/sbin/alsactl: save_state:1590: No soundcards found...
return code is "19"
Add ConditionPathExistsGlob checks of /dev/snd/control* devices for
avoiding unnecessary invocations of alsactl on such a system.
Bugzilla: https://bugzilla.suse.com/show_bug.cgi?id=940950
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 4 Aug 2015 16:26:40 +0000 (18:26 +0200)]
alsaucm: Drop localbuild hacks
The include and library paths shouldn't be across the build tree.
The installed alsa-lib must have the UCM support for building the
stuff here in alsa-utils repo correctly.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 4 Aug 2015 15:46:02 +0000 (17:46 +0200)]
Add topology/alsatplg to .gitignore
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Liam Girdwood [Tue, 4 Aug 2015 15:23:03 +0000 (16:23 +0100)]
topology: Add command line topology tool to build topology binaries
Add a command line tool that will parse topology text files and convert to the binary
topology data as used by the kernel.
Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Julian Scheel [Tue, 30 Jun 2015 06:57:49 +0000 (08:57 +0200)]
speaker-test: Add option to specify signal scale
Allow generated signals (sine and noise) to have a specified signal scale
instead of using hardcoded limits of 80%. This can be handy for debugging, ie
when analysing clipping issues with audio drivers.
Signed-off-by: Julian Scheel <julian@jusst.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Tobias Stoeckmann [Sat, 11 Jul 2015 11:23:57 +0000 (13:23 +0200)]
alsactl: terminate readlink result string
readlink does not guarantee that its result string is nul-terminated.
Instead, increase the buffer by one byte to make sure that we can
add '\0' at the end.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Wed, 29 Apr 2015 16:01:58 +0000 (18:01 +0200)]
aplay: Fix uninterruptible aplay
When aplay is invoked to play from stdin, it can't be terminated by
normal signals like SIGTERM or SIGINT. It's because our signal
handler tries to trap as much as possible while the stalling point is
not in the PCM loop but rather the file I/O.
For fixing this, leave our signal handler once when a signal is
received and snd_pcm_abort() is called. At the next hit, it shall be
handled normally.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Wed, 29 Apr 2015 16:01:07 +0000 (18:01 +0200)]
aplay: Fix type for signal flag
A flag used in signal handlers has to be a special atomic type,
volatile sig_atomic_t.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Mon, 27 Apr 2015 19:27:05 +0000 (21:27 +0200)]
alsa-info: Don't try update when wget isn't available
... otherwise it overwrites a zero size file. Also add a check of
zero size file in the update procedure, too.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Sakamoto [Wed, 8 Apr 2015 16:30:56 +0000 (01:30 +0900)]
amixer: expand local storage for item name according to kernel code
According to kernel code (snd_ctl_elem_init_enum_names() in
sound/core/control.c), the maximum length of item name is 63 characters
(+ 1 terminator = 64 bytes). But current amixer implementation
uses 40 bytes. This causes name truncation and fail to operation.
This commit fixes this bug by expanding the length of local variables.
Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Peter Meerwald [Tue, 3 Mar 2015 17:39:52 +0000 (18:39 +0100)]
amixer: Don't set only the first item in sset_enum()
Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Thu, 26 Feb 2015 14:49:40 +0000 (15:49 +0100)]
Release v1.0.29
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Thu, 26 Feb 2015 14:47:27 +0000 (15:47 +0100)]
alsa-info.sh: add script to EXTRA_DIST (automake)
Matthieu Crapet [Wed, 14 Jan 2015 14:44:19 +0000 (15:44 +0100)]
configure: allow contitional compilation of alsaucm
If alsa-lib have been compiled with --disable-ucm, alsaucm can't be built.
Detection is dynamic, no configure command line option is available for now.
Signed-off-by: Matthieu Crapet <Matthieu.Crapet@ingenico.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
David Henningsson [Mon, 12 Jan 2015 15:48:38 +0000 (16:48 +0100)]
alsactl/init: Add "Line Out" to list of outputs to initialize
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
David Henningsson [Mon, 12 Jan 2015 15:48:37 +0000 (16:48 +0100)]
alsactl/init: Change the "basic rules" description
We now enable more outputs than just the main speaker, so update
the basic rules to reflect the actual situation.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Wed, 24 Dec 2014 19:15:26 +0000 (20:15 +0100)]
alsactl: add missing state_unlock() call
Takashi Iwai [Sun, 23 Nov 2014 09:04:24 +0000 (10:04 +0100)]
amixer: Parse the value more strictly
So far amixer allows some unexpected suffix and assumes as a raw
absolute value without returning an error. This is rather dangerous,
e.g. user might not notice that a completely wrong value was set when
the command line included a typo.
This patch makes the parser a bit more strict: it doesn't allow any
longer invalid suffixes, instead either returns an error or skips the
invalid value, depending on the operation mode.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Sun, 23 Nov 2014 08:40:07 +0000 (09:40 +0100)]
amixer: Make "dB" case-insensitive in set commands
We don't have to be necessarily too strict about case-sensitivity of
"dB" suffix used in set commands.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Wed, 1 Oct 2014 13:43:57 +0000 (15:43 +0200)]
Revert "aplay: fix pcm_read() return value"
This reverts commit
8aa13eec80eac312e4b99423909387660fb99b8f.
The semantics for pcm_read() and pcm_readv() was changed, but the
callers expect the exact frame count as requested. It's possible
to fix callers, but the fix is more complicated than to revert the
change. Note that '-d' processing was broken in some cases.
Note: The reverted commit allows that the return value might be
greater than requested (see the first condition in read routines).
Jaroslav Kysela [Wed, 24 Sep 2014 08:52:17 +0000 (10:52 +0200)]
alsactl: coverity - missing_va_end – va_end was not called for "ap"
Jaroslav Kysela [Wed, 24 Sep 2014 08:50:54 +0000 (10:50 +0200)]
monitor: fix clang warning - Declared variable-length array (VLA) has zero size
Jaroslav Kysela [Wed, 24 Sep 2014 08:47:48 +0000 (10:47 +0200)]
speaker-text: fix simple signess assignment warning
Jaroslav Kysela [Wed, 24 Sep 2014 08:46:02 +0000 (10:46 +0200)]
alsactl: aded missing monitor() prototype
Jaroslav Kysela [Wed, 24 Sep 2014 08:35:53 +0000 (10:35 +0200)]
alsactl: Fix the file locking routines (for the state management)
Takashi Iwai [Tue, 16 Sep 2014 14:36:44 +0000 (16:36 +0200)]
speaker-test: Add missing draining at the end
Without the call of snd_pcm_drain() the pending data on the buffer
might be discarded, which results in the abort of playback sound in
the middle. Let's fix it.
Reported-and-tested-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
David Henningsson [Fri, 22 Aug 2014 08:31:41 +0000 (10:31 +0200)]
alsa-info: Refactor "withall" logic
Previously, using --output, --no-upload, --upload and --pastebin
switches implied the withall switch.
A more intuitive logic would be that --with-all is disabled if you
use another --with* switch, such as --withdmesg, and only then.
Also update script version to reflect the behaviour change.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
David Henningsson [Fri, 22 Aug 2014 08:31:40 +0000 (10:31 +0200)]
alsa-info: Make sure all full script is run even with "output" option
For some reason, when the --output option is used, less information
is included compared to when no options are used. This is unexpected.
Fix this by running "withall" also when the output option is used.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 12 Aug 2014 14:19:06 +0000 (16:19 +0200)]
Add missing alsa-info entry to the root Makefile.am
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Wed, 30 Jul 2014 10:18:07 +0000 (12:18 +0200)]
Add alsa-info.sh to alsa-utils repo
Copied the latest version (0.4.63) from alsa-driver repo.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Wed, 25 Jun 2014 08:49:23 +0000 (10:49 +0200)]
alsamixer: include missing mixer_controls.h
Jaroslav Kysela [Wed, 25 Jun 2014 08:47:21 +0000 (10:47 +0200)]
alsactl: save state - do not call rename for stdio
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Fri, 13 Jun 2014 17:21:05 +0000 (19:21 +0200)]
Release v1.0.28
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Sergey [Fri, 13 Jun 2014 01:28:49 +0000 (05:28 +0400)]
aplay: Fix VU-meter stdout/stderr mess
Commit
6bbeb78d forgot to change some of VU-meter output to stderr.
This patch makes the output of `aplay -vvv` consistent again.
Signed-off-by: Sergey <sergemp@mail.ru>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
David Henningsson [Fri, 13 Jun 2014 09:31:44 +0000 (11:31 +0200)]
alsactl: Fixup test for mydatadir/sbindir
Use the "mydatadir" name consistently.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
David Henningsson [Fri, 13 Jun 2014 08:04:25 +0000 (10:04 +0200)]
alsactl: Do not run udev rule before datadir/sbindir are both mounted
Sometimes 90-alsa-restore.rules is run before /usr is mounted,
and alsactl restore depends on /usr/share/alsa being present.
If /usr/share/alsa is not present, we're so early in the boot
process that alsa-restore.service (or upstart equivalent) will
run later on.
BugLink: https://bugs.launchpad.net/bugs/1289730
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Fri, 13 Jun 2014 08:52:26 +0000 (10:52 +0200)]
aplay/arecord: Add more in_aborting checks to read/write loops
Reported-by: Sergey <sergemp@mail.ru>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Thu, 12 Jun 2014 08:48:22 +0000 (10:48 +0200)]
configure.ac: cosmetic change
Jaroslav Kysela [Wed, 7 May 2014 09:13:41 +0000 (11:13 +0200)]
alsactl: add -L (no-lock) and change -D (lock-dir) to -O (state-lock-file)
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 7 May 2014 07:49:52 +0000 (09:49 +0200)]
Modernize configure.ac
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 7 May 2014 07:46:08 +0000 (09:46 +0200)]
configure.in -> configure.ac rename
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 7 May 2014 07:43:45 +0000 (09:43 +0200)]
Makefiles - use AM_CPPFLAGS instead INCLUDES
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 7 May 2014 07:29:16 +0000 (09:29 +0200)]
update the gettext configuration
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 7 May 2014 07:19:36 +0000 (09:19 +0200)]
configure: add --with-lock-dir option
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Julian Scheel [Tue, 6 May 2014 19:32:19 +0000 (21:32 +0200)]
alsactl: Store lockfile in /var/lock, add -D option to specify the lock dir
It can not be generally assumed that the directories in which asound.state
resides are writable. Use /var/lock and allow users to alter this path.
Signed-off-by: Julian Scheel <julian@jusst.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Karl Bongers [Wed, 7 May 2014 04:06:47 +0000 (23:06 -0500)]
fix aconnect -l option
aconnect -l would just print usage.
This fix makes it do what usage says it should do.
Signed-off-by: Karl Bongers <karlbongers@gmail.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Erik Ackermann [Wed, 26 Feb 2014 14:52:29 +0000 (06:52 -0800)]
speaker-test: update man page for new -X arg, also consistency fixes
Signed-off-by: Erik Ackermann <kurterikackermann@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Erik Ackermann [Tue, 25 Feb 2014 19:45:24 +0000 (11:45 -0800)]
speaker-test: add --force-frequency option to allow hz outside range
Signed-off-by: Erik Ackermann <kurterikackermann@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Olivier Langlois [Tue, 21 Jan 2014 20:25:12 +0000 (15:25 -0500)]
aplay: fix timespec to msec conversion
There is 1M nsec in a msec.
Signed-off-by: Olivier Langlois <olivier@trillion01.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Dave Reisner [Sun, 12 Jan 2014 16:15:52 +0000 (11:15 -0500)]
alsa-restore.rules: refer to correct attr
$attr{number} in the RUN rule is an empty expansion. This makes sense,
because the path doesn't exist -- i.e., it refers to the path:
/sys/devices/pci0000:00/foo/bar/sound/card0/controlC0/number
Instead, refer to $attr{device/number}, which does exist.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Olivier Langlois [Wed, 8 Jan 2014 04:18:17 +0000 (23:18 -0500)]
aplay: fix pcm_read() return value
Because of the way the pcm_read() functions are currently used, returning
rcount or result is equivalent but I feel it is more accurate to
return 'result'.
Signed-off-by: Olivier Langlois <olivier@trillion01.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Sun, 29 Dec 2013 19:03:21 +0000 (20:03 +0100)]
alsactl: Fix the va_list initialization in cerror_() and dbg_()
The <ap> argument for syslog_() was uninitialized.
From: Alan Hamilton <alanh@arizonaroads.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Takashi Iwai [Tue, 26 Nov 2013 13:27:30 +0000 (14:27 +0100)]
alsactl: monitor all cards as default
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 26 Nov 2013 12:59:19 +0000 (13:59 +0100)]
alsactl: Fix REMOVE event handling in monitor command
SND_CTL_EVENT_MASK_REMOVE has to be checked at first and ignore the
rest if it matches. Suggested by Clemens.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai [Tue, 26 Nov 2013 10:44:40 +0000 (11:44 +0100)]
alsactl: Add monitor command
With monitor command, you can monitor the events received from the
given control device.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Ivailo Monev [Sat, 16 Nov 2013 14:00:19 +0000 (14:00 +0000)]
configure: detect udevdir via pkg-config, fallback to /lib/udev/rules.d
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Mike Frysinger [Wed, 13 Nov 2013 18:23:48 +0000 (13:23 -0500)]
alsaconf: update gentoo to use modprobe.d method as everyone else
We migrated off modules.d a long time ago.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Mike Frysinger [Wed, 13 Nov 2013 18:23:47 +0000 (13:23 -0500)]
alsaconf: support newer m-i-t and kmod
The m-i-t package made it up to 3.10 versions before ending, so update
the glob to handle those too.
Most distros are moving on to kmod, so we also want to handle the version
string that package outputs.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Anssi Hannula [Sun, 10 Nov 2013 18:29:19 +0000 (20:29 +0200)]
speaker-test: Show out-of-chmap channels as Unknown
Currently speaker-test falls back to ALSA default channel names for
channels out-of-chmap.
This causes e.g. the 4th channel of
$ speaker-test -c4 -Dhdmi -m "FR,FL,FC"
to be shown as "Rear Right".
Change the code to show such channels as Unknown instead, similar to
when snd_pcm_chmap_long_name() does not know the name.
Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Anssi Hannula [Sun, 10 Nov 2013 18:29:18 +0000 (20:29 +0200)]
speaker-test: Always show chmap channel names if available
Currently speaker-test only uses channel names retrieved by
snd_pcm_chmap_long_name() when a channel map has been manually set.
However, the device may provide a default (or fixed) channel map that
differs from the traditional ALSA map, in which case wrong channel names
are shown.
Fix that by always using the name from the channel map when a channel
map is present.
Note that the names retrieved by snd_pcm_chmap_long_name() are not
currently localized via gettext.
Also note that Linux kernel HDMI driver reported wrong default channel
maps before
56cac413dd6d43af8355f5d1f90a199b540f73fc ("ALSA: hda - hdmi:
Fix reported channel map on common default layouts").
Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Anssi Hannula [Mon, 11 Nov 2013 22:04:02 +0000 (00:04 +0200)]
speaker-test: Fix chmapped channel selection without specified chmap
The channel selection currently does not work properly when there is a
driver-provided non-ALSA-traditional channel map but no manual channel
map was explicitely requested with "-m".
For example, the CEA/HDMI 8ch map is FL,FR,RLC,RRC,FC,LFE,RL,RR. Note
that it is otherwise the same as the traditional ALSA channel map,
except that the traditional rear speakers are considered
rear-center speakers and the traditional side speakers are considered
rear speakers.
Speaker-test tries to play back channels in this following order:
0, /* Front Left */
4, /* Center */
1, /* Front Right */
7, /* Side Right */
3, /* Rear Right */
2, /* Rear Left */
6, /* Side Left */
5, /* LFE */
When it is the time to play back Side Left/Right, speaker-test tries to
look for SL/SR in the chmap, but doesn't find it, so it just plays back
channels 6/7 (which indeed are the side speakers, or RL/RR in this
channel map - so the correct channels are selected).
When it becomes the time to playback Rear Left/Right, speaker-test again
tries to find RL/RR in the chmap, and this time it does find them in the
chmap positions 6/7.
So the channels 6/7 are tested twice and 2/3 are never tested.
To fix this, define a generic playback order channel_order[] to be used
when the channel map is present (but not user-defined) and generate a
(speaker/playback number => channel number) mapping with the channels
ordered in the following order:
1. regular channels found in channel_order[] in the defined order,
2. channels not found in channel_order[] ordered by channel number.
3. UNKNOWN channels ordered by channel number.
4. NA channels ordered by channel number.
For channels outside the channel map just use their channel numbers (so
they will be last after all of the above).
For example, if the playback device has a fictional default channel map
of FR,FL,UNKNOWN1,FOO,BAR,RR,RL,UNKNOWN2, the playback order will be
FL,FR,RR,RL,FOO,BAR,UNKNOWN1,UNKNOWN2(,any_extra_channels).
When the channel mapping is specified manually, the specified order is
used for playback as before.
Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
John Spencer [Fri, 8 Nov 2013 12:59:41 +0000 (13:59 +0100)]
alsaloop: pcmjob.c: use portable way to initialize recursive mutex
PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP is not in POSIX, as _NP
(non-portable) suggests.
exposing such a symbol in musl libc would lock in the ABI for all
times and makes it impossible to do future changes to the under-
lying struct without hideous symbol versioning hacks.
use the portable way instead: pthread_once was designed for such
cases.
Signed-off-by: John Spencer <maillist-alsa@barfooze.de>
Tested-by: John Spencer <maillist-alsa@barfooze.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Anssi Hannula [Tue, 1 Oct 2013 20:46:53 +0000 (23:46 +0300)]
amixer: fix indentation when printing container TLV contents
decode_tlv() adds indentation in the beginning, with the expectation
that the TLV will be printed on the line afterwards in a switch-case.
However, in the case of a container TLV the switch-case simply adds
another level of indentation and calls decode_tlv() for the inner TLVs.
This causes the first inner TLV to be printed with too much indentation
and double '|'.
Fix that by printing "container" and a newline for container TLVs, so
that the result is as follows:
: values=0,0,0,0,0,0,0,0
| container
| chmap-variable=FL,FR
| chmap-variable=FL,FR,LFE
| chmap-variable=FL,FR,FC
Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Anssi Hannula [Mon, 30 Sep 2013 20:46:50 +0000 (23:46 +0300)]
amixer: actually print all TLVs in a container TLV
Due to a wrong indexing of tlv[] decode_tlv() always skips to the end of
the container TLV since the used tlv[1] contains the container TLV size
instead of the intended element size.
This causes, for example, only the first HDMI channel map TLV to be
shown.
Fix the indexing to actually use the element size.
Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Fri, 26 Jul 2013 14:16:00 +0000 (16:16 +0200)]
alsaloop: add -z,--syslog option to use syslog for errors
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jurgen Kramer [Mon, 9 Sep 2013 10:02:29 +0000 (12:02 +0200)]
aplay: fix two off by one errors
Attached patch for aplay fixes two off-by-one errors preventing usage
of the last available sample format.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Tue, 23 Jul 2013 12:57:05 +0000 (14:57 +0200)]
alsaloop: fix wrong alias for signal.h
in POSIX, there is no <sys/signal.h>.
it's merely a legacy alias used by glibc, and the header does nothing
else than including <signal.h>.
so let's do the right thing and use the right name, which works everywhere.
Signed-off-by: John Spencer <maillist-alsa@barfooze.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Fri, 19 Jul 2013 12:36:52 +0000 (14:36 +0200)]
alsactl: alsa-state.service - fix typo (rkill -> kill)
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Tue, 9 Jul 2013 15:28:37 +0000 (17:28 +0200)]
Release v1.0.27.2
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
David Henningsson [Mon, 10 Jun 2013 14:42:48 +0000 (16:42 +0200)]
speaker-test: Fix wrong wave file played back in chmap setup
When explicitly specifying channel maps, we need to use that when
loading wave files so the correct file is played back.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
David Henningsson [Fri, 14 Jun 2013 09:41:01 +0000 (11:41 +0200)]
amixer: Print TLV of channel map controls
Previously these were written as "unk-25..." which wasn't very user friendly.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Tue, 28 May 2013 06:43:30 +0000 (08:43 +0200)]
amixer: fix print_dB for -0.99 .. -0.01 range
The first number is 0 when input dB (hundreds) is in range -99 .. -1 .
The printed number was positive in this case. This patch fixes this issue.
Reported-by: Tom Becker <GTBecker@RighTime.com>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Mon, 27 May 2013 14:40:26 +0000 (16:40 +0200)]
amixer: Fix the hctl elem search bug
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Mon, 27 May 2013 07:26:39 +0000 (09:26 +0200)]
alsactl: return back the udevrules_DATA rule for 90-alsa-restore.rules
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Gabriel M. Beddingfield [Sun, 26 May 2013 22:54:44 +0000 (15:54 -0700)]
alsactl init: ca0106 file was omitted
The file alsactl/init/00main includes the line:
CARDINFO{driver}=="CA0106", INCLUDE="ca0106", GOTO="init_end"
However, the file alsactl/init/ca0106 is not making it into the
release tarballs (nor to user installations).
This patch adds the ca0106 file to the build.
Signed-off-by: Gabriel M. Beddingfield <gabrbedd@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jordi Mallach [Fri, 17 May 2013 12:30:46 +0000 (14:30 +0200)]
Require alsa-lib 1.0.27.
Both aplay and speaker-test use the new snd_pcm_abort() function, which was
introduced in alsa-lib 1.0.27.
Signed-off-by: Jordi Mallach <jordi@debian.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Tue, 21 May 2013 08:48:28 +0000 (10:48 +0200)]
Release v1.0.27.1
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Tue, 21 May 2013 08:27:25 +0000 (10:27 +0200)]
alsactl: remove 90-alsa-restore.rules from the tar ball
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jordi Mallach [Wed, 15 May 2013 17:12:57 +0000 (19:12 +0200)]
Add AM_MAINTAINER_MODE([enable]) to configure.in.
Signed-off-by: Jordi Mallach <jordi@debian.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jordi Mallach [Wed, 15 May 2013 17:12:56 +0000 (19:12 +0200)]
Fix a build failure due to a misused format string.
This fixes builds with -Werror=format-security.
Signed-off-by: Jordi Mallach <jordi@debian.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jordi Mallach [Wed, 15 May 2013 17:12:55 +0000 (19:12 +0200)]
Several formatting fixes for manpages.
Fix many occurrences of unescaped “-”.
Fix minor English issue.
Signed-off-by: Jordi Mallach <jordi@debian.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Elimar Riesebieter [Wed, 15 May 2013 17:12:54 +0000 (19:12 +0200)]
Fix several typos in manpage and help strings.
Signed-off-by: Jordi Mallach <jordi@debian.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Doug Goldstein [Wed, 1 May 2013 16:30:26 +0000 (11:30 -0500)]
alsactl: sprintf to snprintf prevent buffer overflow
sprintf() is a bit dangerous unless you explicitly know your type size
and want to keep it in sync always. Its safer to just use snprintf() and
ensure your string doesn't overflow and is NULL terminated.
Signed-off-by: Doug Goldstein <cardoe@cardoe.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Wed, 17 Apr 2013 06:34:34 +0000 (08:34 +0200)]
arecord: add a missing break to the capture loop
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Mon, 15 Apr 2013 12:44:13 +0000 (14:44 +0200)]
alsactl: Fix the string size for the lock file contents
The string length is 10 characters + LF + '\0' = 12 characters.
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Takashi Iwai [Mon, 15 Apr 2013 09:20:41 +0000 (11:20 +0200)]
alsactl: Fix a typo in systemd alsa-restore.service
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Jaroslav Kysela [Thu, 11 Apr 2013 11:43:06 +0000 (13:43 +0200)]
Release v1.0.27
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 10 Apr 2013 09:08:47 +0000 (11:08 +0200)]
alsactl: add --with-alsactl-daemonswitch=FILE to the global configure.in
It may be useful to have the file location configurable.
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 10 Apr 2013 08:23:16 +0000 (10:23 +0200)]
alsactl: revert back old systemd static units with the /etc/alsa/state-daemon.conf switch
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 10 Apr 2013 07:42:40 +0000 (09:42 +0200)]
alsactl: add --nice and --sched-idle options
The state management can run at low priority, add --nice and --sched-idle
options to set the scheduler.
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Tue, 9 Apr 2013 16:38:58 +0000 (18:38 +0200)]
amixer: Use the alsa-lib functions for id print and parse and value parse
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Tue, 9 Apr 2013 16:10:22 +0000 (18:10 +0200)]
alsactl: daemon mode - remove disconnected cards
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Mon, 8 Apr 2013 12:49:31 +0000 (14:49 +0200)]
alsactl: move systemd config to the daemon mode
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Mon, 8 Apr 2013 11:57:51 +0000 (13:57 +0200)]
speaker-test: change the interrupt handling logic to follow aplay/arecord
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Mon, 8 Apr 2013 11:30:54 +0000 (13:30 +0200)]
aplay/arecord: change the interrupt handling using snd_pcm_abort()
It is required (exclude the fatal SIGABRT) to call snd_pcm_close() and
the end of work (outside of the interrupt handler). Use new snd_pcm_abort()
function to inform alsa-lib to not ignore EINTR and move the in_aborting
variable to the global scope to be checked in the i/o loops.
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Mon, 8 Apr 2013 09:31:45 +0000 (11:31 +0200)]
alsactl: add event filter and cache for the daemon mode
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Fri, 5 Apr 2013 11:42:15 +0000 (13:42 +0200)]
alsactl: Improved command line argument handling...
Improve command line argument handling for future extensions.
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Fri, 5 Apr 2013 09:51:51 +0000 (11:51 +0200)]
alsactl: add the daemon mode
For the plug-and-play hardware, like USB devices, it may be helpful
to manage the sound state periodically, before the devices are removed.
This change implements new commands 'daemon' and 'rdaemon' to save
the sound state in defined intervals when the sound controls are changed.
The udev rules can notify the daemon using the 'kill' or 'nrestore'
commands to rescan available cards in the system.
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Jaroslav Kysela [Wed, 3 Apr 2013 09:57:52 +0000 (11:57 +0200)]
alsactl: small code reorder to avoid memory leaks
Signed-off-by: Jaroslav Kysela <perex@perex.cz>