Re: [PATCH bpf-next 1/2] libbpf: stop enforcing kern_version, populate it for users

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

 



Alexei Starovoitov wrote:
> On 10/4/19 7:32 AM, Andrii Nakryiko wrote:
> >> If we are not going to validate the section should we also skip collect'ing it?
> > Well, if user supplied version, we will parse and use it to override
> > out prepopulated one, so in that sense we do have validation.
> > 
> > But I think it's fine just to drop it altogether. Will do in v3.
> > 
> 
> what about older kernel that still enforce it?
> May be populate it in bpf_attr while loading, but
> don't check it in elf from libbpf?

Yeah, guess I wasn't thinking clearly this morning. The way my BPF progs
are currently written we use the version section to populate the kver.
Easy enough to change though if we think its cleaner to use an attribute
to set it. Actually, seems better to pass via bpf_attr IMO because
currently we use defines to populate the version which is a bit ugly.



[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