linux-stable/kernel/cgroup
Waiman Long 292fd843de cgroup/cpuset: Fix partition root's cpuset.cpus update bug
It was found that commit 7a2127e66a ("cpuset: Call
set_cpus_allowed_ptr() with appropriate mask for task") introduced a bug
that corrupted "cpuset.cpus" of a partition root when it was updated.

It is because the tmp->new_cpus field of the passed tmp parameter
of update_parent_subparts_cpumask() should not be used at all as
it contains important cpumask data that should not be overwritten.
Fix it by using tmp->addmask instead.

Also update update_cpumask() to make sure that trialcs->cpu_allowed
will not be corrupted until it is no longer needed.

Fixes: 7a2127e66a ("cpuset: Call set_cpus_allowed_ptr() with appropriate mask for task")
Signed-off-by: Waiman Long <longman@redhat.com>
Cc: stable@vger.kernel.org # v6.2+
Signed-off-by: Tejun Heo <tj@kernel.org>
2023-03-29 08:37:07 -10:00
..
cgroup-internal.h memcg: fix possible use-after-free in memcg_write_event_control() 2022-12-09 18:41:17 -08:00
cgroup-v1.c cgroup: Use cgroup_attach_{lock,unlock}() from cgroup_attach_task_all() 2022-08-26 11:14:34 -10:00
cgroup.c fs: port ->permission() to pass mnt_idmap 2023-01-19 09:24:28 +01:00
cpuset.c cgroup/cpuset: Fix partition root's cpuset.cpus update bug 2023-03-29 08:37:07 -10:00
debug.c
freezer.c cgroup: cleanup comments 2022-03-13 19:19:27 -10:00
legacy_freezer.c freezer,sched: Rewrite core freezer logic 2022-09-07 21:53:50 +02:00
Makefile
misc.c misc_cgroup: remove error log to avoid log flood 2021-09-20 07:35:38 -10:00
namespace.c memcg: enable accounting for new namesapces and struct nsproxy 2021-09-03 09:58:12 -07:00
pids.c cgroup: add pids.peak interface for pids controller 2022-09-04 09:26:51 -10:00
rdma.c cgroup: fix spelling mistakes 2021-05-24 12:45:26 -04:00
rstat.c cgroup: fix display of forceidle time at root 2023-03-17 12:19:15 -10:00