|
@@ -1388,16 +1388,16 @@ static int cpuset_can_attach(struct cgroup *cgrp, struct cgroup_taskset *tset)
|
|
|
|
|
|
cgroup_taskset_for_each(task, cgrp, tset) {
|
|
|
/*
|
|
|
- * Kthreads bound to specific cpus cannot be moved to a new
|
|
|
- * cpuset; we cannot change their cpu affinity and
|
|
|
- * isolating such threads by their set of allowed nodes is
|
|
|
- * unnecessary. Thus, cpusets are not applicable for such
|
|
|
- * threads. This prevents checking for success of
|
|
|
- * set_cpus_allowed_ptr() on all attached tasks before
|
|
|
- * cpus_allowed may be changed.
|
|
|
+ * Kthreads which disallow setaffinity shouldn't be moved
|
|
|
+ * to a new cpuset; we don't want to change their cpu
|
|
|
+ * affinity and isolating such threads by their set of
|
|
|
+ * allowed nodes is unnecessary. Thus, cpusets are not
|
|
|
+ * applicable for such threads. This prevents checking for
|
|
|
+ * success of set_cpus_allowed_ptr() on all attached tasks
|
|
|
+ * before cpus_allowed may be changed.
|
|
|
*/
|
|
|
ret = -EINVAL;
|
|
|
- if (task->flags & PF_THREAD_BOUND)
|
|
|
+ if (task->flags & PF_NO_SETAFFINITY)
|
|
|
goto out_unlock;
|
|
|
ret = security_task_setscheduler(task);
|
|
|
if (ret)
|