Skip to content

Commit b7131ee

Browse files
Christoph Hellwigaxboe
Christoph Hellwig
authored andcommitted
blk-cgroup: fix a hd_struct leak in blkcg_fill_root_iostats
disk_get_part needs to be paired with a disk_put_part. Cc: [email protected] Fixes: ef45fe4 ("blk-cgroup: show global disk stats in root cgroup io.stat") Signed-off-by: Christoph Hellwig <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
1 parent 9f16a66 commit b7131ee

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

block/blk-cgroup.c

+1
Original file line numberDiff line numberDiff line change
@@ -849,6 +849,7 @@ static void blkcg_fill_root_iostats(void)
849849
blkg_iostat_set(&blkg->iostat.cur, &tmp);
850850
u64_stats_update_end(&blkg->iostat.sync);
851851
}
852+
disk_put_part(part);
852853
}
853854
}
854855

0 commit comments

Comments
 (0)