Explorar o código

usb: gadget: udc: fusb300: make use of new usb_endpoint_maxp_mult()

We have introduced a helper to calculate multiplier
value from wMaxPacketSize. Start using it.

Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Felipe Balbi %!s(int64=9) %!d(string=hai) anos
pai
achega
2f237451a8
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      drivers/usb/gadget/udc/fusb300_udc.c

+ 1 - 1
drivers/usb/gadget/udc/fusb300_udc.c

@@ -218,7 +218,7 @@ static int config_ep(struct fusb300_ep *ep,
 	   (info.type == USB_ENDPOINT_XFER_ISOC)) {
 		info.interval = desc->bInterval;
 		if (info.type == USB_ENDPOINT_XFER_ISOC)
-			info.bw_num = ((desc->wMaxPacketSize & 0x1800) >> 11);
+			info.bw_num = usb_endpoint_maxp_mult(desc);
 	}
 
 	ep_fifo_setting(fusb300, info);