diff options
Diffstat (limited to 'kern/kmem_i.h')
-rw-r--r-- | kern/kmem_i.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/kern/kmem_i.h b/kern/kmem_i.h index d4671e24..beae6c45 100644 --- a/kern/kmem_i.h +++ b/kern/kmem_i.h @@ -18,6 +18,7 @@ #ifndef _KERN_KMEM_I_H #define _KERN_KMEM_I_H +#include <stdalign.h> #include <stddef.h> #include <kern/list.h> @@ -30,13 +31,13 @@ * The flags member is a read-only CPU-local copy of the parent cache flags. */ struct kmem_cpu_pool { - struct mutex lock; + alignas(CPU_L1_SIZE) struct mutex lock; int flags; int size; int transfer_size; int nr_objs; void **array; -} __aligned(CPU_L1_SIZE); +}; /* * When a cache is created, its CPU pool type is determined from the buffer |