lkml.org 
[lkml]   [2020]   [Dec]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/2] workqueue: Fix affinity of kworkers attached during late hotplug
On Fri, Dec 11, 2020 at 11:39:21AM +0000, Vincent Donnefort wrote:
> On Thu, Dec 10, 2020 at 04:38:30PM +0000, Valentin Schneider wrote:
> > + if (pool->flags & POOL_DISASSOCIATED) {
> > worker->flags |= WORKER_UNBOUND;
> > + set_cpus_allowed_ptr(worker->task, cpu_active_mask);
> > + } else {
> > + /*
> > + * set_cpus_allowed_ptr() will fail if the cpumask doesn't have any
> > + * online CPUs. It'll be re-applied when any of the CPUs come up.
> > + */
>
> Does this comment still stand ? IIUC, we should always be in the
> POOL_DISASSOCIATED case if the CPU from cpumask is offline. Unless a
> pool->attrs->cpumask can have several CPUs. In that case maybe we should check
> for the cpu_active_mask here too ?

IIUC it can be a numa mask, and would still be valid in that case.

> > + set_cpus_allowed_ptr(worker->task, pool->attrs->cpumask);
> > + }

\
 
 \ /
  Last update: 2020-12-11 13:55    [W:0.070 / U:0.472 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site