Skip to contentSkip to conversation

powernv: Properly mask POWER9 DD1 PVR for different chip types

PATCH In review Michael Neuling 2 participants 4 messages Jun 7, 2017 – Jun 8, 2017 PowerPC

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 powernv: Properly mask POWER9 DD1 PVR for different chip types

Bits 48:51 in the PVR for POWER9 represent different chip types (scale up vs out and 12 vs 24 core). Current chips have 0 here, but could be non-zero in the future.

This changes the POWER9 DD1 mask to correctly ignore these bits 48:51.

---
 arch/powerpc/kernel/cputable.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/powerpc/kernel/cputable.c +2 -2
index 9b3e88b1a9..89dcd94237 100644
@@ -526,8 +526,8 @@ static struct cpu_spec __initdata cpu_specs[] = {
 		.machine_check_early	= __machine_check_early_realmode_p8,
 		.platform		= "power8",
 	},
-	{	/* Power9 DD1*/
-		.pvr_mask		= 0xffffff00,
+	{	/* Power9 DD1. Bits 48:51 represent chip type so mask these */
+		.pvr_mask		= 0xffff0f00,
 		.pvr_value		= 0x004e0100,
 		.cpu_name		= "POWER9 (raw)",
 		.cpu_features		= CPU_FTRS_POWER9_DD1,
Signature · 1 line
2.11.0
#1 lore raw
Quoted 10 lines · Michael Neuling

Bits 48:51 in the PVR for POWER9 represent different chip types (scale up vs out and 12 vs 24 core). Current chips have 0 here, but could be non-zero in the future.

This changes the POWER9 DD1 mask to correctly ignore these bits 48:51.

---
 arch/powerpc/kernel/cputable.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Presumably we should backport this?

cheers

Quoted 17 lines
arch/powerpc/kernel/cputable.c +2 -2
index 9b3e88b1a9..89dcd94237 100644
@@ -526,8 +526,8 @@ static struct cpu_spec __initdata cpu_specs[] = {
 		.machine_check_early	= __machine_check_early_realmode_p8,
 		.platform		= "power8",
 	},
-	{	/* Power9 DD1*/
-		.pvr_mask		= 0xffffff00,
+	{	/* Power9 DD1. Bits 48:51 represent chip type so mask these */
+		.pvr_mask		= 0xffff0f00,
 		.pvr_value		= 0x004e0100,
 		.cpu_name		= "POWER9 (raw)",
 		.cpu_features		= CPU_FTRS_POWER9_DD1,
Signature · 1 line
2.11.0
#2 lore raw
Quoted 12 lines · Michael Ellerman

Michael Neuling <[email protected]> writes:
=20

Quoted 10 lines

Bits 48:51 in the PVR for POWER9 represent different chip types (scale up vs out and 12 vs 24 core). Current chips have 0 here, but could be non-zero in the future.
=20
This changes the POWER9 DD1 mask to correctly ignore these bits 48:51. =20

---
=C2=A0arch/powerpc/kernel/cputable.c | 4 ++-- =C2=A01 file changed, 2 insertions(+), 2 deletions(-)

Quoted 2 lines

=20
Presumably we should backport this?

Actually, we need to scrap this patch.

Looks like the scale up version will be marked as DD1, but it won't need th= ese
workarounds. So we need it to match on the other POWER9 entry.

Mikey

Quoted 4 lines

=20
cheers
=20

arch/powerpc/kernel/cputa=

Quoted 1 line
arch/powerpc/kernel/cputa= renamed from arch/powerpc/kernel/cputable.c +0 -0

ble.c

Quoted 20 lines
Quoted 13 lines

index 9b3e88b1a9..89dcd94237 100644

arch/powerpc/kernel/cputable.c +0 -0
@@ -526,8 +526,8 @@ static struct cpu_spec __initdata cpu_specs[] =3D {

=C2=A0 .machine_check_early =3D
__machine_check_early_realmode_p8,
=C2=A0 .platform =3D "power8",
=C2=A0 },

arch/powerpc/kernel/cputable.c +1 -2
-	{	/* Power9 DD1*/
-		.pvr_mask		=3D 0xffffff00,
+	{	/* Power9 DD1. Bits 48:51 represent chip type so mask

these */

arch/powerpc/kernel/cputable.c +1 -0
+		.pvr_mask		=3D 0xffff0f00,
Quoted 5 lines

=C2=A0 .pvr_value =3D 0x004e0100,
=C2=A0 .cpu_name =3D "POWER9 (raw)",
=C2=A0 .cpu_features =3D CPU_FTRS_POWER9_DD1,
--=C2=A0
2.11.0

=20
=20

#3 lore raw
Quoted 13 lines · Michael Neuling
Quoted 12 lines · Michael Ellerman

Michael Neuling <[email protected]> writes:
=20

Quoted 10 lines

Bits 48:51 in the PVR for POWER9 represent different chip types (scale up vs out and 12 vs 24 core). Current chips have 0 here, but could be non-zero in the future.
=20
This changes the POWER9 DD1 mask to correctly ignore these bits 48:51. =20

---
=C2=A0arch/powerpc/kernel/cputable.c | 4 ++-- =C2=A01 file changed, 2 insertions(+), 2 deletions(-)

Quoted 6 lines
Quoted 2 lines

=20
Presumably we should backport this?

Actually, we need to scrap this patch.

Looks like the scale up version will be marked as DD1, but it won't need =

these

Quoted 1 line

workarounds. So we need it to match on the other POWER9 entry.

OK.

/giphy "dumpster fire"

cheers