Skip to contentSkip to conversation

ARM: kirkwood: fix cpu info for 6282 device id

PATCH New Luka Perkov 4 participants 4 messages Jul 2, 2014 – Jul 4, 2014 Arm (32-bit)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: kirkwood: fix cpu info for 6282 device id

CC Prafulla Wadaskar <[email protected]>
CC Stefan Roese <[email protected]>
---
 arch/arm/cpu/arm926ejs/kirkwood/cpu.c | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)
arch/arm/cpu/arm926ejs/kirkwood/cpu.c +8 -3
index da80240..312d2b2 100644
@@ -252,7 +252,7 @@ static void kw_sysrst_check(void)
 #if defined(CONFIG_DISPLAY_CPUINFO)
 int print_cpuinfo(void)
 {
-	char *rev;
+	char *rev = "??";
 	u16 devid = (readl(KW_REG_PCIE_DEVID) >> 16) & 0xffff;
 	u8 revid = readl(KW_REG_PCIE_REVID) & 0xff;
 
@@ -263,7 +263,13 @@ int print_cpuinfo(void)
 
 	switch (revid) {
 	case 0:
-		rev = "Z0";
+		if (devid == 0x6281)
+			rev = "Z0";
+		else if (devid == 0x6282)
+			rev = "A0";
+		break;
+	case 1:
+		rev = "A1";
 		break;
 	case 2:
 		rev = "A0";
@@ -272,7 +278,6 @@ int print_cpuinfo(void)
 		rev = "A1";
 		break;
 	default:
-		rev = "??";
 		break;
 	}
 
Signature · 1 line
2.0.1
#2 lore raw

PATCH 1/1 ARM: kirkwood: fix cpu info for 6282 device id

In reply to Luka Perkov
Quoted 48 lines

-----Original Message-----
From: Luka Perkov [mailto:luka at openwrt.org]
Sent: 02 July 2014 05:48
To: u-boot at lists.denx.de
Cc: luka at openwrt.org; Prafulla Wadaskar; Stefan Roese
Subject: [PATCH] ARM: kirkwood: fix cpu info for 6282 device id

CC Prafulla Wadaskar <[email protected]>
CC Stefan Roese <[email protected]>
---
 arch/arm/cpu/arm926ejs/kirkwood/cpu.c | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)
arch/arm/cpu/arm926ejs/kirkwood/cpu.c +8 -2
index da80240..312d2b2 100644
@@ -252,7 +252,7 @@ static void kw_sysrst_check(void)
 #if defined(CONFIG_DISPLAY_CPUINFO)
 int print_cpuinfo(void)
 {
-	char *rev;
+	char *rev = "??";
 	u16 devid = (readl(KW_REG_PCIE_DEVID) >> 16) &
 0xffff;
 	u8 revid = readl(KW_REG_PCIE_REVID) & 0xff;
@@ -263,7 +263,13 @@ int print_cpuinfo(void)
 
 	switch (revid) {
 	case 0:
-		rev = "Z0";
+		if (devid == 0x6281)
+			rev = "Z0";
+		else if (devid == 0x6282)
+			rev = "A0";
+		break;
+	case 1:
+		rev = "A1";
 		break;
 	case 2:
 		rev = "A0";

arch/arm/cpu/arm926ejs/kirkwood/cpu.c int print_cpuinfo(void) · line 283

Quoted 7 lines
arch/arm/cpu/arm926ejs/kirkwood/cpu.c +0 -1
@@ -272,7 +278,6 @@ int print_cpuinfo(void)
 		rev = "A1";
 		break;
 	default:
-		rev = "??";
 		break;
 	}
 

Will be pulled latter.

Regards...
Prafulla . . .

#3 lore raw

PATCH 1/1 ARM: kirkwood: fix cpu info for 6282 device id

Hi Prafulla,

Quoted 58 lines · Prafulla Wadaskar
Quoted 48 lines

-----Original Message-----
From: Luka Perkov [mailto:luka at openwrt.org]
Sent: 02 July 2014 05:48
To: u-boot at lists.denx.de
Cc: luka at openwrt.org; Prafulla Wadaskar; Stefan Roese
Subject: [PATCH] ARM: kirkwood: fix cpu info for 6282 device id

CC Prafulla Wadaskar <[email protected]>
CC Stefan Roese <[email protected]>
---
 arch/arm/cpu/arm926ejs/kirkwood/cpu.c | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)
arch/arm/cpu/arm926ejs/kirkwood/cpu.c +8 -2
index da80240..312d2b2 100644
@@ -252,7 +252,7 @@ static void kw_sysrst_check(void)
 #if defined(CONFIG_DISPLAY_CPUINFO)
 int print_cpuinfo(void)
 {
-	char *rev;
+	char *rev = "??";
 	u16 devid = (readl(KW_REG_PCIE_DEVID) >> 16) &
 0xffff;
 	u8 revid = readl(KW_REG_PCIE_REVID) & 0xff;
@@ -263,7 +263,13 @@ int print_cpuinfo(void)
 
 	switch (revid) {
 	case 0:
-		rev = "Z0";
+		if (devid == 0x6281)
+			rev = "Z0";
+		else if (devid == 0x6282)
+			rev = "A0";
+		break;
+	case 1:
+		rev = "A1";
 		break;
 	case 2:
 		rev = "A0";

arch/arm/cpu/arm926ejs/kirkwood/cpu.c int print_cpuinfo(void) · line 283

Quoted 7 lines
arch/arm/cpu/arm926ejs/kirkwood/cpu.c +0 -1
@@ -272,7 +278,6 @@ int print_cpuinfo(void)
 		rev = "A1";
 		break;
 	default:
-		rev = "??";
 		break;
 	}
 
Quoted 1 line

Will be pulled latter.

Prafulla, just a note in case you intend to send a PR for 2014.07: I'll be unavailable for U-Boot work from Monday july 7th to Tuesday july 22nd inclusive, so meanwhile, a Marvell PR for 2014.07 would have to be sent to Tom Rini.

Quoted 2 lines

Regards...
Prafulla . . .

Amicalement,

Signature · 1 line
Albert.