linux/drivers/platform/surface/aggregator
Maximilian Luz 4b38a1dcf3 platform/surface: aggregator: Allow enabling of events without notifiers
We can already enable and disable SAM events via one of two ways: either
via a (non-observer) notifier tied to a specific event group, or a
generic event enable/disable request. In some instances, however,
neither method may be desirable.

The first method will tie the event enable request to a specific
notifier, however, when we want to receive notifications for multiple
event groups of the same target category and forward this to the same
notifier callback, we may receive duplicate events, i.e. one event per
registered notifier. The second method will bypass the internal
reference counting mechanism, meaning that a disable request will
disable the event regardless of any other client driver using it, which
may break the functionality of that driver.

To address this problem, add new functions that allow enabling and
disabling of events via the event reference counting mechanism built
into the controller, without needing to register a notifier.

This can then be used in combination with observer notifiers to process
multiple events of the same target category without duplication in the
same callback function.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20210604134755.535590-3-luzmaximilian@gmail.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-06-16 17:47:53 +02:00
..
bus.c platform/surface: aggregator: Add dedicated bus and device type 2021-01-07 00:06:39 +01:00
bus.h platform/surface: aggregator: Add dedicated bus and device type 2021-01-07 00:06:39 +01:00
controller.c platform/surface: aggregator: Allow enabling of events without notifiers 2021-06-16 17:47:53 +02:00
controller.h platform/surface: aggregator: Add event item allocation caching 2021-01-06 23:45:34 +01:00
core.c platform/surface: aggregator: Add dedicated bus and device type 2021-01-07 00:06:39 +01:00
Kconfig platform/surface: aggregator: Add dedicated bus and device type 2021-01-07 00:06:39 +01:00
Makefile platform/surface: aggregator: Add dedicated bus and device type 2021-01-07 00:06:39 +01:00
ssh_msgb.h
ssh_packet_layer.c platform/surface: aggregator: Fix access of unaligned value 2021-02-11 16:47:50 +01:00
ssh_packet_layer.h
ssh_parser.c
ssh_parser.h
ssh_request_layer.c platform/surface: aggregator: Fix kernel-doc references 2021-01-18 19:22:08 +01:00
ssh_request_layer.h
trace.h platform/surface: aggregator: Add error injection capabilities 2021-01-07 00:06:22 +01:00