From: Hai Pham Date: Mon, 27 Oct 2025 17:08:52 +0000 (+0100) Subject: arm64: renesas: Use reset macro from common header X-Git-Tag: v2026.01-rc2~27^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=eb5ffe54adbd9a9636869a82b8857c9e058b466d;p=thirdparty%2Fu-boot.git arm64: renesas: Use reset macro from common header Clean up to avoid more reset macro duplication. Signed-off-by: Hai Pham Signed-off-by: Marek Vasut --- diff --git a/arch/arm/mach-renesas/include/mach/rcar-gen4-base.h b/arch/arm/mach-renesas/include/mach/rcar-gen4-base.h index 403054e4a7e..d882a9ba4a0 100644 --- a/arch/arm/mach-renesas/include/mach/rcar-gen4-base.h +++ b/arch/arm/mach-renesas/include/mach/rcar-gen4-base.h @@ -29,6 +29,8 @@ #define RST_BASE 0xE6160000 /* Domain0 */ #define RST_SRESCR0 (RST_BASE + 0x18) #define RST_SPRES 0x5AA58000 +#define RST_WDTRSTCR (RST_BASE + 0x10) +#define RST_RWDT 0xA55A8002 /* Arm Generic Timer */ #define CNTCR_BASE 0xE6080000 diff --git a/arch/arm/mach-renesas/psci-rcar64.c b/arch/arm/mach-renesas/psci-rcar64.c index a230692c9e0..459dd55ff45 100644 --- a/arch/arm/mach-renesas/psci-rcar64.c +++ b/arch/arm/mach-renesas/psci-rcar64.c @@ -8,6 +8,7 @@ #include #include #include +#include int __secure psci_features(u32 function_id, u32 psci_fid) { @@ -29,10 +30,6 @@ u32 __secure psci_version(void) return ARM_PSCI_VER_0_2; } -#define RST_BASE 0xE6160000 /* Domain0 */ -#define RST_SRESCR0 (RST_BASE + 0x18) -#define RST_SPRES 0x5AA58000 - void __secure __noreturn psci_system_reset(void) { writel(RST_SPRES, RST_SRESCR0); diff --git a/board/renesas/common/gen4-common.c b/board/renesas/common/gen4-common.c index f7d129be4c8..38fba7a5ea7 100644 --- a/board/renesas/common/gen4-common.c +++ b/board/renesas/common/gen4-common.c @@ -16,10 +16,6 @@ #include #include -#define RST_BASE 0xE6160000 /* Domain0 */ -#define RST_WDTRSTCR (RST_BASE + 0x10) -#define RST_RWDT 0xA55A8002 - DECLARE_GLOBAL_DATA_PTR; static void init_generic_timer(void) @@ -77,10 +73,6 @@ int board_init(void) return 0; } -#define RST_BASE 0xE6160000 /* Domain0 */ -#define RST_SRESCR0 (RST_BASE + 0x18) -#define RST_SPRES 0x5AA58000 - void __weak reset_cpu(void) { writel(RST_SPRES, RST_SRESCR0);