usb: musb: Prevent the masking of the return value

Currently the errors returned by fifo_setup get masked
by EINVAL, propagate the same to the caller.

Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
This commit is contained in:
Shubhrajyoti D 2012-08-07 19:56:31 +05:30 committed by Felipe Balbi
parent 660fa8863d
commit f69dfa1f01

View File

@ -1295,7 +1295,7 @@ done:
if (offset < 0) {
pr_debug("%s: mem overrun, ep %d\n",
musb_driver_name, epn);
return -EINVAL;
return offset;
}
epn++;
musb->nr_endpoints = max(epn, musb->nr_endpoints);