[dm-devel] [PATCH] block: remove redundant blk-cgroup init from __bio_clone

Christoph Hellwig hch at infradead.org
Tue Apr 12 05:27:54 UTC 2022


On Mon, Apr 11, 2022 at 01:33:58PM -0400, Mike Snitzer wrote:
> When bio_{alloc,init}_clone are passed a bdev, bio_init() will call
> bio_associate_blkg() so the __bio_clone() work to initialize blkcg
> isn't needed.

No, unfortunately it isn't as simple as that.  There are bios that do
not use the default cgroup and thus blkg, e.g. those that come from
cgroup writeback.



More information about the dm-devel mailing list