aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndre Silva <andasilv@amd.com>2026-07-28 14:48:37 +0000
committerMitchell Horne <mhorne@FreeBSD.org>2026-07-28 14:53:33 +0000
commit77404ee1e99d502345a1f9356b05c09abfbde831 (patch)
treeda2b4bfa73f642defa2ed4232231b39744be02e2
parentcac0eab342c702dc73e566e2038208c0bbc8fbd3 (diff)
x86: add AMD RAPL MSR definitions to specialreg.h
specialreg.h is the tree's MSR registry and already carries the Intel RAPL group. Add the AMD RAPL package/core energy and unit MSRs here so the hwpmc RAPL class can reference them without a private driver copy. Use the names Linux's msr-index.h gives these registers. Reviewed by: mhorne, adrian, Ali Mashtizadeh <ali@mashtizadeh.com> MFC after: 3 days Sponsored by: AMD Differential Revision: https://reviews.freebsd.org/D58027
-rw-r--r--sys/x86/include/specialreg.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/x86/include/specialreg.h b/sys/x86/include/specialreg.h
index f5ca0b8415bb..f201725920bd 100644
--- a/sys/x86/include/specialreg.h
+++ b/sys/x86/include/specialreg.h
@@ -1272,6 +1272,9 @@
#define MSR_SMM_MASK 0xc0010113 /* SMM TSEG address mask */
#define MSR_VM_CR 0xc0010114 /* SVM: feature control */
#define MSR_VM_HSAVE_PA 0xc0010117 /* SVM: host save area address */
+#define MSR_AMD_RAPL_POWER_UNIT 0xc0010299 /* RAPL unit shifts */
+#define MSR_AMD_CORE_ENERGY_STATUS 0xc001029a /* RAPL per-core energy */
+#define MSR_AMD_PKG_ENERGY_STATUS 0xc001029b /* RAPL package energy */
#define MSR_AMD_CPUID07 0xc0011002 /* CPUID 07 %ebx override */
#define MSR_AMD_CPUID01 0xc0011004 /* CPUID 01 %ecx override */
#define MSR_EXTFEATURES 0xc0011005 /* Extended CPUID Features override */