mm-move-kvmalloc-related-functions-to-slabh.patch removed from -mm tree
The patch titled
Subject: mm: move kvmalloc-related functions to slab.h
has been removed from the -mm tree. Its filename was
mm-move-kvmalloc-related-functions-to-slabh.patch
This patch was dropped because it was merged into mainline or a subsystem tree
------------------------------------------------------
From: "Matthew Wilcox (Oracle)" <[email protected]>
Subject: mm: move kvmalloc-related functions to slab.h
Not all files in the kernel should include mm.h. Migrating callers from kmalloc to kvmalloc is easier if the kvmalloc functions are in slab.h.
[[email protected]: move the new kvrealloc() also]
[[email protected]: drivers/hwmon/occ/p9_sbe.c needs slab.h]
Signed-off-by Matthew Wilcox (Oracle) <[email protected]>
Acked-by Pekka Enberg <[email protected]>
Cc Christoph Lameter <[email protected]>
Cc David Rientjes <[email protected]>
Cc Joonsoo Kim <[email protected]>
Cc Vlastimil Babka <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
drivers/hwmon/occ/p9_sbe.c | 1 + drivers/of/kexec.c | 1 + include/linux/mm.h | 34 ---------------------------------- include/linux/slab.h | 34 ++++++++++++++++++++++++++++++++++ 4 files changed, 36 insertions(+), 34 deletions(-)
drivers/hwmon/occ/p9_sbe.c renamed from drivers/hwmon/occ/p9_sbe.c~mm-move-kvmalloc-related-functions-to-slabh +1 -0
@@ -3,6 +3,7 @@#include <linux/device.h> #include <linux/errno.h> +#include <linux/slab.h> #include <linux/fsi-occ.h> #include <linux/module.h> #include <linux/platform_device.h>
drivers/of/kexec.c renamed from drivers/of/kexec.c~mm-move-kvmalloc-related-functions-to-slabh +1 -0
@@ -16,6 +16,7 @@#include <linux/of.h> #include <linux/of_fdt.h> #include <linux/random.h> +#include <linux/slab.h> #include <linux/types.h> #define RNG_SEED_SIZE 128
include/linux/mm.h renamed from include/linux/mm.h~mm-move-kvmalloc-related-functions-to-slabh +0 -34
@@ -799,40 +799,6 @@ static inline int is_vmalloc_or_module_a }#endif -extern void *kvmalloc_node (size_t size,gfp_t flags,int node); -static inline void *kvmalloc (size_t size,gfp_t flags) -{ -return kvmalloc_node (size, flags,NUMA_NO_NODE ); -} -static inline void *kvzalloc_node (size_t size,gfp_t flags,int node) -{ -return kvmalloc_node (size, flags | __GFP_ZERO, node); -} -static inline void *kvzalloc (size_t size,gfp_t flags) -{ -return kvmalloc (size, flags | __GFP_ZERO); -} - -static inline void *kvmalloc_array (size_t n,size_t size,gfp_t flags) -{ -size_t bytes; - -if (unlikely (check_mul_overflow (n, size, &bytes))) -return NULL ; - -return kvmalloc (bytes, flags); -} - -static inline void *kvcalloc (size_t n,size_t size,gfp_t flags) -{ -return kvmalloc_array (n, size, flags | __GFP_ZERO); -} - -extern void *kvrealloc (const void *p,size_t oldsize,size_t newsize, -gfp_t flags); -extern void kvfree (const void *addr); -extern void kvfree_sensitive (const void *addr,size_t len); -static inline int head_compound_mapcount (struct page *head) {return atomic_read (compound_mapcount_ptr (head)) +1 ;
include/linux/slab.h renamed from include/linux/slab.h~mm-move-kvmalloc-related-functions-to-slabh +34 -0
@@ -732,6 +732,40 @@ static inline void *kzalloc_node(size_treturn kmalloc_node (size, flags | __GFP_ZERO, node); } +extern void *kvmalloc_node (size_t size,gfp_t flags,int node); +static inline void *kvmalloc (size_t size,gfp_t flags) +{ +return kvmalloc_node (size, flags,NUMA_NO_NODE ); +} +static inline void *kvzalloc_node (size_t size,gfp_t flags,int node) +{ +return kvmalloc_node (size, flags | __GFP_ZERO, node); +} +static inline void *kvzalloc (size_t size,gfp_t flags) +{ +return kvmalloc (size, flags | __GFP_ZERO); +} + +static inline void *kvmalloc_array (size_t n,size_t size,gfp_t flags) +{ +size_t bytes; + +if (unlikely (check_mul_overflow (n, size, &bytes))) +return NULL ; + +return kvmalloc (bytes, flags); +} + +static inline void *kvcalloc (size_t n,size_t size,gfp_t flags) +{ +return kvmalloc_array (n, size, flags | __GFP_ZERO); +} + +extern void *kvrealloc (const void *p,size_t oldsize,size_t newsize, +gfp_t flags); +extern void kvfree (const void *addr); +extern void kvfree_sensitive (const void *addr,size_t len); +unsigned int kmem_cache_size (struct kmem_cache *s);void __init kmem_cache_init_late (void );
_
Patches currently in -mm which might be from [email protected] are
hitting-bug_on-trap-in-read_pages-mm-optimise-put_pages_list.patch