Re: Fwd: bpf syscall failing on aarch64 with "Invalid argument" (Asahi Linux on M1)

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

 



On Fri, Sep 30, 2022 at 1:01 AM Owayss Kabtoul <owayssk@xxxxxxxxx> wrote:
>
> Hello John.
>
> The "minimal" program in question is the one from:
> https://github.com/libbpf/libbpf-bootstrap/blob/bc186797086bee39769e3f24bcccf292a94cdcb7/examples/c/minimal.c
>

Please don't top-post in kernel mailing lists, reply inline instead.

>
> On Fri, Sep 30, 2022 at 4:11 AM John Fastabend <john.fastabend@xxxxxxxxx> wrote:
> >
> > Owayss Kabtoul wrote:
> > > Hello.
> > >
> > > I have built libbpf from source (a7c0f7e). When running any of the
> > > provided examples, the bpf syscall fails with "Invalid argument":
> > >
> > > ```
> > > $ sudo strace ./minimal
> >
> > Could you post the minimal C code. Its likely easier to read than
> > trying to parse the strace output. Sure we could probably figure
> > it out from strace but lets go the easier route.
> >
> > Caveat I didn't bother to try and read the strace.
> >

:) I did bother a bit, it looks like maps are created, and trivial
SOCKET_FILTER prog is created successfully as well. So BPF is at least
minimally enabled.

But do check CONFIG_BPF_EVENTS=y in your kernel config, it seems to be
the requirement for bpf_trace_printk() BPF helper used from
bpf_printk() macro.


> > Thanks,
> > John



[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