]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
x86,fs/resctrl: Add architectural event pointer
authorTony Luck <tony.luck@intel.com>
Wed, 17 Dec 2025 17:21:05 +0000 (09:21 -0800)
committerBorislav Petkov (AMD) <bp@alien8.de>
Fri, 9 Jan 2026 15:37:08 +0000 (16:37 +0100)
commit8ccb1f8fa6a3dfde32cf33e7ded3558014e6cca2
tree47e34eb574904e77b8b8a620a545927994cad76d
parent8f6b6ad69b50bf16bb762ffafbfa44a4884f9a17
x86,fs/resctrl: Add architectural event pointer

The resctrl file system layer passes the domain, RMID, and event id to the
architecture to fetch an event counter.

Fetching a telemetry event counter requires additional information that is
private to the architecture, for example, the offset into MMIO space from
where the counter should be read.

Add mon_evt::arch_priv that architecture can use for any private data related
to the event. The resctrl filesystem initializes mon_evt::arch_priv when the
architecture enables the event and passes it back to architecture when needing
to fetch an event counter.

Suggested-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Reinette Chatre <reinette.chatre@intel.com>
Link: https://lore.kernel.org/20251217172121.12030-1-tony.luck@intel.com
arch/x86/kernel/cpu/resctrl/core.c
arch/x86/kernel/cpu/resctrl/monitor.c
fs/resctrl/internal.h
fs/resctrl/monitor.c
include/linux/resctrl.h