]> git.baikalelectronics.ru Git - kernel.git/commit
blkcg: don't offline parent blkcg first
authorTejun Heo <tj@kernel.org>
Wed, 24 Jul 2019 17:37:55 +0000 (10:37 -0700)
committerJens Axboe <axboe@kernel.dk>
Wed, 1 Apr 2020 20:56:44 +0000 (14:56 -0600)
commitb873c077e66a8b3fc1e8d537c8469d6b3ab1c12d
treea6617ca3addbb90cc2be00a78a8d22e3da725d48
parent52dc78b4d394b3d4b94ea679e9722c3f192f0005
blkcg: don't offline parent blkcg first

blkcg->cgwb_refcnt is used to delay blkcg offlining so that blkgs
don't get offlined while there are active cgwbs on them.  However, it
ends up making offlining unordered sometimes causing parents to be
offlined before children.

Let's fix this by making child blkcgs pin the parents' online states.

Note that pin/unpin names are chosen over get/put intentionally
because css uses get/put online for something different.

Signed-off-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-cgroup.c
include/linux/blk-cgroup.h