syzbot


netbsd boot error: page fault in virtio_free_vq

Status: fixed on 2023/03/29 14:18
Reported-by: syzbot+f79e99ac21cb702c2581@syzkaller.appspotmail.com
Fix commit: a66d32465828 Added check of pointer for allocated memory before release of resource
First crash: 412d, last: 410d

Sample crash report:
[   1.0438096] fatal page fault in supervisor mode
[   1.0438096] trap type 6 code 0 rip 0xffffffff83db4d09 cs 0x8 rflags 0x10246 cr2 0xffff8c8010b20000 ilevel 0x8 rsp 0xffffffff870a93b0
[   1.0438096] curlwp 0xffffffff86742ac0 pid 0.0 lowest kstack 0xffffffff870a42c0
kernel: page fault trap, code=0
Stopped in pid 0.0 (system) at  netbsd:virtio_free_vq+0xad:     movq    0(%r12),
%r12
virtio_free_vq() at netbsd:virtio_free_vq+0xad sys/dev/pci/virtio.c:906
vioscsi_attach() at netbsd:vioscsi_attach+0x4e6 sys/dev/pci/vioscsi.c:209
config_attach_internal() at netbsd:config_attach_internal+0x4d6 sys/kern/subr_autoconf.c:1785
config_found() at netbsd:config_found+0x354 sys/kern/subr_autoconf.c:1272
virtio_pci_rescan() at netbsd:virtio_pci_rescan+0x8e sys/dev/pci/virtio_pci.c:318
virtio_pci_attach() at netbsd:virtio_pci_attach+0x459 sys/dev/pci/virtio_pci.c:299
config_attach_internal() at netbsd:config_attach_internal+0x4d6 sys/kern/subr_autoconf.c:1785
config_found() at netbsd:config_found+0x354 sys/kern/subr_autoconf.c:1272
pci_probe_device() at netbsd:pci_probe_device+0xec9 sys/dev/pci/pci.c:488
pci_enumerate_bus() at netbsd:pci_enumerate_bus+0x481 sys/dev/pci/pci.c:819
pcirescan() at netbsd:pcirescan+0x75 sys/dev/pci/pci.c:113
pciattach() at netbsd:pciattach+0x50f sys/dev/pci/pci.c:210
config_attach_internal() at netbsd:config_attach_internal+0x4d6 sys/kern/subr_autoconf.c:1785
config_found() at netbsd:config_found+0x354 sys/kern/subr_autoconf.c:1272
mp_pci_scan() at netbsd:mp_pci_scan+0x1d6 sys/arch/x86/x86/mp.c:96
amd64_mainbus_attach() at netbsd:amd64_mainbus_attach+0x467 sys/arch/amd64/amd64/amd64_mainbus.c:213
config_attach_internal() at netbsd:config_attach_internal+0x4d6 sys/kern/subr_autoconf.c:1785
config_rootfound() at netbsd:config_rootfound+0x92 config_attach sys/kern/subr_autoconf.c:1820 [inline]
config_rootfound() at netbsd:config_rootfound+0x92 sys/kern/subr_autoconf.c:1300
cpu_configure() at netbsd:cpu_configure+0x58 sys/arch/amd64/amd64/autoconf.c:112
main() at netbsd:main+0x452 sys/kern/init_main.c:555
--db_more--

Crashes (27):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/03/25 11:11 netbsd 3daeca3d1d8d fbf0499a .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/25 11:11 netbsd 3daeca3d1d8d fbf0499a .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/25 11:11 netbsd 3daeca3d1d8d fbf0499a .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 19:39 netbsd 3daeca3d1d8d 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 19:39 netbsd 3daeca3d1d8d 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 19:39 netbsd 3daeca3d1d8d 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 17:55 netbsd 21746ce2933d 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 17:55 netbsd 21746ce2933d 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 17:54 netbsd 21746ce2933d 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 16:21 netbsd 2b37664c4382 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 16:21 netbsd 2b37664c4382 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 16:21 netbsd 2b37664c4382 9700afae .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 14:34 netbsd 2b37664c4382 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 14:34 netbsd 2b37664c4382 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 14:34 netbsd 2b37664c4382 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 02:28 netbsd 10808e928e94 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 02:28 netbsd 10808e928e94 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/24 02:27 netbsd 10808e928e94 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 23:36 netbsd 694b95b79ba9 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 23:36 netbsd 694b95b79ba9 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 23:36 netbsd 694b95b79ba9 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 20:16 netbsd 474ba2351ae6 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 20:16 netbsd 474ba2351ae6 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 20:16 netbsd 474ba2351ae6 f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 18:29 netbsd b96529fbe61a f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 18:29 netbsd b96529fbe61a f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
2023/03/23 18:29 netbsd b96529fbe61a f94b4a29 .config console log report ci2-netbsd-kubsan netbsd boot error: page fault in virtio_free_vq
* Struck through repros no longer work on HEAD.