From e8fad1b70bed78e019ada7af3e29bbfce0652094 Mon Sep 17 00:00:00 2001 From: Stefan Agner Date: Thu, 24 Jul 2014 13:10:42 +0200 Subject: vf610: improve CPU type detection Detect VF5xx CPU's by reading the CPU count register. Also we can guess the second number of the CPU type (VF6x0) which indicates the presence of a L2 cache. --- arch/arm/cpu/armv7/vf610/generic.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/arch/arm/cpu/armv7/vf610/generic.c b/arch/arm/cpu/armv7/vf610/generic.c index a26d63ebe0..e1b3f4dc79 100644 --- a/arch/arm/cpu/armv7/vf610/generic.c +++ b/arch/arm/cpu/armv7/vf610/generic.c @@ -283,7 +283,11 @@ static char *get_reset_cause(void) int print_cpuinfo(void) { - printf("CPU: Freescale Vybrid VF610 at %d MHz\n", + struct mscm *mscm = (struct mscm *)MSCM_BASE_ADDR; + + printf("CPU: Freescale Vybrid VF%c%c0 at %d MHz\n", + mscm->cpxcount ? '6' : '5', /* Dual Core => VF6x0 */ + mscm->cpxcfg1 ? '1' : '0', /* L2 Cache => VFx10 */ mxc_get_clock(MXC_ARM_CLK) / 1000000); printf("Reset cause: %s\n", get_reset_cause()); -- cgit v1.2.3