From d0b9e3a42ad28d89fc59f064d75819ab915b9bde Mon Sep 17 00:00:00 2001 From: Dave Hansen Date: Tue, 22 Sep 2026 20:42:10 -0700 Subject: [PATCH 10/75] x86/platform/uv: Remove unused hub class predicates is_uv_hub() ("is this any UV hub at all"), is_uvx_hub() (UV2/3/4) and is_uvy_hub() (UV5 and later) have no callers. Code that cares tests for a specific hub generation with is_uv2_hub() .. is_uv5_hub(), or asks is_uv_system()/is_uv_hubbed() about the platform rather than the hub. is_uv1_hub() is stranger still. UV1 support was removed in commit 9b9ee172410d ("x86/platform/uv: Remove support for uv1 platform from uv_hub") which deleted it, and then commit 647128f1536e ("x86/platform/uv: Update UV MMRs for UV5") reintroduced it hardcoded to return 0 while reworking the MMR accessors. It has had no callers either way. Remove all four. is_uv() itself and the UVX/UVY/UV_ANY masks stay - they are used directly by x2apic_uv_x.c and by the MMR accessors in uv_mmrs.h. No functional change intended. --- arch/x86/include/asm/uv/uv_hub.h | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/arch/x86/include/asm/uv/uv_hub.h b/arch/x86/include/asm/uv/uv_hub.h index 977b1d7393b58..93c7b057991cf 100644 --- a/arch/x86/include/asm/uv/uv_hub.h +++ b/arch/x86/include/asm/uv/uv_hub.h @@ -205,7 +205,6 @@ static inline __init void uv_hub_type_set(int uvmask) #define UV5_HUB_REVISION_BASE 9 static inline int is_uv(int uvmask) { return uv_hub_type() & uvmask; } -static inline int is_uv1_hub(void) { return 0; } static inline int is_uv2_hub(void) { return is_uv(UV2); } static inline int is_uv3_hub(void) { return is_uv(UV3); } static inline int is_uv4a_hub(void) { return is_uv(UV4A); } @@ -219,15 +218,6 @@ static inline int is_uv5_hub(void) { return is_uv(UV5); } * then test if is UV4. */ -/* UVX class: UV2,3,4 */ -static inline int is_uvx_hub(void) { return is_uv(UVX); } - -/* UVY class: UV5,..? */ -static inline int is_uvy_hub(void) { return is_uv(UVY); } - -/* Any UV Hubbed System */ -static inline int is_uv_hub(void) { return is_uv(UV_ANY); } - union uvh_apicid { unsigned long v; struct uvh_apicid_s { -- 2.43.0