Skip to contentSkip to conversation

gpio: mcp230xx: add missing header for udelay()

PATCH New [email protected] 1 participant 1 message Sep 19, 2024 GPIO

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gpio: mcp230xx: add missing header for udelay()

From: Maksim Kiselev <[email protected]>

Since GCC 14 -Werror=implicit-function-declaration is enabled by default. This leads to following compilation error:

  drivers/gpio/mcp230xx_gpio.c:57:9: error:
    implicit declaration of function ‘udelay’
    [-Wimplicit-function-declaration]
      57 |         udelay(1);

Add missing header to fix this error.

---
 drivers/gpio/mcp230xx_gpio.c | 1 +
 1 file changed, 1 insertion(+)
drivers/gpio/mcp230xx_gpio.c +1 -0
index 42e7fe9d47..b6f533b130 100644
@@ -14,6 +14,7 @@
 #include <asm/gpio.h>
 #include <dm/device_compat.h>
 #include <dt-bindings/gpio/gpio.h>
+#include <linux/delay.h>
 
 enum mcp230xx_type {
 	UNKNOWN = 0,
Signature · 1 line
2.45.2