greybus: connection: fix cport-id range
authorJohan Hovold <johan@hovoldconsulting.com>
Sat, 21 Nov 2015 09:51:58 +0000 (10:51 +0100)
committerGreg Kroah-Hartman <gregkh@google.com>
Tue, 24 Nov 2015 03:23:27 +0000 (19:23 -0800)
Fix cport-id allocation that failed to include the highest port id in the
available cport-id range.

Signed-off-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
drivers/staging/greybus/connection.c

index 96dabf7640a4de3f951fc912fcd5eca2b9c29878..695f1481ba0fc77119c8ef95c9115b2c646415df 100644 (file)
@@ -219,7 +219,7 @@ struct gb_connection *gb_connection_create(struct gb_bundle *bundle,
 {
        return gb_connection_create_range(bundle->intf->hd, bundle,
                                          &bundle->dev, cport_id, protocol_id,
-                                         0, bundle->intf->hd->num_cports - 1);
+                                         0, bundle->intf->hd->num_cports);
 }
 
 /*