bpf: Add map_name to bpf_map_info
authorMartin KaFai Lau <kafai@fb.com>
Wed, 27 Sep 2017 21:37:53 +0000 (14:37 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 29 Sep 2017 05:17:05 +0000 (06:17 +0100)
commitad5b177bd73f5107d97c36f56395c4281fb6f089
tree90f03bf2a9ce3370d0979524a10784bce7714042
parentcb4d2b3f03d8eed90be3a194e5b54b734ec4bbe9
bpf: Add map_name to bpf_map_info

This patch allows userspace to specify a name for a map
during BPF_MAP_CREATE.

The map's name can later be exported to user space
via BPF_OBJ_GET_INFO_BY_FD.

Signed-off-by: Martin KaFai Lau <kafai@fb.com>
Acked-by: Alexei Starovoitov <ast@fb.com>
Acked-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/bpf.h
include/uapi/linux/bpf.h
kernel/bpf/syscall.c