diff options
author | Maximilian Luz <luzmaximilian@gmail.com> | 2021-10-28 02:22:41 +0200 |
---|---|---|
committer | Hans de Goede <hdegoede@redhat.com> | 2021-11-16 10:56:54 +0100 |
commit | 38543b72fbe52b7eec0dedd420d80a06c652d8e4 (patch) | |
tree | 9dbc872dad045892eaa9db3e90c05579a64345b4 /drivers/platform/surface/aggregator/core.c | |
parent | 0f0ac158d28ff78e75c334e869b1cb8e69372a1f (diff) | |
download | linux-38543b72fbe52b7eec0dedd420d80a06c652d8e4.tar.gz linux-38543b72fbe52b7eec0dedd420d80a06c652d8e4.tar.bz2 linux-38543b72fbe52b7eec0dedd420d80a06c652d8e4.zip |
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 'drivers/platform/surface/aggregator/core.c')
-rw-r--r-- | drivers/platform/surface/aggregator/core.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/platform/surface/aggregator/core.c b/drivers/platform/surface/aggregator/core.c index c61bbeeec2df..d384d36098c2 100644 --- a/drivers/platform/surface/aggregator/core.c +++ b/drivers/platform/surface/aggregator/core.c @@ -22,6 +22,7 @@ #include <linux/sysfs.h> #include <linux/surface_aggregator/controller.h> +#include <linux/surface_aggregator/device.h> #include "bus.h" #include "controller.h" @@ -735,7 +736,7 @@ static void ssam_serial_hub_remove(struct serdev_device *serdev) ssam_controller_lock(ctrl); /* Remove all client devices. */ - ssam_controller_remove_clients(ctrl); + ssam_remove_clients(&serdev->dev); /* Act as if suspending to silence events. */ status = ssam_ctrl_notif_display_off(ctrl); |