summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorOtavio Salvador <otavio@ossystems.com.br>2013-01-11 03:19:08 +0000
committerStefano Babic <sbabic@denx.de>2013-01-21 12:05:20 +0100
commitf69077e4206d8a33cdb1d9b14afaafd343cb9eea (patch)
tree9b9257343afbfac631a9d27afde7741e1542fe52 /arch
parent95e873d6011e299852e679cb7d5e74c4e6f67808 (diff)
downloadu-boot-imx-f69077e4206d8a33cdb1d9b14afaafd343cb9eea.zip
u-boot-imx-f69077e4206d8a33cdb1d9b14afaafd343cb9eea.tar.gz
u-boot-imx-f69077e4206d8a33cdb1d9b14afaafd343cb9eea.tar.bz2
mx23: Add support on print_cpuinfo()
Add information to identify i.MX23 chips and its known revisions. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Marek Vasut <marex@denx.de> Cc: Stefano Babic <sbabic@denx.de>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/cpu/arm926ejs/mxs/mxs.c19
-rw-r--r--arch/arm/include/asm/arch-mxs/regs-digctl.h1
2 files changed, 19 insertions, 1 deletions
diff --git a/arch/arm/cpu/arm926ejs/mxs/mxs.c b/arch/arm/cpu/arm926ejs/mxs/mxs.c
index 6ce8019..a748623 100644
--- a/arch/arm/cpu/arm926ejs/mxs/mxs.c
+++ b/arch/arm/cpu/arm926ejs/mxs/mxs.c
@@ -1,5 +1,5 @@
/*
- * Freescale i.MX28 common code
+ * Freescale i.MX23/i.MX28 common code
*
* Copyright (C) 2011 Marek Vasut <marek.vasut@gmail.com>
* on behalf of DENX Software Engineering GmbH
@@ -196,6 +196,8 @@ static const char *get_cpu_type(void)
(struct mxs_digctl_regs *)MXS_DIGCTL_BASE;
switch (readl(&digctl_regs->hw_digctl_chipid) & HW_DIGCTL_CHIPID_MASK) {
+ case HW_DIGCTL_CHIPID_MX23:
+ return "23";
case HW_DIGCTL_CHIPID_MX28:
return "28";
default:
@@ -210,6 +212,21 @@ static const char *get_cpu_rev(void)
uint8_t rev = readl(&digctl_regs->hw_digctl_chipid) & 0x000000FF;
switch (readl(&digctl_regs->hw_digctl_chipid) & HW_DIGCTL_CHIPID_MASK) {
+ case HW_DIGCTL_CHIPID_MX23:
+ switch (rev) {
+ case 0x0:
+ return "1.0";
+ case 0x1:
+ return "1.1";
+ case 0x2:
+ return "1.2";
+ case 0x3:
+ return "1.3";
+ case 0x4:
+ return "1.4";
+ default:
+ return "??";
+ }
case HW_DIGCTL_CHIPID_MX28:
switch (rev) {
case 0x1:
diff --git a/arch/arm/include/asm/arch-mxs/regs-digctl.h b/arch/arm/include/asm/arch-mxs/regs-digctl.h
index e7cc4b4..d043325 100644
--- a/arch/arm/include/asm/arch-mxs/regs-digctl.h
+++ b/arch/arm/include/asm/arch-mxs/regs-digctl.h
@@ -154,6 +154,7 @@ struct mxs_digctl_regs {
/* Product code identification */
#define HW_DIGCTL_CHIPID_MASK (0xffff << 16)
+#define HW_DIGCTL_CHIPID_MX23 (0x3780 << 16)
#define HW_DIGCTL_CHIPID_MX28 (0x2800 << 16)
#endif /* __MX28_REGS_DIGCTL_H__ */