BTRFS info (device loop1): disabling disk space caching ================================================================== 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 ffff8880ae148e58 by task syz-executor.3/17630 CPU: 1 PID: 17630 Comm: syz-executor.3 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_bio+0x3a6/0x4d0 kernel/trace/blktrace.c:915 trace_block_bio_queue include/trace/events/block.h:357 [inline] generic_make_request_checks+0x1637/0x22e0 block/blk-core.c:2346 generic_make_request+0x23f/0xdf0 block/blk-core.c:2412 submit_bio+0xb1/0x430 block/blk-core.c:2576 submit_bh_wbc+0x5a7/0x760 fs/buffer.c:3090 submit_bh fs/buffer.c:3096 [inline] __bread_slow fs/buffer.c:1176 [inline] __bread_gfp+0x14e/0x300 fs/buffer.c:1369 sb_bread include/linux/buffer_head.h:309 [inline] fat_fill_super+0x317/0x35a0 fs/fat/inode.c:1644 mount_bdev+0x2fc/0x3b0 fs/super.c:1158 mount_fs+0xa3/0x310 fs/super.c:1261 vfs_kern_mount.part.0+0x68/0x470 fs/namespace.c:961 vfs_kern_mount fs/namespace.c:951 [inline] do_new_mount fs/namespace.c:2492 [inline] do_mount+0x115c/0x2f50 fs/namespace.c:2822 ksys_mount+0xcf/0x130 fs/namespace.c:3038 __do_sys_mount fs/namespace.c:3052 [inline] __se_sys_mount fs/namespace.c:3049 [inline] __x64_sys_mount+0xba/0x150 fs/namespace.c:3049 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x7f3ec7b3f63a Code: 48 c7 c2 b8 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb d2 e8 b8 04 00 00 0f 1f 84 00 00 00 00 00 49 89 ca b8 a5 00 00 00 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:00007f3ec64b2f88 EFLAGS: 00000206 ORIG_RAX: 00000000000000a5 RAX: ffffffffffffffda RBX: 0000000020000600 RCX: 00007f3ec7b3f63a RDX: 0000000020000200 RSI: 0000000020000100 RDI: 00007f3ec64b2fe0 RBP: 00007f3ec64b3020 R08: 00007f3ec64b3020 R09: 0000000020000200 R10: 0000000000000000 R11: 0000000000000206 R12: 0000000020000200 R13: 0000000020000100 R14: 00007f3ec64b2fe0 R15: 0000000020000180 Allocated by task 14598: 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 d_alloc_parallel+0xeb/0x19e0 fs/dcache.c:2443 __lookup_slow+0x18d/0x4a0 fs/namei.c:1655 lookup_slow fs/namei.c:1689 [inline] walk_component+0x7ac/0xda0 fs/namei.c:1811 link_path_walk.part.0+0x901/0x1230 fs/namei.c:2142 link_path_walk fs/namei.c:2270 [inline] path_lookupat+0xe4/0x8d0 fs/namei.c:2318 filename_lookup+0x1ac/0x5a0 fs/namei.c:2349 user_path_at include/linux/namei.h:57 [inline] vfs_statx+0x113/0x210 fs/stat.c:185 vfs_stat include/linux/fs.h:3132 [inline] __do_sys_newstat fs/stat.c:337 [inline] __se_sys_newstat+0x96/0x120 fs/stat.c:333 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 18: __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 ffff8880ae148e00 which belongs to the cache dentry of size 288 The buggy address is located 88 bytes inside of 288-byte region [ffff8880ae148e00, ffff8880ae148f20) The buggy address belongs to the page: page:ffffea0002b85200 count:1 mapcount:0 mapping:ffff88813be45200 index:0xffff8880ae1485c0 flags: 0xfff00000000100(slab) raw: 00fff00000000100 ffffea0002b87488 ffffea0002b88708 ffff88813be45200 raw: ffff8880ae1485c0 ffff8880ae148040 0000000100000008 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880ae148d00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880ae148d80: 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc fc >ffff8880ae148e00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff8880ae148e80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8880ae148f00: fb fb fb fb fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================