==================================================================
BUG: KASAN: null-ptr-deref in instrument_atomic_read_write include/linux/instrumented.h:102 [inline]
BUG: KASAN: null-ptr-deref in atomic_try_cmpxchg_acquire include/linux/atomic/atomic-instrumented.h:541 [inline]
BUG: KASAN: null-ptr-deref in queued_write_lock include/asm-generic/qrwlock.h:98 [inline]
BUG: KASAN: null-ptr-deref in __raw_write_lock include/linux/rwlock_api_smp.h:210 [inline]
BUG: KASAN: null-ptr-deref in _raw_write_lock+0x97/0x170 kernel/locking/spinlock.c:300
Write of size 4 at addr 0000000000000030 by task syz-executor.0/8443
CPU: 1 PID: 8443 Comm: syz-executor.0 Not tainted 6.1.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/28/2023
Call Trace:
__dump_stack lib/dump_stack.c:88 [inline]
dump_stack_lvl+0x105/0x148 lib/dump_stack.c:106
print_report+0xe1/0x4e0 mm/kasan/report.c:398
kasan_report+0x13c/0x170 mm/kasan/report.c:495
kasan_check_range+0x294/0x2a0 mm/kasan/generic.c:189
__kasan_check_write+0x14/0x20 mm/kasan/shadow.c:37
instrument_atomic_read_write include/linux/instrumented.h:102 [inline]
atomic_try_cmpxchg_acquire include/linux/atomic/atomic-instrumented.h:541 [inline]
queued_write_lock include/asm-generic/qrwlock.h:98 [inline]
__raw_write_lock include/linux/rwlock_api_smp.h:210 [inline]
_raw_write_lock+0x97/0x170 kernel/locking/spinlock.c:300
__drop_extent_tree fs/f2fs/extent_cache.c:974 [inline]
f2fs_drop_extent_tree+0x1c1/0x3f0 fs/f2fs/extent_cache.c:990
f2fs_insert_range+0x339/0x450 fs/f2fs/file.c:1666
f2fs_fallocate+0x309/0x500 fs/f2fs/file.c:1840
vfs_fallocate+0x330/0x410 fs/open.c:323
ksys_fallocate fs/open.c:346 [inline]
__do_sys_fallocate fs/open.c:354 [inline]
__se_sys_fallocate fs/open.c:352 [inline]
__x64_sys_fallocate+0xb3/0xe0 fs/open.c:352
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:0x7fbbaf28c169
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 f1 19 00 00 90 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 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fbbb00cb168 EFLAGS: 00000246 ORIG_RAX: 000000000000011d
RAX: ffffffffffffffda RBX: 00007fbbaf3abf80 RCX: 00007fbbaf28c169
RDX: 0000000000000000 RSI: 0000000000000020 RDI: 0000000000000005
RBP: 00007fbbaf2e7ca1 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000010000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffe2418685f R14: 00007fbbb00cb300 R15: 0000000000022000
==================================================================
BUG: kernel NULL pointer dereference, address: 0000000000000030
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 1268db067 P4D 1268db067 PUD 113d28067 PMD 0
Oops: 0002 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 8443 Comm: syz-executor.0 Tainted: G B 6.1.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/28/2023
RIP: 0010:atomic_try_cmpxchg_acquire include/linux/atomic/atomic-instrumented.h:543 [inline]
RIP: 0010:queued_write_lock include/asm-generic/qrwlock.h:98 [inline]
RIP: 0010:__raw_write_lock include/linux/rwlock_api_smp.h:210 [inline]
RIP: 0010:_raw_write_lock+0xb6/0x170 kernel/locking/spinlock.c:300
Code: ef be 04 00 00 00 e8 89 4c 1a fd 4c 89 ff be 04 00 00 00 e8 7c 4c 1a fd 43 0f b6 04 26 84 c0 75 7d 8b 44 24 20 b9 ff 00 00 00 41 0f b1 4d 00 75 33 48 c7 04 24 0e 36 e0 45 49 c7 04 1c 00 00
RSP: 0018:ffffc90002047be0 EFLAGS: 00010297
RAX: 0000000000000000 RBX: 1ffff92000408f7c RCX: 00000000000000ff
RDX: 0000000000000001 RSI: 0000000000000004 RDI: ffffc90002047c00
RBP: ffffc90002047c70 R08: dffffc0000000000 R09: 0000000000000003
R10: ffffffffffffffff R11: dffffc0000000001 R12: dffffc0000000000
R13: 0000000000000030 R14: 1ffff92000408f80 R15: ffffc90002047c00
FS: 00007fbbb00cb700(0000) GS:ffff8881f7300000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000030 CR3: 0000000113a48000 CR4: 00000000003506a0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
__drop_extent_tree fs/f2fs/extent_cache.c:974 [inline]
f2fs_drop_extent_tree+0x1c1/0x3f0 fs/f2fs/extent_cache.c:990
f2fs_insert_range+0x339/0x450 fs/f2fs/file.c:1666
f2fs_fallocate+0x309/0x500 fs/f2fs/file.c:1840
vfs_fallocate+0x330/0x410 fs/open.c:323
ksys_fallocate fs/open.c:346 [inline]
__do_sys_fallocate fs/open.c:354 [inline]
__se_sys_fallocate fs/open.c:352 [inline]
__x64_sys_fallocate+0xb3/0xe0 fs/open.c:352
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:0x7fbbaf28c169
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 f1 19 00 00 90 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 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fbbb00cb168 EFLAGS: 00000246 ORIG_RAX: 000000000000011d
RAX: ffffffffffffffda RBX: 00007fbbaf3abf80 RCX: 00007fbbaf28c169
RDX: 0000000000000000 RSI: 0000000000000020 RDI: 0000000000000005
RBP: 00007fbbaf2e7ca1 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000010000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffe2418685f R14: 00007fbbb00cb300 R15: 0000000000022000
Modules linked in:
CR2: 0000000000000030
---[ end trace 0000000000000000 ]---
RIP: 0010:atomic_try_cmpxchg_acquire include/linux/atomic/atomic-instrumented.h:543 [inline]
RIP: 0010:queued_write_lock include/asm-generic/qrwlock.h:98 [inline]
RIP: 0010:__raw_write_lock include/linux/rwlock_api_smp.h:210 [inline]
RIP: 0010:_raw_write_lock+0xb6/0x170 kernel/locking/spinlock.c:300
Code: ef be 04 00 00 00 e8 89 4c 1a fd 4c 89 ff be 04 00 00 00 e8 7c 4c 1a fd 43 0f b6 04 26 84 c0 75 7d 8b 44 24 20 b9 ff 00 00 00 41 0f b1 4d 00 75 33 48 c7 04 24 0e 36 e0 45 49 c7 04 1c 00 00
RSP: 0018:ffffc90002047be0 EFLAGS: 00010297
RAX: 0000000000000000 RBX: 1ffff92000408f7c RCX: 00000000000000ff
RDX: 0000000000000001 RSI: 0000000000000004 RDI: ffffc90002047c00
RBP: ffffc90002047c70 R08: dffffc0000000000 R09: 0000000000000003
R10: ffffffffffffffff R11: dffffc0000000001 R12: dffffc0000000000
R13: 0000000000000030 R14: 1ffff92000408f80 R15: ffffc90002047c00
FS: 00007fbbb00cb700(0000) GS:ffff8881f7300000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000030 CR3: 0000000113a48000 CR4: 00000000003506a0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
0: ef out %eax,(%dx)
1: be 04 00 00 00 mov $0x4,%esi
6: e8 89 4c 1a fd callq 0xfd1a4c94
b: 4c 89 ff mov %r15,%rdi
e: be 04 00 00 00 mov $0x4,%esi
13: e8 7c 4c 1a fd callq 0xfd1a4c94
18: 43 0f b6 04 26 movzbl (%r14,%r12,1),%eax
1d: 84 c0 test %al,%al
1f: 75 7d jne 0x9e
21: 8b 44 24 20 mov 0x20(%rsp),%eax
25: b9 ff 00 00 00 mov $0xff,%ecx
* 2a: f0 41 0f b1 4d 00 lock cmpxchg %ecx,0x0(%r13) <-- trapping instruction
30: 75 33 jne 0x65
32: 48 c7 04 24 0e 36 e0 movq $0x45e0360e,(%rsp)
39: 45
3a: 49 rex.WB
3b: c7 .byte 0xc7
3c: 04 1c add $0x1c,%al