syzbot


WARNING in nilfs_dat_prepare_end

Status: upstream: reported C repro on 2022/10/10 02:44
Reported-by: syzbot+683c851b3ddd51b50708@syzkaller.appspotmail.com
First crash: 116d, last: 28d
similar bugs (2):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-4.19 WARNING in nilfs_dat_prepare_end nilfs2 C error 4 28d 116d 0/1 upstream: reported C repro on 2022/10/09 12:14
upstream WARNING in nilfs_dat_prepare_end nilfs2 C error 192 1d10h 122d 1/24 upstream: reported C repro on 2022/10/03 16:30

Sample crash report:
NILFS error (device loop0): nilfs_check_page: bad entry in directory #12: rec_len is smaller than minimal - offset=0, inode=0, rec_len=0, name_len=0
Remounting filesystem read-only
------------[ cut here ]------------
WARNING: CPU: 0 PID: 7980 at fs/nilfs2/dat.c:160 nilfs_dat_prepare_end+0x1e8/0x2e0 fs/nilfs2/dat.c:160
Kernel panic - not syncing: panic_on_warn set ...

CPU: 0 PID: 7980 Comm: syz-executor160 Not tainted 4.14.295-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/22/2022
Call Trace:
 __dump_stack lib/dump_stack.c:17 [inline]
 dump_stack+0x1b2/0x281 lib/dump_stack.c:58
 panic+0x1f9/0x42d kernel/panic.c:183
 __warn.cold+0x20/0x44 kernel/panic.c:547
 report_bug+0x208/0x250 lib/bug.c:183
 fixup_bug arch/x86/kernel/traps.c:177 [inline]
 fixup_bug arch/x86/kernel/traps.c:172 [inline]
 do_error_trap+0x195/0x2d0 arch/x86/kernel/traps.c:295
 invalid_op+0x1b/0x40 arch/x86/entry/entry_64.S:964
RIP: 0010:nilfs_dat_prepare_end+0x1e8/0x2e0 fs/nilfs2/dat.c:160
RSP: 0018:ffff888095d8f968 EFLAGS: 00010297
RAX: ffff88809c6fe1c0 RBX: ffff888095d8f9d0 RCX: 61c8864680b583eb
RDX: 0000000000000000 RSI: 0000000000000002 RDI: ffff88808df1ba38
RBP: ffff888095d8f9e8 R08: 0000000000000000 R09: 0000000000000005
R10: 0000000000000000 R11: 0000000000000000 R12: 00000000fffffffe
R13: ffff88808df1f9c8 R14: ffff88808df1f9c8 R15: ffff88808df1a1b0
 nilfs_bmap_prepare_end_ptr fs/nilfs2/bmap.h:220 [inline]
 nilfs_direct_delete+0x1b7/0x250 fs/nilfs2/direct.c:164
 nilfs_bmap_do_delete+0x1d8/0x280 fs/nilfs2/bmap.c:185
 nilfs_bmap_do_truncate fs/nilfs2/bmap.c:273 [inline]
 nilfs_bmap_truncate+0xe9/0x280 fs/nilfs2/bmap.c:306
 nilfs_truncate_bmap+0x101/0x2c0 fs/nilfs2/inode.c:719
 nilfs_evict_inode+0x11b/0x3a0 fs/nilfs2/inode.c:806
 evict+0x2c8/0x700 fs/inode.c:555
 iput_final fs/inode.c:1524 [inline]
 iput+0x458/0x7e0 fs/inode.c:1551
 dentry_unlink_inode+0x25c/0x310 fs/dcache.c:387
 d_delete+0x1c5/0x280 fs/dcache.c:2417
 vfs_rmdir.part.0+0x260/0x390 fs/namei.c:3922
 vfs_rmdir fs/namei.c:3895 [inline]
 do_rmdir+0x334/0x3c0 fs/namei.c:3970
 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292
 entry_SYSCALL_64_after_hwframe+0x46/0xbb
RIP: 0033:0x7f2fff57c289
RSP: 002b:00007ffe7a12ead8 EFLAGS: 00000246 ORIG_RAX: 0000000000000054
RAX: ffffffffffffffda RBX: 0030656c69662f2e RCX: 00007f2fff57c289
RDX: 00007f2fff53a823 RSI: 0000000000000000 RDI: 0000000020000780
RBP: 00007f2fff53baf0 R08: 0000555556e662c0 R09: 0000000000000000
R10: 00007ffe7a12e9a0 R11: 0000000000000246 R12: 00007f2fff53bb80
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
Kernel Offset: disabled
Rebooting in 86400 seconds..

Fix bisection attempts:
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci2-linux-4-14 2022/11/09 03:16 linux-4.14.y a901bb6c7db7 aea5da89 .config console log report syz C
* Struck through repros no longer work on HEAD.
Crashes (2):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci2-linux-4-14 2022/10/10 02:43 linux-4.14.y 9d5c0b3a8e1a aea5da89 .config console log report syz C [disk image] [vmlinux] [mounted in repro] WARNING in nilfs_dat_prepare_end
ci2-linux-4-14 2023/01/06 08:30 linux-4.14.y c4215ee4771b 1dac8c7a .config console log report info [disk image] [vmlinux] [kernel image] WARNING in nilfs_dat_prepare_end
* Struck through repros no longer work on HEAD.