XFS (loop3): Quotacheck: Done. ================================================================== BUG: KASAN: stack-out-of-bounds in instrument_atomic_read include/linux/instrumented.h:68 [inline] BUG: KASAN: stack-out-of-bounds in atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline] BUG: KASAN: stack-out-of-bounds in xfs_buf_lock+0x9e/0x520 fs/xfs/xfs_buf.c:1191 Read of size 4 at addr ffffc9000fee7b84 by task syz-executor304/15128 CPU: 2 PID: 15128 Comm: syz-executor304 Not tainted 6.8.0-syzkaller-11725-g78c3925c048c #0 Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.2-debian-1.16.2-1 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x116/0x1f0 lib/dump_stack.c:114 print_address_description mm/kasan/report.c:377 [inline] print_report+0xc3/0x620 mm/kasan/report.c:488 kasan_report+0xd9/0x110 mm/kasan/report.c:601 check_region_inline mm/kasan/generic.c:183 [inline] kasan_check_range+0xef/0x1a0 mm/kasan/generic.c:189 instrument_atomic_read include/linux/instrumented.h:68 [inline] atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline] xfs_buf_lock+0x9e/0x520 fs/xfs/xfs_buf.c:1191 xfs_buf_delwri_submit_buffers+0x140/0xa40 fs/xfs/xfs_buf.c:2290 xfs_buf_delwri_submit+0x8a/0x270 fs/xfs/xfs_buf.c:2368 xfs_qm_shrink_scan+0x209/0x3f0 fs/xfs/xfs_qm.c:522 do_shrink_slab+0x44f/0x11c0 mm/shrinker.c:435 shrink_slab+0x18a/0x1310 mm/shrinker.c:662 drop_slab_node mm/vmscan.c:393 [inline] drop_slab+0x14c/0x2c0 mm/vmscan.c:411 drop_caches_sysctl_handler+0x171/0x190 fs/drop_caches.c:68 proc_sys_call_handler+0x4cc/0x6f0 fs/proc/proc_sysctl.c:595 call_write_iter include/linux/fs.h:2108 [inline] iter_file_splice_write+0x906/0x10b0 fs/splice.c:743 do_splice_from fs/splice.c:941 [inline] direct_splice_actor+0x19b/0x6d0 fs/splice.c:1164 splice_direct_to_actor+0x346/0xa40 fs/splice.c:1108 do_splice_direct_actor fs/splice.c:1207 [inline] do_splice_direct+0x17e/0x250 fs/splice.c:1233 do_sendfile+0xaa8/0xdb0 fs/read_write.c:1295 __do_sys_sendfile64 fs/read_write.c:1356 [inline] __se_sys_sendfile64 fs/read_write.c:1348 [inline] __x64_sys_sendfile64+0x155/0x220 fs/read_write.c:1348 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xd2/0x260 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x6d/0x75 RIP: 0033:0x7fdeb5214319 Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 21 18 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:00007ffd5f40e858 EFLAGS: 00000246 ORIG_RAX: 0000000000000028 RAX: ffffffffffffffda RBX: 0000000000000003 RCX: 00007fdeb5214319 RDX: 0000000020002080 RSI: 0000000000000004 RDI: 0000000000000005 RBP: 0000000000000000 R08: 00007ffd5f40e890 R09: 00007ffd5f40e890 R10: 0000000000000870 R11: 0000000000000246 R12: 00007ffd5f40e87c R13: 0000000000000117 R14: 431bde82d7b634db R15: 00007ffd5f40e8b0 The buggy address belongs to the virtual mapping at [ffffc9000fee0000, ffffc9000fee9000) created by: kernel_clone+0xfd/0x980 kernel/fork.c:2796 The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1daab flags: 0xfff80000000000(node=0|zone=1|lastcpupid=0xfff) page_type: 0xffffffff() raw: 00fff80000000000 0000000000000000 dead000000000122 0000000000000000 raw: 0000000000000000 0000000000000000 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x2dc2(GFP_KERNEL|__GFP_HIGHMEM|__GFP_NOWARN|__GFP_ZERO), pid 2, tgid 2 (kthreadd), ts 730689854027, free_ts 730672980329 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x2d4/0x350 mm/page_alloc.c:1534 prep_new_page mm/page_alloc.c:1541 [inline] get_page_from_freelist+0xa28/0x3780 mm/page_alloc.c:3317 __alloc_pages+0x22b/0x2460 mm/page_alloc.c:4575 alloc_pages_mpol+0x275/0x610 mm/mempolicy.c:2264 vm_area_alloc_pages mm/vmalloc.c:3545 [inline] __vmalloc_area_node mm/vmalloc.c:3621 [inline] __vmalloc_node_range+0xa26/0x14b0 mm/vmalloc.c:3802 alloc_thread_stack_node kernel/fork.c:309 [inline] dup_task_struct kernel/fork.c:1114 [inline] copy_process+0xe56/0x9160 kernel/fork.c:2219 kernel_clone+0xfd/0x980 kernel/fork.c:2796 kernel_thread+0xc0/0x100 kernel/fork.c:2858 create_kthread kernel/kthread.c:411 [inline] kthreadd+0x4ef/0x7d0 kernel/kthread.c:764 ret_from_fork+0x45/0x80 arch/x86/kernel/process.c:147 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:243 page last free pid 4684 tgid 4684 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1141 [inline] free_unref_page_prepare+0x527/0xb10 mm/page_alloc.c:2347 free_unref_page+0x33/0x3c0 mm/page_alloc.c:2487 selinux_genfs_get_sid security/selinux/hooks.c:1343 [inline] inode_doinit_with_dentry+0xac4/0x12c0 security/selinux/hooks.c:1541 selinux_d_instantiate+0x26/0x30 security/selinux/hooks.c:6345 security_d_instantiate+0x57/0xf0 security/security.c:3915 d_splice_alias+0x94/0xdf0 fs/dcache.c:2973 kernfs_iop_lookup+0x283/0x330 fs/kernfs/dir.c:1220 __lookup_slow+0x24f/0x460 fs/namei.c:1692 lookup_slow fs/namei.c:1709 [inline] walk_component+0x350/0x5b0 fs/namei.c:2004 lookup_last fs/namei.c:2461 [inline] path_lookupat+0x17f/0x770 fs/namei.c:2485 filename_lookup+0x1e5/0x5b0 fs/namei.c:2514 user_path_at_empty+0x42/0x60 fs/namei.c:2921 do_readlinkat+0xdd/0x310 fs/stat.c:499 __do_sys_readlink fs/stat.c:532 [inline] __se_sys_readlink fs/stat.c:529 [inline] __x64_sys_readlink+0x78/0xc0 fs/stat.c:529 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xd2/0x260 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x6d/0x75 Memory state around the buggy address: ffffc9000fee7a80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc9000fee7b00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 >ffffc9000fee7b80: f1 f1 04 f2 04 f2 00 f3 f3 f3 00 00 00 00 00 00 ^ ffffc9000fee7c00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc9000fee7c80: 00 00 00 00 00 00 00 00 f1 f1 f1 f1 f1 f1 04 f2 ==================================================================