Skip to content

Commit

Permalink
block: reorder cfq_queue to save space on 64bit builds
Browse files Browse the repository at this point in the history
saves 8 bytes of padding & increases objects/slab from 30 to 32 on my
AMD64 config

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 May 28, 2008
1 parent 05caf8d commit be754d2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions block/cfq-iosched.c
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@ struct cfq_data {
struct cfq_queue {
/* reference count */
atomic_t ref;
/* various state flags, see below */
unsigned int flags;
/* parent cfq_data */
struct cfq_data *cfqd;
/* service_tree member */
Expand All @@ -138,23 +140,21 @@ struct cfq_queue {
int queued[2];
/* currently allocated requests */
int allocated[2];
/* pending metadata requests */
int meta_pending;
/* fifo list of requests in sort_list */
struct list_head fifo;

unsigned long slice_end;
long slice_resid;

/* pending metadata requests */
int meta_pending;
/* number of requests that are on the dispatch list or inside driver */
int dispatched;

/* io prio of this group */
unsigned short ioprio, org_ioprio;
unsigned short ioprio_class, org_ioprio_class;

/* various state flags, see below */
unsigned int flags;
};

enum cfqq_state_flags {
Expand Down

0 comments on commit be754d2

Please sign in to comment.