Skip to contentSkip to conversation

Add PCI device IDs for family 17h, model 70h

PATCH In review Isaac Vaughn 2 participants 3 messages Sep 6, 2019 – Sep 7, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Add PCI device IDs for family 17h, model 70h

Add the new Family 17h Model 70h PCI IDs (device 18h functions 0 and 6) to the AMD64 EDAC module.

Cc Borislav Petkov <[email protected]> (maintainer:EDAC-AMD64)
Cc Mauro Carvalho Chehab <[email protected]> (supporter:EDAC-CORE)
Cc James Morse <[email protected]> (reviewer:EDAC-CORE)
Cc [email protected] (open list:EDAC-AMD64)
Cc [email protected] (open list)
---
 drivers/edac/amd64_edac.c | 13 +++++++++++++
 drivers/edac/amd64_edac.h |  3 +++
 2 files changed, 16 insertions(+)
drivers/edac/amd64_edac.c +13 -0
index 873437be86d9..a35c97f9100a 100644
@@ -2253,6 +2253,15 @@ static struct amd64_family_type family_types[] = {
 			.dbam_to_cs		= f17_base_addr_to_cs_size,
 		}
 	},
+	[F17_M70H_CPUS] = {
+		.ctl_name = "F17h_M70h",
+		.f0_id = PCI_DEVICE_ID_AMD_17H_M70H_DF_F0,
+		.f6_id = PCI_DEVICE_ID_AMD_17H_M70H_DF_F6,
+		.ops = {
+			.early_channel_count	= f17_early_channel_count,
+			.dbam_to_cs		= f17_base_addr_to_cs_size,
+		}
+	},
 };
 
 /*
@@ -3241,6 +3250,10 @@ static struct amd64_family_type *per_family_init(struct amd64_pvt *pvt)
 			fam_type = &family_types[F17_M30H_CPUS];
 			pvt->ops = &family_types[F17_M30H_CPUS].ops;
 			break;
+		} else if (pvt->model >= 0x70 && pvt->model <= 0x7f) {
+			fam_type = &family_types[F17_M70H_CPUS];
+			pvt->ops = &family_types[F17_M70H_CPUS].ops;
+			break;
 		}
 		/* fall through */
 	case 0x18:
drivers/edac/amd64_edac.h +3 -0
index 8f66472f7adc..1adf7ddbf744 100644
@@ -119,6 +119,8 @@
 #define PCI_DEVICE_ID_AMD_17H_M10H_DF_F6 0x15ee
 #define PCI_DEVICE_ID_AMD_17H_M30H_DF_F0 0x1490
 #define PCI_DEVICE_ID_AMD_17H_M30H_DF_F6 0x1496
