The rockchip_get_cru() helper is used by the sysreset_rockchip to get the SoC specific CRU base address. The helper may trigger a full clock driver probe to get the fixed CRU base address from the clock driver private data, something that can take several ms.
Change to return the fixed RK3588 specific CRU base address directly to simplify and remove the unneeded complexity of using runtime lookup in SoC specific code. Signed-off-by: Jonas Karlman <[email protected]> --- arch/arm/mach-rockchip/rk3588/clk_rk3588.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/arch/arm/mach-rockchip/rk3588/clk_rk3588.c b/arch/arm/mach-rockchip/rk3588/clk_rk3588.c index 250ec423bd24..9b112e45f1de 100644 --- a/arch/arm/mach-rockchip/rk3588/clk_rk3588.c +++ b/arch/arm/mach-rockchip/rk3588/clk_rk3588.c @@ -4,10 +4,7 @@ */ #include <dm.h> -#include <syscon.h> -#include <asm/arch-rockchip/clock.h> #include <asm/arch-rockchip/cru_rk3588.h> -#include <linux/err.h> int rockchip_get_clk(struct udevice **devp) { @@ -17,15 +14,5 @@ int rockchip_get_clk(struct udevice **devp) void *rockchip_get_cru(void) { - struct rk3588_clk_priv *priv; - struct udevice *dev; - int ret; - - ret = rockchip_get_clk(&dev); - if (ret) - return ERR_PTR(ret); - - priv = dev_get_priv(dev); - - return priv->cru; + return (void *)RK3588_CRU_BASE; } -- 2.54.0
