]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
greybus: connection: call connection_init hook after setting the handler
authorMatt Porter <mporter@linaro.org>
Tue, 28 Oct 2014 14:08:13 +0000 (10:08 -0400)
committerGreg Kroah-Hartman <greg@kroah.com>
Tue, 28 Oct 2014 23:47:56 +0000 (07:47 +0800)
In gb_connection_init() we set the connection_handler for each supported
protocol, but we never call the connection_init hook after doing so. This
results in a failure being returned so fix it by calling the connection_init
hook to get a good return and the associated driver initialized.

Signed-off-by: Matt Porter <mporter@linaro.org>
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
drivers/staging/greybus/connection.c

index f76855c609c33f186d9a310fcda8bc6083051548..69ea3a7887715341ca2c5d9fc2cc1f919c7b6959 100644 (file)
@@ -290,6 +290,8 @@ int gb_connection_init(struct gb_connection *connection)
                break;
        }
 
+       ret = connection->handler->connection_init(connection);
+
        if (ret)
                connection->state = GB_CONNECTION_STATE_ERROR;