diff options
author | Ming Lei <ming.lei@redhat.com> | 2020-10-01 18:48:42 +0300 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2020-10-06 16:29:36 +0300 |
commit | 0549e87c30ae0d43d7e10424f2222bcd8bbe986d (patch) | |
tree | b137a09643eda68a1905de9938b7837665820f2c /include/linux/blkdev.h | |
parent | 2b0d3d3e4fcfb19d10f9a82910b8f0f05c56ee3e (diff) | |
download | linux-0549e87c30ae0d43d7e10424f2222bcd8bbe986d.tar.xz |
block: move 'q_usage_counter' into front of 'request_queue'
The field of 'q_usage_counter' is always fetched in fast path of every
block driver, and move it into front of 'request_queue', so it can be
fetched into 1st cacheline of 'request_queue' instance.
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Tested-by: Veronika Kabatova <vkabatov@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Cc: Sagi Grimberg <sagi@grimberg.me>
Cc: Tejun Heo <tj@kernel.org>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Jens Axboe <axboe@kernel.dk>
Cc: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux/blkdev.h')
-rw-r--r-- | include/linux/blkdev.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index cf80e61b4c5e..5fc940423e5a 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -397,6 +397,8 @@ struct request_queue { struct request *last_merge; struct elevator_queue *elevator; + struct percpu_ref q_usage_counter; + struct blk_queue_stats *stats; struct rq_qos *rq_qos; @@ -569,7 +571,6 @@ struct request_queue { * percpu_ref_kill() and percpu_ref_reinit(). */ struct mutex mq_freeze_lock; - struct percpu_ref q_usage_counter; struct blk_mq_tag_set *tag_set; struct list_head tag_set_list; |