mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-19 21:21:09 +00:00
blk-mq: initialize struct request fields individually
This allows us to avoid a non-atomic memset over ->atomic_flags as well as killing lots of duplicate initializations. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@fb.com>
This commit is contained in:
parent
9fccfed8f0
commit
af76e555e5
2 changed files with 49 additions and 5 deletions
|
@ -90,9 +90,10 @@ enum rq_cmd_type_bits {
|
|||
#define BLK_MAX_CDB 16
|
||||
|
||||
/*
|
||||
* try to put the fields that are referenced together in the same cacheline.
|
||||
* if you modify this structure, be sure to check block/blk-core.c:blk_rq_init()
|
||||
* as well!
|
||||
* Try to put the fields that are referenced together in the same cacheline.
|
||||
*
|
||||
* If you modify this structure, make sure to update blk_rq_init() and
|
||||
* especially blk_mq_rq_ctx_init() to take care of the added fields.
|
||||
*/
|
||||
struct request {
|
||||
struct list_head queuelist;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue