[U-Boot] [PATCH v1 04/11] gpio: Add missing parenthesis to the GPIO_TO_PORT define

Peng Fan peng.fan at nxp.com
Mon Jun 10 01:38:18 UTC 2019


> Subject: [PATCH v1 04/11] gpio: Add missing parenthesis to the
> GPIO_TO_PORT define
> 
> Add missing parenthesis to the GPIO_TO_PORT macro.
> 
> Signed-off-by: Lukasz Majewski <lukma at denx.de>
> ---
> 
>  drivers/gpio/mxc_gpio.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpio/mxc_gpio.c b/drivers/gpio/mxc_gpio.c index
> 8bd30c75b2..64ab7a303f 100644
> --- a/drivers/gpio/mxc_gpio.c
> +++ b/drivers/gpio/mxc_gpio.c
> @@ -31,7 +31,7 @@ struct mxc_bank_info {  };
> 
>  #ifndef CONFIG_DM_GPIO
> -#define GPIO_TO_PORT(n)		(n / 32)
> +#define GPIO_TO_PORT(n)		((n) / 32)
> 
>  /* GPIO port description */
>  static unsigned long gpio_ports[] = {

Reviewed-by: Peng Fan <peng.fan at nxp.com>

> --
> 2.11.0



More information about the U-Boot mailing list