]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
greybus: svc: get hd directly from connection
authorViresh Kumar <viresh.kumar@linaro.org>
Tue, 1 Sep 2015 11:46:16 +0000 (17:16 +0530)
committerJohan Hovold <johan@hovoldconsulting.com>
Wed, 2 Sep 2015 10:09:55 +0000 (12:09 +0200)
There is no need to perform connection->bundle->intf->hd as the same can
be done with connection->hd.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Johan Hovold <johan@hovoldconsulting.com>
drivers/staging/greybus/svc.c

index db009223d7595f9a26a3ee3427e29e068b713074..ac8ff44f3a8979fc92b4e1d45643f3797b363396 100644 (file)
@@ -272,7 +272,7 @@ static void svc_process_hotplug(struct work_struct *work)
        struct gb_svc_intf_hotplug_request *hotplug = &svc_hotplug->data;
        struct gb_connection *connection = svc_hotplug->connection;
        struct gb_svc *svc = connection->private;
-       struct greybus_host_device *hd = connection->bundle->intf->hd;
+       struct greybus_host_device *hd = connection->hd;
        struct device *dev = &connection->dev;
        struct gb_interface *intf;
        u8 intf_id, device_id;
@@ -399,7 +399,7 @@ static int gb_svc_intf_hot_unplug_recv(struct gb_operation *op)
 {
        struct gb_message *request = op->request;
        struct gb_svc_intf_hot_unplug_request *hot_unplug = request->payload;
-       struct greybus_host_device *hd = op->connection->bundle->intf->hd;
+       struct greybus_host_device *hd = op->connection->hd;
        struct device *dev = &op->connection->dev;
        u8 device_id;
        struct gb_interface *intf;