Re: [PATCH] fs/resctrl: Fix use-after-free in resctrl_offline_mon_domain()

From: Luck, Tony

Date: Wed May 06 2026 - 16:03:11 EST


Question?

> + if (!is_percpu_thread()) {
> + list_for_each_entry(d, &r->mon_domains, hdr.list) {
> + if (d->mbm_work_cpu == nr_cpu_ids)
> + mbm_setup_overflow_handler(d, MBM_OVERFLOW_INTERVAL, RESCTRL_PICK_ANY_CPU);

Should that "MBM_OVERFLOW_INTERVAL" be "0"? This worker is presumably
already slightly late because of the offline CPU overhead and time to
be picked up by another CPU. Maybe it should run right away on whatever
new CPU in the domain is picked?

> + }
> + goto out_unlock;
> + }
> +

-Tony