@@ -479,7 +479,6 @@ static struct ishtp_cl_device *ishtp_bus_add_device(struct ishtp_device *dev,
}
ishtp_device_ready = true;
- dev_set_drvdata(&device->dev, device);
return device;
}
@@ -647,6 +646,13 @@ void *ishtp_get_drvdata(struct ishtp_cl_device *cl_device)
}
EXPORT_SYMBOL(ishtp_get_drvdata);
+
+struct ishtp_cl_device *ishtp_dev_to_cl_device(struct device *device)
+{
+ return container_of(device, struct ishtp_cl_device, dev);
+}
+EXPORT_SYMBOL(ishtp_dev_to_cl_device);
+
/**
* ishtp_bus_new_client() - Create a new client
* @dev: ISHTP device instance
driver_data of HECI client device should be managed(set/get) by corresponding HECI client driver. Bus shouldn't set it. Change-Id: I128e36663e3b1f88b53dac7a9d8b846475215875 Signed-off-by: Hyungwoo Yang <hyungwoo.yang@intel.com> --- drivers/hid/intel-ish-hid/ishtp/bus.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)