================================================================== BUG: KASAN: use-after-free in htc_process_conn_rsp drivers/net/wireless/ath/ath9k/htc_hst.c:131 [inline] BUG: KASAN: use-after-free in ath9k_htc_rx_msg+0xa25/0xaf0 drivers/net/wireless/ath/ath9k/htc_hst.c:443 Write of size 2 at addr ffff8881bf8087f0 by task syz-executor.1/401 CPU: 1 PID: 401 Comm: syz-executor.1 Not tainted 5.7.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+0xef/0x16e lib/dump_stack.c:118 print_address_description.constprop.0.cold+0xd3/0x415 mm/kasan/report.c:382 __kasan_report.cold+0x37/0x7d mm/kasan/report.c:511 kasan_report+0x33/0x50 mm/kasan/common.c:625 htc_process_conn_rsp drivers/net/wireless/ath/ath9k/htc_hst.c:131 [inline] ath9k_htc_rx_msg+0xa25/0xaf0 drivers/net/wireless/ath/ath9k/htc_hst.c:443 ath9k_hif_usb_reg_in_cb+0x1c0/0x630 drivers/net/wireless/ath/ath9k/hif_usb.c:718 __usb_hcd_giveback_urb+0x29a/0x550 drivers/usb/core/hcd.c:1650 usb_hcd_giveback_urb+0x368/0x420 drivers/usb/core/hcd.c:1716 dummy_timer+0x125e/0x32b4 drivers/usb/gadget/udc/dummy_hcd.c:1967 call_timer_fn+0x1ac/0x700 kernel/time/timer.c:1405 expire_timers kernel/time/timer.c:1450 [inline] __run_timers kernel/time/timer.c:1774 [inline] __run_timers kernel/time/timer.c:1741 [inline] run_timer_softirq+0x5f9/0x1500 kernel/time/timer.c:1787 __do_softirq+0x21e/0x9aa kernel/softirq.c:292 invoke_softirq kernel/softirq.c:373 [inline] irq_exit+0x178/0x1a0 kernel/softirq.c:413 exiting_irq arch/x86/include/asm/apic.h:546 [inline] smp_apic_timer_interrupt+0x141/0x540 arch/x86/kernel/apic/apic.c:1140 apic_timer_interrupt+0xf/0x20 arch/x86/entry/entry_64.S:829 RIP: 0010:write_comp_data+0x2e/0x80 kernel/kcov.c:218 Code: 25 40 0f 02 00 65 8b 05 88 cf c1 7e a9 00 01 1f 00 74 10 f6 c4 01 74 5c 41 8b 80 2c 13 00 00 85 c0 74 51 41 8b 80 08 13 00 00 <83> f8 03 75 45 49 8b 80 10 13 00 00 45 8b 80 0c 13 00 00 4c 8b 08 RSP: 0018:ffff8881ada2f818 EFLAGS: 00000246 ORIG_RAX: ffffffffffffff13 RAX: 0000000000000000 RBX: 8000000000000007 RCX: ffffffff815d908d RDX: 0000000000000001 RSI: 0000000000000000 RDI: 0000000000000005 RBP: 80000001b1e12007 R08: ffff8881d8cfca40 R09: ffffed103b19f949 R10: ffff8881d8cfca47 R11: ffffed103b19f948 R12: 00000000100400fb R13: 0000000000000001 R14: dffffc0000000000 R15: 0000000000000000 copy_one_pte mm/memory.c:705 [inline] copy_pte_range mm/memory.c:853 [inline] copy_pmd_range mm/memory.c:904 [inline] copy_pud_range mm/memory.c:938 [inline] copy_p4d_range mm/memory.c:960 [inline] copy_page_range+0xf1d/0x2510 mm/memory.c:1022 dup_mmap kernel/fork.c:607 [inline] dup_mm+0x8d5/0x1140 kernel/fork.c:1363 copy_mm kernel/fork.c:1419 [inline] copy_process+0x2752/0x64e0 kernel/fork.c:2085 _do_fork+0x12d/0xfd0 kernel/fork.c:2430 __do_sys_clone+0xef/0x150 kernel/fork.c:2586 do_syscall_64+0xb6/0x5a0 arch/x86/entry/common.c:295 entry_SYSCALL_64_after_hwframe+0x49/0xb3 RIP: 0033:0x45b09a Code: f7 d8 64 89 04 25 d4 02 00 00 64 4c 8b 0c 25 10 00 00 00 31 d2 4d 8d 91 d0 02 00 00 31 f6 bf 11 00 20 01 b8 38 00 00 00 0f 05 <48> 3d 00 f0 ff ff 0f 87 f5 00 00 00 85 c0 41 89 c5 0f 85 fc 00 00 RSP: 002b:00007fff03871fd0 EFLAGS: 00000246 ORIG_RAX: 0000000000000038 RAX: ffffffffffffffda RBX: 00007fff03871fd0 RCX: 000000000045b09a RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000001200011 RBP: 00007fff03872010 R08: 0000000000000001 R09: 000000000118c940 R10: 000000000118cc10 R11: 0000000000000246 R12: 0000000000000001 R13: 0000000000000000 R14: 0000000000000000 R15: 00007fff03872060 Allocated by task 4942: save_stack+0x1b/0x40 mm/kasan/common.c:49 set_track mm/kasan/common.c:57 [inline] __kasan_kmalloc mm/kasan/common.c:495 [inline] __kasan_kmalloc.constprop.0+0xbf/0xd0 mm/kasan/common.c:468 slab_post_alloc_hook mm/slab.h:586 [inline] slab_alloc_node mm/slub.c:2797 [inline] slab_alloc mm/slub.c:2805 [inline] kmem_cache_alloc+0xd8/0x300 mm/slub.c:2810 getname_flags fs/namei.c:138 [inline] getname_flags+0xd2/0x5b0 fs/namei.c:128 user_path_at_empty+0x2a/0x50 fs/namei.c:2632 user_path_at include/linux/namei.h:59 [inline] vfs_statx+0x119/0x1e0 fs/stat.c:197 vfs_lstat include/linux/fs.h:3284 [inline] __do_sys_newlstat+0x96/0x120 fs/stat.c:364 do_syscall_64+0xb6/0x5a0 arch/x86/entry/common.c:295 entry_SYSCALL_64_after_hwframe+0x49/0xb3 Freed by task 4942: save_stack+0x1b/0x40 mm/kasan/common.c:49 set_track mm/kasan/common.c:57 [inline] kasan_set_free_info mm/kasan/common.c:317 [inline] __kasan_slab_free+0x117/0x160 mm/kasan/common.c:456 slab_free_hook mm/slub.c:1455 [inline] slab_free_freelist_hook mm/slub.c:1488 [inline] slab_free mm/slub.c:3045 [inline] kmem_cache_free+0x9b/0x360 mm/slub.c:3061 putname+0xe1/0x120 fs/namei.c:259 filename_lookup+0x282/0x3e0 fs/namei.c:2362 user_path_at include/linux/namei.h:59 [inline] vfs_statx+0x119/0x1e0 fs/stat.c:197 vfs_lstat include/linux/fs.h:3284 [inline] __do_sys_newlstat+0x96/0x120 fs/stat.c:364 do_syscall_64+0xb6/0x5a0 arch/x86/entry/common.c:295 entry_SYSCALL_64_after_hwframe+0x49/0xb3 The buggy address belongs to the object at ffff8881bf808000 which belongs to the cache names_cache of size 4096 The buggy address is located 2032 bytes inside of 4096-byte region [ffff8881bf808000, ffff8881bf809000) The buggy address belongs to the page: page:ffffea0006fe0200 refcount:1 mapcount:0 mapping:00000000b5019c91 index:0x0 head:ffffea0006fe0200 order:3 compound_mapcount:0 compound_pincount:0 flags: 0x200000000010200(slab|head) raw: 0200000000010200 dead000000000100 dead000000000122 ffff8881da11e000 raw: 0000000000000000 0000000000070007 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8881bf808680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8881bf808700: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff8881bf808780: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff8881bf808800: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff8881bf808880: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================