summaryrefslogtreecommitdiff
path: root/rust/helpers/build_bug.c
diff options
context:
space:
mode:
authorVlastimil Babka <vbabka@suse.cz>2024-02-23 21:27:18 +0300
committerVlastimil Babka <vbabka@suse.cz>2024-02-26 12:10:07 +0300
commitcc61eb851c9ae38546d7df6076fd883d3dbc322d (patch)
treea2103acc92def90e1de4f23de700f201e92a0bbb /rust/helpers/build_bug.c
parentcdeeaaba174886aa6c1ff4c0c5449c5066dbe82f (diff)
downloadlinux-cc61eb851c9ae38546d7df6076fd883d3dbc322d.tar.xz
mm, slab: use an enum to define SLAB_ cache creation flags
The values of SLAB_ cache creation flags are defined by hand, which is tedious and error-prone. Use an enum to assign the bit number and a __SLAB_FLAG_BIT() macro to #define the final flags. This renumbers the flag values, which is OK as they are only used internally. Also define a __SLAB_FLAG_UNUSED macro to assign value to flags disabled by their respective config options in a unified and sparse-friendly way. Reviewed-and-tested-by: Xiongwei Song <xiongwei.song@windriver.com> Reviewed-by: Chengming Zhou <chengming.zhou@linux.dev> Reviewed-by: Roman Gushchin <roman.gushchin@linux.dev> Acked-by: David Rientjes <rientjes@google.com> Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
Diffstat (limited to 'rust/helpers/build_bug.c')
0 files changed, 0 insertions, 0 deletions