================================================================== 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:302 [inline] BUG: KASAN: out-of-bounds in end_buffer_read_sync+0xc1/0xd0 fs/buffer.c:161 Write of size 4 at addr ffffc90003fef660 by task kworker/u8:7/1127 CPU: 0 UID: 0 PID: 1127 Comm: kworker/u8:7 Not tainted 6.14.0-rc7-syzkaller-00069-g81e4f8d68c66 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2025 Workqueue: loop0 loop_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 kasan_check_range+0x282/0x290 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:302 [inline] end_buffer_read_sync+0xc1/0xd0 fs/buffer.c:161 end_bio_bh_io_sync+0xc1/0x120 fs/buffer.c:2766 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+0x102/0x150 block/blk-mq.c:1225 handle_softirqs+0x2d6/0x9b0 kernel/softirq.c:561 __do_softirq kernel/softirq.c:595 [inline] invoke_softirq kernel/softirq.c:435 [inline] __irq_exit_rcu+0xf7/0x220 kernel/softirq.c:662 irq_exit_rcu+0x9/0x30 kernel/softirq.c:678 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+0x132/0x190 kernel/softirq.c:723 Code: 40 42 80 3c 23 00 74 08 4c 89 f7 e8 e8 ae a5 00 f6 44 24 41 02 75 4f 41 f7 c5 00 02 00 00 74 01 fb 48 c7 44 24 20 0e 36 e0 45 <4b> c7 04 3c 00 00 00 00 66 43 c7 44 3c 09 00 00 43 c6 44 3c 0b 00 RSP: 0018:ffffc9000402f520 EFLAGS: 00000206 RAX: 3fea864c9d2a4700 RBX: 1ffff92000805eac RCX: ffffffff819d4c7a RDX: dffffc0000000000 RSI: ffffffff8c2ab3a0 RDI: ffffffff8c8100a0 RBP: ffffc9000402f5e8 R08: ffffffff9454d967 R09: 1ffffffff28a9b2c R10: dffffc0000000000 R11: fffffbfff28a9b2d R12: dffffc0000000000 R13: 0000000000000246 R14: ffffc9000402f560 R15: 1ffff92000805ea8 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:1946 [inline] loop_process_work+0x1bc8/0x21c0 drivers/block/loop.c:1964 process_one_work kernel/workqueue.c:3238 [inline] process_scheduled_works+0xac0/0x18e0 kernel/workqueue.c:3319 worker_thread+0x870/0xd30 kernel/workqueue.c:3400 kthread+0x7ab/0x920 kernel/kthread.c:464 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:148 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244 The buggy address belongs to the virtual mapping at [ffffc90003fe8000, ffffc90003ff1000) created by: copy_process+0x5d1/0x3cf0 kernel/fork.c:2233 The buggy address belongs to the physical page: page: refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888067666000 pfn:0x67660 memcg:ffff888029593c82 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 0000000000000000 dead000000000122 0000000000000000 raw: ffff888067666000 0000000000000000 00000001ffffffff ffff888029593c82 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 15727, tgid 15727 (syz.6.2032), ts 1252677698673, free_ts 1251669256131 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1f4/0x240 mm/page_alloc.c:1551 prep_new_page mm/page_alloc.c:1559 [inline] get_page_from_freelist+0x365c/0x37a0 mm/page_alloc.c:3477 __alloc_frozen_pages_noprof+0x292/0x710 mm/page_alloc.c:4740 alloc_pages_mpol+0x311/0x660 mm/mempolicy.c:2270 alloc_frozen_pages_noprof mm/mempolicy.c:2341 [inline] alloc_pages_noprof+0x121/0x190 mm/mempolicy.c:2361 vm_area_alloc_pages mm/vmalloc.c:3591 [inline] __vmalloc_area_node mm/vmalloc.c:3669 [inline] __vmalloc_node_range_noprof+0x9c6/0x1380 mm/vmalloc.c:3846 alloc_thread_stack_node kernel/fork.c:314 [inline] dup_task_struct+0x444/0x8c0 kernel/fork.c:1127 copy_process+0x5d1/0x3cf0 kernel/fork.c:2233 kernel_clone+0x226/0x8e0 kernel/fork.c:2815 __do_sys_clone3 kernel/fork.c:3119 [inline] __se_sys_clone3+0x2ee/0x380 kernel/fork.c:3098 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x77/0x7f page last free pid 25 tgid 25 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1127 [inline] free_frozen_pages+0xe0d/0x10e0 mm/page_alloc.c:2660 pagetable_free include/linux/mm.h:2923 [inline] pagetable_dtor_free include/linux/mm.h:3021 [inline] __tlb_remove_table+0x33c/0x420 include/asm-generic/tlb.h:216 __tlb_remove_table_free mm/mmu_gather.c:227 [inline] tlb_remove_table_rcu+0x76/0xf0 mm/mmu_gather.c:282 rcu_do_batch kernel/rcu/tree.c:2546 [inline] rcu_core+0xaac/0x17a0 kernel/rcu/tree.c:2802 handle_softirqs+0x2d6/0x9b0 kernel/softirq.c:561 run_ksoftirqd+0xca/0x130 kernel/softirq.c:950 smpboot_thread_fn+0x546/0xa30 kernel/smpboot.c:164 kthread+0x7ab/0x920 kernel/kthread.c:464 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:148 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244 Memory state around the buggy address: ffffc90003fef500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffffc90003fef580: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffffc90003fef600: 00 00 00 00 00 00 00 00 f1 f1 f1 f1 00 00 00 00 ^ ffffc90003fef680: 00 00 00 f2 f2 f2 f2 f2 00 f2 f2 f2 01 f3 f3 f3 ffffc90003fef700: 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 23 00 cmpb $0x0,(%rbx,%r12,1) 6: 74 08 je 0x10 8: 4c 89 f7 mov %r14,%rdi b: e8 e8 ae a5 00 call 0xa5aef8 10: f6 44 24 41 02 testb $0x2,0x41(%rsp) 15: 75 4f jne 0x66 17: 41 f7 c5 00 02 00 00 test $0x200,%r13d 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 04 3c 00 00 00 movq $0x0,(%r12,%r15,1) <-- trapping instruction 31: 00 32: 66 43 c7 44 3c 09 00 movw $0x0,0x9(%r12,%r15,1) 39: 00 3a: 43 c6 44 3c 0b 00 movb $0x0,0xb(%r12,%r15,1)