usb 6-1: USB disconnect, device number 52 ================================================================== BUG: KASAN: use-after-free in __lock_acquire+0x3d86/0x54a0 kernel/locking/lockdep.c:4885 Read of size 8 at addr ffff88811135cda8 by task kworker/1:9/7965 CPU: 1 PID: 7965 Comm: kworker/1:9 Not tainted 5.14.0-rc3-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: usb_hub_wq hub_event Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:105 print_address_description.constprop.0.cold+0x6c/0x309 mm/kasan/report.c:233 __kasan_report mm/kasan/report.c:419 [inline] kasan_report.cold+0x83/0xdf mm/kasan/report.c:436 __lock_acquire+0x3d86/0x54a0 kernel/locking/lockdep.c:4885 lock_acquire kernel/locking/lockdep.c:5625 [inline] lock_acquire+0x19d/0x4d0 kernel/locking/lockdep.c:5590 __raw_spin_lock_irq include/linux/spinlock_api_smp.h:128 [inline] _raw_spin_lock_irq+0x2f/0x40 kernel/locking/spinlock.c:167 do_wait_for_common kernel/sched/completion.c:86 [inline] __wait_for_common kernel/sched/completion.c:106 [inline] wait_for_common kernel/sched/completion.c:117 [inline] wait_for_completion+0x181/0x280 kernel/sched/completion.c:138 r871xu_dev_remove+0x80/0x320 drivers/staging/rtl8712/usb_intf.c:599 usb_unbind_interface+0x1d8/0x8d0 drivers/usb/core/driver.c:458 __device_release_driver+0x3bd/0x6f0 drivers/base/dd.c:1201 device_release_driver_internal drivers/base/dd.c:1232 [inline] device_release_driver+0x26/0x40 drivers/base/dd.c:1255 bus_remove_device+0x2eb/0x5a0 drivers/base/bus.c:529 device_del+0x502/0xd40 drivers/base/core.c:3542 usb_disable_device+0x35b/0x7b0 drivers/usb/core/message.c:1419 usb_disconnect.cold+0x27a/0x78e drivers/usb/core/hub.c:2225 hub_port_connect drivers/usb/core/hub.c:5199 [inline] hub_port_connect_change drivers/usb/core/hub.c:5488 [inline] port_event drivers/usb/core/hub.c:5634 [inline] hub_event+0x1c9c/0x4330 drivers/usb/core/hub.c:5716 process_one_work+0x98d/0x15b0 kernel/workqueue.c:2276 worker_thread+0x658/0x11f0 kernel/workqueue.c:2422 kthread+0x3c0/0x4a0 kernel/kthread.c:319 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 stack segment: 0000 [#1] SMP KASAN CPU: 1 PID: 7965 Comm: kworker/1:9 Not tainted 5.14.0-rc3-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: usb_hub_wq hub_event RIP: 0010:nearest_obj include/linux/slub_def.h:169 [inline] RIP: 0010:print_address_description.constprop.0.cold+0xcd/0x309 mm/kasan/report.c:238 Code: 48 8b 45 00 f6 c4 02 0f 84 6b ff ff ff 49 8b 6d 18 b9 0b 00 00 00 b8 11 ff ff 01 48 c1 e1 29 48 c1 e0 27 4c 01 e9 48 c1 f9 06 <8b> 75 18 48 c1 e1 0c 48 01 c1 4c 89 e0 48 29 c8 48 99 48 f7 fe 41 RSP: 0018:ffffc90010e8f420 EFLAGS: 00010006 RAX: ffff888000000000 RBX: 0000000000000008 RCX: 000000000011135c RDX: ffffea000444d601 RSI: ffffffff812a8ee3 RDI: fffff520021d1e76 RBP: dead000000000400 R08: 0000000000000000 R09: 0000000000000000 R10: ffffffff814c031f R11: 0000000000000000 R12: ffff88811135cda8 R13: ffffea000444d700 R14: ffffffff81280fc6 R15: 0000000000000001 FS: 0000000000000000(0000) GS:ffff8881f6900000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f60d8dd5718 CR3: 0000000137cbc000 CR4: 00000000001506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: __kasan_report mm/kasan/report.c:419 [inline] kasan_report.cold+0x83/0xdf mm/kasan/report.c:436 __lock_acquire+0x3d86/0x54a0 kernel/locking/lockdep.c:4885 lock_acquire kernel/locking/lockdep.c:5625 [inline] lock_acquire+0x19d/0x4d0 kernel/locking/lockdep.c:5590 __raw_spin_lock_irq include/linux/spinlock_api_smp.h:128 [inline] _raw_spin_lock_irq+0x2f/0x40 kernel/locking/spinlock.c:167 do_wait_for_common kernel/sched/completion.c:86 [inline] __wait_for_common kernel/sched/completion.c:106 [inline] wait_for_common kernel/sched/completion.c:117 [inline] wait_for_completion+0x181/0x280 kernel/sched/completion.c:138 r871xu_dev_remove+0x80/0x320 drivers/staging/rtl8712/usb_intf.c:599 usb_unbind_interface+0x1d8/0x8d0 drivers/usb/core/driver.c:458 __device_release_driver+0x3bd/0x6f0 drivers/base/dd.c:1201 device_release_driver_internal drivers/base/dd.c:1232 [inline] device_release_driver+0x26/0x40 drivers/base/dd.c:1255 bus_remove_device+0x2eb/0x5a0 drivers/base/bus.c:529 device_del+0x502/0xd40 drivers/base/core.c:3542 usb_disable_device+0x35b/0x7b0 drivers/usb/core/message.c:1419 usb_disconnect.cold+0x27a/0x78e drivers/usb/core/hub.c:2225 hub_port_connect drivers/usb/core/hub.c:5199 [inline] hub_port_connect_change drivers/usb/core/hub.c:5488 [inline] port_event drivers/usb/core/hub.c:5634 [inline] hub_event+0x1c9c/0x4330 drivers/usb/core/hub.c:5716 process_one_work+0x98d/0x15b0 kernel/workqueue.c:2276 worker_thread+0x658/0x11f0 kernel/workqueue.c:2422 kthread+0x3c0/0x4a0 kernel/kthread.c:319 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 Modules linked in: ---[ end trace 1cead9d32ad13e1b ]--- RIP: 0010:nearest_obj include/linux/slub_def.h:169 [inline] RIP: 0010:print_address_description.constprop.0.cold+0xcd/0x309 mm/kasan/report.c:238 Code: 48 8b 45 00 f6 c4 02 0f 84 6b ff ff ff 49 8b 6d 18 b9 0b 00 00 00 b8 11 ff ff 01 48 c1 e1 29 48 c1 e0 27 4c 01 e9 48 c1 f9 06 <8b> 75 18 48 c1 e1 0c 48 01 c1 4c 89 e0 48 29 c8 48 99 48 f7 fe 41 RSP: 0018:ffffc90010e8f420 EFLAGS: 00010006 RAX: ffff888000000000 RBX: 0000000000000008 RCX: 000000000011135c RDX: ffffea000444d601 RSI: ffffffff812a8ee3 RDI: fffff520021d1e76 RBP: dead000000000400 R08: 0000000000000000 R09: 0000000000000000 R10: ffffffff814c031f R11: 0000000000000000 R12: ffff88811135cda8 R13: ffffea000444d700 R14: ffffffff81280fc6 R15: 0000000000000001 FS: 0000000000000000(0000) GS:ffff8881f6900000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f60d8dd5718 CR3: 0000000137cbc000 CR4: 00000000001506e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400