================================================================== BUG: KASAN: use-after-free in hci_cmd_timeout+0x203/0x210 net/bluetooth/hci_core.c:2756 Read of size 2 at addr ffff888026399c08 by task kworker/0:11/11901 CPU: 0 PID: 11901 Comm: kworker/0:11 Not tainted 5.11.0-rc3-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: events hci_cmd_timeout Call Trace: __dump_stack lib/dump_stack.c:79 [inline] dump_stack+0x107/0x163 lib/dump_stack.c:120 print_address_description.constprop.0.cold+0x5b/0x2f8 mm/kasan/report.c:230 __kasan_report mm/kasan/report.c:396 [inline] kasan_report.cold+0x79/0xd5 mm/kasan/report.c:413 hci_cmd_timeout+0x203/0x210 net/bluetooth/hci_core.c:2756 process_one_work+0x98d/0x15f0 kernel/workqueue.c:2275 worker_thread+0x64c/0x1120 kernel/workqueue.c:2421 kthread+0x3b1/0x4a0 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 Allocated by task 8489: kasan_save_stack+0x1b/0x40 mm/kasan/common.c:38 kasan_set_track mm/kasan/common.c:46 [inline] set_alloc_info mm/kasan/common.c:401 [inline] ____kasan_kmalloc.constprop.0+0x82/0xa0 mm/kasan/common.c:429 kasan_slab_alloc include/linux/kasan.h:205 [inline] slab_post_alloc_hook mm/slab.h:512 [inline] slab_alloc_node mm/slub.c:2891 [inline] __kmalloc_node_track_caller+0x1e0/0x3f0 mm/slub.c:4495 __kmalloc_reserve net/core/skbuff.c:142 [inline] __alloc_skb+0xae/0x5a0 net/core/skbuff.c:210 alloc_skb include/linux/skbuff.h:1099 [inline] bt_skb_alloc include/net/bluetooth/bluetooth.h:389 [inline] hci_prepare_cmd+0x2f/0x290 net/bluetooth/hci_request.c:292 hci_req_add_ev+0xdc/0x220 net/bluetooth/hci_request.c:326 __hci_cmd_sync_ev+0x121/0x670 net/bluetooth/hci_request.c:138 btintel_enter_mfg+0x2a/0x90 drivers/bluetooth/btintel.c:71 ag6xx_setup+0xfc/0x790 drivers/bluetooth/hci_ag6xx.c:165 hci_uart_setup+0x1b1/0x480 drivers/bluetooth/hci_ldisc.c:424 hci_dev_do_open+0x3e1/0x1a00 net/bluetooth/hci_core.c:1497 hci_power_on+0x133/0x650 net/bluetooth/hci_core.c:2245 process_one_work+0x98d/0x15f0 kernel/workqueue.c:2275 worker_thread+0x64c/0x1120 kernel/workqueue.c:2421 kthread+0x3b1/0x4a0 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 Freed by task 8489: kasan_save_stack+0x1b/0x40 mm/kasan/common.c:38 kasan_set_track+0x1c/0x30 mm/kasan/common.c:46 kasan_set_free_info+0x20/0x30 mm/kasan/generic.c:356 ____kasan_slab_free+0xe1/0x110 mm/kasan/common.c:362 kasan_slab_free include/linux/kasan.h:188 [inline] slab_free_hook mm/slub.c:1547 [inline] slab_free_freelist_hook+0x5d/0x150 mm/slub.c:1580 slab_free mm/slub.c:3142 [inline] kfree+0xdb/0x3b0 mm/slub.c:4124 skb_free_head net/core/skbuff.c:595 [inline] skb_release_data+0x6d9/0x910 net/core/skbuff.c:615 skb_release_all net/core/skbuff.c:669 [inline] __kfree_skb net/core/skbuff.c:683 [inline] kfree_skb net/core/skbuff.c:701 [inline] kfree_skb+0x133/0x3f0 net/core/skbuff.c:695 hci_dev_do_open+0xa4a/0x1a00 net/bluetooth/hci_core.c:1619 hci_power_on+0x133/0x650 net/bluetooth/hci_core.c:2245 process_one_work+0x98d/0x15f0 kernel/workqueue.c:2275 worker_thread+0x64c/0x1120 kernel/workqueue.c:2421 kthread+0x3b1/0x4a0 kernel/kthread.c:292 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296 The buggy address belongs to the object at ffff888026399c00 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 8 bytes inside of 512-byte region [ffff888026399c00, ffff888026399e00) The buggy address belongs to the page: page:0000000028af3d5e refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x26398 head:0000000028af3d5e order:1 compound_mapcount:0 flags: 0xfff00000010200(slab|head) raw: 00fff00000010200 0000000000000000 0000000500000001 ffff888010041280 raw: 0000000000000000 0000000000080008 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888026399b00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888026399b80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff888026399c00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888026399c80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff888026399d00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================