gpio: Add missing parenthesis to the GPIO_TO_PORT define
authorLukasz Majewski <lukma@denx.de>
Sun, 9 Jun 2019 20:54:40 +0000 (22:54 +0200)
committerStefano Babic <sbabic@denx.de>
Fri, 19 Jul 2019 18:14:50 +0000 (20:14 +0200)
Add missing parenthesis to the GPIO_TO_PORT macro.

Signed-off-by: Lukasz Majewski <lukma@denx.de>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
drivers/gpio/mxc_gpio.c

index 8bd30c7..64ab7a3 100644 (file)
@@ -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[] = {