================================================================== BUG: KASAN: slab-out-of-bounds in tcp_retransmit_timer+0x2d30/0x3220 net/ipv4/tcp_timer.c:499 Read of size 8 at addr ffff88804563c350 by task systemd-udevd/3812 CPU: 0 PID: 3812 Comm: systemd-udevd Not tainted 5.9.0-rc6-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x198/0x1fd lib/dump_stack.c:118 print_address_description.constprop.0.cold+0xae/0x497 mm/kasan/report.c:383 __kasan_report mm/kasan/report.c:513 [inline] kasan_report.cold+0x1f/0x37 mm/kasan/report.c:530 tcp_retransmit_timer+0x2d30/0x3220 net/ipv4/tcp_timer.c:499 tcp_write_timer_handler+0x79b/0xa60 net/ipv4/tcp_timer.c:610 tcp_write_timer+0xa2/0x2b0 net/ipv4/tcp_timer.c:630 call_timer_fn+0x1ac/0x760 kernel/time/timer.c:1413 expire_timers kernel/time/timer.c:1458 [inline] __run_timers.part.0+0x67c/0xaa0 kernel/time/timer.c:1755 __run_timers kernel/time/timer.c:1736 [inline] run_timer_softirq+0xb3/0x1d0 kernel/time/timer.c:1768 __do_softirq+0x1f8/0xb23 kernel/softirq.c:298 asm_call_on_stack+0xf/0x20 arch/x86/entry/entry_64.S:706 __run_on_irqstack arch/x86/include/asm/irq_stack.h:22 [inline] run_on_irqstack_cond arch/x86/include/asm/irq_stack.h:48 [inline] do_softirq_own_stack+0x9d/0xd0 arch/x86/kernel/irq_64.c:77 invoke_softirq kernel/softirq.c:393 [inline] __irq_exit_rcu kernel/softirq.c:423 [inline] irq_exit_rcu+0x235/0x280 kernel/softirq.c:435 sysvec_apic_timer_interrupt+0x51/0xf0 arch/x86/kernel/apic/apic.c:1091 asm_sysvec_apic_timer_interrupt+0x12/0x20 arch/x86/include/asm/idtentry.h:581 RIP: 0010:check_kcov_mode kernel/kcov.c:165 [inline] RIP: 0010:__sanitizer_cov_trace_pc+0x2a/0x60 kernel/kcov.c:197 Code: 65 48 8b 14 25 c0 fe 01 00 65 8b 05 c0 76 8b 7e a9 00 01 ff 00 48 8b 34 24 74 0f f6 c4 01 74 35 8b 82 4c 14 00 00 85 c0 74 2b <8b> 82 28 14 00 00 83 f8 02 75 20 48 8b 8a 30 14 00 00 8b 92 2c 14 RSP: 0018:ffffc90005f77708 EFLAGS: 00000246 RAX: 0000000080000000 RBX: ffff888057f4a100 RCX: ffffffff8135d0e8 RDX: ffff88804a708180 RSI: ffffffff8135d0f2 RDI: 0000000000000006 RBP: ffff8880d7f4a100 R08: 0000000000000001 R09: ffffffff8d10ba77 R10: ffff8880d7f4a100 R11: 0000000000000000 R12: 0000000057f4a100 R13: ffffc90005f77778 R14: 0000000000000200 R15: dffffc0000000000 phys_addr_valid arch/x86/mm/physaddr.h:7 [inline] __phys_addr+0x52/0x110 arch/x86/mm/physaddr.c:28 virt_to_head_page include/linux/mm.h:850 [inline] qlink_to_cache mm/kasan/quarantine.c:128 [inline] qlist_free_all+0xd9/0x170 mm/kasan/quarantine.c:165 quarantine_reduce+0x17e/0x200 mm/kasan/quarantine.c:261 __kasan_kmalloc.constprop.0+0x9e/0xd0 mm/kasan/common.c:442 slab_post_alloc_hook mm/slab.h:518 [inline] slab_alloc mm/slab.c:3312 [inline] kmem_cache_alloc+0x13a/0x3f0 mm/slab.c:3482 shmem_alloc_inode+0x18/0x40 mm/shmem.c:3821 alloc_inode+0x61/0x230 fs/inode.c:232 new_inode_pseudo fs/inode.c:928 [inline] new_inode+0x27/0x2f0 fs/inode.c:957 shmem_get_inode+0x195/0xc10 mm/shmem.c:2293 shmem_mknod+0x5a/0x1f0 mm/shmem.c:2920 lookup_open.isra.0+0xf85/0x1350 fs/namei.c:3103 open_last_lookups fs/namei.c:3177 [inline] path_openat+0x96d/0x2730 fs/namei.c:3365 do_filp_open+0x17e/0x3c0 fs/namei.c:3395 do_sys_openat2+0x16d/0x420 fs/open.c:1168 do_sys_open fs/open.c:1184 [inline] __do_sys_open fs/open.c:1192 [inline] __se_sys_open fs/open.c:1188 [inline] __x64_sys_open+0x119/0x1c0 fs/open.c:1188 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 RIP: 0033:0x7f32d45d46f0 Code: 00 f7 d8 64 89 01 48 83 c8 ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 83 3d 19 30 2c 00 00 75 10 b8 02 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 31 c3 48 83 ec 08 e8 fe 9d 01 00 48 89 04 24 RSP: 002b:00007ffcf914f158 EFLAGS: 00000246 ORIG_RAX: 0000000000000002 RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f32d45d46f0 RDX: 0000000000000180 RSI: 00000000000800c2 RDI: 000055921bc116b0 RBP: 000000000003a2f8 R08: 000000000000fcff R09: 0000000000000030 R10: 0000000000000000 R11: 0000000000000246 R12: 000055921bc116c5 R13: 8421084210842109 R14: 00000000000800c2 R15: 00007f32d4662540 Allocated by task 3898: kasan_save_stack+0x1b/0x40 mm/kasan/common.c:48 kasan_set_track mm/kasan/common.c:56 [inline] __kasan_kmalloc.constprop.0+0xbf/0xd0 mm/kasan/common.c:461 slab_post_alloc_hook mm/slab.h:518 [inline] slab_alloc mm/slab.c:3312 [inline] kmem_cache_alloc+0x13a/0x3f0 mm/slab.c:3482 getname_flags.part.0+0x50/0x4f0 fs/namei.c:138 getname_flags fs/namei.c:2646 [inline] user_path_at_empty+0xa1/0x100 fs/namei.c:2646 user_path_at include/linux/namei.h:59 [inline] do_faccessat+0x129/0x820 fs/open.c:423 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 Freed by task 3898: kasan_save_stack+0x1b/0x40 mm/kasan/common.c:48 kasan_set_track+0x1c/0x30 mm/kasan/common.c:56 kasan_set_free_info+0x1b/0x30 mm/kasan/generic.c:355 __kasan_slab_free+0xd8/0x120 mm/kasan/common.c:422 __cache_free mm/slab.c:3418 [inline] kmem_cache_free.part.0+0x74/0x1e0 mm/slab.c:3693 putname+0xe1/0x120 fs/namei.c:259 filename_lookup+0x3b1/0x560 fs/namei.c:2376 user_path_at include/linux/namei.h:59 [inline] do_faccessat+0x129/0x820 fs/open.c:423 do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46 entry_SYSCALL_64_after_hwframe+0x44/0xa9 The buggy address belongs to the object at ffff88804563c380 which belongs to the cache names_cache of size 4096 The buggy address is located 48 bytes to the left of 4096-byte region [ffff88804563c380, ffff88804563d380) The buggy address belongs to the page: page:00000000ed4ee5bd refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x4563c head:00000000ed4ee5bd order:1 compound_mapcount:0 flags: 0xfffe0000010200(slab|head) raw: 00fffe0000010200 ffffea00013f1908 ffffea000129c408 ffff8880aa221c00 raw: 0000000000000000 ffff88804563c380 0000000100000001 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88804563c200: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88804563c280: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff88804563c300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88804563c380: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88804563c400: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================