Commit 566830fd authored by Alexandre Bailon's avatar Alexandre Bailon Committed by Greg Kroah-Hartman

greybus: es2: update the bulk_ep_set value accepted by map_to_cpor_ep()

The endpoint set 0 is currently considered as invalid.
But 0 mean muxed cports on ep1 and ep2,
then it must not return -EINVAL.
Signed-off-by: default avatarAlexandre Bailon <abailon@baylibre.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
parent 8afd831e
......@@ -149,7 +149,7 @@ int map_cport_to_ep(struct es1_ap_dev *es1,
int retval;
struct cport_to_ep *cport_to_ep;
if (bulk_ep_set == 0 || bulk_ep_set >= NUM_BULKS)
if (bulk_ep_set < 0 || bulk_ep_set >= NUM_BULKS)
return -EINVAL;
if (cport_id >= es1->hd->num_cports)
return -EINVAL;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment