blkcg: remove bio->bi_css and instead use bio->bi_blkg
Prior patches ensured that any bio that interacts with a request_queue is properly associated with a blkg. This makes bio->bi_css unnecessary as blkg maintains a reference to blkcg already. This removes the bio field bi_css and transfers corresponding uses to access via bi_blkg. Signed-off-by: Dennis Zhou <dennis@kernel.org> Reviewed-by: Josef Bacik <josef@toxicpanda.com> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
@@ -498,7 +498,7 @@ do { \
|
||||
do { \
|
||||
(dst)->bi_disk = (src)->bi_disk; \
|
||||
(dst)->bi_partno = (src)->bi_partno; \
|
||||
bio_clone_blkcg_association(dst, src); \
|
||||
bio_clone_blkg_association(dst, src); \
|
||||
} while (0)
|
||||
|
||||
#define bio_dev(bio) \
|
||||
@@ -512,24 +512,21 @@ static inline void bio_associate_blkg_from_page(struct bio *bio,
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_BLK_CGROUP
|
||||
int bio_associate_blkcg(struct bio *bio, struct cgroup_subsys_state *blkcg_css);
|
||||
void bio_disassociate_blkg(struct bio *bio);
|
||||
void bio_associate_blkg(struct bio *bio);
|
||||
void bio_associate_blkg_from_css(struct bio *bio,
|
||||
struct cgroup_subsys_state *css);
|
||||
void bio_disassociate_task(struct bio *bio);
|
||||
void bio_clone_blkcg_association(struct bio *dst, struct bio *src);
|
||||
void bio_clone_blkg_association(struct bio *dst, struct bio *src);
|
||||
#else /* CONFIG_BLK_CGROUP */
|
||||
static inline int bio_associate_blkcg(struct bio *bio,
|
||||
struct cgroup_subsys_state *blkcg_css) { return 0; }
|
||||
static inline void bio_disassociate_blkg(struct bio *bio) { }
|
||||
static inline void bio_associate_blkg(struct bio *bio) { }
|
||||
static inline void bio_associate_blkg_from_css(struct bio *bio,
|
||||
struct cgroup_subsys_state *css)
|
||||
{ }
|
||||
static inline void bio_disassociate_task(struct bio *bio) { }
|
||||
static inline void bio_clone_blkcg_association(struct bio *dst,
|
||||
struct bio *src) { }
|
||||
static inline void bio_clone_blkg_association(struct bio *dst,
|
||||
struct bio *src) { }
|
||||
#endif /* CONFIG_BLK_CGROUP */
|
||||
|
||||
#ifdef CONFIG_HIGHMEM
|
||||
|
Reference in New Issue
Block a user