[PATCH 00/23] Routing: allow router modules to set stream initial routing

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This patch set supersedes the previous routing patch set "Add more
nodes".

As suggested by David, I removed the create_node flags from port,
sink, source, sink input and source output new data. The result is
that now all devices and streams, also virtual ones, expose a node.

Monitor sources require some special handling. Logically there should
be a separate monitor node for each output port node, not just one
monitor corresponding to the monitor source that covers multiple
ports.

The stream initialization is modified to allow nodes and router
modules to access the sink input and source output objects already in
the initial routing phase. I didn't want to somehow expose the new
data structure to nodes and router modules. Consider pa_node.owner,
for example: it's much cleaner to have it always point to
pa_sink_input instead of having it first pointing to
pa_sink_input_new_data and then changing it later to point to
pa_sink_input.

Finally, pa_router is introduced, along with an "experimental router
module", which I intend to evolve into a Murphy module.

Tanu Kaskinen (23):
  Remove pa_device_port_new_data.create_node
  Remove create_node from sink input and source output new data
  Remove create_node from sink and source new data
  source: Initialize pa_source.monitor_of already in pa_source_new()
  sink: Create the sink node before creating the monitor source
  Don't create nodes for monitor sources if the sink has ports
  node: Generate a nice name for monitor nodes
  device-port: Generate monitor nodes for output ports
  source-output: Log the format negotiation result
  sink-input, source-output: Use "goto fail" for error handling in new()
  sink-input, source-output: Allocate the object early in new()
  match: Do proplist updating already in the NEW hook
  sink-input, source-output: Create the node early
  Fix some error reporting style issues
  sink, source: Add a TODO comment about removing get_formats()
  idxset: Allow deep copying with pa_idxset_copy()
  core-format: Add pa_format_info_negotiate()
  sink-input, source-output: Add req_formats to
    pa_sink_input/pa_source_output
  sink-input, source-output: Add set_initial_sink/source()
  sink-input, source-output: Allow pa_node_put() to do routing
  Introduce pa_router
  node: Notify pa_router about new and removed nodes
  New module: module-experimental-router

 src/Makefile.am                                 |  10 +
 src/modules/alsa/alsa-mixer.c                   |   3 +-
 src/modules/alsa/alsa-sink.c                    |  14 +-
 src/modules/alsa/alsa-source.c                  |   5 +-
 src/modules/alsa/alsa-ucm.c                     |   1 -
 src/modules/bluetooth/module-bluetooth-device.c |   2 -
 src/modules/jack/module-jack-sink.c             |   1 -
 src/modules/jack/module-jack-source.c           |   1 -
 src/modules/module-device-manager.c             |   4 +-
 src/modules/module-experimental-router.c        | 128 +++++++++
 src/modules/module-intended-roles.c             |   4 +-
 src/modules/module-match.c                      |  37 ++-
 src/modules/module-stream-restore.c             |   2 +-
 src/pulsecore/core-format.c                     |  51 ++++
 src/pulsecore/core-format.h                     |  44 +++
 src/pulsecore/core.c                            |  18 ++
 src/pulsecore/core.h                            |   6 +
 src/pulsecore/device-port.c                     |  49 +++-
 src/pulsecore/device-port.h                     |   3 +-
 src/pulsecore/idxset.c                          |   4 +-
 src/pulsecore/idxset.h                          |   7 +-
 src/pulsecore/node.c                            |  27 +-
 src/pulsecore/node.h                            |   5 +-
 src/pulsecore/protocol-native.c                 |   4 +-
 src/pulsecore/router.c                          |  91 +++++++
 src/pulsecore/router.h                          |  47 ++++
 src/pulsecore/sink-input.c                      | 344 +++++++++++++++---------
 src/pulsecore/sink-input.h                      |  11 +-
 src/pulsecore/sink.c                            |  33 +--
 src/pulsecore/sink.h                            |   7 +-
 src/pulsecore/source-output.c                   | 336 +++++++++++++++--------
 src/pulsecore/source-output.h                   |  11 +-
 src/pulsecore/source.c                          |  19 +-
 src/pulsecore/source.h                          |   9 +-
 34 files changed, 1003 insertions(+), 335 deletions(-)
 create mode 100644 src/modules/module-experimental-router.c
 create mode 100644 src/pulsecore/core-format.c
 create mode 100644 src/pulsecore/core-format.h
 create mode 100644 src/pulsecore/router.c
 create mode 100644 src/pulsecore/router.h

-- 
1.8.3.1



[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux