================================================================== BUG: KASAN: null-ptr-deref in instrument_atomic_read_write include/linux/instrumented.h:102 [inline] BUG: KASAN: null-ptr-deref in atomic_inc include/linux/atomic/atomic-instrumented.h:190 [inline] BUG: KASAN: null-ptr-deref in xfs_filestream_create_association fs/xfs/xfs_filestream.c:321 [inline] BUG: KASAN: null-ptr-deref in xfs_filestream_select_ag+0x11d9/0x1ca0 fs/xfs/xfs_filestream.c:372 Write of size 4 at addr 0000000000000010 by task syz-executor.3/17714 CPU: 0 PID: 17714 Comm: syz-executor.3 Not tainted 6.3.0-rc6-syzkaller-00183-ga7a55e27ad72 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/30/2023 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x1e7/0x2d0 lib/dump_stack.c:106 print_report+0xe6/0x540 mm/kasan/report.c:433 kasan_report+0x176/0x1b0 mm/kasan/report.c:536 kasan_check_range+0x283/0x290 mm/kasan/generic.c:187 instrument_atomic_read_write include/linux/instrumented.h:102 [inline] atomic_inc include/linux/atomic/atomic-instrumented.h:190 [inline] xfs_filestream_create_association fs/xfs/xfs_filestream.c:321 [inline] xfs_filestream_select_ag+0x11d9/0x1ca0 fs/xfs/xfs_filestream.c:372 xfs_bmap_btalloc_filestreams fs/xfs/libxfs/xfs_bmap.c:3558 [inline] xfs_bmap_btalloc+0xffa/0x28a0 fs/xfs/libxfs/xfs_bmap.c:3672 xfs_bmapi_allocate+0x647/0xf30 xfs_bmapi_convert_delalloc+0x98f/0x1310 fs/xfs/libxfs/xfs_bmap.c:4554 xfs_convert_blocks fs/xfs/xfs_aops.c:266 [inline] xfs_map_blocks+0x780/0x1090 fs/xfs/xfs_aops.c:389 iomap_writepage_map fs/iomap/buffered-io.c:1641 [inline] iomap_do_writepage+0x941/0x2ee0 fs/iomap/buffered-io.c:1803 write_cache_pages+0x89e/0x12c0 mm/page-writeback.c:2473 iomap_writepages+0x68/0x240 fs/iomap/buffered-io.c:1820 xfs_vm_writepages+0x139/0x1a0 fs/xfs/xfs_aops.c:513 do_writepages+0x3a6/0x670 mm/page-writeback.c:2551 filemap_fdatawrite_wbc+0x125/0x180 mm/filemap.c:390 __filemap_fdatawrite_range mm/filemap.c:423 [inline] file_write_and_wait_range+0x20f/0x300 mm/filemap.c:781 xfs_file_fsync+0x1c6/0xa50 fs/xfs/xfs_file.c:151 generic_write_sync include/linux/fs.h:2452 [inline] xfs_file_buffered_write+0xa0e/0xb50 fs/xfs/xfs_file.c:764 call_write_iter include/linux/fs.h:1851 [inline] new_sync_write fs/read_write.c:491 [inline] vfs_write+0x7b2/0xbb0 fs/read_write.c:584 ksys_write+0x1a0/0x2c0 fs/read_write.c:637 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7fd4c308c169 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:00007fd4c3d92168 EFLAGS: 00000246 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 00007fd4c31ac050 RCX: 00007fd4c308c169 RDX: 000000000000fdef RSI: 0000000020000080 RDI: 0000000000000005 RBP: 00007fd4c30e7ca1 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007fff1cd026cf R14: 00007fd4c3d92300 R15: 0000000000022000 ==================================================================