[PATCH v5 4/8] RAS/AMD/ATL: Match AMD CPUs only

From: Lin Wang

Date: Thu Sep 10 2026 - 04:47:12 EST


The ATL CPU table matches Hygon through X86_FEATURE_SMCA and
X86_FEATURE_ZEN, but the library obtains its node count and F4 devices
from the AMD northbridge cache. That cache maps dense node indices to
fixed PCI slots. Hygon PCI slots do not encode node identity, and CPU
NodeIds are sparse across sockets. The cache therefore cannot represent
the Hygon topology or provide ATL with a valid node-to-F4 mapping.

A failed fixed-slot F3 lookup leaves the cache empty, so amd_atl_init()
exits at its amd_nb_num() check.

Limit both feature matches to AMD. Hygon address translation requires
the Hygon node interfaces and will be added separately.

Signed-off-by: Lin Wang <wanglin@xxxxxxxxxxxxxx>
---
drivers/ras/amd/atl/core.c | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/drivers/ras/amd/atl/core.c b/drivers/ras/amd/atl/core.c
index d77dacdd4f56..fe84fc52c657 100644
--- a/drivers/ras/amd/atl/core.c
+++ b/drivers/ras/amd/atl/core.c
@@ -176,18 +176,17 @@ static void check_for_legacy_df_access(void)
}

/*
- * This library provides functionality for AMD-based systems with a Data Fabric.
+ * This library provides functionality for AMD systems with a Data Fabric.
* The set of systems with a Data Fabric is equivalent to the set of Zen-based systems
* and the set of systems with the Scalable MCA feature at this time. However, these
* are technically independent things.
*
* It's possible to match on the PCI IDs of the Data Fabric devices, but this will be
- * an ever expanding list. Instead, match on the SMCA and Zen features to cover all
- * relevant systems.
+ * an ever expanding list. Instead, match AMD CPUs with the SMCA and Zen features.
*/
static const struct x86_cpu_id amd_atl_cpuids[] = {
- X86_MATCH_FEATURE(X86_FEATURE_SMCA, NULL),
- X86_MATCH_FEATURE(X86_FEATURE_ZEN, NULL),
+ X86_MATCH_VENDOR_FEATURE(AMD, X86_FEATURE_SMCA, NULL),
+ X86_MATCH_VENDOR_FEATURE(AMD, X86_FEATURE_ZEN, NULL),
{ }
};

--
2.43.0