ebpf: move read-only fields to bpf_prog and shrink bpf_prog_aux
is_gpl_compatible and prog_type should be moved directly into bpf_prog as they stay immutable during bpf_prog's lifetime, are core attributes and they can be locked as read-only later on via bpf_prog_select_runtime(). With a bit of rearranging, this also allows us to shrink bpf_prog_aux to exactly 1 cacheline. Signed-off-by:Daniel Borkmann <daniel@iogearbox.net> Acked-by:
Alexei Starovoitov <ast@plumgrid.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
Showing
- include/linux/bpf.h 1 addition, 3 deletionsinclude/linux/bpf.h
- include/linux/filter.h 3 additions, 1 deletioninclude/linux/filter.h
- kernel/bpf/syscall.c 3 additions, 4 deletionskernel/bpf/syscall.c
- kernel/bpf/verifier.c 2 additions, 2 deletionskernel/bpf/verifier.c
- net/core/filter.c 2 additions, 2 deletionsnet/core/filter.c
Loading
Please register or sign in to comment