diff options
author | Shengzhou Liu <Shengzhou.Liu@freescale.com> | 2015-11-20 15:52:02 +0800 |
---|---|---|
committer | York Sun <yorksun@freescale.com> | 2015-12-13 18:27:28 -0800 |
commit | 0c028a03284aabceb89a85736e23661d6fe7915e (patch) | |
tree | 66521c44a5610455e0bffbe1b0798699e84568e4 /arch/arm/cpu/armv7/ls102xa/cpu.c | |
parent | 1aaf3f9ae471929a70509f86a48a61da6fbfb19f (diff) |
arm: ls102x: add get_svr and IS_SVR_REV helper
Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com>
Reviewed-by: York Sun <yorksun@freescale.com>
Diffstat (limited to 'arch/arm/cpu/armv7/ls102xa/cpu.c')
-rw-r--r-- | arch/arm/cpu/armv7/ls102xa/cpu.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/arm/cpu/armv7/ls102xa/cpu.c b/arch/arm/cpu/armv7/ls102xa/cpu.c index 2215fe93cf..2f0df65582 100644 --- a/arch/arm/cpu/armv7/ls102xa/cpu.c +++ b/arch/arm/cpu/armv7/ls102xa/cpu.c @@ -218,6 +218,14 @@ void enable_caches(void) } #endif /* #ifndef CONFIG_SYS_DCACHE_OFF */ + +uint get_svr(void) +{ + struct ccsr_gur __iomem *gur = (void *)(CONFIG_SYS_FSL_GUTS_ADDR); + + return in_be32(&gur->svr); +} + #if defined(CONFIG_DISPLAY_CPUINFO) int print_cpuinfo(void) { |