]> git.ipfire.org Git - thirdparty/linux.git/commit
x86/cacheinfo: Standardize _cpuid4_info_regs instance naming
authorAhmed S. Darwish <darwi@linutronix.de>
Mon, 24 Mar 2025 13:33:05 +0000 (14:33 +0100)
committerIngo Molnar <mingo@kernel.org>
Tue, 25 Mar 2025 09:22:29 +0000 (10:22 +0100)
commit1374ff60ed0d4cedd55f653edd3f59f9f19c4171
treea11bb229b945b13b23364496d5d5ed553757a70d
parent036a73b5174477b72d881b4c75740d3dbfd7ec49
x86/cacheinfo: Standardize _cpuid4_info_regs instance naming

The cacheinfo code frequently uses the output registers from CPUID leaf
0x4.  Such registers are cached in 'struct _cpuid4_info_regs', augmented
with related information, and are then passed across functions.

The naming of these _cpuid4_info_regs instances is confusing at best.

Some instances are called "this_leaf", which is vague as "this" lacks
context and "leaf" is overly generic given that other CPUID leaves are
also processed within cacheinfo.  Other _cpuid4_info_regs instances are
just called "base", adding further ambiguity.

Standardize on id4 for all instances.

Signed-off-by: Ahmed S. Darwish <darwi@linutronix.de>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: https://lore.kernel.org/r/20250324133324.23458-11-darwi@linutronix.de
arch/x86/kernel/cpu/cacheinfo.c