summaryrefslogtreecommitdiff
path: root/drivers/hid
diff options
context:
space:
mode:
authorJohan Hovold <johan@kernel.org>2014-09-26 12:55:32 +0200
committerLee Jones <lee.jones@linaro.org>2014-11-25 16:18:42 +0000
commit16b5fe2966b8dc4a474d6618d382d26933d90b24 (patch)
treeff03b321eb5c51455d30bb7aef7c3ecbc5657a47 /drivers/hid
parent1ab589c72ef66f5f281d658ab606e02d661031d8 (diff)
HID: hid-sensor-hub: Use mfd_add_hotplug_devices() helper
Use mfd_add_hotplug_devices() helper to register the subdevices. Compile-only tested. Signed-off-by: Johan Hovold <johan@kernel.org> Acked-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'drivers/hid')
-rw-r--r--drivers/hid/hid-sensor-hub.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/hid/hid-sensor-hub.c b/drivers/hid/hid-sensor-hub.c
index e6d8e18dae97..6a58b6c723aa 100644
--- a/drivers/hid/hid-sensor-hub.c
+++ b/drivers/hid/hid-sensor-hub.c
@@ -641,9 +641,6 @@ static int sensor_hub_probe(struct hid_device *hdev,
goto err_stop_hw;
}
sd->hid_sensor_hub_client_devs[
- sd->hid_sensor_client_cnt].id =
- PLATFORM_DEVID_AUTO;
- sd->hid_sensor_hub_client_devs[
sd->hid_sensor_client_cnt].name = name;
sd->hid_sensor_hub_client_devs[
sd->hid_sensor_client_cnt].platform_data =
@@ -659,8 +656,9 @@ static int sensor_hub_probe(struct hid_device *hdev,
if (last_hsdev)
last_hsdev->end_collection_index = i;
- ret = mfd_add_devices(&hdev->dev, 0, sd->hid_sensor_hub_client_devs,
- sd->hid_sensor_client_cnt, NULL, 0, NULL);
+ ret = mfd_add_hotplug_devices(&hdev->dev,
+ sd->hid_sensor_hub_client_devs,
+ sd->hid_sensor_client_cnt);
if (ret < 0)
goto err_stop_hw;