]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
soc: renesas: rz-sysc: Convert to common field_get() helper
authorGeert Uytterhoeven <geert+renesas@glider.be>
Thu, 6 Nov 2025 13:34:09 +0000 (14:34 +0100)
committerYury Norov (NVIDIA) <yury.norov@gmail.com>
Mon, 24 Nov 2025 19:15:47 +0000 (14:15 -0500)
Drop the driver-specific field_get() macro, in favor of the globally
available variant from <linux/bitfield.h>.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Claudiu Beznea <claudiu.beznea.uj@bp.renesas.com>
Signed-off-by: Yury Norov (NVIDIA) <yury.norov@gmail.com>
drivers/soc/renesas/rz-sysc.c

index b9880085d363406516e19ff9550a8eb8f58d0468..73eaf8b9d69f720803e83f022a09af1af10b0272 100644 (file)
@@ -5,6 +5,7 @@
  * Copyright (C) 2024 Renesas Electronics Corp.
  */
 
+#include <linux/bitfield.h>
 #include <linux/cleanup.h>
 #include <linux/io.h>
 #include <linux/mfd/syscon.h>
@@ -16,9 +17,6 @@
 
 #include "rz-sysc.h"
 
-#undef field_get
-#define field_get(_mask, _reg) (((_reg) & (_mask)) >> (ffs(_mask) - 1))
-
 /**
  * struct rz_sysc - RZ SYSC private data structure
  * @base: SYSC base address