aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget/u_serial.c
diff options
context:
space:
mode:
authorTatyana Brokhman <tlinder@codeaurora.org>2011-06-28 09:33:48 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2011-06-28 14:14:36 -0400
commit72c973dd2b01b212a159faa330a2bc641a3ed809 (patch)
tree2fbc36b4103678cd9b7599deaab06f89e4871de2 /drivers/usb/gadget/u_serial.c
parent0f91349b89f37dfad7b77f7829a105b6a0f526ec (diff)
usb: gadget: add usb_endpoint_descriptor to struct usb_ep
Change usb_ep_enable() prototype to use endpoint descriptor from usb_ep. This optimization spares the FDs from saving the endpoint chosen descriptor. This optimization is not full though. To fully exploit this change, one needs to update all the UDCs as well since in the current implementation each of them saves the endpoint descriptor in it's internal (and extended) endpoint structure. Signed-off-by: Tatyana Brokhman <tlinder@codeaurora.org> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/gadget/u_serial.c')
-rw-r--r--drivers/usb/gadget/u_serial.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/gadget/u_serial.c b/drivers/usb/gadget/u_serial.c
index 40f7716b31fc..a8aa46962d81 100644
--- a/drivers/usb/gadget/u_serial.c
+++ b/drivers/usb/gadget/u_serial.c
@@ -1247,12 +1247,12 @@ int gserial_connect(struct gserial *gser, u8 port_num)
1247 port = ports[port_num].port; 1247 port = ports[port_num].port;
1248 1248
1249 /* activate the endpoints */ 1249 /* activate the endpoints */
1250 status = usb_ep_enable(gser->in, gser->in_desc); 1250 status = usb_ep_enable(gser->in);
1251 if (status < 0) 1251 if (status < 0)
1252 return status; 1252 return status;
1253 gser->in->driver_data = port; 1253 gser->in->driver_data = port;
1254 1254
1255 status = usb_ep_enable(gser->out, gser->out_desc); 1255 status = usb_ep_enable(gser->out);
1256 if (status < 0) 1256 if (status < 0)
1257 goto fail_out; 1257 goto fail_out;
1258 gser->out->driver_data = port; 1258 gser->out->driver_data = port;