add kvmalloc alloc_size attribute

Signed-off-by: Daniel Micay <danielmicay@gmail.com>
Signed-off-by: anupritaisno1 <www.anuprita804@gmail.com>
This commit is contained in:
Daniel Micay 2017-07-04 00:51:33 -04:00 committed by Kreciorek
parent 4816ac7943
commit 11c4ea478b

View file

@ -816,7 +816,7 @@ static inline int is_vmalloc_or_module_addr(const void *x)
}
#endif
extern void *kvmalloc_node(size_t size, gfp_t flags, int node);
extern void *kvmalloc_node(size_t size, gfp_t flags, int node) __attribute__((alloc_size(1)));
static inline void *kvmalloc(size_t size, gfp_t flags)
{
return kvmalloc_node(size, flags, NUMA_NO_NODE);