syzbot


BUG: unable to handle kernel paging request in bpf_dispatcher_xdp_func

Status: upstream: reported C repro on 2023/11/02 10:48
Bug presence: origin:lts
[Documentation on labels]
Reported-by: syzbot+58634c208a101ea760cb@syzkaller.appspotmail.com
First crash: 348d, last: 35d
Cause bisection: introduced by (bisect log) :
commit dbe69b29988465b011f198f2797b1c2b6980b50e
Author: Jiri Olsa <jolsa@kernel.org>
Date: Tue Oct 18 07:59:34 2022 +0000

  bpf: Fix dispatcher patchable function entry to 5 bytes nop

Crash: BUG: unable to handle kernel paging request in bpf_dispatcher_xdp (log)
Repro: C syz .config
  
Fix bisection: failed (error log, bisect log)
  
Bug presence (2)
Date Name Commit Repro Result
2023/11/02 lts (merge base) 52a953d0934b C [report] invalid opcode in bpf_dispatcher_xdp
2023/11/02 upstream (ToT) 4652b8e4f3ff C Didn't crash
Last patch testing requests (1)
Created Duration User Patch Repo Result
2023/11/16 10:47 39m retest repro android14-6.1 report log
Fix bisection attempts (10)
Created Duration User Patch Repo Result
2024/10/15 01:30 0m bisect fix android14-6.1 error job log
2024/09/09 19:49 1h53m bisect fix android14-6.1 OK (0) job log log
2024/08/07 17:56 2h05m bisect fix android14-6.1 OK (0) job log log
2024/06/28 07:22 1h30m bisect fix android14-6.1 OK (0) job log log
2024/05/21 07:00 2h01m bisect fix android14-6.1 OK (0) job log log
2024/04/16 15:45 4h18m bisect fix android14-6.1 OK (0) job log log
2024/03/13 15:34 1h31m bisect fix android14-6.1 OK (0) job log log
2024/02/09 04:38 1h58m bisect fix android14-6.1 OK (0) job log log
2024/01/02 06:36 1h35m bisect fix android14-6.1 OK (0) job log log
2023/12/03 00:22 1h35m bisect fix android14-6.1 OK (0) job log log

Sample crash report:
BUG: unable to handle page fault for address: ffffffc90003697c
#PF: supervisor instruction fetch in kernel mode
#PF: error_code(0x0010) - not-present page
PGD 6c12067 P4D 6c12067 PUD 0 
Oops: 0010 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 13441 Comm: syz-executor289 Not tainted 6.1.43-syzkaller-00254-g4bbeaddf9a63 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/06/2023
RIP: 0010:0xffffffc90003697c
Code: Unable to access opcode bytes at 0xffffffc900036952.
RSP: 0018:ffffc90003697881 EFLAGS: 00010046
RAX: 0000000000000000 RBX: ffffc90003697c00 RCX: ffff88810f712880
RDX: ffffffffa0001750 RSI: ffffc90003699050 RDI: ffffc90003697c00
RBP: ffffc900036978a8 R08: ffffffff842f90cd R09: ffffed1021ee2511
R10: 0000000000000000 R11: dffffc0000000001 R12: dffffc0000000000
R13: ffffc90003699030 R14: ffffffffa0001750 R15: ffffc90003699050
FS:  00007fd4c70436c0(0000) GS:ffff8881f7000000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffc900036952 CR3: 0000000124524000 CR4: 00000000003506b0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 bpf_dispatcher_xdp_func+0x25/0x30 net/core/filter.c:11426
 __bpf_prog_run include/linux/filter.h:600 [inline]
 bpf_prog_run_xdp include/linux/filter.h:775 [inline]
 bpf_test_run+0x470/0xa40 net/bpf/test_run.c:400
 bpf_prog_test_run_xdp+0x7a7/0x1130 net/bpf/test_run.c:1389
 bpf_prog_test_run+0x3b0/0x630 kernel/bpf/syscall.c:3635
 __sys_bpf+0x59f/0x7f0 kernel/bpf/syscall.c:4990
 __do_sys_bpf kernel/bpf/syscall.c:5076 [inline]
 __se_sys_bpf kernel/bpf/syscall.c:5074 [inline]
 __x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:5074
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7fd4c7083dc9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 81 18 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 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fd4c7043168 EFLAGS: 00000246 ORIG_RAX: 0000000000000141
RAX: ffffffffffffffda RBX: 00007fd4c710e3c8 RCX: 00007fd4c7083dc9
RDX: 0000000000000048 RSI: 0000000020001480 RDI: 000000000000000a
RBP: 00007fd4c710e3c0 R08: 00007fd4c70436c0 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007fd4c710e3cc
R13: 0000000000000016 R14: 00007fff3e87a7e0 R15: 00007fff3e87a8c8
 </TASK>
Modules linked in:
CR2: ffffffc90003697c
---[ end trace 0000000000000000 ]---
RIP: 0010:0xffffffc90003697c
Code: Unable to access opcode bytes at 0xffffffc900036952.
RSP: 0018:ffffc90003697881 EFLAGS: 00010046
RAX: 0000000000000000 RBX: ffffc90003697c00 RCX: ffff88810f712880
RDX: ffffffffa0001750 RSI: ffffc90003699050 RDI: ffffc90003697c00
RBP: ffffc900036978a8 R08: ffffffff842f90cd R09: ffffed1021ee2511
R10: 0000000000000000 R11: dffffc0000000001 R12: dffffc0000000000
R13: ffffc90003699030 R14: ffffffffa0001750 R15: ffffc90003699050
FS:  00007fd4c70436c0(0000) GS:ffff8881f7000000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffc900036952 CR3: 0000000124524000 CR4: 00000000003506b0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/11/02 10:46 android14-6.1 4bbeaddf9a63 69904c9f .config console log report syz C [disk image] [vmlinux] [kernel image] ci2-android-6-1 BUG: unable to handle kernel paging request in bpf_dispatcher_xdp_func
* Struck through repros no longer work on HEAD.