Arun Raghavan [Mon, 4 Jan 2016 05:47:29 +0000 (11:17 +0530)]
build-sys: Only use sysroot in OS X CFLAGS if specified
The default value doesn't make sense any more, so we'll only use this if
explicitly specified.
Tanu Kaskinen [Sat, 6 Feb 2016 13:35:31 +0000 (15:35 +0200)]
default.pa: remove X11 module examples
Loading X stuff from default.pa is a bad idea, since it doesn't work
if there are multiple X sessions, or PulseAudio is started outside the
X session. Since it's a bad idea, don't encourage it by including
examples that do so.
I also removed the sample loading examples. I don't think the examples
are particularly useful, since nothing uses the loaded samples once
module-x11-bell is removed from the configuration.
BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=93109
Arun Raghavan [Tue, 9 Feb 2016 10:49:00 +0000 (16:19 +0530)]
glib: Trivial whitespace fix
Jungsup Lee [Tue, 2 Feb 2016 04:47:57 +0000 (13:47 +0900)]
rescue-streams : Fix a typo
Fix a typo in log message.
Signed-off-by: Jungsup Lee <jungsup4.lee@samsung.com>
Tanu Kaskinen [Tue, 26 Jan 2016 12:57:32 +0000 (14:57 +0200)]
device-manager: improve logging about non-existing data
Previously a missing key would cause this kind of log output:
D: [pulseaudio] module-device-manager.c: Database contains invalid data for key: sink:auto_null (probably pre-v1.0 data)
D: [pulseaudio] module-device-manager.c: Attempting to load legacy (pre-v1.0) data for key: sink:auto_null
D: [pulseaudio] module-device-manager.c: Size does not match.
D: [pulseaudio] module-device-manager.c: Unable to load legacy (pre-v1.0) data for key: sink:auto_null. Ignoring.
That is now replaced with
D: [pulseaudio] module-device-manager.c: Database contains no data for key: sink:auto_null
Kamil Rytarowski [Mon, 21 Dec 2015 03:10:35 +0000 (04:10 +0100)]
solaris: Illumos does not ship with SOUND_PCM* functionality
Code reference:
https://github.com/joyent/illumos-joyent/blob/master/usr/src/uts/common/sys/audio/audio_oss.h
Add autoconf checks for:
- SOUND_PCM_READ_RATE
- SOUND_PCM_READ_CHANNELS
- SOUND_PCM_READ_BITS
Some platforms like SunOS (Illumos) may ship without SOUND_PCM_* functionality
Thanks to Jonathan Perkin (Joyent) for Illumos code reference.
Jonathan Perkin [Mon, 21 Dec 2015 03:10:34 +0000 (04:10 +0100)]
solaris: Catch up with newer API
Patch upstreamed from pkgsrc by Kamil Rytarowski <n54@gmx.com>.
See commit
e4a7625ba884c5cce20468d75937857343751c35 for why this was
originally done.
Marcin Lewandowski [Sat, 16 Jan 2016 14:42:34 +0000 (15:42 +0100)]
vala: Added cnames to callback delegates in Vala VAPI
Tanu Kaskinen [Thu, 7 Jan 2016 13:25:41 +0000 (15:25 +0200)]
source-output: remap volume_factor_source when starting move
This gets rid of an error message from the debug log. If
volume_factor_source would actually be used somewhere, this bug would
have caused more severe problems.
volume_factor_source should have the source's channel map. When moving
the stream, the volume needs to be remapped from the old source's
channel map to the new source's map. However, when the stream is being
moved, there is a period where the old source has already been
forgotten and the new source isn't yet known, so the remapping can't
be done directly between the two channel maps. Instead, the volume is
remapped from the old source's map to the stream's own map when the
move starts, and again remapped from the stream's map to the new
source's map when the move finishes.
The first remapping was missing, causing the second remapping fail and
print an error to the log.
(I checked the sink input code as well. It didn't have this bug.)
Tanu Kaskinen [Thu, 7 Jan 2016 13:25:40 +0000 (15:25 +0200)]
source-output: do volume_factor_source application before resampling
Applying the volume after resampling means mismatch between the volume
channel map and the data channel map.
volume_factor_source is not currently used anywhere, so this bug
hasn't been causing any problems. I noticed it while reading the code.
Arun Raghavan [Thu, 31 Dec 2015 03:58:28 +0000 (09:28 +0530)]
pulse: Bump PA_RATE_MAX to 384 kHz
This will likely be needed in the future when we start supporting high
bitrate passthrough, and there actually seem to be people 352/384 kHz
out there (potentially as an intermediate production step).
Arun Raghavan [Thu, 31 Dec 2015 03:57:56 +0000 (09:27 +0530)]
format: Make pa_format_info_valid() stricter for PCM
We should do stricter validation when we can.
Arun Raghavan [Fri, 22 Jan 2016 07:31:36 +0000 (13:01 +0530)]
Update NEWS for 8.0
Jason Gerecke [Thu, 14 Jan 2016 04:27:39 +0000 (20:27 -0800)]
bluetooth: Prevent aborts caused by invalid module arguments
If 'pa_modargs_new' returns a NULL, we need to be careful to not call
'pa_modargs_free' in the failure path since it requires that we pass it
a non-null argument. Also updates 'module-bluetooth-policy.c:pa__init'
to follow the standard "goto fail" pattern used everywhere else.
Signed-off-by: Jason Gerecke <killertofu@gmail.com>
Arun Raghavan [Fri, 15 Jan 2016 10:39:49 +0000 (16:09 +0530)]
build-sys: Use #ifdef with HAVE_FAST_64BIT_OPERATIONS
The define is made conditionally.
Reported by: Kamil Rytarowski <n54@gmx.com>
Arun Raghavan [Tue, 12 Jan 2016 10:01:06 +0000 (15:31 +0530)]
stream: Clarify pa_stream_writable_size() documentation
Arun Raghavan [Mon, 11 Jan 2016 07:22:10 +0000 (12:52 +0530)]
sink-input, source-output: Add some debug output on start_move()
Kamil Rytarowski [Sun, 20 Dec 2015 00:25:41 +0000 (01:25 +0100)]
NetBSD: Stop depending upon nonstandard __WORDSIZE
There is no way to check CPU type in a portable way across ABIs.
Assume if pointers are 64-bit that CPU is capable to perform fast
64-bit operations. Add an extra check to handle x32-ABI.
PulseAudio by default builds with -Wundef. If we add -Werror=undef this
missing define is fatal. By default build log is full of entries like:
In file included from ./pulsecore/core.h:47:0,
from ./pulsecore/module.h:31,
from ./pulsecore/sink-input.h:31,
from pulsecore/sound-file-stream.c:36:
./pulsecore/sample-util.h: In function 'pa_mult_s16_volume':
./pulsecore/sample-util.h:58:5: warning: "__WORDSIZE" is not defined [-Wundef]
#if __WORDSIZE == 64 || ((ULONG_MAX) > (UINT_MAX))
^
(NetBSD-7.99.21 with default GCC 4.8.5)
This change fixes build issues on NetBSD.
This also address a bug reported by Shawn Walker from Oracle (possibly Solaris):
Bug 90880 - builds can fail due to non-portable glibc-specific internal macro usage
jungsup lee [Wed, 6 Jan 2016 05:18:50 +0000 (14:18 +0900)]
rtpoll: Fix build error when building with DEBUG_TIMING
This typo causes a build error when DEBUG_TIMING is defined.
Signed-off-by: jungsup lee <jungsup4.lee@samsung.com>
KimJeongYeon [Wed, 6 Jan 2016 08:28:11 +0000 (17:28 +0900)]
module-tunnel: Fix double free
Local pointer 'dn' freed again when pa_thread_new() failed.
Signed-off-by: KimJeongYeon <jeongyeon.kim@samsung.com>
Mihai Moldovan [Mon, 20 Apr 2015 18:46:02 +0000 (20:46 +0200)]
module-coreaudio-device: get channel name as CFString and convert to plain C string.
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
The old code fetched the channel name via AudioObjectGetPropertyData()
and accessed the "returned" data as a plain char buffer.
This may or may not have worked at some point according to the Apple
CFString documentation, which warns that the actual data layout is an
implementation detail and subject to change at any time.
On recent OS X versions, this behavior led to "random data" channel
names like >H��{, H��{<.
We need to actually let AudioObjectGetPropertyData() populate a CFString
struct and convert this into a plain char buffer.
The conversion function will not free the CFString, so do that in the
caller.
Signed-off-by: Mihai Moldovan <ionic@ionic.de>
Mihai Moldovan [Tue, 21 Apr 2015 06:01:27 +0000 (08:01 +0200)]
system.pa.in: load module-coreaudio-detect if HAVE_COREAUDIO.
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
Signed-off-by: Mihai Moldovan <ionic@ionic.de>
Mihai Moldovan [Tue, 21 Apr 2015 06:01:16 +0000 (08:01 +0200)]
default.pa.in: load module-coreaudio-detect if HAVE_COREAUDIO.
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
Signed-off-by: Mihai Moldovan <ionic@ionic.de>
Mihai Moldovan [Tue, 21 Apr 2015 06:01:05 +0000 (08:01 +0200)]
configure.ac: add HAVE_COREAUDIO to automake and code.
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
Signed-off-by: Mihai Moldovan <ionic@ionic.de>
Arun Raghavan [Tue, 29 Dec 2015 00:30:14 +0000 (06:00 +0530)]
alsa: Don't disable timer-based scheduling on USB devices
This isn't a great fix, but we need ALSA API to do this right. In the
mean time, USB devices work fine with timer-based scheduling, so there's
no reason to force a large minimum latency by disabling tsched on them.
Felipe Sateler [Mon, 28 Dec 2015 23:34:08 +0000 (20:34 -0300)]
build-sys: Fix install order of libpulsecore
It needs to be installed after libpulse, because of libtool relinking.
Felipe Sateler [Mon, 28 Dec 2015 23:34:09 +0000 (20:34 -0300)]
travis: Run make install in travis.
This helps detect ordering problems in the install target
Tanu Kaskinen [Sun, 27 Dec 2015 12:52:37 +0000 (14:52 +0200)]
build-sys: add typedefs.h to libpulsecore SOURCES
Without this the file doesn't get included in tarballs.
Tanu Kaskinen [Sun, 27 Dec 2015 12:41:04 +0000 (14:41 +0200)]
build-sys: bump sonames
Bump 18 -> 19 due to the addition of the LFE balance API.
Arun Raghavan [Mon, 21 Dec 2015 05:24:58 +0000 (10:54 +0530)]
daemon: Sanitise message about unsupported high res timers
Arun Raghavan [Mon, 21 Dec 2015 05:38:25 +0000 (11:08 +0530)]
build: Move to using Travis trusty images
Tanu Kaskinen [Sun, 20 Dec 2015 10:18:28 +0000 (12:18 +0200)]
always-sink: simplify hook management with pa_module_hook_connect()
Yuri Chornoivan [Sun, 20 Dec 2015 11:35:13 +0000 (13:35 +0200)]
i18n: Update Ukrainian translation
David Henningsson [Fri, 18 Dec 2015 12:34:46 +0000 (13:34 +0100)]
gitignore: Add .orig and .rej to gitignore
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Pierre Ossman [Thu, 10 Dec 2015 15:22:54 +0000 (16:22 +0100)]
context: continue without srbchannel if it fails
We might be compiled without eventfd support, or something else
might go wrong. And it's fully possible to continue using the old
channel rather than just disconnecting.
Signed-off-by: Pierre Ossman <ossman@cendio.se>
Georg Chini [Wed, 25 Feb 2015 18:43:24 +0000 (19:43 +0100)]
loopback: Validate the rate parameter
Arun Raghavan [Wed, 18 Nov 2015 02:56:47 +0000 (08:26 +0530)]
echo-cancel: Don't skip canceller when sink is inactive
This forces the canceller engine to be invoked even if playback is not
currently active. We need to do this for cases where the engine provides
additional processing that is independent of playback, such as noise
suppression and AGC.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=83557
Felipe Sateler [Fri, 11 Dec 2015 14:00:30 +0000 (11:00 -0300)]
build-sys: Make pulsecore a private library
It is not meant to be used by third parties, so do not install in a public dir
Tanu Kaskinen [Mon, 7 Dec 2015 21:22:42 +0000 (23:22 +0200)]
client-conf, daemon-conf: enable .d directories
I want to enable client.conf.d, because in OpenEmbedded-core we have
a graphical environment called Sato that runs as root. Sato needs to
set allow-autospawn-for-root=true in client.conf, but the default
configuration in OpenEmbedded-core should not set that option. With
this patch, I can create a Sato-specific package that simply installs
50-sato.conf in /etc/pulse/client.conf.d without conflicting with the
main client.conf coming from a different package.
daemon.conf.d is enabled just because it would be strange to not
support it while client.conf.d is supported.
Tanu Kaskinen [Mon, 7 Dec 2015 21:22:41 +0000 (23:22 +0200)]
conf-parser: add support for .d directories
This allows a configuration scheme where after loading configuration
from "somefile", the parser loads configuration from files in
directory "somefile.d". This feature needs to be enabled on a per-file
basis, though, and this patch doesn't yet enable the feature for any
files.
David Henningsson [Thu, 26 Nov 2015 17:29:58 +0000 (18:29 +0100)]
typedefs.h: Move some typedefs to a separate file
The relationship between sinks, sources, cards, profiles, and ports
is becoming ever more intertwined, to the point that if you try to
include one file from the other, you're likely to end up with some
weird error somewhere else.
Work around this by creating a new typedefs.h, which does not depend
on anything else, and just creates a few typedefs.
(Can be expanded with more typedefs in the future if the need arises.)
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Juho Hämäläinen [Thu, 10 Dec 2015 13:09:34 +0000 (15:09 +0200)]
alsa-mixer: Have valid proplist for synthesized path as well.
When synthesized alsa path is freed there is an assert from NULL
proplist. Create empty proplist for the path to fix.
Signed-off-by: Juho Hämäläinen <juho.hamalainen@nomovok.com>
Kamil Rytarowski [Tue, 8 Dec 2015 03:22:42 +0000 (04:22 +0100)]
netbsd: Revamp NetBSD platform checks
Kamil Rytarowski [Fri, 20 Nov 2015 03:20:36 +0000 (04:20 +0100)]
core, pulse, modules: Fix undefined behavior with array subscript of invalid type
From the NetBSD manual:
The first argument of these functions is of type int, but only a very
restricted subset of values are actually valid. The argument must either
be the value of the macro EOF (which has a negative value), or must be a
non-negative value within the range representable as unsigned char.
Passing invalid values leads to undefined behavior.
-- ctype(3)
Kamil Rytarowski [Tue, 8 Dec 2015 01:52:08 +0000 (02:52 +0100)]
core-rtclock: Add missing declaration of struct timespec
Tanu Kaskinen [Tue, 29 Sep 2015 08:41:51 +0000 (11:41 +0300)]
build-sys: fix PULSE_LOCALEDIR definition
On some systems (at least Arch) DATADIRNAME is not defined. This
caused PULSE_LOCALEDIR to point to a wrong directory. This seemed like
an issue introduced in 7.0, but probably something else was updated in
Arch at the same time, causing DATADIRNAME to become undefined,
because there were no changes between 6.0 and 7.0 that could have
caused this.
After noticing that localedir is a standard variable, my first idea
was to use pulselocaledir='${localedir}' in configure.ac, but Jan
Steffens pointed out that it causes the final PULSE_LOCALEDIR to
become "${prefix}/share/locale", that is, the variables weren't fully
expanded. I then found a FAQ item in Autoconf's manual[1], which
recommends not to define any absolute installation directories in
configure.ac, because the installation directories should be possible
to change when running make. The recommended solution is to define the
constant in AM_CPPFLAGS instead, so that's what this patch does.
[1] https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/Defining-Directories.html
Tanu Kaskinen [Wed, 12 Aug 2015 09:37:00 +0000 (11:37 +0200)]
core-util: improve comments in pa_machine_id()
Kiran Krishnappa [Thu, 25 Jun 2015 16:29:36 +0000 (21:59 +0530)]
module: Remove redundant core argument from pa_module_unload()
pa_module_unload() takes two pointers: pa_module and pa_core.
The pa_core pointer is also available via the pa_module object,
so the pa_core argument is redundant
[David Henningsson: Rebased to git HEAD]
Kamil Rytarowski [Sat, 28 Nov 2015 13:59:26 +0000 (14:59 +0100)]
netbsd: Fix unportable test(1) construct
Kamil Rytarowski [Sat, 28 Nov 2015 09:01:05 +0000 (10:01 +0100)]
netbsd: Improve handling of <locale> and <xlocale.h> headers
NetBSD ships with strtod_l(3) in <stdlib.h>.
Having strtol_l(3) doesn't imply to have <xlocale.h>.
Generalize inclusion of <locale.h> and <xlocale.h>.
Alexander E. Patrakov [Fri, 27 Nov 2015 12:30:38 +0000 (17:30 +0500)]
alsa-sink: Don't pretend to support passthrough on HDMI surround sinks
It doesn't work currently (fails and falls back to PCM), due to channel
count mismatch between the sink sample spec and the sample spec required
by IEC61937.
To be reverted when someone implements changing channel count without
switching profiles. This would also be required for HBR passthrough over
HDMI.
Reported-by: Xamindar <junkxamindar@gmail.com>
Signed-off-by: Alexander E. Patrakov <patrakov@gmail.com>
Tanu Kaskinen [Fri, 4 Dec 2015 05:38:20 +0000 (07:38 +0200)]
man: remove a reference to pacmd from default.pa.5
I don't want to have unnecessary advertising for pacmd, because I
think pacmd should be deprecated.
Tanu Kaskinen [Fri, 4 Dec 2015 05:38:19 +0000 (07:38 +0200)]
man: document when system.pa is used instead of default.pa
David Henningsson [Thu, 26 Nov 2015 13:29:23 +0000 (14:29 +0100)]
card: Only update port's preferred profile if profile is saved
In case pa_card_set_profile is called with save=false, then probably
it makes more sense not to update the port's preferred profile as well.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Mingye Wang (Arthur2e5) [Sat, 21 Nov 2015 22:47:16 +0000 (17:47 -0500)]
i18n: Updated zh_CN translation
This patch updates zh_CN translation to 518 complete, 0 fuzzy and 3
untranslated.
Kamil Rytarowski [Sat, 21 Nov 2015 22:08:23 +0000 (23:08 +0100)]
netbsd: NetBSD ships with paccept(2) a superset of Linux-specific accept4()
[diwic: Moved paccept to #bsd line in configure.ac]
Nazar Mokrynskyi [Sun, 11 Oct 2015 01:35:56 +0000 (03:35 +0200)]
alsa-mixer: sb-omni-surround-5.1.conf: remove analog-surround-21, add Linux 4.3+ support
In 2.1 mode LFE is not actually working at all, so it is removed.
With Linux 4.3-rc1+ Mic/Line are hw:%f,0,0 as it should be: https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/usb?id=
5ee20bc792467d7d612157e0a9962765aa943b08
So now we support both Linux 4.2.x- and 4.3-rc1+ setups.
Also in Linux 4.3-rc1 S/PDIF input was detected incorrectly (there is no such hardware input), so it is not present in config.
David Henningsson [Tue, 17 Nov 2015 14:10:36 +0000 (15:10 +0100)]
module-card-restore: Remove "version" from internal entry struct
If we always write entries of the latest version, we can simplify
code a little by only handling old versions in the "entry_read"
function and assume we have the latest version everywhere else.
Suggested-by: Tanu Kaskinen <tanuk@iki.fi>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 17 Nov 2015 14:10:35 +0000 (15:10 +0100)]
module-switch-on-port-available: Route to preferred profile
This makes the routing slightly more aggressive:
* It will try to route to another profile, if such a profile
is preferred by the port.
* It will allow changing profiles on transitions both to
PA_AVAILABLE_YES and PA_AVAILABLE_NO
To accommodate there is also some refactoring.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 17 Nov 2015 14:10:34 +0000 (15:10 +0100)]
module-switch-on-port-available: Use input and output names
In case input or output names are filled in, we can use this to
get a better match in the profile_good_for_input/output functions
instead of guessing based on number of sources and channels.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 17 Nov 2015 14:10:33 +0000 (15:10 +0100)]
card-restore: Save and restore "preferred profile" of port
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 17 Nov 2015 14:10:32 +0000 (15:10 +0100)]
card: Update preferred_profile for ports when profile changes
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 17 Nov 2015 14:10:31 +0000 (15:10 +0100)]
device-port: Add preferred_profile field to pa_device_port
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 17 Nov 2015 14:10:30 +0000 (15:10 +0100)]
alsa-mixer: Fill in input and output names
Fill in input_name and output_name to make routing easier for
routing modules.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 17 Nov 2015 14:10:29 +0000 (15:10 +0100)]
card: Add variables for splitting up a profile
It can be useful for routing modules to know a profile's input
and output parts, in order to e g change output profile
while keeping the input profile unchanged.
For now filling in these fields is optional and a routing module
must be able to handle NULL in these fields.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Arun Raghavan [Wed, 21 Oct 2015 06:15:32 +0000 (11:45 +0530)]
tests: Make echo-cancel-test not crash
Adding AGC broke this test, so we hard-disable the volume code in test
mode. This is probably okay for now, since at least with analog AGC, the
source volume changes and the data we get is going to be with AGC
applied, but digital gain won't be encapsulated here.
Long term, we might need to figure out how to deal with this properly.
Arun Raghavan [Mon, 16 Nov 2015 14:07:20 +0000 (19:37 +0530)]
alsa: Use helper function for byte conversion across sample specs
Arun Raghavan [Tue, 3 Nov 2015 17:12:08 +0000 (22:42 +0530)]
source: Deal with filter having more channels than the master
Without this, we hit an assert because the channel count in
new_reference (which was inherited from the master) is lower than the
channel count of the filter.
Thomas Petazzoni [Tue, 17 Nov 2015 11:06:36 +0000 (12:06 +0100)]
pulsecore/packet: avoid redefinition of pa_packet structure
packet.h defines:
typedef struct pa_packet pa_packet;
and packet.c defines:
typedef struct pa_packet {
...
} pa_packet;
With old versions of gcc (such as gcc 4.5) this causes a redefinition
error at compile time:
pulsecore/packet.c:43:3: error: redefinition of typedef 'pa_packet'
pulsecore/packet.h:26:26: note: previous declaration of 'pa_packet' was here
In order to fix this, this commit changes the definition in packet.c
to just:
struct pa_packet {
...
};
This way, the contents of the structure remain opaque to users of
pa_packet outside packet.c, and the 'pa_packet' type remains usable.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=91334
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Arun Raghavan [Mon, 16 Nov 2015 14:13:18 +0000 (19:43 +0530)]
sink: Make early drain reporting propagate down to filters
The drain reporting improvements that were added to alsa-sink were only
being applied to directly connected sink inputs. This patch makes the
same logic also recurse down the filter hierarchy, so drains are
acknowledged more accurately (and not late) even if there is a filter
sink in between.
Also does some minor reorganisation of the code and sprinkles in some
comments as documentation.
David Henningsson [Fri, 6 Nov 2015 11:31:32 +0000 (12:31 +0100)]
alsa-mixer: Return early in case of no mixer poll descriptors
We encountered an alsa plugin a while ago (not sure if the source
can be shared) which had mixer controls, but no descriptors to
poll for changes.
Quit early to avoid latter assertion failures.
BugLink: https://bugs.launchpad.net/bugs/1092377
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Zbigniew Kempczyński [Tue, 10 Nov 2015 06:51:46 +0000 (07:51 +0100)]
alsa-sink: Avoid unloading alsa-sink module before calling try_recover()
This fixes rare condition when pulseaudio client tries to rewind,
but a device previously reached underrun and was changed to XRUN state.
David Henningsson [Thu, 29 Oct 2015 14:13:17 +0000 (15:13 +0100)]
alsa-mixer: Add "Front Headphone" to headset mic path
The combination "Front Headphone" + "Headset Mic Phantom"
was found on one the machines we enable. Without this patch,
the headset mic appeared plugged in when nothing was plugged
into the jack.
BugLink: https://bugs.launchpad.net/bugs/1513384
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Arun Raghavan [Fri, 6 Nov 2015 14:19:14 +0000 (19:49 +0530)]
build: Add IRC notifications to Travis
Arun Raghavan [Mon, 2 Nov 2015 06:16:46 +0000 (11:46 +0530)]
tests: Set appropriate timeouts for a couple of tests
sync-playback just had a much longer timeout than it should have, and
extended-test was using the default. We set the expected amount of time,
so the test is more correct (if it takes longer than this, something
probably actually broke).
Arun Raghavan [Fri, 6 Nov 2015 10:24:55 +0000 (15:54 +0530)]
resampler: Don't expose soxr methods if they are not supported
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=92780
Lev Melnikovsky [Wed, 4 Nov 2015 10:42:21 +0000 (12:42 +0200)]
rtp: fix non null terminated string / non portable sscanf
In rtp.c:
if (sscanf(t+9, "%i %64c", &_payload, c) == 2)
the string c seems to be non-null terminated. It is later used as
following:
c[strcspn(c, "\n")] = 0;
The same piece of code is responsible for the inability of pulseaudio
on OpenWRT to handle RTP stream at the rate 48000 from another
machine:
[pulseaudio] sdp.c: Failed to parse SDP data: missing data.
It turns out that uClibc does not agree with glibc about "%64c", see
http://git.uclibc.org/uClibc/tree/docs/Glibc_vs_uClibc_Differences.txt
BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=92568
Andrey Semashev [Sat, 31 Oct 2015 15:59:46 +0000 (18:59 +0300)]
soxr: Use soxr_clear() if libsoxr version is 0.1.2 or later.
The 0.1.2 version of libsoxr fixes soxr_process() crash after soxr_clear() is used, so check the library version at compile time and use soxr_clear() if possible.
Ahmed S. Darwish [Wed, 23 Sep 2015 16:33:05 +0000 (18:33 +0200)]
scripts: Plot memory benchmarks using gnuplot
Now that we have memory usage benchmarks collected at our disposal,
introduce a gnuplot script to plot the newest version.
To avoid scaling issues, memory is plotted in a "double y axis" form,
with VM usage on the left, and dirty RSS memory usage on the right.
Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com>
Ahmed S. Darwish [Wed, 23 Sep 2015 16:30:16 +0000 (18:30 +0200)]
scripts: Introduce benchmark_memory_usage.sh
Add shell script to sample PulseAudio memory usage while increasing
the number of connected 'paplay' clients over time.
Linux kernel /proc/$PID/smaps Private and Shared_Dirty fields are used
to accurately measure the total size of used dirty pages over time.
This shall be useful for benchmarking the PA daemon's memory while
introducing new features like per-client SHM access and memfds.
Also add an empty benchmarks-collection directory 'benchmarks/'. All
output from the benchmarking tools shall be saved in this place, with
timestamps and symbolic links to the newest versions.
Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com>
Peter Mattern [Wed, 14 Oct 2015 16:39:50 +0000 (18:39 +0200)]
pacmd: Fix typo in set-default-* help
which was causing faulty output when running 'pacmd --help' on the shell
David Henningsson [Tue, 27 Oct 2015 08:54:39 +0000 (09:54 +0100)]
volume: Add LFE balance API
The gnome/unity-control-center UIs have a master volume slider, and
three sub-sliders: balance, fade, and subwoofer. Balance and fade
use PA's set_balance and set_fade APIs accordingly, but the subwoofer
slider sometimes does unintuitive things.
In order to make that slider behave better, let's add a LFE balance
API that these volume control UIs can use instead. With this API,
the UI can balance between "no subwoofer" and "only subwoofer" with
"equal balance" in the middle, which would make it more consistent
with the behaviour of the other sliders.
BugLink: https://bugzilla.gnome.org/show_bug.cgi?id=753847
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 27 Oct 2015 08:54:38 +0000 (09:54 +0100)]
volume: Refactor get/set balance/fade
get/set balance and fade use very similar code, so refactor out
common parts.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Tanu Kaskinen [Fri, 23 Oct 2015 10:56:40 +0000 (13:56 +0300)]
alsa-ucm: fix pa_device_port.profiles leak
pa_device_port.profiles is initialized in pa_device_port_new(), so no
need to do that in alsa-ucm.c.
Georg Chini [Sat, 24 Oct 2015 11:00:39 +0000 (13:00 +0200)]
null-sink: correct update of timestamp when state changes to RUNNING or IDLE
u->timestamp should be reset to "now" when the sink state changes from
INIT or SUSPENDED to IDLE or RUNNING.
Thanks to Olivier Delbeke for reporting the bug and testing the patch.
Bug report is here:
http://lists.freedesktop.org/archives/pulseaudio-discuss/2015-October/024553.html
David Henningsson [Mon, 19 Oct 2015 09:16:37 +0000 (11:16 +0200)]
alsa-mixer: Ignore volume with unexpected number of channels
We currently only support one and two channels for volumes, and
bail out otherwise. This makes Xonar users unhappy because they
have a volume with eight channels, and bailing out means they
don't have a path/port at all.
This way they will at least have a port, which will in turn make
the gnome/unity UI behave better.
BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=84983
BugLink: https://bugzilla.gnome.org/show_bug.cgi?id=745017
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Julien Isorce [Mon, 19 Oct 2015 22:29:53 +0000 (23:29 +0100)]
thread-mainloop: keep SIGSYS unblocked if currently trapped
Seccomp-BPF uses SIGSYS signal to trigger
the trap handler attached to sys_open.
If the signal is blocked then the kernel kills
the process whenever pulse audio calls 'open'.
The result backtrace is terminating in sys_open.
That's why it is required to keep SIGSYS unblocked
if it is currently unblocked and trapped.
This patch allows to have pulse audio working
in the Chromium sandbox.
Signed-off-by: Julien Isorce <j.isorce@samsung.com>
Signed-off-by: Arun Raghavan <git@arunraghavan.net>
Ross Burton [Tue, 20 Oct 2015 14:55:23 +0000 (16:55 +0200)]
git-version-gen: Avoid further processing when tarball-version is present
In case a tarball-version file is present, use that and quit.
Otherwise git will continue looking for directories, potentially
finding .git directories which are dirty and mark the version as such.
BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=90936
David Henningsson [Fri, 16 Oct 2015 20:12:32 +0000 (22:12 +0200)]
pstream: Fix use-after-free in srb_callback
We need to guard the pstream with an extra ref to ensure
it is not destroyed at the time we check whether or not the
srbchannel is destroyed.
Reported-by: Takashi Iwai <tiwai@suse.de>
BugLink: http://bugzilla.opensuse.org/show_bug.cgi?id=950487
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Tue, 5 May 2015 15:01:13 +0000 (17:01 +0200)]
module-alsa-card: Report available ports before unavailable ones
In case the same jack causes one port to become available and another
one unavailable, the available should be reported first.
This is to avoid unnecessary changes: e g, consider a 'Headphone Jack'
making 'Headphone' available and 'Speaker' unavailable. In case the
unavailable change triggers first, and there is also a currently available
third port (e g 'Digital out'), the routing system might choose to route
to this port because neither of the 'Speaker' and 'Headphone' ports are
available.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
John Horan [Sun, 19 Apr 2015 14:29:27 +0000 (15:29 +0100)]
make availability of ports visible over dbus
Juho Hämäläinen [Thu, 19 Mar 2015 11:51:00 +0000 (13:51 +0200)]
dbus: Add card profile availability info to API
[diwic: Profile availability to boolean bug fixed]
Julien Isorce [Sat, 10 Oct 2015 19:11:21 +0000 (20:11 +0100)]
core-util: avoid calling fchmod if already right mode
fchmod is denied in chromium sandbox.
David Henningsson [Tue, 5 May 2015 15:01:07 +0000 (17:01 +0200)]
card: Use pa_xmalloc0 when creating card profiles
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Mon, 28 Sep 2015 13:41:15 +0000 (15:41 +0200)]
shm: Warn on not being able to open shm files
With the exception of when trying to clean up shm files,
it's useful to warn if opening them fails, regardless of reason.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Mon, 28 Sep 2015 12:37:49 +0000 (14:37 +0200)]
card: Use pa_xnew0 when creating a card
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
David Henningsson [Mon, 28 Sep 2015 12:36:23 +0000 (14:36 +0200)]
client: Use pa_xnew0 when creating a client
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Tanu Kaskinen [Sun, 27 Sep 2015 13:48:18 +0000 (16:48 +0300)]
build-sys: fix the default bash completion directory
If bashcompletiondir was empty, the check didn't catch that. As
a result, the symlinks that were supposed to be generated in the
completion directory were created in the root directory.
Ahmed S. Darwish [Fri, 18 Sep 2015 23:59:02 +0000 (01:59 +0200)]
build-sys: bootstrap.sh: Do a make only if configure has succeeded
Otherwise the important configure script error messages get buried
by the "make clean" output.
Signed-off-by: Ahmed S. Darwish <darwish.07@gmail.com>
Tanu Kaskinen [Fri, 18 Sep 2015 06:59:45 +0000 (09:59 +0300)]
alsa-mixer: Add "Dock Line Out" jack handling to analog-output-speaker-always
The jack is already in analog-output-speaker, so let's have the same
handling in analog-output-speaker-always too.