[PATCH RFC v2 01/23] rockchip: RK3328: Read the reset cause from clock reset unit for RK3328 SoC

Dragan Simic dsimic at manjaro.org
Fri May 31 23:43:00 CEST 2024


Hello Anand,

On 2024-05-31 16:18, Anand Moon wrote:
> From: Anand Moon <anand at edgeble.ai>
> 
> Read the reset cause from clock reset unit for RK3328 SoC.
> 
> Cc: Jagan Teki <jagan at edgeble.ai>
> Signed-off-by: Anand Moon <anand at edgeble.ai>
> Signed-off-by: Anand Moon <linux.amoon at gmail.com>
> ---
>  arch/arm/include/asm/arch-rockchip/cru.h | 2 ++
>  arch/arm/mach-rockchip/cpu-info.c        | 4 +++-
>  2 files changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/arm/include/asm/arch-rockchip/cru.h
> b/arch/arm/include/asm/arch-rockchip/cru.h
> index 9778790f34..a1499e9652 100644
> --- a/arch/arm/include/asm/arch-rockchip/cru.h
> +++ b/arch/arm/include/asm/arch-rockchip/cru.h
> @@ -13,6 +13,8 @@
> 
>  #if defined(CONFIG_ROCKCHIP_RK3288)
>  # include <asm/arch-rockchip/cru_rk3288.h>
> +#elif defined(CONFIG_ROCKCHIP_RK3328)
> +#include <asm/arch-rockchip/cru_rk3328.h>

A single space character should be added between "#" and "include",
for consistency.

>  #elif defined(CONFIG_ROCKCHIP_RK3399)
>  # include <asm/arch-rockchip/cru_rk3399.h>
>  #elif defined(CONFIG_ROCKCHIP_RK3568)
> diff --git a/arch/arm/mach-rockchip/cpu-info.c
> b/arch/arm/mach-rockchip/cpu-info.c
> index a62ff53c6a..86b0c02970 100644
> --- a/arch/arm/mach-rockchip/cpu-info.c
> +++ b/arch/arm/mach-rockchip/cpu-info.c
> @@ -14,7 +14,9 @@
> 
>  char *get_reset_cause(void)
>  {
> -	struct rockchip_cru *cru = rockchip_get_cru();
> +#if IS_ENABLED(CONFIG_ROCKCHIP_RK3328)
> +	struct rk3328_cru *cru = rockchip_get_cru();
> +#endif
>  	char *cause = NULL;
> 
>  	if (IS_ERR(cru))


More information about the U-Boot mailing list