syzbot


KASAN: null-ptr-deref Read in do_journal_end (2)

Status: upstream: reported C repro on 2022/07/30 19:30
Reported-by: syzbot+845cd8e5c47f2a125683@syzkaller.appspotmail.com
First crash: 318d, last: 28d

Cause bisection: failed (bisect log)
similar bugs (3):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KASAN: null-ptr-deref Read in do_journal_end 1 465d 461d 0/24 auto-closed as invalid on 2022/02/20 18:03
linux-4.19 general protection fault in do_journal_end reiserfs C 3 14d 63d 0/1 upstream: reported C repro on 2022/11/30 04:17
linux-4.14 general protection fault in do_journal_end reiserfs C 2 20d 27d 0/1 upstream: reported C repro on 2023/01/05 12:44

Sample crash report:
REISERFS (device loop0): Created .reiserfs_priv - reserved for xattr storage.
==================================================================
BUG: KASAN: null-ptr-deref in instrument_atomic_read include/linux/instrumented.h:72 [inline]
BUG: KASAN: null-ptr-deref in _test_bit include/asm-generic/bitops/instrumented-non-atomic.h:141 [inline]
BUG: KASAN: null-ptr-deref in set_buffer_uptodate include/linux/buffer_head.h:148 [inline]
BUG: KASAN: null-ptr-deref in do_journal_end+0x155f/0x4a30 fs/reiserfs/journal.c:4081
Read of size 8 at addr 0000000000000000 by task syz-executor318/5067

CPU: 0 PID: 5067 Comm: syz-executor318 Not tainted 6.2.0-rc2-syzkaller-00010-g69b41ac87e4a #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022
Call Trace:
 <TASK>
 __dump_stack lib/dump_stack.c:88 [inline]
 dump_stack_lvl+0x1b1/0x290 lib/dump_stack.c:106
 print_report+0xed/0x1f0 mm/kasan/report.c:420
 kasan_report+0xcd/0x100 mm/kasan/report.c:517
 kasan_check_range+0x2a7/0x2e0 mm/kasan/generic.c:189
 instrument_atomic_read include/linux/instrumented.h:72 [inline]
 _test_bit include/asm-generic/bitops/instrumented-non-atomic.h:141 [inline]
 set_buffer_uptodate include/linux/buffer_head.h:148 [inline]
 do_journal_end+0x155f/0x4a30 fs/reiserfs/journal.c:4081
 reiserfs_sync_fs+0xbb/0x130 fs/reiserfs/super.c:78
 sync_filesystem+0xe8/0x220 fs/sync.c:56
 generic_shutdown_super+0x6b/0x310 fs/super.c:474
 kill_block_super+0x79/0xd0 fs/super.c:1386
 deactivate_locked_super+0xa7/0xf0 fs/super.c:332
 cleanup_mnt+0x494/0x520 fs/namespace.c:1291
 task_work_run+0x243/0x300 kernel/task_work.c:179
 exit_task_work include/linux/task_work.h:38 [inline]
 do_exit+0x644/0x2150 kernel/exit.c:867
 do_group_exit+0x1fd/0x2b0 kernel/exit.c:1012
 __do_sys_exit_group kernel/exit.c:1023 [inline]
 __se_sys_exit_group kernel/exit.c:1021 [inline]
 __x64_sys_exit_group+0x3b/0x40 kernel/exit.c:1021
 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:0x7f62bc7a3aa9
Code: Unable to access opcode bytes at 0x7f62bc7a3a7f.
RSP: 002b:00007fff632d8308 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7
RAX: ffffffffffffffda RBX: 00007f62bc819350 RCX: 00007f62bc7a3aa9
RDX: 000000000000003c RSI: 00000000000000e7 RDI: 0000000000000001
RBP: 0000000000000001 R08: ffffffffffffffc0 R09: 00007f62bc813e40
R10: 000080001d00c0d0 R11: 0000000000000246 R12: 00007f62bc819350
R13: 0000000000000001 R14: 0000000000000000 R15: 0000000000000001
 </TASK>
==================================================================

Crashes (12):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci2-upstream-fs 2023/01/04 06:51 upstream 69b41ac87e4a f0036e18 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] KASAN: null-ptr-deref Read in do_journal_end
ci2-upstream-fs 2022/12/30 12:22 upstream 2258c2dc850b 44712fbc .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] KASAN: null-ptr-deref Read in do_journal_end
ci2-upstream-fs 2022/12/27 22:17 upstream 1b929c02afd3 44712fbc .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] KASAN: null-ptr-deref Read in do_journal_end
ci2-upstream-fs 2022/11/30 15:59 upstream 01f856ae6d0c 4c2a66e8 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] KASAN: null-ptr-deref Read in do_journal_end
ci-upstream-kasan-gce-root 2022/07/30 19:30 upstream 620725263f42 fef302b1 .config console log report info KASAN: null-ptr-deref Read in do_journal_end
ci-qemu-upstream 2022/07/12 17:39 upstream 5a29232d870d d91dd8ea .config console log report info KASAN: null-ptr-deref Read in do_journal_end
ci-qemu-upstream 2022/04/16 01:20 upstream 59250f8a7f3a 8bcc32a6 .config console log report info KASAN: null-ptr-deref Read in do_journal_end
ci-upstream-kasan-gce-selinux-root 2022/04/01 14:12 upstream e8b767f5e040 20955a24 .config console log report info KASAN: null-ptr-deref Read in do_journal_end
ci-upstream-kasan-gce-selinux-root 2022/03/19 20:50 upstream 97e9c8eb4bb1 e2d91b1d .config console log report info KASAN: null-ptr-deref Read in do_journal_end
ci-qemu-upstream-386 2022/10/18 16:13 upstream bb1a1146467a b31320fc .config console log report info KASAN: null-ptr-deref Read in do_journal_end
ci-qemu-upstream-386 2022/10/16 20:07 upstream 2df76606db9d 67cb024c .config console log report info KASAN: null-ptr-deref Read in do_journal_end
ci-upstream-kasan-gce-selinux-root 2022/08/25 21:15 upstream 3f5c20055a64 9b5bf4cd .config console log report info KASAN: null-ptr-deref Write in do_journal_end
* Struck through repros no longer work on HEAD.