general protection fault, probably for non-canonical address 0xdffffc0000000000: 0000 [#1] PREEMPT SMP KASAN KASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007] CPU: 0 PID: 8879 Comm: syz.7.2166 Not tainted 5.10.226-syzkaller-00184-g139a6bb26d9d #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024 RIP: 0010:f2fs_test_and_set_bit fs/f2fs/f2fs.h:2905 [inline] RIP: 0010:update_sit_entry+0x5e0/0x1060 fs/f2fs/segment.c:2330 Code: 4d 90 48 8d 5c c8 18 48 89 d8 48 c1 e8 03 42 80 3c 28 00 74 08 48 89 df e8 ad c8 88 ff 4c 8b 33 4d 01 fe 4d 89 f4 49 c1 ec 03 <43> 0f b6 04 2c 84 c0 0f 85 21 09 00 00 41 0f b6 1e 41 89 df 8b 45 RSP: 0018:ffffc90000f2ecf8 EFLAGS: 00010246 RAX: 1ffff1102399923a RBX: ffff88811ccc91d0 RCX: 0000000000000037 RDX: ffff88810ff5a780 RSI: 0000000000000000 RDI: 0000000000000000 RBP: ffffc90000f2ed90 R08: ffffffff821f8cf1 R09: ffffffff821f884d R10: 0000000000000003 R11: ffff88810ff5a780 R12: 0000000000000000 R13: dffffc0000000000 R14: 0000000000000000 R15: 0000000000000000 FS: 00007fa5a920b6c0(0000) GS:ffff8881f7000000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007fa5a920afb8 CR3: 00000001193a4000 CR4: 00000000003506b0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: f2fs_allocate_data_block+0x18ee/0x3150 fs/f2fs/segment.c:3487 __allocate_data_block+0x5a7/0xb10 fs/f2fs/data.c:1407 f2fs_map_blocks+0x18ef/0x3e50 fs/f2fs/data.c:1575 f2fs_iomap_begin+0x270/0x980 fs/f2fs/data.c:4118 iomap_apply+0x116/0x8a0 fs/iomap/apply.c:46 __iomap_dio_rw+0x767/0x10f0 fs/iomap/direct-io.c:525 f2fs_dio_write_iter fs/f2fs/file.c:4710 [inline] f2fs_file_write_iter+0x12b1/0x2570 fs/f2fs/file.c:4825 call_write_iter include/linux/fs.h:2023 [inline] new_sync_write fs/read_write.c:518 [inline] vfs_write+0xb4c/0xe70 fs/read_write.c:605 ksys_write+0x199/0x2c0 fs/read_write.c:658 __do_sys_write fs/read_write.c:670 [inline] __se_sys_write fs/read_write.c:667 [inline] __x64_sys_write+0x7b/0x90 fs/read_write.c:667 do_syscall_64+0x34/0x70 entry_SYSCALL_64_after_hwframe+0x61/0xcb RIP: 0033:0x7fa5aabb5809 Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007fa5a920b058 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 00007fa5aad7b080 RCX: 00007fa5aabb5809 RDX: 000000000000003b RSI: 0000000020000080 RDI: 0000000000000004 RBP: 00007fa5aac2893e R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000001 R14: 00007fa5aad7b080 R15: 00007ffdd32b4578 Modules linked in: ---[ end trace 68dbe18de2a41de3 ]--- RIP: 0010:f2fs_test_and_set_bit fs/f2fs/f2fs.h:2905 [inline] RIP: 0010:update_sit_entry+0x5e0/0x1060 fs/f2fs/segment.c:2330 Code: 4d 90 48 8d 5c c8 18 48 89 d8 48 c1 e8 03 42 80 3c 28 00 74 08 48 89 df e8 ad c8 88 ff 4c 8b 33 4d 01 fe 4d 89 f4 49 c1 ec 03 <43> 0f b6 04 2c 84 c0 0f 85 21 09 00 00 41 0f b6 1e 41 89 df 8b 45 RSP: 0018:ffffc90000f2ecf8 EFLAGS: 00010246 RAX: 1ffff1102399923a RBX: ffff88811ccc91d0 RCX: 0000000000000037 RDX: ffff88810ff5a780 RSI: 0000000000000000 RDI: 0000000000000000 RBP: ffffc90000f2ed90 R08: ffffffff821f8cf1 R09: ffffffff821f884d R10: 0000000000000003 R11: ffff88810ff5a780 R12: 0000000000000000 R13: dffffc0000000000 R14: 0000000000000000 R15: 0000000000000000 FS: 00007fa5a920b6c0(0000) GS:ffff8881f7000000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f48d2b05178 CR3: 00000001193a4000 CR4: 00000000003506b0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 ---------------- Code disassembly (best guess): 0: 4d 90 rex.WRB xchg %rax,%r8 2: 48 8d 5c c8 18 lea 0x18(%rax,%rcx,8),%rbx 7: 48 89 d8 mov %rbx,%rax a: 48 c1 e8 03 shr $0x3,%rax e: 42 80 3c 28 00 cmpb $0x0,(%rax,%r13,1) 13: 74 08 je 0x1d 15: 48 89 df mov %rbx,%rdi 18: e8 ad c8 88 ff call 0xff88c8ca 1d: 4c 8b 33 mov (%rbx),%r14 20: 4d 01 fe add %r15,%r14 23: 4d 89 f4 mov %r14,%r12 26: 49 c1 ec 03 shr $0x3,%r12 * 2a: 43 0f b6 04 2c movzbl (%r12,%r13,1),%eax <-- trapping instruction 2f: 84 c0 test %al,%al 31: 0f 85 21 09 00 00 jne 0x958 37: 41 0f b6 1e movzbl (%r14),%ebx 3b: 41 89 df mov %ebx,%r15d 3e: 8b .byte 0x8b 3f: 45 rex.RB