diff options
-rw-r--r-- | include/linux/memory.h | 6 | ||||
-rw-r--r-- | mm/slub.c | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/include/linux/memory.h b/include/linux/memory.h index f80e0e331cb7..39628dfe4a4c 100644 --- a/include/linux/memory.h +++ b/include/linux/memory.h | |||
@@ -53,6 +53,12 @@ struct memory_notify { | |||
53 | struct notifier_block; | 53 | struct notifier_block; |
54 | struct mem_section; | 54 | struct mem_section; |
55 | 55 | ||
56 | /* | ||
57 | * Priorities for the hotplug memory callback routines (stored in decreasing | ||
58 | * order in the callback chain) | ||
59 | */ | ||
60 | #define SLAB_CALLBACK_PRI 1 | ||
61 | |||
56 | #ifndef CONFIG_MEMORY_HOTPLUG_SPARSE | 62 | #ifndef CONFIG_MEMORY_HOTPLUG_SPARSE |
57 | static inline int memory_dev_init(void) | 63 | static inline int memory_dev_init(void) |
58 | { | 64 | { |
@@ -2978,7 +2978,7 @@ void __init kmem_cache_init(void) | |||
2978 | kmalloc_caches[0].refcount = -1; | 2978 | kmalloc_caches[0].refcount = -1; |
2979 | caches++; | 2979 | caches++; |
2980 | 2980 | ||
2981 | hotplug_memory_notifier(slab_memory_callback, 1); | 2981 | hotplug_memory_notifier(slab_memory_callback, SLAB_CALLBACK_PRI); |
2982 | #endif | 2982 | #endif |
2983 | 2983 | ||
2984 | /* Able to allocate the per node structures */ | 2984 | /* Able to allocate the per node structures */ |