Skip to content

Commit

Permalink
block: reorder struct bio to remove padding on 64bit
Browse files Browse the repository at this point in the history
Remove 8 bytes of padding from struct bio which also removes 16 bytes from
struct bio_pair to make it 248 bytes.  bio_pair then fits into one fewer
cache lines & into a smaller slab.

Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
  • Loading branch information
Richard Kennedy authored and Jens Axboe committed Dec 29, 2008
1 parent 64d01dc commit ba744d5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion include/linux/bio.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,11 @@ struct bio {

unsigned int bi_comp_cpu; /* completion CPU */

atomic_t bi_cnt; /* pin count */

struct bio_vec *bi_io_vec; /* the actual vec list */

bio_end_io_t *bi_end_io;
atomic_t bi_cnt; /* pin count */

void *bi_private;
#if defined(CONFIG_BLK_DEV_INTEGRITY)
Expand Down

0 comments on commit ba744d5

Please sign in to comment.