mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-20 08:22:39 +00:00
md/raid0: attach correct cgroup info in bio
The discard bio doesn't attach the original bio cgroup info. Normal bio is cloned, so is fine. Signed-off-by: Shaohua Li <shli@fb.com>
This commit is contained in:
parent
b5e0fff19b
commit
8a8e6f84ad
@ -2085,7 +2085,7 @@ void bio_clone_blkcg_association(struct bio *dst, struct bio *src)
|
|||||||
if (src->bi_css)
|
if (src->bi_css)
|
||||||
WARN_ON(bio_associate_blkcg(dst, src->bi_css));
|
WARN_ON(bio_associate_blkcg(dst, src->bi_css));
|
||||||
}
|
}
|
||||||
|
EXPORT_SYMBOL_GPL(bio_clone_blkcg_association);
|
||||||
#endif /* CONFIG_BLK_CGROUP */
|
#endif /* CONFIG_BLK_CGROUP */
|
||||||
|
|
||||||
static void __init biovec_init_slabs(void)
|
static void __init biovec_init_slabs(void)
|
||||||
|
@ -539,6 +539,7 @@ static void raid0_handle_discard(struct mddev *mddev, struct bio *bio)
|
|||||||
!discard_bio)
|
!discard_bio)
|
||||||
continue;
|
continue;
|
||||||
bio_chain(discard_bio, bio);
|
bio_chain(discard_bio, bio);
|
||||||
|
bio_clone_blkcg_association(discard_bio, bio);
|
||||||
if (mddev->gendisk)
|
if (mddev->gendisk)
|
||||||
trace_block_bio_remap(bdev_get_queue(rdev->bdev),
|
trace_block_bio_remap(bdev_get_queue(rdev->bdev),
|
||||||
discard_bio, disk_devt(mddev->gendisk),
|
discard_bio, disk_devt(mddev->gendisk),
|
||||||
|
Loading…
Reference in New Issue
Block a user