… > +++ b/arch/x86/kernel/cpu/resctrl/ctrlmondata.c … > @@ -609,12 +609,21 @@ int rdtgroup_mondata_show(struct seq_file *m, void *arg) … + if (resctrl_arch_get_abmc_enabled()) { + index = mon_event_config_index_get(evtid); + if (rdtgrp->mon.cntr_id[index] == MON_CNTR_UNSET) + seq_puts(m, "Unassigned\n"); + else + seq_puts(m, "Unavailable\n"); + } else { … I suggest to restrict the scope for the shown local variable to this if branch. How do you think about to apply a code variant like the following? int index = mon_event_config_index_get(evtid); seq_puts(m, (rdtgrp->mon.cntr_id[index] == MON_CNTR_UNSET ? "Unassigned\n" : "Unavailable\n") ); Regards, Markus