lkml.org 
[lkml]   [2024]   [Apr]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v1 04/31] x86/resctrl: Add helper for setting CPU default properties
From
Hi James,

On 3/21/2024 9:50 AM, James Morse wrote:

> --- a/arch/x86/kernel/cpu/resctrl/rdtgroup.c
> +++ b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
> @@ -3623,14 +3623,18 @@ static int rdtgroup_mkdir(struct kernfs_node *parent_kn, const char *name,
> static int rdtgroup_rmdir_mon(struct rdtgroup *rdtgrp, cpumask_var_t tmpmask)
> {
> struct rdtgroup *prdtgrp = rdtgrp->mon.parent;
> + u32 closid, rmid;
> int cpu;
>
> /* Give any tasks back to the parent group */
> rdt_move_group_tasks(rdtgrp, prdtgrp, tmpmask);
>
> /* Update per cpu rmid of the moved CPUs first */
> + closid = rdtgrp->closid;
> + rmid = prdtgrp->mon.rmid;
> for_each_cpu(cpu, &rdtgrp->cpu_mask)
> - per_cpu(pqr_state.default_rmid, cpu) = prdtgrp->mon.rmid;
> + resctrl_arch_set_cpu_default_closid_rmid(cpu, closid, rmid);
> +

While I understand that the CLOSIDs are the same, I do think it looks unexpected
for the CLOSID to be set to the CLOSID of the group being removed. Could this
be set to CLOSID of parent group instead?

Reinette

\
 
 \ /
  Last update: 2024-04-09 05:15    [W:0.693 / U:0.776 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site