From ef5a7438ac72798e82b9f8684bad935bcdd465e6 Mon Sep 17 00:00:00 2001 From: Josef Lusticky Date: Fri, 17 Apr 2020 09:32:25 +0200 Subject: board: atmel: Fix compiler warning 'board_usb_hw_init()' not used Wrap definition of board_usb_hw_init() around with #ifdef CONFIG_CMD_USB to avoid warning: 'board_usb_hw_init' defined but not used [-Wunused-function] when compiling without CONFIG_CMD_USB. This patch makes sama5d27_som1_ek, sama5d2_ptc_ek and sama5d2_xplained consistent with other boards that use the same #ifdef to avoid the warning. Cc: Eugen Hristev Cc: Ludovic Desroches Signed-off-by: Josef Lusticky Reviewed-by: Eugen Hristev --- board/atmel/sama5d2_ptc_ek/sama5d2_ptc_ek.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'board/atmel/sama5d2_ptc_ek') diff --git a/board/atmel/sama5d2_ptc_ek/sama5d2_ptc_ek.c b/board/atmel/sama5d2_ptc_ek/sama5d2_ptc_ek.c index 4b3a703..b0a23b0 100644 --- a/board/atmel/sama5d2_ptc_ek/sama5d2_ptc_ek.c +++ b/board/atmel/sama5d2_ptc_ek/sama5d2_ptc_ek.c @@ -76,10 +76,12 @@ int board_late_init(void) } #endif +#ifdef CONFIG_CMD_USB static void board_usb_hw_init(void) { atmel_pio4_set_pio_output(AT91_PIO_PORTB, 12, ATMEL_PIO_PUEN_MASK); } +#endif #ifdef CONFIG_DEBUG_UART_BOARD_INIT static void board_uart0_hw_init(void) -- cgit v1.1