RDX: 0000000000000000 RSI: 0000000020000400 RDI: 0000000000000004 RBP: 00007f1103d680ed R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffc2d7659cf R14: 00007f1102683300 R15: 0000000000022000 ================================================================== BUG: KASAN: use-after-free in d_inode include/linux/dcache.h:516 [inline] BUG: KASAN: use-after-free in relay_switch_subbuf+0x8cc/0x940 kernel/relay.c:761 Read of size 8 at addr ffff8880a1da51b8 by task kworker/u4:1/24479 CPU: 0 PID: 24479 Comm: kworker/u4:1 Not tainted 4.19.211-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/29/2022 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x1fc/0x2ef lib/dump_stack.c:118 print_address_description.cold+0x54/0x219 mm/kasan/report.c:256 kasan_report_error.cold+0x8a/0x1b9 mm/kasan/report.c:354 kasan_report mm/kasan/report.c:412 [inline] __asan_report_load8_noabort+0x88/0x90 mm/kasan/report.c:433 d_inode include/linux/dcache.h:516 [inline] relay_switch_subbuf+0x8cc/0x940 kernel/relay.c:761 relay_reserve include/linux/relay.h:261 [inline] trace_note+0x5eb/0x750 kernel/trace/blktrace.c:96 trace_note_tsk kernel/trace/blktrace.c:127 [inline] __blk_add_trace+0xb86/0xe20 kernel/trace/blktrace.c:267 blk_add_trace_plug+0xfe/0x240 kernel/trace/blktrace.c:1000 trace_block_plug include/trace/events/block.h:456 [inline] blk_mq_make_request+0x14b7/0x1c00 block/blk-mq.c:1902 generic_make_request+0x613/0xdf0 block/blk-core.c:2467 submit_bio+0xb1/0x430 block/blk-core.c:2576 ext4_mpage_readpages+0x679/0x1aa0 fs/ext4/readpage.c:293 ext4_readpages+0xd5/0x110 fs/ext4/inode.c:3372 read_pages.isra.0+0xf6/0x5d0 mm/readahead.c:123 __do_page_cache_readahead+0x5c6/0x6c0 mm/readahead.c:211 ra_submit mm/internal.h:66 [inline] ondemand_readahead.isra.0+0x575/0xd40 mm/readahead.c:493 page_cache_sync_readahead mm/readahead.c:528 [inline] page_cache_sync_readahead+0x275/0x520 mm/readahead.c:510 generic_file_buffered_read mm/filemap.c:2115 [inline] generic_file_read_iter+0x1497/0x2b60 mm/filemap.c:2385 ext4_file_read_iter+0x17b/0x3a0 fs/ext4/file.c:78 call_read_iter include/linux/fs.h:1815 [inline] new_sync_read fs/read_write.c:406 [inline] __vfs_read+0x518/0x750 fs/read_write.c:418 vfs_read+0x194/0x3c0 fs/read_write.c:452 kernel_read+0xa6/0x110 fs/read_write.c:431 prepare_binprm+0x64f/0x890 fs/exec.c:1596 __do_execve_file+0xfb8/0x2360 fs/exec.c:1815 do_execveat_common fs/exec.c:1879 [inline] do_execve+0x35/0x50 fs/exec.c:1896 call_usermodehelper_exec_async+0x50e/0x6a0 kernel/umh.c:116 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415 Allocated by task 23536: kmem_cache_alloc+0x122/0x370 mm/slab.c:3559 __d_alloc+0x2b/0xa10 fs/dcache.c:1612 d_alloc+0x4a/0x230 fs/dcache.c:1696 __lookup_hash+0xc8/0x180 fs/namei.c:1543 do_unlinkat+0x295/0x660 fs/namei.c:4052 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 8108: __cache_free mm/slab.c:3503 [inline] kmem_cache_free+0x7f/0x260 mm/slab.c:3765 __rcu_reclaim kernel/rcu/rcu.h:236 [inline] rcu_do_batch kernel/rcu/tree.c:2584 [inline] invoke_rcu_callbacks kernel/rcu/tree.c:2897 [inline] __rcu_process_callbacks kernel/rcu/tree.c:2864 [inline] rcu_process_callbacks+0x8ff/0x18b0 kernel/rcu/tree.c:2881 __do_softirq+0x265/0x980 kernel/softirq.c:292 The buggy address belongs to the object at ffff8880a1da5160 which belongs to the cache dentry of size 288 The buggy address is located 88 bytes inside of 288-byte region [ffff8880a1da5160, ffff8880a1da5280) The buggy address belongs to the page: page:ffffea0002876940 count:1 mapcount:0 mapping:ffff88813be45200 index:0x0 flags: 0xfff00000000100(slab) raw: 00fff00000000100 ffffea0002371588 ffffea000239d008 ffff88813be45200 raw: 0000000000000000 ffff8880a1da5000 000000010000000b 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a1da5080: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880a1da5100: fb fb fb fb fc fc fc fc fc fc fc fc fb fb fb fb >ffff8880a1da5180: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff8880a1da5200: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880a1da5280: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ==================================================================