[v6.6] KASAN: null-ptr-deref Read in do_journal_end

2 views
Skip to first unread message

syzbot

unread,
Aug 4, 2025, 9:55:28 PM8/4/25
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 3a8ababb8b6a Linux 6.6.101
git tree: linux-6.6.y
console output: https://syzkaller.appspot.com/x/log.txt?x=14bfc042580000
kernel config: https://syzkaller.appspot.com/x/.config?x=a2bd95b6de4839b7
dashboard link: https://syzkaller.appspot.com/bug?extid=c6491824ba4027804128
compiler: Debian clang version 20.1.7 (++20250616065708+6146a88f6049-1~exp1~20250616065826.132), Debian LLD 20.1.7

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/f06c672f5fa8/disk-3a8ababb.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/9af9b7afcdc5/vmlinux-3a8ababb.xz
kernel image: https://storage.googleapis.com/syzbot-assets/351a55aafa77/bzImage-3a8ababb.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+c64918...@syzkaller.appspotmail.com

==================================================================
BUG: KASAN: null-ptr-deref in instrument_atomic_read include/linux/instrumented.h:68 [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:149 [inline]
BUG: KASAN: null-ptr-deref in do_journal_end+0x10cf/0x4860 fs/reiserfs/journal.c:4086
Read of size 8 at addr 0000000000000000 by task syz-executor/5787

CPU: 0 PID: 5787 Comm: syz-executor Not tainted 6.6.101-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025
Call Trace:
<TASK>
dump_stack_lvl+0x16c/0x230 lib/dump_stack.c:106
kasan_report+0x117/0x150 mm/kasan/report.c:581
check_region_inline mm/kasan/generic.c:-1 [inline]
kasan_check_range+0x288/0x290 mm/kasan/generic.c:187
instrument_atomic_read include/linux/instrumented.h:68 [inline]
_test_bit include/asm-generic/bitops/instrumented-non-atomic.h:141 [inline]
set_buffer_uptodate include/linux/buffer_head.h:149 [inline]
do_journal_end+0x10cf/0x4860 fs/reiserfs/journal.c:4086
reiserfs_sync_fs+0xd0/0x150 fs/reiserfs/super.c:78
sync_filesystem+0xea/0x220 fs/sync.c:56
generic_shutdown_super+0x6f/0x2b0 fs/super.c:666
kill_block_super+0x44/0x90 fs/super.c:1660
deactivate_locked_super+0x97/0x100 fs/super.c:481
cleanup_mnt+0x429/0x4c0 fs/namespace.c:1250
task_work_run+0x1ce/0x250 kernel/task_work.c:239
resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
exit_to_user_mode_loop+0xe6/0x110 kernel/entry/common.c:177
exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:210
__syscall_exit_to_user_mode_work kernel/entry/common.c:291 [inline]
syscall_exit_to_user_mode+0x1a/0x50 kernel/entry/common.c:302
do_syscall_64+0x61/0xb0 arch/x86/entry/common.c:87
entry_SYSCALL_64_after_hwframe+0x68/0xd2
RIP: 0033:0x7f2135b8fe97
Code: a8 ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 0f 1f 44 00 00 31 f6 e9 09 00 00 00 66 0f 1f 84 00 00 00 00 00 b8 a6 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 c7 c2 a8 ff ff ff f7 d8 64 89 02 b8
RSP: 002b:00007ffeb110a088 EFLAGS: 00000246 ORIG_RAX: 00000000000000a6
RAX: 0000000000000000 RBX: 00007f2135c11bdd RCX: 00007f2135b8fe97
RDX: 0000000000000000 RSI: 0000000000000009 RDI: 00007ffeb110a140
RBP: 00007ffeb110a140 R08: 0000000000000000 R09: 0000000000000000
R10: 00000000ffffffff R11: 0000000000000246 R12: 00007ffeb110b1d0
R13: 00007f2135c11bdd R14: 00000000000185c2 R15: 00007ffeb110b210
</TASK>
==================================================================


---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title

If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup

syzbot

unread,
Aug 5, 2025, 4:36:32 AM8/5/25
to syzkaller...@googlegroups.com
syzbot has found a reproducer for the following issue on:

HEAD commit: 3a8ababb8b6a Linux 6.6.101
git tree: linux-6.6.y
console output: https://syzkaller.appspot.com/x/log.txt?x=157005bc580000
kernel config: https://syzkaller.appspot.com/x/.config?x=a2bd95b6de4839b7
dashboard link: https://syzkaller.appspot.com/bug?extid=c6491824ba4027804128
compiler: Debian clang version 20.1.7 (++20250616065708+6146a88f6049-1~exp1~20250616065826.132), Debian LLD 20.1.7
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=164e4434580000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=16dcc2f0580000
mounted in repro #1: https://storage.googleapis.com/syzbot-assets/40a5ed61fb33/mount_0.gz
fsck result: failed (log: https://syzkaller.appspot.com/x/fsck.log?x=116f06a2580000)
mounted in repro #2: https://storage.googleapis.com/syzbot-assets/b97f586561dc/mount_5.gz
fsck result: failed (log: https://syzkaller.appspot.com/x/fsck.log?x=117005bc580000)

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+c64918...@syzkaller.appspotmail.com

==================================================================
BUG: KASAN: null-ptr-deref in instrument_atomic_read include/linux/instrumented.h:68 [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:149 [inline]
BUG: KASAN: null-ptr-deref in do_journal_end+0x10cf/0x4860 fs/reiserfs/journal.c:4086
Read of size 8 at addr 0000000000000000 by task syz-executor/5901

CPU: 1 PID: 5901 Comm: syz-executor Not tainted 6.6.101-syzkaller #0
RIP: 0033:0x7f33f498fe97
Code: a8 ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 0f 1f 44 00 00 31 f6 e9 09 00 00 00 66 0f 1f 84 00 00 00 00 00 b8 a6 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 01 c3 48 c7 c2 a8 ff ff ff f7 d8 64 89 02 b8
RSP: 002b:00007ffdd12ac418 EFLAGS: 00000246 ORIG_RAX: 00000000000000a6
RAX: 0000000000000000 RBX: 00007f33f4a11bdd RCX: 00007f33f498fe97
RDX: 0000000000000000 RSI: 0000000000000009 RDI: 00007ffdd12ac4d0
RBP: 00007ffdd12ac4d0 R08: 0000000000000000 R09: 0000000000000000
R10: 00000000ffffffff R11: 0000000000000246 R12: 00007ffdd12ad560
R13: 00007f33f4a11bdd R14: 000000000001482e R15: 00007ffdd12ad5a0
</TASK>
==================================================================


---
If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.
Reply all
Reply to author
Forward
0 new messages