summaryrefslogtreecommitdiff
path: root/include/linux/blk-mq.h
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2022-08-06 01:39:04 +0300
committerJens Axboe <axboe@kernel.dk>2022-08-22 19:07:56 +0300
commitf5d632d15e9e0a037339601680d82bb840f85d10 (patch)
tree9b13ba0fcdf8da7c7fdd6a93e072517cd79d5b6e /include/linux/blk-mq.h
parentd322f355e9368045ff89b7a3df9324fe0c33839b (diff)
downloadlinux-f5d632d15e9e0a037339601680d82bb840f85d10.tar.xz
block: shrink rq_map_data a bit
We don't need full ints for several of these members. Change the page_order and nr_entries to unsigned shorts, and the true/false from_user and null_mapped to booleans. This shrinks the struct from 32 to 24 bytes on 64-bit archs. Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux/blk-mq.h')
-rw-r--r--include/linux/blk-mq.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/linux/blk-mq.h b/include/linux/blk-mq.h
index c38575209d51..74b99d716b0b 100644
--- a/include/linux/blk-mq.h
+++ b/include/linux/blk-mq.h
@@ -963,11 +963,11 @@ blk_status_t blk_insert_cloned_request(struct request *rq);
struct rq_map_data {
struct page **pages;
- int page_order;
- int nr_entries;
unsigned long offset;
- int null_mapped;
- int from_user;
+ unsigned short page_order;
+ unsigned short nr_entries;
+ bool null_mapped;
+ bool from_user;
};
int blk_rq_map_user(struct request_queue *, struct request *,