diff options
author | Fabio Estevam <fabio.estevam@freescale.com> | 2014-01-26 15:06:41 -0200 |
---|---|---|
committer | Stefano Babic <sbabic@denx.de> | 2014-02-11 11:24:12 +0100 |
commit | 94db66557997a929313e0f5020c83368b1c6627f (patch) | |
tree | ebf36d6578d1140bd995c49cc9f266f8937d7052 /arch/arm/cpu/armv7 | |
parent | 6a99f03d696ee51e584a9c95b9fb065ebf0d46b4 (diff) | |
download | u-boot-imx-94db66557997a929313e0f5020c83368b1c6627f.zip u-boot-imx-94db66557997a929313e0f5020c83368b1c6627f.tar.gz u-boot-imx-94db66557997a929313e0f5020c83368b1c6627f.tar.bz2 |
mx6: Distinguish mx6dual from mx6quad
Currently when we boot a mx6dual U-boot reports that it is a mx6quad.
Report it as MX6D instead:
CPU: Freescale i.MX6D rev1.2 at 792 MHz
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Stefano babic <sbabic@denx.de>
Acked-by: Otavio Salvador <otavio@ossystems.com.br>
Diffstat (limited to 'arch/arm/cpu/armv7')
-rw-r--r-- | arch/arm/cpu/armv7/mx6/soc.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/arch/arm/cpu/armv7/mx6/soc.c b/arch/arm/cpu/armv7/mx6/soc.c index 2aad0a1..4c5c367 100644 --- a/arch/arm/cpu/armv7/mx6/soc.c +++ b/arch/arm/cpu/armv7/mx6/soc.c @@ -41,14 +41,19 @@ u32 get_cpu_rev(void) if (type != MXC_CPU_MX6SL) { reg = readl(&anatop->digprog); + struct scu_regs *scu = (struct scu_regs *)SCU_BASE_ADDR; + u32 cfg = readl(&scu->config) & 3; type = ((reg >> 16) & 0xff); if (type == MXC_CPU_MX6DL) { - struct scu_regs *scu = (struct scu_regs *)SCU_BASE_ADDR; - u32 cfg = readl(&scu->config) & 3; - if (!cfg) type = MXC_CPU_MX6SOLO; } + + if (type == MXC_CPU_MX6Q) { + if (cfg == 1) + type = MXC_CPU_MX6D; + } + } reg &= 0xff; /* mx6 silicon revision */ return (type << 12) | (reg + 0x10); @@ -62,6 +67,9 @@ u32 __weak get_board_rev(void) if (type == MXC_CPU_MX6SOLO) cpurev = (MXC_CPU_MX6DL) << 12 | (cpurev & 0xFFF); + if (type == MXC_CPU_MX6D) + cpurev = (MXC_CPU_MX6Q) << 12 | (cpurev & 0xFFF); + return cpurev; } #endif |