@@ -1727,14 +1727,23 @@ init_peripheral_ep(struct musb *musb, struct musb_ep *ep, u8 epnum, int is_in)
ep->end_point.name = ep->name;
INIT_LIST_HEAD(&ep->end_point.ep_list);
if (!epnum) {
+ ep->end_point.has_dir_in = true;
+ ep->end_point.has_dir_out = true;
+ ep->end_point.has_control = true;
usb_ep_set_maxpacket_limit(&ep->end_point, 64);
ep->end_point.ops = &musb_g_ep0_ops;
musb->g.ep0 = &ep->end_point;
} else {
- if (is_in)
+ if (is_in) {
+ ep->end_point.has_dir_in = true;
usb_ep_set_maxpacket_limit(&ep->end_point, hw_ep->max_packet_sz_tx);
- else
+ } else {
+ ep->end_point.has_dir_out = true;
usb_ep_set_maxpacket_limit(&ep->end_point, hw_ep->max_packet_sz_rx);
+ }
+ ep->end_point.has_bulk = true;
+ ep->end_point.has_interrupt = true;
+ ep->end_point.has_isochronous = true;
ep->end_point.ops = &musb_ep_ops;
list_add_tail(&ep->end_point.ep_list, &musb->g.ep_list);
}
switch over to endpoint feature flags so we can drop naming conventions. Signed-off-by: Felipe Balbi <balbi@ti.com> --- drivers/usb/musb/musb_gadget.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-)