+#define PCI_DEVICE_ID_AMD_17H_M70H_DF_F0 0x1440
+#define PCI_DEVICE_ID_AMD_17H_M70H_DF_F6 0x1446
 
 /*
  * Function 1 - Address Map
@@ -285,6 +287,7 @@ enum amd_families {
 	F17_CPUS,
 	F17_M10H_CPUS,
 	F17_M30H_CPUS,
+	F17_M70H_CPUS,
 	NUM_FAMILIES,
 };
 
Signature · 1 line
2.23.0
maintainer
#1 lore raw
Quoted 19 lines · Isaac Vaughn

Add the new Family 17h Model 70h PCI IDs (device 18h functions 0 and 6) to the AMD64 EDAC module.

Cc Borislav Petkov <[email protected]> (maintainer:EDAC-AMD64)
Cc Mauro Carvalho Chehab <[email protected]> (supporter:EDAC-CORE)
Cc James Morse <[email protected]> (reviewer:EDAC-CORE)
Cc [email protected] (open list:EDAC-AMD64)
Cc [email protected] (open list)
---
 drivers/edac/amd64_edac.c | 13 +++++++++++++
 drivers/edac/amd64_edac.h |  3 +++
 2 files changed, 16 insertions(+)
drivers/edac/amd64_edac.c +0 -0
index 873437be86d9..a35c97f9100a 100644

drivers/edac/amd64_edac.c static struct amd64_family_type family_types[] = { · line 2262

Quoted 10 lines
drivers/edac/amd64_edac.c +7 -0
@@ -2253,6 +2253,15 @@ static struct amd64_family_type family_types[] = {
 			.dbam_to_cs		= f17_base_addr_to_cs_size,
 		}
 	},
+	[F17_M70H_CPUS] = {
+		.ctl_name = "F17h_M70h",
+		.f0_id = PCI_DEVICE_ID_AMD_17H_M70H_DF_F0,
+		.f6_id = PCI_DEVICE_ID_AMD_17H_M70H_DF_F6,
+		.ops = {
+			.early_channel_count	= f17_early_channel_count,
+			.dbam_to_cs		= f17_base_addr_to_cs_size,

You still have f17_base_addr_to_cs_size here. If you'd built it against the branch I pointed you at:

https://git.kernel.org/pub/scm/linux/kernel/git/ras/ras.git/log/?h=edac-for-next

it would have failed.

Anyway, I fixed it up and applied it.

Thx.

Signature · 4 lines
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette
#2 lore raw
Quoted 33 lines
Quoted 19 lines

Add the new Family 17h Model 70h PCI IDs (device 18h functions 0 and 6) to the AMD64 EDAC module.

Cc Borislav Petkov <[email protected]> (maintainer:EDAC-AMD64)
Cc Mauro Carvalho Chehab <[email protected]> (supporter:EDAC-CORE)
Cc James Morse <[email protected]> (reviewer:EDAC-CORE)
Cc [email protected] (open list:EDAC-AMD64)
Cc [email protected] (open list)
---
 drivers/edac/amd64_edac.c | 13 +++++++++++++
 drivers/edac/amd64_edac.h |  3 +++
 2 files changed, 16 insertions(+)
drivers/edac/amd64_edac.c +0 -0
index 873437be86d9..a35c97f9100a 100644

drivers/edac/amd64_edac.c static struct amd64_family_type family_types[] = { · line 2262

Quoted 10 lines
drivers/edac/amd64_edac.c +7 -0
@@ -2253,6 +2253,15 @@ static struct amd64_family_type family_types[] = {
 			.dbam_to_cs		= f17_base_addr_to_cs_size,
 		}
 	},
+	[F17_M70H_CPUS] = {
+		.ctl_name = "F17h_M70h",
+		.f0_id = PCI_DEVICE_ID_AMD_17H_M70H_DF_F0,
+		.f6_id = PCI_DEVICE_ID_AMD_17H_M70H_DF_F6,
+		.ops = {
+			.early_channel_count	= f17_early_channel_count,
+			.dbam_to_cs		= f17_base_addr_to_cs_size,

You still have f17_base_addr_to_cs_size here. If you'd built it against the branch I pointed you at:

Quoted 13 lines

https://nam02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgit.kernel.org%2Fpub%2Fscm%2Flinux%2Fkernel%2Fgit%2Fras%2Fras.git%2Flog%2F%3Fh%3Dedac-for-next&amp;data=02%7C01%7Cisaac.vaughn%40Knights.ucf.edu%7Ca142cff36aab414087c608d733588d1f%7C5b16e18278b3412c919668342689eeb7%7C0%7C0%7C637034327751460625&amp;sdata=Ky1T%2F9tWeNYEDcLftxU%2FQyVeN0zbrmRIrH5fHF2Mz8s%3D&amp;reserved=0

it would have failed.

Anyway, I fixed it up and applied it.

Thx.

Signature · 4 lines
Regards/Gruss,
    Boris.

https://nam02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fpeople.kernel.org%2Ftglx%2Fnotes-about-netiquette&amp;data=02%7C01%7Cisaac.vaughn%40Knights.ucf.edu%7Ca142cff36aab414087c608d733588d1f%7C5b16e18278b3412c919668342689eeb7%7C0%7C0%7C637034327751460625&amp;sdata=mOi8dnvpzomUvfX4FAabgA5G0A8tr3bMcbUx%2BKB91r8%3D&amp;reserved=0

Sorry about that, I didn't follow that edac-for-next was a branch and built against ras master.

Thanks again for all the help.

Sincerely,
Isaac Vaughn