Skip to content

Commit 81630e2

Browse files
Christoph Hellwigaxboe
authored andcommitted
blk-cgroup: remove the !bio->bi_blkg check in blkcg_bio_issue_check
This is purely a sanity check for grave programming errors. Remove it to simplify further work in this area. Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent 13c7863 commit 81630e2

1 file changed

Lines changed: 1 addition & 14 deletions

File tree

‎include/linux/blk-cgroup.h‎

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -543,24 +543,11 @@ static inline void blkcg_bio_issue_init(struct bio *bio)
543543
static inline bool blkcg_bio_issue_check(struct request_queue *q,
544544
struct bio *bio)
545545
{
546-
struct blkcg_gq *blkg;
546+
struct blkcg_gq *blkg = bio->bi_blkg;
547547
bool throtl = false;
548548

549549
rcu_read_lock();
550-
551-
if (!bio->bi_blkg) {
552-
char b[BDEVNAME_SIZE];
553-
554-
WARN_ONCE(1,
555-
"no blkg associated for bio on block-device: %s\n",
556-
bio_devname(bio, b));
557-
bio_associate_blkg(bio);
558-
}
559-
560-
blkg = bio->bi_blkg;
561-
562550
throtl = blk_throtl_bio(q, blkg, bio);
563-
564551
if (!throtl) {
565552
struct blkg_iostat_set *bis;
566553
int rwd, cpu;

0 commit comments

Comments
 (0)