summaryrefslogtreecommitdiff
path: root/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c
diff options
context:
space:
mode:
authorJosef Lusticky <josef@lusticky.cz>2020-04-17 09:32:25 +0200
committerEugen Hristev <eugen.hristev@microchip.com>2020-05-06 16:18:53 +0300
commitef5a7438ac72798e82b9f8684bad935bcdd465e6 (patch)
tree018333f32f9711b162c38058ca6c2fe995d6436d /board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c
parentdd2c676a659a03daeef31d1221da2edff009d426 (diff)
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 <eugen.hristev@microchip.com> Cc: Ludovic Desroches <ludovic.desroches@microchip.com> Signed-off-by: Josef Lusticky <josef@lusticky.cz> Reviewed-by: Eugen Hristev <eugen.hristev@microchip.com>
Diffstat (limited to 'board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c')
-rw-r--r--board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c b/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c
index f3816c8334..376562cd0e 100644
--- a/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c
+++ b/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c
@@ -20,10 +20,12 @@ extern void at91_pda_detect(void);
DECLARE_GLOBAL_DATA_PTR;
+#ifdef CONFIG_CMD_USB
static void board_usb_hw_init(void)
{
atmel_pio4_set_pio_output(AT91_PIO_PORTA, 27, 1);
}
+#endif
#ifdef CONFIG_BOARD_LATE_INIT
int board_late_init(void)