On Fri, Nov 29, 2019 at 02:47:44PM +0200, Lorenzo Bianconi wrote: > > + usb->data_len = usb_maxpacket(udev, usb_sndctrlpipe(udev, 0), 1); > > + if (usb->data_len < 32) > > + usb->data_len = 32; > > Hi Stanislaw, > > usb->data_len = max_t(u16, 32, > usb_maxpacket(udev, usb_sndctrlpipe(udev, 0), 1)); > Why this is better ? > Moreover are you sure using ctrl endpoint 0 is fine for all devices? usb_sndctrlpipe(udev, 0) is used in __mt76u_vendor_request() for all out requests i.e. on all cases were usb->data is used. Stanislaw