]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
dt-bindings: reset: fix double id on rk3562-cru reset ids
authorHeiko Stuebner <heiko@sntech.de>
Wed, 12 Mar 2025 21:59:23 +0000 (22:59 +0100)
committerStephen Boyd <sboyd@kernel.org>
Fri, 14 Mar 2025 00:54:29 +0000 (17:54 -0700)
Id 173 was accidentially used two times for SRST_P_DDR_HWLP and
SRST_P_DDR_PHY. This makes both resets ambiguous and also causes build
warnings like:

drivers/clk/rockchip/rst-rk3562.c:21:57: error: initialized field overwritten [-Werror=override-init]
   21 | #define RK3562_DDRCRU_RESET_OFFSET(id, reg, bit) [id] = (0x20000*4 + reg * 16 + bit)
      |                                                         ^
drivers/clk/rockchip/rst-rk3562.c:266:9: note: in expansion of macro 'RK3562_DDRCRU_RESET_OFFSET'
  266 |         RK3562_DDRCRU_RESET_OFFSET(SRST_P_DDR_PHY, 0, 8),
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/clk/rockchip/rst-rk3562.c:21:57: note: (near initialization for 'rk3562_register_offset[173]')
   21 | #define RK3562_DDRCRU_RESET_OFFSET(id, reg, bit) [id] = (0x20000*4 + reg * 16 + bit)
      |                                                         ^
drivers/clk/rockchip/rst-rk3562.c:266:9: note: in expansion of macro 'RK3562_DDRCRU_RESET_OFFSET'
  266 |         RK3562_DDRCRU_RESET_OFFSET(SRST_P_DDR_PHY, 0, 8),
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~

To fix that issue give SRST_P_DDR_PHY a new and now unique id.

Reported-by: Stephen Boyd <sboyd@kernel.org>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202503121743.0zcDf6nE-lkp@intel.com/
Fixes: dd113c4fefc8 ("dt-bindings: clock: Add RK3562 cru")
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Link: https://lore.kernel.org/r/20250312215923.275625-1-heiko@sntech.de
Acked-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
include/dt-bindings/reset/rockchip,rk3562-cru.h

index a74471d7d2a93920fff03446a41d43d7e3376c46..8df95113056e36b8c6d8e3ca7ffd50ef9b9de585 100644 (file)
 #define SRST_MSCH_BRG_BIU              171
 #define SRST_P_MSCH_BIU                        172
 #define SRST_P_DDR_HWLP                        173
-#define SRST_P_DDR_PHY                 173
+#define SRST_P_DDR_PHY                 290
 #define SRST_P_DDR_DFICTL              174
 #define SRST_P_DDR_DMA2DDR             175
 /********Name=DDRSOFTRST_CON01,Offset=0x20204********/