Re: [PATCH bpf-next 2/2] selftests/bpf: Add selftest for allow_ptr_leaks

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

 



On Wed, Aug 23, 2023 at 2:45 AM Eduard Zingerman <eddyz87@xxxxxxxxx> wrote:
>
> On Mon, 2023-08-21 at 15:45 -0700, Alexei Starovoitov wrote:
> [...]
> > > diff --git a/tools/testing/selftests/bpf/progs/test_tc_bpf.c b/tools/testing/selftests/bpf/progs/test_tc_bpf.c
> > > index d28ca8d..3e0f218 100644
> > > --- a/tools/testing/selftests/bpf/progs/test_tc_bpf.c
> > > +++ b/tools/testing/selftests/bpf/progs/test_tc_bpf.c
> > > @@ -1,5 +1,8 @@
> > >  // SPDX-License-Identifier: GPL-2.0
> > >
> > > +#include <linux/pkt_cls.h>
> > > +#include <linux/ip.h>
> > > +#include <linux/if_ether.h>
> >
> > Due to above it fails to compile:
> >
> > In file included from progs/test_tc_bpf.c:4:
> > In file included from /usr/include/linux/ip.h:21:
> > In file included from /usr/include/asm/byteorder.h:5:
> > In file included from /usr/include/linux/byteorder/little_endian.h:13:
> > /usr/include/linux/swab.h:136:8: error: unknown type name '__always_inline'
> >   136 | static __always_inline unsigned long __swab(const unsigned long y)
> >       |        ^
> >
>
> This is strange, I can compile it no problem. On my system:
> /usr/include/linux/swab.h includes /usr/include/linux/stddef.h
> which defines __always_inline.
>
> What distro are you using?

That was centos8.
dnf provides /usr/include/linux/swab.h
kernel-headers-6.4.3.x86_64 : Header files for the Linux kernel for use by glibc
Repo        : kernel
Matched from:
Filename    : /usr/include/linux/swab.h





[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