Date: Fri, 13 May 2016 07:03:36 +0200 Subject: [PATCH 1/2] hw/usb-xhci: Remove unused const variables
Remove the unused arrays `eptype_to_xhci_in` and `eptype_to_xhci_out` to fix the GCC 6 warnings below.
``` $ gcc-6 --version gcc-6 (Debian 6.1.1-3) 6.1.1 20160511 […] $ make CC=gcc-6 […] Compile checking out/src/hw/usb-xhci.o […] src/hw/usb-xhci.c:296:18: warning: 'eptype_to_xhci_out' defined but not used [-Wunused-const-variable=] static const int eptype_to_xhci_out[] = { ^~~~~~~~~~~~~~~~~~ src/hw/usb-xhci.c:289:18: warning: 'eptype_to_xhci_in' defined but not used [-Wunused-const-variable=] static const int eptype_to_xhci_in[] = { ```
Signed-off-by: Paul Menzel paulepanter@users.sourceforge.net --- src/hw/usb-xhci.c | 14 -------------- 1 file changed, 14 deletions(-)
diff --git a/src/hw/usb-xhci.c b/src/hw/usb-xhci.c index 5e2f071..69954b9 100644 --- a/src/hw/usb-xhci.c +++ b/src/hw/usb-xhci.c @@ -286,20 +286,6 @@ static const int speed_to_xhci[] = { [ USB_SUPERSPEED ] = 4, }; -static const int eptype_to_xhci_in[] = { - [ USB_ENDPOINT_XFER_CONTROL] = 4, - [ USB_ENDPOINT_XFER_ISOC ] = 5, - [ USB_ENDPOINT_XFER_BULK ] = 6, - [ USB_ENDPOINT_XFER_INT ] = 7, -}; - -static const int eptype_to_xhci_out[] = { - [ USB_ENDPOINT_XFER_CONTROL] = 4, - [ USB_ENDPOINT_XFER_ISOC ] = 1, - [ USB_ENDPOINT_XFER_BULK ] = 2, - [ USB_ENDPOINT_XFER_INT ] = 3, -}; - static int wait_bit(u32 *reg, u32 mask, int value, u32 timeout) { u32 end = timer_calc(timeout); -- 2.8.1