asix 5-1:0.0 eth1: register 'asix' at usb-dummy_hcd.4-1, ASIX AX88172A USB 2.0 Ethernet, 76:53:dd:86:0e:75 usb 5-1: USB disconnect, device number 89 asix 5-1:0.0 eth1: unregister 'asix' usb-dummy_hcd.4-1, ASIX AX88172A USB 2.0 Ethernet ================================================================== BUG: KASAN: use-after-free in ax88172a_remove_mdio drivers/net/usb/ax88172a.c:123 [inline] BUG: KASAN: use-after-free in ax88172a_unbind+0x6a/0xc0 drivers/net/usb/ax88172a.c:274 Read of size 8 at addr ffff88819c035180 by task kworker/1:59/9191 CPU: 1 PID: 9191 Comm: kworker/1:59 Tainted: G W 5.4.43-syzkaller-00528-g9b26d323fe7a #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:77 [inline] dump_stack+0x14a/0x1ce lib/dump_stack.c:118 print_address_description+0x93/0x620 mm/kasan/report.c:374 __kasan_report+0x16d/0x1e0 mm/kasan/report.c:506 kasan_report+0x34/0x60 mm/kasan/common.c:634 ax88172a_remove_mdio drivers/net/usb/ax88172a.c:123 [inline] ax88172a_unbind+0x6a/0xc0 drivers/net/usb/ax88172a.c:274 usbnet_disconnect+0x14e/0x340 drivers/net/usb/usbnet.c:1618 usb_unbind_interface+0x1d8/0x850 drivers/usb/core/driver.c:423 __device_release_driver drivers/base/dd.c:1137 [inline] device_release_driver_internal+0x515/0x7b0 drivers/base/dd.c:1168 bus_remove_device+0x2e7/0x350 drivers/base/bus.c:532 device_del+0x7bc/0x1200 drivers/base/core.c:2721 usb_disable_device+0x3fe/0xc90 drivers/usb/core/message.c:1244 usb_disconnect+0x341/0x880 drivers/usb/core/hub.c:2217 hub_port_connect drivers/usb/core/hub.c:4974 [inline] hub_port_connect_change drivers/usb/core/hub.c:5238 [inline] port_event drivers/usb/core/hub.c:5384 [inline] hub_event+0x1c6c/0x4fa0 drivers/usb/core/hub.c:5466 process_one_work+0x777/0xf90 kernel/workqueue.c:2274 worker_thread+0xa8f/0x1430 kernel/workqueue.c:2420 kthread+0x2df/0x300 kernel/kthread.c:255 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:352 Allocated by task 9191: save_stack mm/kasan/common.c:69 [inline] set_track mm/kasan/common.c:77 [inline] __kasan_kmalloc+0x12c/0x1c0 mm/kasan/common.c:510 kmem_cache_alloc_trace+0xc3/0x280 mm/slub.c:2793 kmalloc include/linux/slab.h:556 [inline] kzalloc include/linux/slab.h:690 [inline] ax88172a_bind+0xc7/0x980 drivers/net/usb/ax88172a.c:191 usbnet_probe+0xa9f/0x2770 drivers/net/usb/usbnet.c:1737 usb_probe_interface+0x631/0xad0 drivers/usb/core/driver.c:361 really_probe+0x764/0xf70 drivers/base/dd.c:555 driver_probe_device+0xe6/0x230 drivers/base/dd.c:724 bus_for_each_drv+0x17a/0x200 drivers/base/bus.c:430 __device_attach+0x27b/0x420 drivers/base/dd.c:897 bus_probe_device+0xbb/0x200 drivers/base/bus.c:490 device_add+0x105a/0x1750 drivers/base/core.c:2544 usb_set_configuration+0x197f/0x1f00 drivers/usb/core/message.c:2030 generic_probe+0x82/0x140 drivers/usb/core/generic.c:210 really_probe+0x764/0xf70 drivers/base/dd.c:555 driver_probe_device+0xe6/0x230 drivers/base/dd.c:724 bus_for_each_drv+0x17a/0x200 drivers/base/bus.c:430 __device_attach+0x27b/0x420 drivers/base/dd.c:897 bus_probe_device+0xbb/0x200 drivers/base/bus.c:490 device_add+0x105a/0x1750 drivers/base/core.c:2544 usb_new_device+0xda7/0x1710 drivers/usb/core/hub.c:2554 hub_port_connect drivers/usb/core/hub.c:5123 [inline] hub_port_connect_change drivers/usb/core/hub.c:5238 [inline] port_event drivers/usb/core/hub.c:5384 [inline] hub_event+0x2963/0x4fa0 drivers/usb/core/hub.c:5466 process_one_work+0x777/0xf90 kernel/workqueue.c:2274 process_scheduled_works kernel/workqueue.c:2336 [inline] worker_thread+0xdb6/0x1430 kernel/workqueue.c:2422 kthread+0x2df/0x300 kernel/kthread.c:255 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:352 Freed by task 9191: save_stack mm/kasan/common.c:69 [inline] set_track mm/kasan/common.c:77 [inline] kasan_set_free_info mm/kasan/common.c:332 [inline] __kasan_slab_free+0x181/0x230 mm/kasan/common.c:471 slab_free_hook mm/slub.c:1424 [inline] slab_free_freelist_hook+0xd0/0x150 mm/slub.c:1457 slab_free mm/slub.c:3014 [inline] kfree+0x12b/0x600 mm/slub.c:3975 ax88172a_bind+0x844/0x980 drivers/net/usb/ax88172a.c:250 usbnet_probe+0xa9f/0x2770 drivers/net/usb/usbnet.c:1737 usb_probe_interface+0x631/0xad0 drivers/usb/core/driver.c:361 really_probe+0x764/0xf70 drivers/base/dd.c:555 driver_probe_device+0xe6/0x230 drivers/base/dd.c:724 bus_for_each_drv+0x17a/0x200 drivers/base/bus.c:430 __device_attach+0x27b/0x420 drivers/base/dd.c:897 bus_probe_device+0xbb/0x200 drivers/base/bus.c:490 device_add+0x105a/0x1750 drivers/base/core.c:2544 usb_set_configuration+0x197f/0x1f00 drivers/usb/core/message.c:2030 generic_probe+0x82/0x140 drivers/usb/core/generic.c:210 really_probe+0x764/0xf70 drivers/base/dd.c:555 driver_probe_device+0xe6/0x230 drivers/base/dd.c:724 bus_for_each_drv+0x17a/0x200 drivers/base/bus.c:430 __device_attach+0x27b/0x420 drivers/base/dd.c:897 bus_probe_device+0xbb/0x200 drivers/base/bus.c:490 device_add+0x105a/0x1750 drivers/base/core.c:2544 usb_new_device+0xda7/0x1710 drivers/usb/core/hub.c:2554 hub_port_connect drivers/usb/core/hub.c:5123 [inline] hub_port_connect_change drivers/usb/core/hub.c:5238 [inline] port_event drivers/usb/core/hub.c:5384 [inline] hub_event+0x2963/0x4fa0 drivers/usb/core/hub.c:5466 process_one_work+0x777/0xf90 kernel/workqueue.c:2274 process_scheduled_works kernel/workqueue.c:2336 [inline] worker_thread+0xdb6/0x1430 kernel/workqueue.c:2422 kthread+0x2df/0x300 kernel/kthread.c:255 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:352 The buggy address belongs to the object at ffff88819c035180 which belongs to the cache kmalloc-64 of size 64 The buggy address is located 0 bytes inside of 64-byte region [ffff88819c035180, ffff88819c0351c0) The buggy address belongs to the page: page:ffffea0006700d40 refcount:1 mapcount:0 mapping:ffff8881da803180 index:0x0 flags: 0x8000000000000200(slab) raw: 8000000000000200 dead000000000100 dead000000000122 ffff8881da803180 raw: 0000000000000000 0000000000200020 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88819c035080: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff88819c035100: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc >ffff88819c035180: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ^ ffff88819c035200: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ffff88819c035280: 00 00 00 00 00 00 fc fc fc fc fc fc fc fc fc fc ================================================================== asix 5-1:0.0 eth1 (unregistered): deregistering mdio bus ` ------------[ cut here ]------------ kernel BUG at drivers/net/phy/mdio_bus.c:456! invalid opcode: 0000 [#1] PREEMPT SMP KASAN CPU: 1 PID: 9191 Comm: kworker/1:59 Tainted: G B W 5.4.43-syzkaller-00528-g9b26d323fe7a #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: usb_hub_wq hub_event RIP: 0010:mdiobus_unregister+0x1da/0x1e0 drivers/net/phy/mdio_bus.c:456 Code: f5 fe e9 80 fe ff ff 44 89 f9 80 e1 07 80 c1 03 38 c1 0f 8c 94 fe ff ff 4c 89 ff e8 50 55 f5 fe e9 87 fe ff ff e8 66 2a c7 fe <0f> 0b 0f 1f 40 00 41 57 41 56 41 55 41 54 53 49 89 ff 49 bc 00 00 RSP: 0018:ffff8881cd61f620 EFLAGS: 00010246 RAX: ffffffff827ac88a RBX: 0000000000000000 RCX: 0000000000040000 RDX: ffffc90001c1f000 RSI: 000000000003ffff RDI: 0000000000040000 RBP: 1ffff110398ace13 R08: ffffffff827ac6f6 R09: ffffed103b725df0 R10: ffffed103b725df0 R11: 0000000000000000 R12: dffffc0000000000 R13: dffffc0000000000 R14: ffff8881cc567000 R15: ffff8881cc567098 FS: 0000000000000000(0000) GS:ffff8881db900000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00005568d5e2e818 CR3: 00000001c4a6b006 CR4: 00000000001606e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: ax88172a_remove_mdio drivers/net/usb/ax88172a.c:124 [inline] ax88172a_unbind+0x99/0xc0 drivers/net/usb/ax88172a.c:274 usbnet_disconnect+0x14e/0x340 drivers/net/usb/usbnet.c:1618 usb_unbind_interface+0x1d8/0x850 drivers/usb/core/driver.c:423 __device_release_driver drivers/base/dd.c:1137 [inline] device_release_driver_internal+0x515/0x7b0 drivers/base/dd.c:1168 bus_remove_device+0x2e7/0x350 drivers/base/bus.c:532 device_del+0x7bc/0x1200 drivers/base/core.c:2721 usb_disable_device+0x3fe/0xc90 drivers/usb/core/message.c:1244 usb_disconnect+0x341/0x880 drivers/usb/core/hub.c:2217 hub_port_connect drivers/usb/core/hub.c:4974 [inline] hub_port_connect_change drivers/usb/core/hub.c:5238 [inline] port_event drivers/usb/core/hub.c:5384 [inline] hub_event+0x1c6c/0x4fa0 drivers/usb/core/hub.c:5466 process_one_work+0x777/0xf90 kernel/workqueue.c:2274 worker_thread+0xa8f/0x1430 kernel/workqueue.c:2420 kthread+0x2df/0x300 kernel/kthread.c:255 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:352 Modules linked in: ---[ end trace a06638fd1de8db62 ]--- RIP: 0010:mdiobus_unregister+0x1da/0x1e0 drivers/net/phy/mdio_bus.c:456 Code: f5 fe e9 80 fe ff ff 44 89 f9 80 e1 07 80 c1 03 38 c1 0f 8c 94 fe ff ff 4c 89 ff e8 50 55 f5 fe e9 87 fe ff ff e8 66 2a c7 fe <0f> 0b 0f 1f 40 00 41 57 41 56 41 55 41 54 53 49 89 ff 49 bc 00 00 RSP: 0018:ffff8881cd61f620 EFLAGS: 00010246 RAX: ffffffff827ac88a RBX: 0000000000000000 RCX: 0000000000040000 RDX: ffffc90001c1f000 RSI: 000000000003ffff RDI: 0000000000040000 RBP: 1ffff110398ace13 R08: ffffffff827ac6f6 R09: ffffed103b725df0 R10: ffffed103b725df0 R11: 0000000000000000 R12: dffffc0000000000 R13: dffffc0000000000 R14: ffff8881cc567000 R15: ffff8881cc567098 FS: 0000000000000000(0000) GS:ffff8881db900000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00005568d5e2e818 CR3: 00000001c6980004 CR4: 00000000001606e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400