Commit 622dc5ad authored by David S. Miller's avatar David S. Miller

Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next

Daniel Borkmann says:

====================
pull-request: bpf-next 2019-11-26

The following pull-request contains BPF updates for your *net-next* tree.

We've added 2 non-merge commits during the last 1 day(s) which contain
a total of 2 files changed, 14 insertions(+), 3 deletions(-).

The main changes, 2 small fixes are:

1) Fix libbpf out of tree compilation which complained about unknown u32
   type used in libbpf_find_vmlinux_btf_id() which needs to be __u32 instead,
   from Andrii Nakryiko.

2) Follow-up fix for the prior BPF mmap series where kbuild bot complained
   about missing vmalloc_user_node_flags() for no-MMU, also from Andrii Nakryiko.
====================
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents adf6f8cb b615e5a1
......@@ -155,11 +155,11 @@ void *__vmalloc_node_flags(unsigned long size, int node, gfp_t flags)
return __vmalloc(size, flags, PAGE_KERNEL);
}
void *vmalloc_user(unsigned long size)
static void *__vmalloc_user_flags(unsigned long size, gfp_t flags)
{
void *ret;
ret = __vmalloc(size, GFP_KERNEL | __GFP_ZERO, PAGE_KERNEL);
ret = __vmalloc(size, flags, PAGE_KERNEL);
if (ret) {
struct vm_area_struct *vma;
......@@ -172,8 +172,19 @@ void *vmalloc_user(unsigned long size)
return ret;
}
void *vmalloc_user(unsigned long size)
{
return __vmalloc_user_flags(size, GFP_KERNEL | __GFP_ZERO);
}
EXPORT_SYMBOL(vmalloc_user);
void *vmalloc_user_node_flags(unsigned long size, int node, gfp_t flags)
{
return __vmalloc_user_flags(size, flags | __GFP_ZERO);
}
EXPORT_SYMBOL(vmalloc_user_node_flags);
struct page *vmalloc_to_page(const void *addr)
{
return virt_to_page(addr);
......
......@@ -5128,7 +5128,7 @@ int libbpf_find_vmlinux_btf_id(const char *name,
char *dst = raw_tp_btf + sizeof(BTF_PREFIX) - 1;
const char *btf_name;
int err = -EINVAL;
u32 kind;
__u32 kind;
if (IS_ERR(btf)) {
pr_warn("vmlinux BTF is not found\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment