STRUCT MON_DATA(9)
π struct mon_data(9) π
okay so bestie, welcome to the kernel API manual β this one's about struct mon_data, and it's literally the monitoring details for each event file. that's it, that's the vibe. π
β¨ SYNOPSIS β¨
struct mon_data {
struct list_head list;
enum resctrl_res_level rid;
struct mon_evt *evt;
int domid;
bool sum;
};
look at her. five fields. absolute icon behavior. π
π§ Members π§
listβ she's a member of the globalmon_data_kn_priv_listlist. yes, the global one. main character energy fr fr. πridβ the resource id that's associated with the event file. that's her whole thing.evtβ the event structure associated with the event file. like, the event's event. iconic.domidβ okay so this one's got β¨rangeβ¨:- when
sumis zero, this is the domain that the event file belongs to. - when
sumis one, this is the id of the L3 cache that all the domains to be summed share.
- when
yes, same field, two totally different jobs. she's versatile. πΈ
sumβ set forRDT_RESOURCE_L3when the event must be summed across multiple domains. math girlie moment. π₯
π Description π
so the kernfs kn->priv field of monitoring event files points to this struct. that's the link-up. π¦
β οΈ lowkey important: readers and writers must hold rdtgroup_mutex. no exceptions, no shortcuts, no "it'll be fine." hold the mutex. periodt. π
π SEE ALSO π
- Kernel file
./fs/resctrl/internal.h cpumask_any_housekeeping(9)struct mon_evt(9)struct rmid_read(9)enum rdtgrp_mode(9)struct mongroup(9)struct rdtgroup(9)struct rftype(9)struct mbm_state(9)
π«Ά and that's the whole page bestie! this one came from ./fs/resctrl, dated October 2026 β so yeah, note the source and the date, and go be obsessed with your event files. ngl this struct ate. πβ¨π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms