cgroup: Prevent kill_css() from being called more than once
authorWaiman Long <longman@redhat.com>
Mon, 15 May 2017 13:34:06 +0000 (09:34 -0400)
committerTejun Heo <tj@kernel.org>
Wed, 17 May 2017 20:58:32 +0000 (16:58 -0400)
commit33c35aa4817864e056fd772230b0c6b552e36ea2
treec5eea540e4e818e11aa809d7652cface407203e7
parent2ea659a9ef488125eb46da6eb571de5eae5c43f6
cgroup: Prevent kill_css() from being called more than once

The kill_css() function may be called more than once under the condition
that the css was killed but not physically removed yet followed by the
removal of the cgroup that is hosting the css. This patch prevents any
harmm from being done when that happens.

Signed-off-by: Waiman Long <longman@redhat.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: stable@vger.kernel.org # v4.5+
include/linux/cgroup-defs.h
kernel/cgroup/cgroup.c