Skip to content

Commit 98e62da

Browse files
committed
Merge tag 'x86-cache-2021-06-28' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 resource control documentation fixes from Ingo Molnar: "Fix Docbook comments in the x86/resctrl code" * tag 'x86-cache-2021-06-28' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/resctrl: Fix kernel-doc in internal.h x86/resctrl: Fix kernel-doc in pseudo_lock.c
2 parents 1b98ed0 + fd2afa7 commit 98e62da

2 files changed

Lines changed: 22 additions & 9 deletions

File tree

arch/x86/kernel/cpu/resctrl/internal.h

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ DECLARE_STATIC_KEY_FALSE(rdt_mon_enable_key);
7070
* struct mon_evt - Entry in the event list of a resource
7171
* @evtid: event id
7272
* @name: name of the event
73+
* @list: entry in &rdt_resource->evt_list
7374
*/
7475
struct mon_evt {
7576
u32 evtid;
@@ -78,10 +79,13 @@ struct mon_evt {
7879
};
7980

8081
/**
81-
* struct mon_data_bits - Monitoring details for each event file
82-
* @rid: Resource id associated with the event file.
82+
* union mon_data_bits - Monitoring details for each event file
83+
* @priv: Used to store monitoring event data in @u
84+
* as kernfs private data
85+
* @rid: Resource id associated with the event file
8386
* @evtid: Event id associated with the event file
8487
* @domid: The domain to which the event file belongs
88+
* @u: Name of the bit fields struct
8589
*/
8690
union mon_data_bits {
8791
void *priv;
@@ -119,6 +123,7 @@ enum rdt_group_type {
119123
* @RDT_MODE_PSEUDO_LOCKSETUP: Resource group will be used for Pseudo-Locking
120124
* @RDT_MODE_PSEUDO_LOCKED: No sharing of this resource group's allocations
121125
* allowed AND the allocations are Cache Pseudo-Locked
126+
* @RDT_NUM_MODES: Total number of modes
122127
*
123128
* The mode of a resource group enables control over the allowed overlap
124129
* between allocations associated with different resource groups (classes
@@ -142,7 +147,7 @@ enum rdtgrp_mode {
142147

143148
/**
144149
* struct mongroup - store mon group's data in resctrl fs.
145-
* @mon_data_kn kernlfs node for the mon_data directory
150+
* @mon_data_kn: kernfs node for the mon_data directory
146151
* @parent: parent rdtgrp
147152
* @crdtgrp_list: child rdtgroup node list
148153
* @rmid: rmid for this rdtgroup
@@ -282,11 +287,11 @@ struct rftype {
282287
/**
283288
* struct mbm_state - status for each MBM counter in each domain
284289
* @chunks: Total data moved (multiply by rdt_group.mon_scale to get bytes)
285-
* @prev_msr Value of IA32_QM_CTR for this RMID last time we read it
290+
* @prev_msr: Value of IA32_QM_CTR for this RMID last time we read it
286291
* @prev_bw_msr:Value of previous IA32_QM_CTR for bandwidth counting
287-
* @prev_bw The most recent bandwidth in MBps
288-
* @delta_bw Difference between the current and previous bandwidth
289-
* @delta_comp Indicates whether to compute the delta_bw
292+
* @prev_bw: The most recent bandwidth in MBps
293+
* @delta_bw: Difference between the current and previous bandwidth
294+
* @delta_comp: Indicates whether to compute the delta_bw
290295
*/
291296
struct mbm_state {
292297
u64 chunks;
@@ -456,11 +461,13 @@ struct rdt_parse_data {
456461
* @data_width: Character width of data when displaying
457462
* @domains: All domains for this resource
458463
* @cache: Cache allocation related data
464+
* @membw: If the component has bandwidth controls, their properties.
459465
* @format_str: Per resource format string to show domain value
460466
* @parse_ctrlval: Per resource function pointer to parse control values
461467
* @evt_list: List of monitoring events
462468
* @num_rmid: Number of RMIDs available
463469
* @mon_scale: cqm counter * mon_scale = occupancy in bytes
470+
* @mbm_width: Monitor width, to detect and correct for overflow.
464471
* @fflags: flags to choose base and info files
465472
*/
466473
struct rdt_resource {

arch/x86/kernel/cpu/resctrl/pseudo_lock.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ static struct class *pseudo_lock_class;
4949

5050
/**
5151
* get_prefetch_disable_bits - prefetch disable bits of supported platforms
52+
* @void: It takes no parameters.
5253
*
5354
* Capture the list of platforms that have been validated to support
5455
* pseudo-locking. This includes testing to ensure pseudo-locked regions
@@ -162,7 +163,7 @@ static struct rdtgroup *region_find_by_minor(unsigned int minor)
162163
}
163164

164165
/**
165-
* pseudo_lock_pm_req - A power management QoS request list entry
166+
* struct pseudo_lock_pm_req - A power management QoS request list entry
166167
* @list: Entry within the @pm_reqs list for a pseudo-locked region
167168
* @req: PM QoS request
168169
*/
@@ -184,6 +185,7 @@ static void pseudo_lock_cstates_relax(struct pseudo_lock_region *plr)
184185

185186
/**
186187
* pseudo_lock_cstates_constrain - Restrict cores from entering C6
188+
* @plr: Pseudo-locked region
187189
*
188190
* To prevent the cache from being affected by power management entering
189191
* C6 has to be avoided. This is accomplished by requesting a latency
@@ -196,6 +198,8 @@ static void pseudo_lock_cstates_relax(struct pseudo_lock_region *plr)
196198
* the ACPI latencies need to be considered while keeping in mind that C2
197199
* may be set to map to deeper sleep states. In this case the latency
198200
* requirement needs to prevent entering C2 also.
201+
*
202+
* Return: 0 on success, <0 on failure
199203
*/
200204
static int pseudo_lock_cstates_constrain(struct pseudo_lock_region *plr)
201205
{
@@ -520,7 +524,7 @@ static int pseudo_lock_fn(void *_rdtgrp)
520524

521525
/**
522526
* rdtgroup_monitor_in_progress - Test if monitoring in progress
523-
* @r: resource group being queried
527+
* @rdtgrp: resource group being queried
524528
*
525529
* Return: 1 if monitor groups have been created for this resource
526530
* group, 0 otherwise.
@@ -1140,6 +1144,8 @@ static int measure_l3_residency(void *_plr)
11401144

11411145
/**
11421146
* pseudo_lock_measure_cycles - Trigger latency measure to pseudo-locked region
1147+
* @rdtgrp: Resource group to which the pseudo-locked region belongs.
1148+
* @sel: Selector of which measurement to perform on a pseudo-locked region.
11431149
*
11441150
* The measurement of latency to access a pseudo-locked region should be
11451151
* done from a cpu that is associated with that pseudo-locked region.

0 commit comments

Comments
 (0)