Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE/BUG] Bpf module test failed on loongarch #1850

Open
yzewei opened this issue May 8, 2024 · 5 comments
Open

[FEATURE/BUG] Bpf module test failed on loongarch #1850

yzewei opened this issue May 8, 2024 · 5 comments
Labels
kind/bug Something isn't working
Milestone

Comments

@yzewei
Copy link
Contributor

yzewei commented May 8, 2024

Describe the bug
ERROR:

-----------------------------------------------------
- Setup phase
-----------------------------------------------------

* Configure BPF probe tests! Probe path: /home/yzw/rd/libs/build/driver/bpf/probe.o
* Using buffer dim: 8388608
-- BEGIN PROG LOAD LOG --
0: R1=ctx() R10=fp0
0: (85) call bpf_get_smp_processor_id#8       ; R0_w=scalar(smin=smin32=0,smax=umax=smax32=umax32=7,var_off=(0x0; 0x7))
1: (63) *(u32 *)(r10 -4) = r0         ; R0_w=scalar(smin=smin32=0,smax=umax=smax32=umax32=7,var_off=(0x0; 0x7)) R10=fp0 fp-8=mmmm????
2: (bf) r2 = r10                      ; R2_w=fp0 R10=fp0
3: (07) r2 += -4                      ; R2_w=fp-4
4: (18) r1 = 0x900000059f745800       ; R1_w=map_ptr(ks=4,vs=201)
6: (85) call bpf_map_lookup_elem#1    ; R0_w=map_value_or_null(id=1,ks=4,vs=201)
7: (18) r1 = 0x9000000135452e00       ; R1=map_ptr(ks=4,vs=4)
9: (15) if r0 == 0x0 goto pc+2        ; R0=map_value(ks=4,vs=201)
10: (18) r1 = 0x9000000135452e00      ; R1_w=map_ptr(ks=4,vs=4)
12: (61) r2 = *(u32 *)(r1 +0)
cannot access ptr member ops with moff 0 in struct bpf_map with off 0 size 4
processed 10 insns (limit 1000000) max_states_per_insn 0 total_states 1 peak_states 1 mark_read 1

-- END PROG LOAD LOG --
Unable to open the engine: libscap: bpf_load_program() event=tracepoint/filler/terminate_filler: Operation not permitted

How to reproduce it

cmake -DUSE_BUNDLED_DEPS=On -DENABLE_DRIVERS_TESTS=On -DBUILD_LIBSCAP_GVISOR=Off -DBUILD_BPF=On -DBUILD_LIBSCAP_MODERN_BPF=On -DCREATE_TEST_TARGETS=On -DMODERN_BPF_DEBUG_MODE=On ..
make drivers_test
make bpf
sudo ./test/drivers/drivers_test -b

Environment

  • Falco version: master
  • OS: fedora 38
  • Kernel: 6.8.0-rc5
  • Installation method: source
  • Arch: loongarch
@yzewei yzewei added the kind/bug Something isn't working label May 8, 2024
@yzewei
Copy link
Contributor Author

yzewei commented May 8, 2024

@FedeDP @Andreagit97

@FedeDP
Copy link
Contributor

FedeDP commented May 14, 2024

Hi @yzewei ! it seems you are hitting a verifier issue; are you using libs from master?

@FedeDP
Copy link
Contributor

FedeDP commented May 14, 2024

/milestone TBD

@poiana poiana added this to the TBD milestone May 14, 2024
@yzewei
Copy link
Contributor Author

yzewei commented May 16, 2024

Hi @yzewei ! it seems you are hitting a verifier issue; are you using libs from master?

@FedeDP Currently using the 0.14.3 branch, ready to use the master branch to try.

@FedeDP
Copy link
Contributor

FedeDP commented May 16, 2024

Yes it would be great, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants