block: always attach cgroup info into bio
authorShaohua Li <shli@fb.com>
Wed, 12 Jul 2017 18:49:54 +0000 (11:49 -0700)
committerJens Axboe <axboe@kernel.dk>
Sat, 29 Jul 2017 15:00:03 +0000 (09:00 -0600)
commit007cc56b7eeca8848021bc43aca2b8607fbe5589
treed178bdf4a51e3a0b6b4b72341dd10b9aa3d299c4
parentca1136c99b66b1566781ff12ecddc635d570f932
block: always attach cgroup info into bio

blkcg_bio_issue_check() already gets blkcg for a BIO.
bio_associate_blkcg() uses a percpu refcounter, so it's a very cheap
operation. There is no point we don't attach the cgroup info into bio at
blkcg_bio_issue_check. This also makes blktrace outputs correct cgroup
info.

Acked-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Shaohua Li <shli@fb.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-throttle.c
include/linux/blk-cgroup.h