syzbot


bpf-next boot error: WARNING in bpf_prog_pack_free

Status: upstream: reported on 2022/03/21 06:55
Reported-by: syzbot+c946805b5ce6ab87df0b@syzkaller.appspotmail.com
Fix commit: 96805674e562 bpf: Fix bpf_prog_pack for multi-node setup
Patched on: [ci-qemu-upstream ci-qemu-upstream-386 ci-qemu2-arm32 ci-qemu2-arm64 ci-qemu2-arm64-compat ci-qemu2-arm64-mte ci-upstream-bpf-kasan-gce ci-upstream-bpf-next-kasan-gce ci-upstream-gce-leak ci-upstream-kasan-gce ci-upstream-kasan-gce-386 ci-upstream-kasan-gce-root ci-upstream-kasan-gce-selinux-root ci-upstream-kasan-gce-smack-root ci-upstream-kmsan-gce ci-upstream-kmsan-gce-386 ci-upstream-linux-next-kasan-gce-root ci-upstream-net-kasan-gce ci-upstream-net-this-kasan-gce ci2-upstream-kcsan-gce ci2-upstream-usb], missing on: [ci-qemu2-riscv64]
First crash: 100d, last: 99d

Sample crash report:
input: AT Translated Set 2 keyboard as /devices/platform/i8042/serio0/input/input2
input: ImExPS/2 Generic Explorer Mouse as /devices/platform/i8042/serio1/input/input4
------------[ cut here ]------------
bpf_prog_pack bug
WARNING: CPU: 0 PID: 921 at kernel/bpf/core.c:947 bpf_prog_pack_free+0x2fc/0x3a0 kernel/bpf/core.c:947
Modules linked in:
CPU: 0 PID: 921 Comm: kworker/0:2 Not tainted 5.17.0-rc6-syzkaller-02064-gd56c9fe6a068 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: events bpf_prog_free_deferred
RIP: 0010:bpf_prog_pack_free+0x2fc/0x3a0 kernel/bpf/core.c:947
Code: 0b 31 ff 89 de e8 94 44 f3 ff 84 db 0f 85 82 fe ff ff e8 07 42 f3 ff 48 c7 c7 60 df b2 89 c6 05 12 9a fa 0b 01 e8 9b 10 87 07 <0f> 0b e9 63 fe ff ff e8 e8 41 f3 ff 0f 0b 0f 0b 41 be ff ff ff ff
RSP: 0000:ffffc90004f6fc60 EFLAGS: 00010282
RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000000
RDX: ffff88801bd2d700 RSI: ffffffff815fe3a8 RDI: fffff520009edf7e
RBP: ffffffff8bc177e0 R08: 0000000000000000 R09: 0000000000000001
R10: ffffffff815f8a3e R11: 0000000000000000 R12: ffff8881401c8010
R13: ffffffffa0400000 R14: ffffffffa0600640 R15: 0000000000000540
FS:  0000000000000000(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffff88823ffff000 CR3: 000000000b88e000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 bpf_jit_binary_pack_free kernel/bpf/core.c:1151 [inline]
 bpf_jit_free+0x11d/0x2b0 kernel/bpf/core.c:1180
 bpf_prog_free_deferred+0x5c1/0x790 kernel/bpf/core.c:2553
 process_one_work+0x9ac/0x1650 kernel/workqueue.c:2307
 worker_thread+0x657/0x1110 kernel/workqueue.c:2454
 kthread+0x2e9/0x3a0 kernel/kthread.c:377
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295
 </TASK>

Crashes (12):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci-upstream-bpf-next-kasan-gce 2022/03/22 04:29 bpf-next d56c9fe6a068 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/22 04:29 bpf-next d56c9fe6a068 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/22 04:29 bpf-next d56c9fe6a068 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 15:44 bpf-next d8dc09a4db45 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 15:44 bpf-next d8dc09a4db45 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 15:44 bpf-next d8dc09a4db45 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 14:14 bpf-next f70986902c86 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 14:14 bpf-next f70986902c86 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 14:14 bpf-next f70986902c86 e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 02:44 bpf-next 7ada3787e91c e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 02:44 bpf-next 7ada3787e91c e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free
ci-upstream-bpf-next-kasan-gce 2022/03/21 02:44 bpf-next 7ada3787e91c e2d91b1d .config log report bpf-next boot error: WARNING in bpf_prog_pack_free