third_party.pigweed.src/pw_multisink/docs.rst
Prashanth Swaminathan 76cd48178d pw_multisink: Lock multisink operations
Guards all multisink transactions with a lock. The new configuration
option PW_MULTISINK_LOCK_INTERRUPT_SAFE allows the project to select
the type of lock used to guard transactions. By default, it is enabled
and makes use of an interrupt spin-lock. If disabled, a mutex is used
instead.

Change-Id: I71ab2729d130c524da27e0d06beb0c3fdf73d145
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/45720
Commit-Queue: Prashanth Swaminathan <prashanthsw@google.com>
Pigweed-Auto-Submit: Prashanth Swaminathan <prashanthsw@google.com>
Reviewed-by: Ewout van Bekkum <ewout@google.com>
2021-05-18 20:40:19 +00:00

26 lines
895 B
ReStructuredText

.. _module-pw_multisink:
============
pw_multisink
============
This is an module that forwards messages to multiple attached sinks, which
consume messages asynchronously. It is not ready for use and is under
construction.
Module Configuration Options
============================
The following configurations can be adjusted via compile-time configuration
of this module, see the
:ref:`module documentation <module-structure-compile-time-configuration>` for
more details.
.. c:macro:: PW_MULTISINK_CONFIG_LOCK_INTERRUPT_SAFE
Whether an interrupt-safe lock is used to guard multisink read/write operations.
By default, this option is enabled and the multisink uses an interrupt spin-lock
to guard its transactions. If disabled, a mutex is used instead.
Disabling this will alter the entry precondition of the multisink, requiring that
it not be called from an interrupt context.