mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-21 14:21:48 +00:00
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>
This commit is contained in:
parent
cb4d2b3f03
commit
ad5b177bd7
3 changed files with 9 additions and 1 deletions
|
@ -56,6 +56,7 @@ struct bpf_map {
|
|||
struct work_struct work;
|
||||
atomic_t usercnt;
|
||||
struct bpf_map *inner_map_meta;
|
||||
u8 name[BPF_OBJ_NAME_LEN];
|
||||
};
|
||||
|
||||
/* function argument constraints */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue