Re: [PATCH bpf] libbpf: set BTF FD for prog only when there is supported .BTF.ext data

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

 



On Thu, Aug 1, 2019 at 12:41 AM Andrii Nakryiko <andriin@xxxxxx> wrote:
>
> 5d01ab7bac46 ("libbpf: fix erroneous multi-closing of BTF FD")
> introduced backwards-compatibility issue, manifesting itself as -E2BIG
> error returned on program load due to unknown non-zero btf_fd attribute
> value for BPF_PROG_LOAD sys_bpf() sub-command.
>
> This patch fixes bug by ensuring that we only ever associate BTF FD with
> program if there is a BTF.ext data that was successfully loaded into
> kernel, which automatically means kernel supports func_info/line_info
> and associated BTF FD for progs (checked and ensured also by BTF
> sanitization code).
>
> Fixes: 5d01ab7bac46 ("libbpf: fix erroneous multi-closing of BTF FD")
> Reported-by: Andrey Ignatov <rdna@xxxxxx>
> Signed-off-by: Andrii Nakryiko <andriin@xxxxxx>

Applied. Thanks



[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