[PATCH v12 07/25] x86/resctrl: Update special case for Intel Haswell enumeration
From: Tony Luck
Date: Wed Sep 16 2026 - 19:15:49 EST
Certain Intel Haswell CPUs have support for resctrl L3 cache allocation
but do not enumerate the feature. There is a quirk to check for support
and provide hard-coded parameters. This quirk sets rdt_alloc_capable
to indicate to get_rdt_alloc_resources() that normal enumeration is
not needed.
Drop setting of rdt_alloc_capable in cache_alloc_hsw_probe() in
preparation for removal of this global variable.
Signed-off-by: Tony Luck <tony.luck@xxxxxxxxx>
---
v12:
Remove the new hsw_alloc_capable variable.
---
arch/x86/kernel/cpu/resctrl/core.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/arch/x86/kernel/cpu/resctrl/core.c b/arch/x86/kernel/cpu/resctrl/core.c
index f0cfb37482d3..f2bf160d01c1 100644
--- a/arch/x86/kernel/cpu/resctrl/core.c
+++ b/arch/x86/kernel/cpu/resctrl/core.c
@@ -177,8 +177,6 @@ static inline void cache_alloc_hsw_probe(void)
r->cache.min_cbm_bits = 2;
r->cache.arch_has_sparse_bitmasks = false;
r->alloc_capable = true;
-
- rdt_alloc_capable = true;
}
/*
@@ -930,7 +928,11 @@ static __init bool get_rdt_alloc_resources(void)
struct rdt_resource *r;
bool ret = false;
- if (rdt_alloc_capable)
+ /*
+ * On Haswell systems cache_alloc_hsw_probe() already marked
+ * RDT_RESOURCE_L3 as alloc_capable. No further enumeration is needed.
+ */
+ if (resctrl_alloc_capable())
return true;
if (!boot_cpu_has(X86_FEATURE_RDT_A))
--
2.55.0