syzbot


invalid opcode in bpf_dispatcher_xdp

Status: upstream: reported C repro on 2023/10/07 06:11
Bug presence: origin:lts-only
[Documentation on labels]
Reported-by: syzbot+7ea81ba9180113ec63d2@syzkaller.appspotmail.com
First crash: 411d, last: 233d
Bug presence (2)
Date Name Commit Repro Result
2024/01/11 linux-6.1.y (ToT) 7c58bfa711cb C [report] INFO: rcu detected stall in corrupted
2024/01/11 upstream (ToT) de927f6c0b07 C Didn't crash
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
android-6-1 invalid opcode in bpf_dispatcher_xdp C error done 55 33d 543d 0/2 upstream: reported C repro on 2023/05/28 12:21
Fix bisection attempts (3)
Created Duration User Patch Repo Result
2024/01/13 11:42 7h26m fix candidate upstream OK (1) job log
2023/11/16 09:53 7h30m fix candidate upstream OK (1) job log
2023/10/08 12:06 20m fix candidate upstream error job log

Sample crash report:
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 21855 Comm: syz-executor335 Not tainted 6.1.79-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/25/2024
RIP: 0010:bpf_dispatcher_xdp+0x812/0x1000
Code: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 48 81 fa dc 07 00 a0 7f 17 48 81 fa dc 07 00 a0 0f 84 <06> c7 ff ff ff e2 0f 1f 84 00 00 00 00 00 48 81 fa 54 4c 00 a0 0f
RSP: 0018:ffffc9000b2a7978 EFLAGS: 00010246
RAX: ffffffff888ce7e3 RBX: ffffc9000b2a7a60 RCX: ffff88807e7fbb80
RDX: ffffffffa00007dc RSI: ffffc9000b26b048 RDI: ffffc9000b2a7c80
RBP: ffffc9000b2a7b70 R08: ffffffff88bd4b97 R09: ffffed100fcff771
R10: 0000000000000000 R11: dffffc0000000001 R12: dffffc0000000000
R13: ffffc9000b26b030 R14: 0000000000000000 R15: ffffc9000b2a7c60
FS:  0000555555ef2380(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fed06026130 CR3: 000000007b75c000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 bpf_prog_test_run_xdp+0x7a7/0x1130 net/bpf/test_run.c:1389
 bpf_prog_test_run+0x32f/0x3a0 kernel/bpf/syscall.c:3670
 __sys_bpf+0x3eb/0x6c0 kernel/bpf/syscall.c:5023
 __do_sys_bpf kernel/bpf/syscall.c:5109 [inline]
 __se_sys_bpf kernel/bpf/syscall.c:5107 [inline]
 __x64_sys_bpf+0x78/0x90 kernel/bpf/syscall.c:5107
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:81
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7fed05faade9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 c1 17 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffc510e5908 EFLAGS: 00000246 ORIG_RAX: 0000000000000141
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007fed05faade9
RDX: 0000000000000048 RSI: 0000000020000180 RDI: 000000000000000a
RBP: 0000000000000000 R08: 00000000000000a0 R09: 00000000000000a0
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:bpf_dispatcher_xdp+0x812/0x1000
Code: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 48 81 fa c8 4f 00 a0 7f 37 48 81 fa dc 07 00 a0 7f 1e <48> 81 fa dc 07 00 a0 0f 84 fd c6 ff ff ff e2 0f 1f 84 00 00 00 00
RSP: 0018:ffffc9000b2a7978 EFLAGS: 00010246
RAX: ffffffff888ce7e3 RBX: ffffc9000b2a7a60 RCX: ffff88807e7fbb80
RDX: ffffffffa00007dc RSI: ffffc9000b26b048 RDI: ffffc9000b2a7c80
RBP: ffffc9000b2a7b70 R08: ffffffff88bd4b97 R09: ffffed100fcff771
R10: 0000000000000000 R11: dffffc0000000001 R12: dffffc0000000000
R13: ffffc9000b26b030 R14: 0000000000000000 R15: ffffc9000b2a7c60
FS:  0000555555ef2380(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fed060230d0 CR3: 000000007b75c000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
  18:	48 81 fa c8 4f 00 a0 	cmp    $0xffffffffa0004fc8,%rdx
  1f:	7f 37                	jg     0x58
  21:	48 81 fa dc 07 00 a0 	cmp    $0xffffffffa00007dc,%rdx
  28:	7f 1e                	jg     0x48
* 2a:	48 81 fa dc 07 00 a0 	cmp    $0xffffffffa00007dc,%rdx <-- trapping instruction
  31:	0f 84 fd c6 ff ff    	je     0xffffc734
  37:	ff e2                	jmp    *%rdx
  39:	0f                   	.byte 0xf
  3a:	1f                   	(bad)
  3b:	84 00                	test   %al,(%rax)
  3d:	00 00                	add    %al,(%rax)

Crashes (14):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/03/01 03:09 linux-6.1.y 81e1dc2f7001 352ab904 .config console log report syz C [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan invalid opcode in bpf_dispatcher_xdp
2024/01/11 02:37 linux-6.1.y 7c58bfa711cb 04815ef1 .config console log report syz C [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2024/04/02 01:43 linux-6.1.y e5cd595e23c1 6baf5069 .config console log report syz [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan invalid opcode in bpf_dispatcher_xdp
2023/11/03 12:13 linux-6.1.y 4a61839152cc c4ac074c .config console log report syz [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2023/10/30 20:55 linux-6.1.y 32c9cdbe383c b5729d82 .config console log report syz [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2023/10/28 18:05 linux-6.1.y 32c9cdbe383c 3c418d72 .config console log report syz [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2023/10/07 17:09 linux-6.1.y ecda77b46871 5e837c76 .config console log report syz [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2024/01/18 07:02 linux-6.1.y fec3b1451d5f 915053c7 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2023/11/22 15:22 linux-6.1.y 69e434a1cb21 03e12510 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan invalid opcode in bpf_dispatcher_xdp
2023/11/11 00:24 linux-6.1.y fb2635ac69ab d80eec66 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan invalid opcode in bpf_dispatcher_xdp
2023/11/03 00:15 linux-6.1.y 4a61839152cc c4ac074c .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2023/10/28 16:20 linux-6.1.y 32c9cdbe383c 3c418d72 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2023/10/13 01:10 linux-6.1.y 082280fe94a0 6388bc36 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
2023/10/07 06:10 linux-6.1.y ecda77b46871 5e837c76 .config console log report info [disk image] [vmlinux] [kernel image] ci2-linux-6-1-kasan-perf invalid opcode in bpf_dispatcher_xdp
* Struck through repros no longer work on HEAD.