From: Heinrich Schuchardt Date: Wed, 12 Oct 2022 16:59:27 +0000 (+0200) Subject: board: gateworks: gw_ventana: fix building with GCC 12.2 X-Git-Tag: v2023.07~288^2~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=65e8b64d237a8a6e9062568412fae03c1673885c;p=platform%2Fkernel%2Fu-boot.git board: gateworks: gw_ventana: fix building with GCC 12.2 Building with GCC 12.2 results in an error board/gateworks/gw_ventana/gw_ventana.c:636:68: error: the comparison will always evaluate as 'true' for the address of 'pwm_padmux' will never be NULL [-Werror=address] 636 | } else if (hwconfig_subarg_cmp(arg, "mode", "pwm") && | ^~ Remove the superfluous check. Signed-off-by: Heinrich Schuchardt Reviewed-By: Tim Harvey Reviewed-by: Fabio Estevam --- diff --git a/board/gateworks/gw_ventana/gw_ventana.c b/board/gateworks/gw_ventana/gw_ventana.c index 99f52b9..78d317d 100644 --- a/board/gateworks/gw_ventana/gw_ventana.c +++ b/board/gateworks/gw_ventana/gw_ventana.c @@ -633,8 +633,7 @@ void setup_board_gpio(int board, struct ventana_board_info *info) ctrl); gpio_requestf(cfg->gpio_param, "dio%d", i); gpio_direction_input(cfg->gpio_param); - } else if (hwconfig_subarg_cmp(arg, "mode", "pwm") && - cfg->pwm_padmux) { + } else if (hwconfig_subarg_cmp(arg, "mode", "pwm")) { if (!cfg->pwm_param) { printf("DIO%d: Error: pwm config invalid\n", i);