Hi Felipe, Can you take this series or would you like me to resend it? BR, Yousaf > -----Original Message----- > From: Kaukab, Yousaf > Sent: Monday, February 2, 2015 10:55 AM > To: linux-usb@xxxxxxxxxxxxxxx; balbi@xxxxxx; ricardo.ribalda@xxxxxxxxx; > stern@xxxxxxxxxxxxxxxxxxx > Cc: Kaukab, Yousaf > Subject: [PATCH 1/4] usb: gadget: net2280: use ep_autoconfig compatible > names in advance mode > > Each struct usb_ep added for net2280 can be used in either direction. > Whereas, each struct usb_ep for usb3380 has fixed direction. Use ep_autoconf > compatible names so that endpoint with correct direction can be selected. > > Name sequence is due to the logic in usb_reinit_338x() in ne[] and > ep_reg_addr[]. > > Signed-off-by: Mian Yousaf Kaukab <yousaf.kaukab@xxxxxxxxx> > --- > drivers/usb/gadget/udc/net2280.c | 9 ++++++++- > 1 file changed, 8 insertions(+), 1 deletion(-) > > diff --git a/drivers/usb/gadget/udc/net2280.c > b/drivers/usb/gadget/udc/net2280.c > index d2c0bf6..b7024dc 100644 > --- a/drivers/usb/gadget/udc/net2280.c > +++ b/drivers/usb/gadget/udc/net2280.c > @@ -80,6 +80,13 @@ static const char *const ep_name[] = { > "ep-e", "ep-f", "ep-g", "ep-h", > }; > > +/* Endpoint names for usb3380 advance mode */ static const char *const > +ep_name_adv[] = { > + ep0name, > + "ep1in", "ep2out", "ep3in", "ep4out", > + "ep1out", "ep2in", "ep3out", "ep4in", > +}; > + > /* mode 0 == ep-{a,b,c,d} 1K fifo each > * mode 1 == ep-{a,b} 2K fifo each, ep-{c,d} unavailable > * mode 2 == ep-a 2K fifo, ep-{b,c} 1K each, ep-d unavailable @@ -1977,7 > +1984,7 @@ static void usb_reinit_338x(struct net2280 *dev) > for (i = 0; i < dev->n_ep; i++) { > struct net2280_ep *ep = &dev->ep[i]; > > - ep->ep.name = ep_name[i]; > + ep->ep.name = dev->enhanced_mode ? > ep_name_adv[i] : ep_name[i]; > ep->dev = dev; > ep->num = i; > > -- > 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html