* BUG: bpf test case fails to run on LoongArch
@ 2025-04-21 2:52 bibo mao
2025-04-23 1:28 ` Tiezhu Yang
0 siblings, 1 reply; 3+ messages in thread
From: bibo mao @ 2025-04-21 2:52 UTC (permalink / raw)
To: yangtiezhu, Huacai Chen; +Cc: bpf, linux-kernel
Hi,
When I run built-in bpf test case with lib/test_bpf.c,
it reports such error, I do not know whether it is a problem.
test_bpf: #843 ALU32_RSH_X: all shift values jited:1 239 PASS
test_bpf: #844 ALU32_ARSH_X: all shift values jited:1 237 PASS
test_bpf: #845 ALU64_LSH_X: all shift values with the same register
------------[ cut here ]------------
kernel BUG at lib/test_bpf.c:794!
Oops - BUG[#1]:
CPU: 15 UID: 0 PID: 2323 Comm: insmod Not tainted 6.15.0-rc2+ #297
PREEMPT(full)
Hardware name: QEMU QEMU Virtual Machine, BIOS unknown 2/2/2022
pc ffff80000272c0e0 ra ffff80000272bf90 tp 900000013defc000 sp
900000013deffb40
a0 0000000000000000 a1 900000013deffb80 a2 900000010aa4fbf8 a3
900000013deffb88
a4 900000013deffb80 a5 900000010aa4fbf0 a6 0000000000000218 a7
8000000000000000
t0 00000000000000c0 t1 0000000000000c10 t2 00000000000000c0 t3
0000000000000000
t4 0000000000000095 t5 0000000000000c08 t6 00000000000000c0 t7
00000001000000b7
t8 0000000000000183 u0 0000000000010000 s9 0000000000000040 s0
0000000000000c00
s1 0000000000000181 s2 0000000000000000 s3 0000000000000040 s4
000000000001211d
s5 0000000000000218 s6 0000000000000011 s7 00000000000001b7 s8
900000010aa4f000
ra: ffff80000272bf90 __bpf_fill_alu_shift_same_reg+0x118/0x298
[test_bpf]
ERA: ffff80000272c0e0 __bpf_fill_alu_shift_same_reg+0x268/0x298
[test_bpf]
CRMD: 000000b0 (PLV0 -IE -DA +PG DACF=CC DACM=CC -WE)
PRMD: 00000004 (PPLV0 +PIE -PWE)
EUEN: 00000000 (-FPE -SXE -ASXE -BTE)
ECFG: 00071c1d (LIE=0,2-4,10-12 VS=7)
ESTAT: 000c0000 [BRK] (IS= ECode=12 EsubCode=0)
PRID: 0014c010 (Loongson-64bit, Loongson-3A5000)
Modules linked in: test_bpf(+) snd_seq_dummy snd_seq snd_seq_device
rfkill vfat fat virtio_net virtio_gpu net_failover virtio_balloon
failover virtio_dma_buf efi_pstore virtio_scsi pstore dm_multipath fuse
nfnetlink efivarfs
Process insmod (pid: 2323, threadinfo=000000006d91be37,
task=00000000064df522)
Stack : 9000000002018bc0 0000000000000060 000000000000006f
000000000000006c
0000000000000183 ffff800002ba1c40 8000000000000000
0000000000000218
8000000000000000 545a35de324f71ab 900000013deffbb8
ffff800002808080
9000000002018bc0 0000000000000000 0000000000000000
000000000000034d
0000000000000000 ffff80001d438000 ffff800002ba0b08
ffff800002ba2c40
000000000000034d ffff8000027807e8 0000000000000001
0000000000000341
ffff800002808100 0000000000000341 00000000000003e8
0000000000000001
ffff800002ba1b09 ffff800002ba1bb4 9000000002c30140
9000000002b240b8
0000000000000000 0000000000000000 ffff80001d438000
0000000000000000
0000000000000000 545a35de324f71ab 0000000000000000
000000000000002f
...
Call Trace:
[<ffff80000272c0e0>] __bpf_fill_alu_shift_same_reg+0x268/0x298 [test_bpf]
[<ffff8000027807e4>] test_bpf_init+0x39c/0x3bb8 [test_bpf]
[<9000000000240154>] do_one_initcall+0x74/0x200
[<9000000000327764>] do_init_module+0x54/0x2a0
[<9000000000329ccc>] __do_sys_init_module+0x204/0x2a8
[<90000000015b17a0>] do_syscall+0xa0/0x188
[<90000000002413b8>] handle_syscall+0xb8/0x158
Code: 03400000 03400000 03400000 <002a0001> 29c28076 29c26077
29c24078 29c1e07b 29c1c07c
---[ end trace 0000000000000000 ]---
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: BUG: bpf test case fails to run on LoongArch
2025-04-21 2:52 BUG: bpf test case fails to run on LoongArch bibo mao
@ 2025-04-23 1:28 ` Tiezhu Yang
2025-04-23 1:49 ` bibo mao
0 siblings, 1 reply; 3+ messages in thread
From: Tiezhu Yang @ 2025-04-23 1:28 UTC (permalink / raw)
To: bibo mao, Huacai Chen; +Cc: bpf, linux-kernel, loongarch
On 04/21/2025 10:52 AM, bibo mao wrote:
> Hi,
>
> When I run built-in bpf test case with lib/test_bpf.c,
> it reports such error, I do not know whether it is a problem.
>
> test_bpf: #843 ALU32_RSH_X: all shift values jited:1 239 PASS
> test_bpf: #844 ALU32_ARSH_X: all shift values jited:1 237 PASS
> test_bpf: #845 ALU64_LSH_X: all shift values with the same register
> ------------[ cut here ]------------
> kernel BUG at lib/test_bpf.c:794!
This is a known issue I have ever encountered.
I guess your GCC version is 14.1, this is a bug of GCC,
it has been fixed in the higher version, you can update
you GCC version (14.2+).
$ gcc --version | head -1
gcc (GCC) 14.2.1 20241104
$ dmesg -t | grep Summary
test_bpf: Summary: 1053 PASSED, 0 FAILED, [0/1041 JIT'ed]
test_bpf: test_tail_calls: Summary: 10 PASSED, 0 FAILED, [0/10 JIT'ed]
test_bpf: test_skb_segment: Summary: 2 PASSED, 0 FAILED
test_bpf: Summary: 1053 PASSED, 0 FAILED, [1041/1041 JIT'ed]
test_bpf: test_tail_calls: Summary: 10 PASSED, 0 FAILED, [10/10 JIT'ed]
test_bpf: test_skb_segment: Summary: 2 PASSED, 0 FAILED
Thanks,
Tiezhu
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: BUG: bpf test case fails to run on LoongArch
2025-04-23 1:28 ` Tiezhu Yang
@ 2025-04-23 1:49 ` bibo mao
0 siblings, 0 replies; 3+ messages in thread
From: bibo mao @ 2025-04-23 1:49 UTC (permalink / raw)
To: Tiezhu Yang, Huacai Chen; +Cc: bpf, linux-kernel, loongarch
On 2025/4/23 上午9:28, Tiezhu Yang wrote:
> On 04/21/2025 10:52 AM, bibo mao wrote:
>> Hi,
>>
>> When I run built-in bpf test case with lib/test_bpf.c,
>> it reports such error, I do not know whether it is a problem.
>>
>> test_bpf: #843 ALU32_RSH_X: all shift values jited:1 239 PASS
>> test_bpf: #844 ALU32_ARSH_X: all shift values jited:1 237 PASS
>> test_bpf: #845 ALU64_LSH_X: all shift values with the same register
>> ------------[ cut here ]------------
>> kernel BUG at lib/test_bpf.c:794!
>
> This is a known issue I have ever encountered.
> I guess your GCC version is 14.1, this is a bug of GCC,
yes, My gcc version is 14.1
> it has been fixed in the higher version, you can update
> you GCC version (14.2+).
OK, I will update my gcc. And sorry for the noise.
Regards
Bibo Mao
>
> $ gcc --version | head -1
> gcc (GCC) 14.2.1 20241104
> $ dmesg -t | grep Summary
> test_bpf: Summary: 1053 PASSED, 0 FAILED, [0/1041 JIT'ed]
> test_bpf: test_tail_calls: Summary: 10 PASSED, 0 FAILED, [0/10 JIT'ed]
> test_bpf: test_skb_segment: Summary: 2 PASSED, 0 FAILED
> test_bpf: Summary: 1053 PASSED, 0 FAILED, [1041/1041 JIT'ed]
> test_bpf: test_tail_calls: Summary: 10 PASSED, 0 FAILED, [10/10 JIT'ed]
> test_bpf: test_skb_segment: Summary: 2 PASSED, 0 FAILED
>
> Thanks,
> Tiezhu
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-04-23 1:51 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-04-21 2:52 BUG: bpf test case fails to run on LoongArch bibo mao
2025-04-23 1:28 ` Tiezhu Yang
2025-04-23 1:49 ` bibo mao
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®