================================================================== BUG: KASAN: out-of-bounds in instrument_atomic_read_write include/linux/instrumented.h:96 [inline] BUG: KASAN: out-of-bounds in atomic_dec include/linux/atomic/atomic-instrumented.h:592 [inline] BUG: KASAN: out-of-bounds in put_bh include/linux/buffer_head.h:301 [inline] BUG: KASAN: out-of-bounds in end_buffer_read_sync+0xc1/0xd0 fs/buffer.c:161 Write of size 4 at addr ffffc9000418f660 by task kworker/u8:8/3480 CPU: 0 UID: 0 PID: 3480 Comm: kworker/u8:8 Not tainted 6.14.0-next-20250404-syzkaller #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2025 Workqueue: loop1 loop_rootcg_workfn Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:408 [inline] print_report+0x16e/0x5b0 mm/kasan/report.c:521 kasan_report+0x143/0x180 mm/kasan/report.c:634 check_region_inline mm/kasan/generic.c:-1 [inline] kasan_check_range+0x28f/0x2a0 mm/kasan/generic.c:189 instrument_atomic_read_write include/linux/instrumented.h:96 [inline] atomic_dec include/linux/atomic/atomic-instrumented.h:592 [inline] put_bh include/linux/buffer_head.h:301 [inline] end_buffer_read_sync+0xc1/0xd0 fs/buffer.c:161 end_bio_bh_io_sync+0xbf/0x120 fs/buffer.c:2748 blk_update_request+0x5e5/0x1160 block/blk-mq.c:983 blk_mq_end_request+0x3e/0x70 block/blk-mq.c:1145 blk_complete_reqs block/blk-mq.c:1220 [inline] blk_done_softirq+0x100/0x150 block/blk-mq.c:1225 handle_softirqs+0x2d6/0x9b0 kernel/softirq.c:579 __do_softirq kernel/softirq.c:613 [inline] invoke_softirq kernel/softirq.c:453 [inline] __irq_exit_rcu+0xfb/0x220 kernel/softirq.c:680 irq_exit_rcu+0x9/0x30 kernel/softirq.c:696 instr_sysvec_call_function_single arch/x86/kernel/smp.c:266 [inline] sysvec_call_function_single+0xa3/0xc0 arch/x86/kernel/smp.c:266 asm_sysvec_call_function_single+0x1a/0x20 arch/x86/include/asm/idtentry.h:709 RIP: 0010:raise_softirq+0x134/0x190 kernel/softirq.c:741 Code: 40 42 80 3c 2b 00 74 08 4c 89 f7 e8 b6 29 a9 00 f6 44 24 41 02 75 52 41 f7 c4 00 02 00 00 74 01 fb 48 c7 44 24 20 0e 36 e0 45 <4b> c7 44 3d 00 00 00 00 00 66 43 c7 44 3d 09 00 00 43 c6 44 3d 0b RSP: 0018:ffffc9000c64f520 EFLAGS: 00000206 RAX: 6faedcbf23e1ed00 RBX: 1ffff920018c9eac RCX: 0000000000000006 RDX: 0000000000000006 RSI: ffffffff8e6a4c4b RDI: ffffffff8ca1e060 RBP: ffffc9000c64f5e8 R08: ffffffff905ffd37 R09: 1ffffffff20bffa6 R10: dffffc0000000000 R11: fffffbfff20bffa7 R12: 0000000000000246 R13: dffffc0000000000 R14: ffffc9000c64f560 R15: 1ffff920018c9ea8 blk_mq_raise_softirq block/blk-mq.c:1282 [inline] blk_mq_complete_request_remote+0x541/0x740 block/blk-mq.c:1306 blk_mq_complete_request+0x19/0xa0 block/blk-mq.c:1322 loop_handle_cmd drivers/block/loop.c:1960 [inline] loop_process_work+0x1bdf/0x21d0 drivers/block/loop.c:1978 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xac3/0x18e0 kernel/workqueue.c:3319 worker_thread+0x870/0xd50 kernel/workqueue.c:3400 kthread+0x7b7/0x940 kernel/kthread.c:464 ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:153 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 The buggy address belongs to the virtual mapping at [ffffc90004188000, ffffc90004191000) created by: copy_process+0x5dc/0x3d10 kernel/fork.c:2259 The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x1ab pfn:0x266e3 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 0000000000000000 dead000000000122 0000000000000000 raw: 00000000000001ab 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_ZERO|__GFP_NOWARN), pid 5847, tgid 5847 (syz-executor298), ts 88849194618, free_ts 88820484059 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1f4/0x240 mm/page_alloc.c:1718 prep_new_page mm/page_alloc.c:1726 [inline] get_page_from_freelist+0x356d/0x3700 mm/page_alloc.c:3655 __alloc_frozen_pages_noprof+0x211/0x5b0 mm/page_alloc.c:4937 alloc_pages_mpol+0x339/0x690 mm/mempolicy.c:2302 alloc_frozen_pages_noprof mm/mempolicy.c:2373 [inline] alloc_pages_noprof+0x121/0x190 mm/mempolicy.c:2393 vm_area_alloc_pages mm/vmalloc.c:3591 [inline] __vmalloc_area_node mm/vmalloc.c:3669 [inline] __vmalloc_node_range_noprof+0x9cb/0x1390 mm/vmalloc.c:3844 __vmalloc_node_noprof+0x80/0xa0 mm/vmalloc.c:3907 alloc_thread_stack_node kernel/fork.c:314 [inline] dup_task_struct+0x3f7/0x870 kernel/fork.c:1136 copy_process+0x5dc/0x3d10 kernel/fork.c:2259 kernel_clone+0x242/0x930 kernel/fork.c:2844 __do_sys_clone kernel/fork.c:2987 [inline] __se_sys_clone kernel/fork.c:2971 [inline] __x64_sys_clone+0x268/0x2e0 kernel/fork.c:2971 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xf3/0x230 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f page last free pid 5849 tgid 5849 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1262 [inline] free_unref_folios+0xe0e/0x17f0 mm/page_alloc.c:2739 folios_put_refs+0x70a/0x800 mm/swap.c:992 folio_batch_release include/linux/pagevec.h:101 [inline] truncate_inode_pages_range+0x462/0x10e0 mm/truncate.c:379 kill_bdev block/bdev.c:91 [inline] blkdev_flush_mapping+0x108/0x270 block/bdev.c:674 blkdev_put_whole block/bdev.c:681 [inline] bdev_release+0x460/0x700 block/bdev.c:1106 blkdev_release+0x15/0x20 block/fops.c:660 __fput+0x3e9/0x9f0 fs/file_table.c:465 task_work_run+0x251/0x310 kernel/task_work.c:227 ptrace_notify+0x2dc/0x390 kernel/signal.c:2520 ptrace_report_syscall include/linux/ptrace.h:415 [inline] ptrace_report_syscall_exit include/linux/ptrace.h:477 [inline] syscall_exit_work+0xc7/0x1d0 kernel/entry/common.c:173 syscall_exit_to_user_mode_prepare kernel/entry/common.c:200 [inline] __syscall_exit_to_user_mode_work kernel/entry/common.c:205 [inline] syscall_exit_to_user_mode+0x24a/0x340 kernel/entry/common.c:218 do_syscall_64+0x100/0x230 arch/x86/entry/syscall_64.c:100 entry_SYSCALL_64_after_hwframe+0x77/0x7f Memory state around the buggy address: ffffc9000418f500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc9000418f580: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffffc9000418f600: 00 00 00 00 00 00 00 00 f1 f1 f1 f1 00 00 00 00 ^ ffffc9000418f680: 00 00 00 f2 f2 f2 f2 f2 00 f2 f2 f2 01 f3 f3 f3 ffffc9000418f700: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ================================================================== ---------------- Code disassembly (best guess): 0: 40 rex 1: 42 80 3c 2b 00 cmpb $0x0,(%rbx,%r13,1) 6: 74 08 je 0x10 8: 4c 89 f7 mov %r14,%rdi b: e8 b6 29 a9 00 call 0xa929c6 10: f6 44 24 41 02 testb $0x2,0x41(%rsp) 15: 75 52 jne 0x69 17: 41 f7 c4 00 02 00 00 test $0x200,%r12d 1e: 74 01 je 0x21 20: fb sti 21: 48 c7 44 24 20 0e 36 movq $0x45e0360e,0x20(%rsp) 28: e0 45 * 2a: 4b c7 44 3d 00 00 00 movq $0x0,0x0(%r13,%r15,1) <-- trapping instruction 31: 00 00 33: 66 43 c7 44 3d 09 00 movw $0x0,0x9(%r13,%r15,1) 3a: 00 3b: 43 rex.XB 3c: c6 .byte 0xc6 3d: 44 rex.R 3e: 3d .byte 0x3d 3f: 0b .byte 0xb