[PATCH v18 09/17] x86/resctrl: Add new fields to struct rmid_read for summation of domains
From: Tony Luck
Date: Wed May 15 2024 - 18:25:01 EST
rdtgroup_mondata_show() calls mon_event_count() which packages up all
the required details into an rmid_read structure passed across the
smp_call*() infrastructure.
Legacy files reporting for a single domain pass that domain in the
rmid_read structure. Files that need to sum multiple domains have
meta data that provides the display_id for domains that must be
summed.
Add the sumdomains and display_id fields to the rmid_read structure.
Signed-off-by: Tony Luck <tony.luck@xxxxxxxxx>
---
arch/x86/kernel/cpu/resctrl/internal.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/arch/x86/kernel/cpu/resctrl/internal.h b/arch/x86/kernel/cpu/resctrl/internal.h
index 49440f194253..498c5d240c68 100644
--- a/arch/x86/kernel/cpu/resctrl/internal.h
+++ b/arch/x86/kernel/cpu/resctrl/internal.h
@@ -150,6 +150,8 @@ struct rmid_read {
struct rdt_mon_domain *d;
enum resctrl_event_id evtid;
bool first;
+ bool sumdomains;
+ int display_id;
int err;
u64 val;
void *arch_mon_ctx;
--
2.44.0