usb 2-1: RX USB error -2.
usb 2-1: error -1 when submitting rx urb
==================================================================
BUG: KASAN: use-after-free in ar5523_cmd_tx_cb+0x220/0x240 drivers/net/wireless/ath/ar5523/ar5523.c:228
Read of size 8 at addr ffff888079a7b450 by task syz-executor.1/3655
CPU: 0 PID: 3655 Comm: syz-executor.1 Not tainted 6.0.0-syzkaller-09039-ga6afa4199d3d #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/22/2022
Call Trace:
__dump_stack lib/dump_stack.c:88 [inline]
dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106
print_address_description mm/kasan/report.c:317 [inline]
print_report.cold+0x2ba/0x719 mm/kasan/report.c:433
kasan_report+0xb1/0x1e0 mm/kasan/report.c:495
ar5523_cmd_tx_cb+0x220/0x240 drivers/net/wireless/ath/ar5523/ar5523.c:228
__usb_hcd_giveback_urb+0x2b0/0x5c0 drivers/usb/core/hcd.c:1671
usb_hcd_giveback_urb+0x380/0x430 drivers/usb/core/hcd.c:1754
dummy_timer+0x11ff/0x32c0 drivers/usb/gadget/udc/dummy_hcd.c:1988
call_timer_fn+0x1a0/0x6b0 kernel/time/timer.c:1474
expire_timers kernel/time/timer.c:1519 [inline]
__run_timers.part.0+0x674/0xa80 kernel/time/timer.c:1790
__run_timers kernel/time/timer.c:1768 [inline]
run_timer_softirq+0xb3/0x1d0 kernel/time/timer.c:1803
__do_softirq+0x1d0/0x9c8 kernel/softirq.c:571
invoke_softirq kernel/softirq.c:445 [inline]
__irq_exit_rcu+0x123/0x180 kernel/softirq.c:650
irq_exit_rcu+0x5/0x20 kernel/softirq.c:662
sysvec_apic_timer_interrupt+0x93/0xc0 arch/x86/kernel/apic/apic.c:1107
asm_sysvec_apic_timer_interrupt+0x16/0x20 arch/x86/include/asm/idtentry.h:649
RIP: 0010:stack_trace_consume_entry+0x87/0x160 kernel/stacktrace.c:89
Code: 81 00 00 00 48 8d 7b 0c 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 0f b6 14 02 48 89 f8 83 e0 07 83 c0 03 38 d0 7c 08 <84> d2 0f 85 90 00 00 00 8b 43 0c 85 c0 75 53 48 b8 00 00 00 00 00
RSP: 0018:ffffc90004d6f2f8 EFLAGS: 00000202
RAX: 0000000000000007 RBX: ffffc90004d6f3d0 RCX: 0000000000000000
RDX: 0000000000000000 RSI: ffffffff81bc213a RDI: ffffc90004d6f3dc
RBP: 0000000000000004 R08: ffffffff8e6a8e3e R09: ffffc90004d6f34c
R10: fffff520009ade6e R11: ffffc90004d6f6d8 R12: ffffc90004d6f3d0
R13: 0000000000000000 R14: ffff8880275b5880 R15: 0000015b8ae156e2
arch_stack_walk+0x6d/0xe0 arch/x86/kernel/stacktrace.c:27
stack_trace_save+0x8c/0xc0 kernel/stacktrace.c:122
save_stack+0x151/0x1e0 mm/page_owner.c:127
__reset_page_owner+0x59/0x170 mm/page_owner.c:148
reset_page_owner include/linux/page_owner.h:24 [inline]
free_pages_prepare mm/page_alloc.c:1449 [inline]
free_pcp_prepare+0x5e4/0xd20 mm/page_alloc.c:1499
free_unref_page_prepare mm/page_alloc.c:3380 [inline]
free_unref_page+0x19/0x4d0 mm/page_alloc.c:3476
__vunmap+0x85d/0xd30 mm/vmalloc.c:2696
__vfree+0x3c/0xd0 mm/vmalloc.c:2744
vfree+0x5a/0x90 mm/vmalloc.c:2775
xt_compat_flush_offsets+0x8b/0x160 net/netfilter/x_tables.c:691
translate_compat_table+0x11fc/0x1840 net/ipv4/netfilter/ip_tables.c:1453
compat_do_replace.constprop.0+0x24e/0x400 net/ipv4/netfilter/ip_tables.c:1520
do_ipt_set_ctl+0x5b0/0xb10 net/ipv4/netfilter/ip_tables.c:1627
nf_setsockopt+0x83/0xe0 net/netfilter/nf_sockopt.c:101
ip_setsockopt+0xee/0x100 net/ipv4/ip_sockglue.c:1444
tcp_setsockopt+0x9b/0x100 net/ipv4/tcp.c:3799
__sys_setsockopt+0x2d6/0x690 net/socket.c:2252
__do_compat_sys_socketcall+0x4ef/0x660 net/compat.c:489
do_syscall_32_irqs_on arch/x86/entry/common.c:112 [inline]
__do_fast_syscall_32+0x65/0xf0 arch/x86/entry/common.c:178
do_fast_syscall_32+0x2f/0x70 arch/x86/entry/common.c:203
entry_SYSENTER_compat_after_hwframe+0x70/0x82
RIP: 0023:0xf7fc8549
Code: 03 74 c0 01 10 05 03 74 b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 8d b4 26 00 00 00 00 8d b4 26 00 00 00 00
RSP: 002b:00000000f74af650 EFLAGS: 00000286 ORIG_RAX: 0000000000000066
RAX: ffffffffffffffda RBX: 000000000000000e RCX: 00000000f74af668
RDX: 00000000f74af8d8 RSI: 00000000f74af6d8 RDI: 00000000f74af72c
RBP: 00000000f6f4dca0 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000286 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
The buggy address belongs to the physical page:
page:ffffea0001e69ec0 refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x79a7b
flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff)
raw: 00fff00000000000 0000000000000000 dead000000000122 0000000000000000
raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as freed
page last allocated via order 2, migratetype Unmovable, gfp_mask 0x140dc0(GFP_USER|__GFP_COMP|__GFP_ZERO), pid 143, tgid 143 (kworker/0:2), ts 1490544475000, free_ts 1492615887325
prep_new_page mm/page_alloc.c:2532 [inline]
get_page_from_freelist+0x109b/0x2ce0 mm/page_alloc.c:4283
__alloc_pages+0x1c7/0x510 mm/page_alloc.c:5549
alloc_pages+0x1a6/0x270 mm/mempolicy.c:2270
kmalloc_order+0x34/0xf0 mm/slab_common.c:933
kmalloc_order_trace+0x13/0x120 mm/slab_common.c:949
kmalloc include/linux/slab.h:605 [inline]
kzalloc include/linux/slab.h:733 [inline]
wiphy_new_nm+0x6fc/0x2090 net/wireless/core.c:440
ieee80211_alloc_hw_nm+0x44b/0x2490 net/mac80211/main.c:668
ieee80211_alloc_hw include/net/mac80211.h:4562 [inline]
ar5523_probe+0x11a/0x1d10 drivers/net/wireless/ath/ar5523/ar5523.c:1595
usb_probe_interface+0x30b/0x7f0 drivers/usb/core/driver.c:396
call_driver_probe drivers/base/dd.c:560 [inline]
really_probe+0x249/0xb90 drivers/base/dd.c:639
__driver_probe_device+0x1df/0x4d0 drivers/base/dd.c:778
driver_probe_device+0x4c/0x1a0 drivers/base/dd.c:808
__device_attach_driver+0x1d0/0x2e0 drivers/base/dd.c:936
bus_for_each_drv+0x15f/0x1e0 drivers/base/bus.c:427
__device_attach+0x1e4/0x530 drivers/base/dd.c:1008
bus_probe_device+0x1e4/0x290 drivers/base/bus.c:487
page last free stack trace:
reset_page_owner include/linux/page_owner.h:24 [inline]
free_pages_prepare mm/page_alloc.c:1449 [inline]
free_pcp_prepare+0x5e4/0xd20 mm/page_alloc.c:1499
free_unref_page_prepare mm/page_alloc.c:3380 [inline]
free_unref_page+0x19/0x4d0 mm/page_alloc.c:3476
device_release+0x9f/0x240 drivers/base/core.c:2330
kobject_cleanup lib/kobject.c:673 [inline]
kobject_release lib/kobject.c:704 [inline]
kref_put include/linux/kref.h:65 [inline]
kobject_put+0x1be/0x4c0 lib/kobject.c:721
put_device+0x1b/0x30 drivers/base/core.c:3624
ar5523_probe+0xe38/0x1d10 drivers/net/wireless/ath/ar5523/ar5523.c:1719
usb_probe_interface+0x30b/0x7f0 drivers/usb/core/driver.c:396
call_driver_probe drivers/base/dd.c:560 [inline]
really_probe+0x249/0xb90 drivers/base/dd.c:639
__driver_probe_device+0x1df/0x4d0 drivers/base/dd.c:778
driver_probe_device+0x4c/0x1a0 drivers/base/dd.c:808
__device_attach_driver+0x1d0/0x2e0 drivers/base/dd.c:936
bus_for_each_drv+0x15f/0x1e0 drivers/base/bus.c:427
__device_attach+0x1e4/0x530 drivers/base/dd.c:1008
bus_probe_device+0x1e4/0x290 drivers/base/bus.c:487
device_add+0xbd5/0x1e90 drivers/base/core.c:3517
usb_set_configuration+0x1019/0x1900 drivers/usb/core/message.c:2170
Memory state around the buggy address:
ffff888079a7b300: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ffff888079a7b380: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
>ffff888079a7b400: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
^
ffff888079a7b480: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
ffff888079a7b500: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff
==================================================================
----------------
Code disassembly (best guess):
0: 81 00 00 00 48 8d addl $0x8d480000,(%rax)
6: 7b 0c jnp 0x14
8: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax
f: fc ff df
12: 48 89 fa mov %rdi,%rdx
15: 48 c1 ea 03 shr $0x3,%rdx
19: 0f b6 14 02 movzbl (%rdx,%rax,1),%edx
1d: 48 89 f8 mov %rdi,%rax
20: 83 e0 07 and $0x7,%eax
23: 83 c0 03 add $0x3,%eax
26: 38 d0 cmp %dl,%al
28: 7c 08 jl 0x32
* 2a: 84 d2 test %dl,%dl <-- trapping instruction
2c: 0f 85 90 00 00 00 jne 0xc2
32: 8b 43 0c mov 0xc(%rbx),%eax
35: 85 c0 test %eax,%eax
37: 75 53 jne 0x8c
39: 48 rex.W
3a: b8 00 00 00 00 mov $0x0,%eax