Skip to content

Commit

Permalink
maple_tree: shrink struct maple_tree
Browse files Browse the repository at this point in the history
Pack the members of struct maple_tree to avoid holes on 64-bit.  The size
shrinks from 24 to 16 bytes which will save eight bytes in every structure
which embeds it.

[willy@infradead.org: changelog alterations]
Link: https://lkml.kernel.org/r/20230821225145.2169848-1-mjguzik@gmail.com
Signed-off-by: Mateusz Guzik <mjguzik@gmail.com>
Reviewed-by: Liam R. Howlett <Liam.Howlett@oracle.com>
Reviewed-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
  • Loading branch information
Mateusz Guzik authored and Andrew Morton committed Aug 24, 2023
1 parent 432af5c commit 52ae298
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/linux/maple_tree.h
Original file line number Diff line number Diff line change
Expand Up @@ -220,8 +220,8 @@ struct maple_tree {
spinlock_t ma_lock;
lockdep_map_p ma_external_lock;
};
void __rcu *ma_root;
unsigned int ma_flags;
void __rcu *ma_root;
};

/**
Expand Down

0 comments on commit 52ae298

Please sign in to comment.