Re: [PATCH bpf-next 0/1] use preserve_static_offset in bpf uapi headers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2023-12-08 at 09:46 -0800, Alexei Starovoitov wrote:
[...]
> > I just want to propose to have less work :-) since we are only dealing
> > with a few structs in bpf domain. Note that eventually generated
> > vmlinux.h will be the same whether we use 'hard code' approach or the
> > decl_tag approach. The difference is just how to do it: - dwarf/btf with
> > decl tag -> bpftool vmlinux.h gen, or - dwarf/btf without decl tag +
> > hardcoded bpf ctx info -> bpftool vmlinux.h gen If we intends to cover
> > all uapi data structures (to prevent unnecessary CORE relocation, esp.
> > for troublesome bitfield operations), hardcoded approach won't work and
> > we may have to go to decl tag approach.
> 
> +1 for simplicity of "hard code" approach.
> We've stopped adding new uapi "mirror" structs like __sk_buff long ago.
> The number of structs that need ctx rewrite will not increase.

Ok, I'll submit V2 with changes in libbpf/bpftool to emit
preserve_static_offset for predefined set of types.





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux