[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZhB1RrjyTDtbwMjZ@localhost.localdomain>
Date: Sat, 6 Apr 2024 00:03:50 +0200
From: Frederic Weisbecker <frederic@...nel.org>
To: Tejun Heo <tj@...nel.org>, Nick Piggin <npiggin@...il.com>
Cc: Oleg Nesterov <oleg@...hat.com>, Leonardo Bras <leobras@...hat.com>,
Thomas Gleixner <tglx@...utronix.de>,
Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Lai Jiangshan <jiangshanlai@...il.com>,
linux-kernel@...r.kernel.org, Junyao Zhao <junzhao@...hat.com>,
Chris von Recklinghausen <crecklin@...hat.com>
Subject: Re: [PATCH v2 1/1] wq: Avoid using isolated cpus' timers on
queue_delayed_work
Le Fri, Apr 05, 2024 at 05:38:54AM -1000, Tejun Heo a écrit :
> > > > > So it seems that we should fix housekeeping_setup() ? see the patch below.
> > > > >
> > > > > In any case the usage of cpu_present_mask doesn't look right to me.
> > > > >
> > > > > Oleg.
> > > > >
> > > > > --- a/kernel/sched/isolation.c
> > > > > +++ b/kernel/sched/isolation.c
> > > > > @@ -129,7 +154,7 @@ static int __init housekeeping_setup(char *str, unsigned long flags)
> > > > > cpumask_andnot(housekeeping_staging,
> > > > > cpu_possible_mask, non_housekeeping_mask);
> > > > >
> > > > > - if (!cpumask_intersects(cpu_present_mask, housekeeping_staging)) {
> > > > > + if (!cpumask_test_cpu(smp_processor_id(), housekeeping_staging)) {
> > > > > __cpumask_set_cpu(smp_processor_id(), housekeeping_staging);
> > > > > __cpumask_clear_cpu(smp_processor_id(), non_housekeeping_mask);
> > > > > if (!housekeeping.flags) {
>
> Ensuring the boot CPU always be a housekeeping CPU makes sense to me but I'm
> not very familiar with the housekeeping code. Frederic, what do you think?
I vote for reverting:
08ae95f4fd3b (nohz_full: Allow the boot CPU to be nohz_full)
And if that's not possible because there are actual users of it, then
the best we can do is to make housekeeping_any_cpu() return smp_processor_id()
if the housekeeping_mask() is empty. Or rather if the housekeeping_mask is
empty, return cpumask_of(smp_processor_id()).
Of course that's merely just a bandaid.
Thanks.
Powered by blists - more mailing lists