Tanu Kaskinen [Wed, 3 Dec 2014 13:20:19 +0000 (15:20 +0200)]
logind: Add seat tracking
This will be used by the tunnel manager to filter out devices in the
system instance that belong to some other user.
Change-Id: Ib1ba098014a485fef320a6ce4bc034973b607e9c
Tanu Kaskinen [Tue, 2 Dec 2014 19:48:37 +0000 (21:48 +0200)]
logind: Move the code that interfaces with logind to liblogind.so
This doesn't change the behaviour in any important way. The purpose of
this move is to provide access to logind from multiple modules without
needing to use the logind API from more than one place. Currently
there's only one module using liblogind.so, but module-tunnel-manager
will need seat tracking, so that will be another module that needs to
access logind.
Change-Id: I352193fef0d0b0601ea509af501af395786c6cf9
Tanu Kaskinen [Wed, 3 Dec 2014 12:05:44 +0000 (14:05 +0200)]
tunnel-manager: Make the tunnel enabling policy configurable
There's no real configurability yet, because only one condition is
supported. Support for more conditions will be added later.
The syntax of the configuration option pretends to conform to some
programming language, but there's no real parser for the language.
A proper parser may be implemented later, but for now the option
values are parsed simply by comparing to a list of predefined string
constants.
Change-Id: I57bbb0cd2b91691415be78f9732aef6b3bebde56
Tanu Kaskinen [Thu, 27 Nov 2014 10:30:35 +0000 (12:30 +0200)]
tunnel-manager: Load tunnel sinks and sources
This makes the tunnel manager load tunnel sinks and sources for all
devices in the remote servers, except for monitor sources.
Change-Id: Ie3793dfc8a500b2ae7ec6b2b0a82e49793361f91
Tanu Kaskinen [Thu, 27 Nov 2014 12:57:10 +0000 (14:57 +0200)]
tunnel-new: Read parameters from tunnel manager when available
This prepares for loading tunnel sink and source module instances from
the tunnel manager.
If the tunnel manager is available, and the tunnel manager has
sample spec and channel map information for the device, then let's use
that information when creating the sink or source so that the tunnel
will automatically match the parameters of the remote device. The
remote device's proplist is copied to the tunnel too.
Change-Id: I2755d6fc984d9014bc039924dd1d51ea5689c22c
Tanu Kaskinen [Fri, 3 Oct 2014 04:20:11 +0000 (07:20 +0300)]
tunnel-manager: New module for managing tunnels to remote servers
The initial use case for this module is to connect user PulseAudio
instances to the system instance via tunnel sinks and sources. This
is the so called "cascaded setup". The point of doing that is to allow
multiple users to access the same hardware simultaneously.
The module connects to zero or more remote servers and builds an
internal representation of all sinks and sources in those servers.
Currently the module doesn't actually load any tunnel sinks or
sources, because the tunnel sink and source code have to be first
modified a bit (the next patch does that).
The remote servers are configured in a separate configuration file
that is named tunnel-manager.conf. Currently only the server address
can be configured, but I expect more configuration options to be
implement in the future, such as options for defining the policy of
which remote devices to use. Here's an example of the configuration
file syntax:
[RemoteServer foo]
address = /run/pulse/native
[RemoteServer bar]
address = example.com
The bulk of the functionality is not in module-tunnel-manager.so, but
in libtunnel-manager.so, which will be used also by the tunnel sink
and source modules to access the information that the tunnel manager
has previously queried from the remote server.
Change-Id: I3d41936451572b6341cfb9717e07b355d8449490
Tanu Kaskinen [Thu, 4 Dec 2014 13:51:26 +0000 (15:51 +0200)]
device-type: Add pa_device_type_to_string()
This is needed by the tunnel manager. It feels a bit silly to
introduce new source files for just this function, but I couldn't
think of any other appropriate place. pa_device_type_t is defined
in pulse/def.h, and that's not an appropriate place for any
functions.
Change-Id: I6f969fe3acb934e8bb8fdfa5873a4d6d3fa6721c
Tanu Kaskinen [Wed, 12 Nov 2014 09:42:55 +0000 (11:42 +0200)]
module: Add PA_CORE_HOOK_MODULE_UNLOAD
Change-Id: I20a6bdd2f367a332554d86219de0ea22e08d82d9
Tanu Kaskinen [Fri, 3 Oct 2014 04:42:21 +0000 (07:42 +0300)]
tunnel-sink-new: Fix requested latency check
This fixes a bug in latency configuration. The wrong type in the cast
caused UINT64_MAX being not treated as special, so the configured
latency was set to UINT64_MAX usecs, which of course is absurdly huge
latency.
Change-Id: Iec239e7970944ed920837580a09bfe76a2ae2bfd
Tanu Kaskinen [Fri, 3 Oct 2014 04:38:55 +0000 (07:38 +0300)]
tunnel-sink-new: Limit the maximum latency to 200 ms
The default maximum latency is 10 seconds, which is not good,
especially since the tunnel sink doesn't support rewinding. Due to the
lack of rewinding, e.g. volume changes take a long time with large
latencies.
Change-Id: I13753d30a17598ebc9e6a3eda3db4096ff6fcf4e
Tanu Kaskinen [Wed, 12 Nov 2014 08:53:15 +0000 (10:53 +0200)]
build-sys: Fix a variable value check
Change-Id: Ie39c9c335baf70d5a6c40fa4b6845ff78e2812ec
Jaska Uimonen [Fri, 24 Oct 2014 06:39:01 +0000 (09:39 +0300)]
release: updated changelog
Change-Id: Ia12c7675382e3f8852549508bd62d5410d429be1
Jaska Uimonen [Mon, 27 Oct 2014 12:42:22 +0000 (14:42 +0200)]
Disable loading of protocol esound module
There seems to be nobody in tizen using esound
so we might as well disable the loading of the
corresponding pulseaudio protocol. If this is
later on enabled the socket should be also added
to pulseaudio.socket if the socket activation
is wanted also for esound.
Change-Id: Ieec337d3d36c8fc94aff7678b4657ffc656c1e73
Jaska Uimonen [Thu, 23 Oct 2014 06:50:21 +0000 (09:50 +0300)]
add systemd socket activation files to spec
Change-Id: Ia7341844fc0be2f9449e306470b05a3653c3eee9
Jaska Uimonen [Fri, 31 Oct 2014 09:39:50 +0000 (11:39 +0200)]
add tcp ipv4 local port to default.pa
Change-Id: I226cad5552c6331b90269bba751ef01e942a05da
Jaska Uimonen [Wed, 5 Nov 2014 11:53:28 +0000 (13:53 +0200)]
add ipv4 socket to pulseaudio.socket
Change-Id: I68867a475ba6892d1ca3c24e985687219e807a92
Jaska Uimonen [Wed, 5 Nov 2014 11:50:43 +0000 (13:50 +0200)]
socket-server: add tcp support for systemd socket activation
Change-Id: I181d2f34f925349069c802b6f68e1a0bdbe0b7f0
Colin Guthrie [Sat, 18 Oct 2014 17:33:59 +0000 (19:33 +0200)]
build-sys: Minor cosmetic tidyup of configure summary
Change-Id: I8a3e17d35ab7c9b2570b866e8cb09ebbc2c2c86b
Colin Guthrie [Fri, 17 Oct 2014 13:37:33 +0000 (15:37 +0200)]
launch: Disable autospawn by default when systemd daemon support is enabled.
When enabled, this method is prefered over pulseaudio's built in
systems so we should try our best to ensure that it cannot be spawned
outside of the mechanisms desired.
Packagers should call 'systemctl --global enable pulseaudio.socket' to
enable the socket for all users, or alternatively ship an enabling
symlink in /usr/lib/systemd/user/sockets.target.wants/ folder. It may
also make sense for distributions to add in a ConditionNNN= line to the
socket unit if they have a downstream mechanism for enabling or
disabling pulseaudio.
If individual users wish to opt out of this vendor (or administrator)
decision, they can call 'systemctl --user mask pulseaudio.socket'
Change-Id: Ieb1a0080aa5287212808d55000f54a079913808c
Colin Guthrie [Fri, 17 Oct 2014 13:10:14 +0000 (15:10 +0200)]
launch: Add systemd units for launching pulseaudio user instances
Change-Id: I7d2b504afe055927b69e454d0f9d32d581ca2e1b
Colin Guthrie [Fri, 17 Oct 2014 12:43:18 +0000 (14:43 +0200)]
launch: Avoid specifically starting PA and rely on autospawn/socket activation
This --start is patched out in several downstreams to allow users to easily
disable PA by simply disabling autospawn.
If autospawn is enabled, then the first pactl command will start it and if not
it will fail and the script will exit.
When switching to systemd socket activation, we very much do not want to
start PA manually here. We could replace it with a
systemctl --user start pulseaudio
but really it just makes sense to rely on the socket activation as this
should apply equally to non-systemd setups which use PA's own autospawn.
Change-Id: Ie730dacd598453f0bd3493cb3df3467a805a7a8b
Colin Guthrie [Thu, 16 Oct 2014 09:05:19 +0000 (10:05 +0100)]
socket-server: Add support for systemd socket activation.
This adds support to module-native-protocol-unix to take over already
listening sockets passed in via socket activation (e.g. from systemd)
Most of the code is isolated to socket-server but some cleanup code also
had to be tweaked to ensure we do not overzealously close open fds.
Change-Id: I07eb04fe3c51626ee801566cd376062406f418b9
Colin Guthrie [Fri, 17 Oct 2014 11:51:25 +0000 (13:51 +0200)]
build-sys: Add support for newer systemd without compatibility libs
In newer versions of systemd some libraries were combined for the sake of
general simplicity.
This change checks against the newer name first and avoids separate pkgconfig
checks if it's found. We probably want to keep support for the older library
names for some time. systemd does allow for the shipping of compatibility
pkgconfig files to not break downstream code like ourselves which is why this
likely hasn't been "fixed" until now.
With this change we no longer rely on systemd having been built with those
compatibility pkgconfig files.
Change-Id: Ibdbd0b01968b74237a4e2110759000f9eb705122
Colin Guthrie [Fri, 17 Oct 2014 11:32:03 +0000 (13:32 +0200)]
build-sys: Clarify some systemd sub-component variable/define names.
We currently use the term SYSTEMD when referring to libsystemd-login
and JOURNAL when referring to libsystemd-journal.
I will be shortly adding support for libsystemd-daemon and in
preparation I figured it would be a good idea to clarify the names
used currently before adding another!
Change-Id: I1e513087eedce4371c2c0a992faa0281ecf0fa6a
Colin Guthrie [Fri, 17 Oct 2014 11:09:14 +0000 (13:09 +0200)]
man: Fix XDG_RUNTIME_DIR variable reference.
Change-Id: I92785b104a1f42943884dfc7f51998c8cba65290
Tanu Kaskinen [Mon, 3 Nov 2014 09:23:25 +0000 (11:23 +0200)]
socket-server: Improve readability
Change-Id: Ia323ade04dc7a793e47d3d2c8f167812bae1aea3
Jaska Uimonen [Mon, 13 Oct 2014 10:38:01 +0000 (13:38 +0300)]
Remove msbc support from bluetooth ofono backend.
This fixes TC-162.
Change-Id: I1695d82f6841119ad6e80ba17ebec8408825b4a2
Bug-Tizen: TC-162
Jaska Uimonen [Fri, 10 Oct 2014 12:59:55 +0000 (15:59 +0300)]
release: updated changelog
Change-Id: I29476fad2c858e5ab4dc8ff979bba90843a544bb
Jaska Uimonen [Fri, 10 Oct 2014 12:48:10 +0000 (05:48 -0700)]
Merge "Fixed TC-1588. Added libcap-tools requirement" into tizen
Kévin THIERRY [Tue, 7 Oct 2014 13:23:12 +0000 (15:23 +0200)]
Packaging: clean spec file
* Use rpm macros where possible.
* Do not use "%configure" since configure is already done by
bootstrap.sh.
* Remove "description-shorter-than-summary" rpmlint warnings.
Change-Id: Ic2f20c5d231f903d19575f5ef2177e64627a3b7c
Signed-off-by: Kévin THIERRY <kevin.thierry@open.eurogiciel.org>
John L. Whiteman [Thu, 9 Oct 2014 22:28:56 +0000 (15:28 -0700)]
Fixed TC-1588. Added libcap-tools requirement
Change-Id: Ibafe33a40f0509e2cb0b03c2b4c12649336ae603
Signed-off-by: John L. Whiteman <john.l.whiteman@intel.com>
Jaska Uimonen [Mon, 29 Sep 2014 07:38:43 +0000 (10:38 +0300)]
release: updated changelog
Change-Id: Id1602c0f5589d630e8ad4a2fa73be2c0a2795e6a
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Thu, 4 Sep 2014 08:39:30 +0000 (11:39 +0300)]
protocol-stub: Don't query FQDN when loading module-native-protocol-tcp
This works around the issue that in some environments it takes 10
seconds to start PulseAudio, because the network is not responding to
our FQDN queries.
A side effect of this is that we don't register the server address in
the native protocol, so things that use the address registry don't
work. Currently this affects module-zeroconf-publish and
module-bonjour-publish. The assumption is that Tizen doesn't need
either of those.
This patch is not upstreamable. To get rid of this patch, someone
needs to fix https://bugs.freedesktop.org/show_bug.cgi?id=81802
Change-Id: I38a2e2676bd4ea3fe8c54a4c0f712fa7c3c5e115
Jaska Uimonen [Thu, 28 Aug 2014 09:49:48 +0000 (12:49 +0300)]
release: updated changelog
Change-Id: I9ce5b4c2d9c7d2c8b46b067af7a60ef4ac658bff
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Thu, 14 Aug 2014 08:01:28 +0000 (11:01 +0300)]
set realtime prio from a package
Change-Id: Ifdba5072d251b630cf63751068162b7e3d1b284f
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Tue, 17 Jun 2014 16:45:45 +0000 (19:45 +0300)]
audio-groups, main-volume-policy, volume-api: Various fixes
Sorry, this is a huge unreviewable commit. Contained improvements
include at least:
* Flat volumes are now handled properly. Previously, audio groups
controlled the absolute volume of streams if flat volume was in
effect, which made no sense.
* Audio group volumes are now persistent.
* Audio group volumes are applied to new streams before the streams
start to play, instead of after, which could cause audible
glitches.
* When a stream volume is changed by the user, the volume is
propagated to the stream's audio group.
* Fixed the handling of the "NEG" keyword in the match syntax in
module-audio-groups. Previously the "NEG" keyword was parsed, but
it had no effect.
Change-Id: I02bad3d23b3e562c71dbc6af6f3e308089893751
Tanu Kaskinen [Tue, 5 Aug 2014 09:01:54 +0000 (12:01 +0300)]
sink-input, source-output: Add the real object pointer to new_data
module-volume-api needs the pointer already in the FIXATE hook, where
it creates the volume control objects. The pointer is needed, because
otherwise there's no way to correlate the created controls with the
sink inputs and source outputs.
Since the object is created early, pa_sink_input_new() and
pa_source_output_new() need to free it in case of failure, so a bunch
of direct returns were replaced with "goto fails".
Since the object may now be unlinked in a completely uninitialized
state, I reviewed the unlinking code, and made sure that unlinking is
performed only once (the "unlinked" flag was needed for this).
Change-Id: I89bee3fb51c54d270ccf856750c5b577babc7905
Tanu Kaskinen [Mon, 4 Aug 2014 18:42:45 +0000 (21:42 +0300)]
sink-input, source-output: Use new_data.volume only for absolute volume
This simplifies life for modules that care about the initial volume of
streams. new_data.volume will always be the absolute volume (assuming
that flat volume is in effect) and new_data.reference_ratio will
always be the relative volume.
This will be especially useful when creating volume controls (absolute
and relative) for new streams in module-volume-api.
Change-Id: Ibca033c8441dde35a0b43d9276c41e383c675306
Tanu Kaskinen [Mon, 4 Aug 2014 18:26:17 +0000 (21:26 +0300)]
sink-input, source-output: Add hooks for reference ratio changes
Needed for implementing relative volume controls for streams in
module-volume-api. The plan is to create those controls in the core,
though, and these hooks won't be needed at that point any more.
Change-Id: Id30f38f4adfa9ede7bd0b12b484fe329ca1a3991
Tanu Kaskinen [Mon, 4 Aug 2014 17:57:55 +0000 (20:57 +0300)]
sink-input, source-output: Assign to reference_ratio from a single place
This makes it easy to log a message every time the reference ratio
changes. I also need to add a hook for reference ratio changes, but
that need will go away if the stream relative volume controls will be
created by the core in the future.
Change-Id: I2344ba7825f76cd72241599bd138b21e16555e01
Tanu Kaskinen [Mon, 4 Aug 2014 17:31:00 +0000 (20:31 +0300)]
core-util: Add pa_boolean_to_string()
I need to save booleans in a plain text database, and the existing
pa_yes_no() is not good, because it will do translation in the next
PulseAudio release.
Change-Id: I85f12da01aa0eb3d5c555350bd14ba337fbcc25b
Tanu Kaskinen [Mon, 4 Aug 2014 13:00:01 +0000 (16:00 +0300)]
role-ducking: Handle unlinking of uninitialized streams gracefully
There should be no assumptions about what has been initialized when
the unlink hook is fired.
Change-Id: Id3c069093894bf508fbc0be75db046ff875ce965
Tanu Kaskinen [Mon, 4 Aug 2014 12:59:06 +0000 (15:59 +0300)]
role-cork: Handle unlinking of uninitialized streams gracefully
There should be no assumptions about what has been initialized when
the unlink hook is fired.
Change-Id: I4ea4372570e7a0a83c31caab6e2e6781a98cd3ad
Tanu Kaskinen [Mon, 4 Aug 2014 12:33:01 +0000 (15:33 +0300)]
alsa: Handle unlinking of uninitialized streams gracefully
There should be no assumptions about what has been initialized when
the unlink hook is fired.
Change-Id: I7502f0e7a3d244413dd806bc8657014999c9b9b3
Tanu Kaskinen [Tue, 17 Jun 2014 16:35:21 +0000 (19:35 +0300)]
core: Create the config home directory on startup
This avoids the need to check for the existence of the config home
directory every time some file needs to be opened from that directory.
Change-Id: I449c61aa46eaea3f8c7eb0aa040310db58421828
Tanu Kaskinen [Sun, 8 Jun 2014 13:33:00 +0000 (16:33 +0300)]
core-util: Add pa_append_to_config_home_dir()
Change-Id: Ib4e6a096a740a61188220a983f26ecea434f6200
Tanu Kaskinen [Sun, 8 Jun 2014 13:32:59 +0000 (16:32 +0300)]
core-util: Add pa_get_config_home_dir()
Change-Id: I6aa3df386a7414563b03435683bad2596cf60b8b
Tanu Kaskinen [Sun, 8 Jun 2014 13:32:57 +0000 (16:32 +0300)]
core-util: Add pa_append_to_home_dir()
Change-Id: I746d2efb5f205820480b0cbd11c23cff11367656
Ismo Puustinen [Tue, 27 May 2014 07:27:16 +0000 (10:27 +0300)]
audio-groups: fix issues found by static analysis.
Change-Id: Ia2805a5977868b236bd6a33e7bc8fdcb944020ea
Tanu Kaskinen [Tue, 27 May 2014 08:06:10 +0000 (11:06 +0300)]
main-volume-policy: Fix a memory leak
There can be multiple calls to pa_binding_target_info_new() in this
function, but only the last allocated info object was freed.
Change-Id: I9df43f0663b27b07ba7b8d01bc8ea9cc0a6c1b51
Tanu Kaskinen [Tue, 27 May 2014 07:45:04 +0000 (10:45 +0300)]
device-creator, stream-creator: Add a couple of assertions
Klocwork complained that source (in device-creator) and output (in
stream-creator) may be dereferenced if they're NULL. Let's make
Klocwork happy, and the code a bit more obvious to human readers as
well.
Change-Id: I835dd7d9da44e2866a97bc0424001a42c29602a8
Ismo Puustinen [Mon, 26 May 2014 11:37:48 +0000 (14:37 +0300)]
configuration: x-example -> x-tizen-ivi in volume configuration.
Change-Id: I1c11084d6891e431dd909c632e4bfb62968167df
Tanu Kaskinen [Mon, 26 May 2014 13:26:14 +0000 (16:26 +0300)]
pactl: Fix crash in "pactl list"
Fixes this assertion error:
Assertion 'actions > 0' failed at utils/pactl.c:172, function complete_action(). Aborting.
Change-Id: Icdcdf0817af431115444cb4fdef0a042fe5d7560
Jaska Uimonen [Fri, 7 Mar 2014 15:22:37 +0000 (17:22 +0200)]
release: updated changelog
Change-Id: I74897ff4279cafe9c466df5253a1dc2fe5de7b6d
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Thu, 18 Jul 2013 10:43:14 +0000 (18:43 +0800)]
configuration: pulseaudio tizen configuration in default.pa
Change-Id: Id9370a1858d5c1ba0ed3319d717bc7f3e9ed5d31
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Tue, 11 Jun 2013 14:17:16 +0000 (17:17 +0300)]
packaging: added packaging for gerrit.
Change-Id: I9cf677e15311085610c42788fe3d9ac5b44dbfe9
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
David Henningsson [Fri, 21 Mar 2014 09:19:19 +0000 (10:19 +0100)]
sink/source: Initialize port before fixate hook (fixes volume/mute not saved)
In case a port has not yet been saved, which is e g often the case
if a sink/source has only one port, reading volume/mute will be done
without port, whereas writing volume/mute will be done with port.
Work around this by setting a default port before the fixate hook,
so module-device-restore can read volume/mute for the correct port.
Change-Id: Iea6a742f0667771712059cb39b8082785b2a6887
BugLink: https://bugs.launchpad.net/bugs/1289515
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Tanu Kaskinen [Thu, 22 May 2014 11:43:33 +0000 (14:43 +0300)]
configuration: Add default IVI audio group and main volume configuration
Change-Id: Idd348cc9f469e988405d574dbc2459c5822a33c2
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 21 May 2014 11:13:41 +0000 (14:13 +0300)]
Add module-main-volume-policy
Change-Id: I787141b43cafb652aa752c64ae28b6b7aa052d8e
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 21 May 2014 11:08:40 +0000 (14:08 +0300)]
Add module-audio-groups
Change-Id: Iaa0284e0537785ed245caae6e49544477ca246b9
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 21 May 2014 11:05:47 +0000 (14:05 +0300)]
pactl: Add support for the new volume API
Change-Id: I2bb6625c1cd575366388ec8dc3dd4fd2097c9a4a
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 21 May 2014 10:42:02 +0000 (13:42 +0300)]
Add module-volume-api and the related client API
Change-Id: I79e31d8eaacb5d86a29538e89db1e140d28ac1c0
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 21 May 2014 08:51:27 +0000 (11:51 +0300)]
volume-api: Add libvolume-api.so
This library implements the "core" of the new volume system, which
will be used by several modules.
Change-Id: Ib25ada1392e83237a3908e6064ee0ad6dff7afaf
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Tue, 4 Mar 2014 13:03:05 +0000 (15:03 +0200)]
context, extension: Add the pa_extension class
pa_extension is an abstraction layer that allows pa_context to manage
the extensions without needing any extension-specific code. This patch
only implements the pa_extension base class, the class isn't used yet
by any actual extensions.
Change-Id: I457b3d0b674b4cfd1d38452d8f8cb51cf6b7b533
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Fri, 9 May 2014 08:25:28 +0000 (11:25 +0300)]
sink: Link monitor source before activating port
The port activation hook callbacks may want to use the monitor source.
Change-Id: I5d5c51171a78162dacb3286983cb560001e79ba1
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Tue, 15 Apr 2014 08:27:53 +0000 (11:27 +0300)]
sink-input, source-output: Add hooks for mute changes
Change-Id: I256cfa27ffa6addb35640266b73f1fe07a483203
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Tue, 15 Apr 2014 08:10:24 +0000 (11:10 +0300)]
sink, source: Add hooks for mute changes
Change-Id: I1203c1199fea0e93f1a61391695b12ab8af66180
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 7 Apr 2014 11:22:43 +0000 (14:22 +0300)]
sink-input, source-output: Add hooks for volume changes
Change-Id: I89c6f2934762caa2c49c70c0446c14d0de58a10e
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Sun, 9 Mar 2014 11:36:04 +0000 (13:36 +0200)]
sink, source: Add hooks for volume changes
Change-Id: Id4389a38e601dee3f84d7fad0583a7dc87108e87
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 14 Apr 2014 12:34:57 +0000 (15:34 +0300)]
solaris, tunnel: Remove some redundant boolean conversions
Change-Id: Ibc922f8455a3ccb6c71289e70cd474464930643e
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 14 Apr 2014 12:24:31 +0000 (15:24 +0300)]
sink-input, source-output: Remove redundant get_mute() functions
The functions just return the muted value. Callers can as well read
the struct field directly, it's simpler that way.
Change-Id: I368f7e09cdf522039a6573e5002f7544b4e840d3
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 14 Apr 2014 11:52:16 +0000 (14:52 +0300)]
sink, source: Assign to s->muted from only one place
Forcing all mute changes to go through set_mute() makes it easier to
check where the muted field is changed, and it also allows us to have
only one place where notifications for changed mute are sent.
Change-Id: Idb1bd6ef923a165e249d42265ebedc30a6c8fca4
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Tue, 15 Apr 2014 06:39:49 +0000 (09:39 +0300)]
sink, source: Call set_mute() from mute_changed()
This refactoring reduces duplication, as mute_changed() used to do the
same things as set_mute(). Other benefits are improved logging
(set_mute() logs the mute change, mute_changed() used to not do that)
and the soft mute state is kept up to date, because set_mute() sends
the SET_MUTE message to the IO thread.
The set_mute_in_progress flag is an extra precaution for preventing
recursion in case a sink/source implementation's set_mute() callback
causes mute_changed() to be called. Currently there are no such
implementations, but I think that would be a valid thing to do, so
some day there might be such implementation.
Change-Id: I33c81f4034001f777c4533c2c63eada67548c683
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 14 Apr 2014 12:13:08 +0000 (15:13 +0300)]
echo-cancel: Remove redundant get_mute() callback
The callback just called pa_source_output_get_mute(), which doesn't
have any side effects, and the return value wasn't used either, so
the callback was essentially a no-op.
Change-Id: Ic16824b06393f59b55087842da64c7d09035b9e8
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 14 Apr 2014 11:43:23 +0000 (14:43 +0300)]
sink, source: Allow calling set_mute() during initialization
Currently the alsa sink and source write directly to s->muted during
initialization, but I think it's better to avoid direct writes, and
use the set_mute() function instead, because that makes it easier to
figure out where s->muted is modified. This patch prevents the
set_mute() call from crashing in the state assertion.
Change-Id: I12220fb2668723931bebbe1484f115016f1edf25
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 14 Apr 2014 11:13:56 +0000 (14:13 +0300)]
sink-input, source-output: Add logging to set_mute()
Change-Id: Ie10aa76cae75c7b6a52ea4a9039b8e3e37a748b2
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 14 Apr 2014 11:03:24 +0000 (14:03 +0300)]
sink, source: Return early from set_mute()
This avoids redundant set_mute() callback calls.
Some logging was added too.
Change-Id: I10188c3b43d61fe751abe0f9940015af35c4a137
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 7 Apr 2014 09:48:15 +0000 (12:48 +0300)]
sink-input, source-output: Assign to volume from only one place
Forcing all volume changes to go through set_volume_direct() makes
it easier to check where the stream volume is changed, and it also
allows us to have only one place where notifications for changed
volume are sent.
Change-Id: Ie61bcc5747b419bb83c19a3ed78fd9f4d8a73cce
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 7 Apr 2014 09:20:58 +0000 (12:20 +0300)]
sink, source: Assign to reference_volume from only one place
Forcing all reference volume changes to go through
set_reference_volume_direct() makes it easier to check where the
reference volume is changed, and it also allows us to have only one
place where notifications for changed reference volume are sent.
Change-Id: I2e769b8a2b0d7031a02446dead8ca2e0c3402751
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 26 Mar 2014 11:41:42 +0000 (13:41 +0200)]
device-port: Add pa_device_port.active
In the Tizen volume API, I create and delete volume control objects
for ports based on their state (only active ports have volume
controls). Having the pa_device_port.active flag directly accessible
is much nicer than figuring out the state by iterating through sinks
and checking what their active port is. It's also safer to get a
notification for a deactivated port before the port switch is
executed, compared to using the SINK_PORT_CHANGED hook that is fired
only after the port switch is complete.
Change-Id: I3f7f8855721c8dc3a643708a72f6e35341ff7117
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 26 Mar 2014 11:58:40 +0000 (13:58 +0200)]
hashmap: Add pa_hashmap_remove_and_free()
Change-Id: Ia3530c29cecf8964989aec4f0527fc982e80e34a
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 21 May 2014 08:36:19 +0000 (11:36 +0300)]
dynarray: Add pa_dynarray_remove_all()
Change-Id: I35079f8fe4b361221a1bdc1fececbe318bf3ee0e
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 21 May 2014 08:32:09 +0000 (11:32 +0300)]
dynarray: Add pa_dynarray_remove_last()
Change-Id: I9098df96aac57a3ee2084061aa174f7ee02b1588
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Thu, 19 Dec 2013 19:29:50 +0000 (21:29 +0200)]
dynarray: Add PA_DYNARRAY_FOREACH
The PA_DYNARRAY_FOREACH macro requires that pa_dynarray_get() returns
NULL if the index is out of bounds.
Change-Id: If9db312516fbb079e8b67d94d35a44783ab3395a
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 26 Mar 2014 11:33:31 +0000 (13:33 +0200)]
dynarray: Add pa_dynarray_get_raw_array()
Change-Id: I6e40c2a20586d13c99c9d98059e4dbb1d0e9e562
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 26 Mar 2014 11:15:12 +0000 (13:15 +0200)]
core-util: Add pa_join()
Change-Id: I84ac0ee7a3097fce8ed9bad26b210fc97db9e9a7
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Wed, 26 Mar 2014 08:25:17 +0000 (10:25 +0200)]
direction: Add a couple of direction helper functions
Change-Id: I365acd7ce3e7abcbcb8a532c79016fca558238e8
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 14 Apr 2014 11:29:48 +0000 (14:29 +0300)]
sink-input, source-output: Fix mute saving
Change-Id: I2298ab51a384c3ddfa33da3e941e03f5027b4d77
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Sun, 9 Mar 2014 08:50:23 +0000 (10:50 +0200)]
volume: Increase PA_SW_VOLUME_SNPRINT_DB_MAX
10 bytes isn't enough for "-123.45 dB", including the terminating null
byte.
Change-Id: I865060befd01d3dde69556c1f90b7de55350501a
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Sun, 16 Feb 2014 12:30:38 +0000 (14:30 +0200)]
pactl: Fix crash with older servers
Servers older than 0.9.15 don't know anything about cards, and card
operations will return a NULL pa_operation object when connected to
that old server. We must check the pa_operation pointer before passing
it to pa_operation_unref(), otherwise a NULL operation will result in
a crash.
Change-Id: Idc258479c077aafaff6254b76acb18034a158107
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Tanu Kaskinen [Mon, 24 Feb 2014 10:38:31 +0000 (12:38 +0200)]
.gitignore: Add pulsecore-config.h
Change-Id: I8409f1964e65e79669eaeb4930c6d536417a0b05
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Tue, 11 Jun 2013 14:03:27 +0000 (17:03 +0300)]
added pulseaudio.service file
Change-Id: I8efef41060189f116be49b3455c588d67f045f82
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
vivian,zhang [Wed, 17 Jul 2013 03:17:40 +0000 (11:17 +0800)]
Add bt_profile_set patch which fixed bt a2dp&hsp profile setting issues in mobile
Change-Id: I9bc3649b02ab7ac56584211789a3ea18ff17fbb7
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Wed, 14 Aug 2013 12:00:52 +0000 (15:00 +0300)]
adjust default bluetooth profile to off
Change-Id: I95ca525b0d20c1a864a0c66060767bb4c2160400
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Wed, 8 Aug 2012 08:14:40 +0000 (11:14 +0300)]
volume ramp: add client api support for volume ramping
Change-Id: I6afc7540af68400db54eec258bdf4a80c311bb69
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Tue, 11 Mar 2014 10:47:52 +0000 (12:47 +0200)]
fix warning in gconf helper
Change-Id: Id75cd24cfd1c0d62d4c227b6715dc0d9d5ea6b1f
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Fri, 7 Mar 2014 15:49:42 +0000 (17:49 +0200)]
fixes and improvements to makefile and configure in - samsung
Change-Id: Ic2338a8382fe45f9d509537950592c9c4aa83606
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Thu, 8 Aug 2013 08:28:39 +0000 (11:28 +0300)]
use udev only for usb devices - samsung
Change-Id: Ia8cd2f5eb5ebe5248af11906c67d572ede133b33
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Thu, 8 Aug 2013 08:27:44 +0000 (11:27 +0300)]
cope with possible infinite waiting in startup - samsung
Change-Id: Ie7c74131e267f44324f031a953c15f81b0c31a07
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>
Jaska Uimonen [Thu, 8 Aug 2013 08:24:25 +0000 (11:24 +0300)]
set alsa suspend timeout to zero - samsung
Change-Id: Ie7c93c727d878226189f751efbd6e088ece7f36f
Signed-off-by: Jaska Uimonen <jaska.uimonen@intel.com>