imx: vf610 add get_cpu_rev
authorPeng Fan <Peng.Fan@freescale.com>
Tue, 1 Sep 2015 09:15:03 +0000 (17:15 +0800)
committerStefano Babic <sbabic@denx.de>
Wed, 2 Sep 2015 13:39:51 +0000 (15:39 +0200)
Since we need to support runtime check for different drivers, we need
to add get_cpu_rev for vf610, otherwise there will be build errors.

This patch introduces a dummy CPU id which is not read from chip
silicon. Later when we can get the real id from chip, can fix the
value of MXC_CPU_VF610 then.

Signed-off-by: Peng Fan <Peng.Fan@freescale.com>
Suggested-by: Stefano Babic <sbabic@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Acked-by: Stefano Babic <sbabic@denx.de>
arch/arm/cpu/armv7/vf610/generic.c
arch/arm/include/asm/arch-imx/cpu.h

index 05c401dc73ce66529d7033325c5424aff1b9711e..08b9ef42a19012982a44f9572198931da3681aa6 100644 (file)
@@ -9,6 +9,7 @@
 #include <asm/arch/imx-regs.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/crm_regs.h>
+#include <asm/imx-common/sys_proto.h>
 #include <netdev.h>
 #ifdef CONFIG_FSL_ESDHC
 #include <fsl_esdhc.h>
@@ -266,6 +267,11 @@ void imx_get_mac_from_fuse(int dev_id, unsigned char *mac)
 }
 #endif
 
+u32 get_cpu_rev(void)
+{
+       return MXC_CPU_VF610 << 12;
+}
+
 #if defined(CONFIG_DISPLAY_CPUINFO)
 static char *get_reset_cause(void)
 {
index be13b9694f7fc1b4d41c4fa82e5847909505ba73..1c8d24e576f99a9c9c9e732c6ffb9a9f00457611 100644 (file)
@@ -21,6 +21,7 @@
 #define MXC_CPU_MX6D           0x67
 #define MXC_CPU_MX6DP          0x68
 #define MXC_CPU_MX6QP          0x69
+#define MXC_CPU_VF610          0xF6 /* dummy ID */
 
 #define CS0_128                                        0
 #define CS0_64M_CS1_64M                                1