rockchip: Separate the reset cause from display cpuinfo
authorJagan Teki <jagan@amarulasolutions.com>
Tue, 21 Jul 2020 15:06:03 +0000 (20:36 +0530)
committerKever Yang <kever.yang@rock-chips.com>
Wed, 22 Jul 2020 12:55:13 +0000 (20:55 +0800)
commite230c579a3f6a325fa1624ed9a3df445096674bb
tree1a18bc60e7daab3d10b7eb1c1856728aa58d4ce6
parent88132e0a280adc120642f05f140aa77fd7e52611
rockchip: Separate the reset cause from display cpuinfo

reset cause is a generic functionality based on the soc
cru registers in rockchip. This can be used for printing
the cause of reset in cpuinfo or some other place where
reset cause is needed. 

Other than cpuinfo, reset cause can also be using during
bootcount for checking the specific reset cause and glow
the led based on the reset cause.

So, let's separate the reset cause code from cpuinfo, and
add a check to build it for rk3399, rk3288 since these two
soc are supporting reset cause as of now.

Tested-by: Suniel Mahesh <sunil@amarulasolutions.com>
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
arch/arm/include/asm/arch-rockchip/cru.h
arch/arm/mach-rockchip/Makefile
arch/arm/mach-rockchip/cpu-info.c