Re: [PATCH bpf-next] bpf: btf: restore resolve_mode when popping the resolve stack

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

 



On Mon, May 15, 2023 at 8:26 PM Daniel Borkmann <daniel@xxxxxxxxxxxxx> wrote:
>
> On 5/15/23 2:15 PM, Lorenz Bauer wrote:
> > In commit 9b459804ff99 ("btf: fix resolving BTF_KIND_VAR after ARRAY, STRUCT, UNION, PTR")
> > I fixed a bug that occurred during resolving of a DATASEC by strategically resetting
> > resolve_mode. This fixes the immediate bug but leaves us open to future bugs where
> > nested types have to be resolved.
>
> Lgtm, is there a way we could also craft a test case for this corner case?

There is a test for the datasec bug already, it went in with the
original patch. See commit dfdd608c3b36 ("selftests/bpf: check that
modifier resolves after pointer").

Not sure how to test this beyond that specific case.





[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