drivers/usb/gadget/epautoconf.c: In function `ep_matches':
drivers/usb/gadget/epautoconf.c:175: error: `typeof' applied to a bit-field
}
/* report (variable) full speed bulk maxpacket */
- if (USB_ENDPOINT_XFER_BULK == type)
- desc->wMaxPacketSize = cpu_to_le16 (
- min ((unsigned)64, ep->maxpacket));
+ if (USB_ENDPOINT_XFER_BULK == type) {
+ int size = ep->maxpacket;
+
+ /* min() doesn't work on bitfields with gcc-3.5 */
+ if (size > 64)
+ size = 64;
+ desc->wMaxPacketSize = cpu_to_le16(size);
+ }
return 1;
}