[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250403132406.81003-1-arnd@kernel.org>
Date: Thu, 3 Apr 2025 15:23:59 +0200
From: Arnd Bergmann <arnd@...nel.org>
To: Uwe Kleine-König <ukleinek@...nel.org>
Cc: Arnd Bergmann <arnd@...db.de>,
linux-pwm@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH] pwm: rcar: include linux/bitfield.h
From: Arnd Bergmann <arnd@...db.de>
The use of FIELD_MAX() breaks in some configurations because of
a missing header:
drivers/pwm/pwm-rcar.c:114:12: error: call to undeclared function 'FIELD_MAX'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
114 | if (tmp > FIELD_MAX(RCAR_PWMCNT_CYC0_MASK))
| ^
Fixes: edd549f4956b ("pwm: rcar: Improve register calculation")
Signed-off-by: Arnd Bergmann <arnd@...db.de>
---
drivers/pwm/pwm-rcar.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/pwm/pwm-rcar.c b/drivers/pwm/pwm-rcar.c
index 19e5d0b849a6..578dbdd2d5a7 100644
--- a/drivers/pwm/pwm-rcar.c
+++ b/drivers/pwm/pwm-rcar.c
@@ -8,6 +8,7 @@
* - The hardware cannot generate a 0% duty cycle.
*/
+#include <linux/bitfield.h>
#include <linux/clk.h>
#include <linux/err.h>
#include <linux/io.h>
--
2.39.5
Powered by blists - more mailing lists