usb: gadget: composite: mark expected switch fall-throughs
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com> Acked-by: Felipe Balbi <felipe.balbi@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>hifive-unleashed-5.1
parent
0f8838a8a0
commit
624916a950
|
@ -170,20 +170,20 @@ int config_ep_by_speed(struct usb_gadget *g,
|
||||||
want_comp_desc = 1;
|
want_comp_desc = 1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
/* else: Fall trough */
|
/* fall through */
|
||||||
case USB_SPEED_SUPER:
|
case USB_SPEED_SUPER:
|
||||||
if (gadget_is_superspeed(g)) {
|
if (gadget_is_superspeed(g)) {
|
||||||
speed_desc = f->ss_descriptors;
|
speed_desc = f->ss_descriptors;
|
||||||
want_comp_desc = 1;
|
want_comp_desc = 1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
/* else: Fall trough */
|
/* fall through */
|
||||||
case USB_SPEED_HIGH:
|
case USB_SPEED_HIGH:
|
||||||
if (gadget_is_dualspeed(g)) {
|
if (gadget_is_dualspeed(g)) {
|
||||||
speed_desc = f->hs_descriptors;
|
speed_desc = f->hs_descriptors;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
/* else: fall through */
|
/* fall through */
|
||||||
default:
|
default:
|
||||||
speed_desc = f->fs_descriptors;
|
speed_desc = f->fs_descriptors;
|
||||||
}
|
}
|
||||||
|
@ -224,6 +224,7 @@ ep_found:
|
||||||
case USB_ENDPOINT_XFER_ISOC:
|
case USB_ENDPOINT_XFER_ISOC:
|
||||||
/* mult: bits 1:0 of bmAttributes */
|
/* mult: bits 1:0 of bmAttributes */
|
||||||
_ep->mult = (comp_desc->bmAttributes & 0x3) + 1;
|
_ep->mult = (comp_desc->bmAttributes & 0x3) + 1;
|
||||||
|
/* fall through */
|
||||||
case USB_ENDPOINT_XFER_BULK:
|
case USB_ENDPOINT_XFER_BULK:
|
||||||
case USB_ENDPOINT_XFER_INT:
|
case USB_ENDPOINT_XFER_INT:
|
||||||
_ep->maxburst = comp_desc->bMaxBurst + 1;
|
_ep->maxburst = comp_desc->bMaxBurst + 1;
|
||||||
|
|
Loading…
Reference in New Issue