diff options
author | Maximilian Luz <luzmaximilian@gmail.com> | 2021-10-28 03:22:41 +0300 |
---|---|---|
committer | Hans de Goede <hdegoede@redhat.com> | 2021-11-16 12:56:54 +0300 |
commit | 38543b72fbe52b7eec0dedd420d80a06c652d8e4 (patch) | |
tree | 9dbc872dad045892eaa9db3e90c05579a64345b4 /include/linux/surface_aggregator | |
parent | 0f0ac158d28ff78e75c334e869b1cb8e69372a1f (diff) | |
download | linux-38543b72fbe52b7eec0dedd420d80a06c652d8e4.tar.xz |
platform/surface: aggregator: Make client device removal more generic
Currently, there are similar functions defined in the Aggregator
Registry and the controller core.
Make client device removal more generic and export it. We can then use
this function later on to remove client devices from device hubs as well
as the controller and avoid re-defining similar things.
Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/20211028002243.1586083-2-luzmaximilian@gmail.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Diffstat (limited to 'include/linux/surface_aggregator')
-rw-r--r-- | include/linux/surface_aggregator/device.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/surface_aggregator/device.h b/include/linux/surface_aggregator/device.h index f636c5310321..cc257097eb05 100644 --- a/include/linux/surface_aggregator/device.h +++ b/include/linux/surface_aggregator/device.h @@ -319,6 +319,15 @@ void ssam_device_driver_unregister(struct ssam_device_driver *d); ssam_device_driver_unregister) +/* -- Helpers for controller and hub devices. ------------------------------- */ + +#ifdef CONFIG_SURFACE_AGGREGATOR_BUS +void ssam_remove_clients(struct device *dev); +#else /* CONFIG_SURFACE_AGGREGATOR_BUS */ +static inline void ssam_remove_clients(struct device *dev) {} +#endif /* CONFIG_SURFACE_AGGREGATOR_BUS */ + + /* -- Helpers for client-device requests. ----------------------------------- */ /** |