Bluetooth: hci1: sending frame failed (-49) Bluetooth: hci1: sending frame failed (-49) Bluetooth: hci1: Received unexpected HCI Event 00000000 ================================================================== BUG: KASAN: use-after-free in __skb_unlink include/linux/skbuff.h:2090 [inline] BUG: KASAN: use-after-free in __skb_dequeue include/linux/skbuff.h:2109 [inline] BUG: KASAN: use-after-free in skb_dequeue+0x90/0x140 net/core/skbuff.c:3159 Read of size 8 at addr ffff888025f8c3c0 by task kworker/u5:0/2026 CPU: 1 PID: 2026 Comm: kworker/u5:0 Not tainted 5.14.0-rc6-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: hci1 hci_rx_work Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0x1ae/0x29f lib/dump_stack.c:105 print_address_description+0x66/0x3b0 mm/kasan/report.c:233 __kasan_report mm/kasan/report.c:419 [inline] kasan_report+0x163/0x210 mm/kasan/report.c:436 __skb_unlink include/linux/skbuff.h:2090 [inline] __skb_dequeue include/linux/skbuff.h:2109 [inline] skb_dequeue+0x90/0x140 net/core/skbuff.c:3159 hci_rx_work+0x2e0/0x410 net/bluetooth/hci_core.c:5084 process_one_work+0x833/0x10c0 kernel/workqueue.c:2276 worker_thread+0xac1/0x1320 kernel/workqueue.c:2422 kthread+0x453/0x480 kernel/kthread.c:319 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 Allocated by task 8513: kasan_save_stack mm/kasan/common.c:38 [inline] kasan_set_track mm/kasan/common.c:46 [inline] set_alloc_info mm/kasan/common.c:434 [inline] __kasan_slab_alloc+0x96/0xd0 mm/kasan/common.c:467 kasan_slab_alloc include/linux/kasan.h:254 [inline] slab_post_alloc_hook mm/slab.h:519 [inline] slab_alloc_node mm/slub.c:2959 [inline] kmem_cache_alloc_node+0x200/0x370 mm/slub.c:2995 __alloc_skb+0xd8/0x580 net/core/skbuff.c:414 alloc_skb include/linux/skbuff.h:1112 [inline] bt_skb_alloc include/net/bluetooth/bluetooth.h:389 [inline] h4_recv_buf+0x274/0xd50 drivers/bluetooth/hci_h4.c:181 h4_recv+0xf4/0x1b0 drivers/bluetooth/hci_h4.c:115 hci_uart_tty_receive+0x1d2/0x4a0 drivers/bluetooth/hci_ldisc.c:613 tiocsti drivers/tty/tty_io.c:2311 [inline] tty_ioctl+0xde5/0x1720 drivers/tty/tty_io.c:2719 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:1069 [inline] __se_sys_ioctl+0xfb/0x170 fs/ioctl.c:1055 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae Freed by task 2026: kasan_save_stack mm/kasan/common.c:38 [inline] kasan_set_track+0x3d/0x70 mm/kasan/common.c:46 kasan_set_free_info+0x1f/0x40 mm/kasan/generic.c:360 ____kasan_slab_free+0x109/0x150 mm/kasan/common.c:366 kasan_slab_free include/linux/kasan.h:230 [inline] slab_free_hook mm/slub.c:1628 [inline] slab_free_freelist_hook+0x1d8/0x290 mm/slub.c:1653 slab_free mm/slub.c:3213 [inline] kmem_cache_free+0x85/0x170 mm/slub.c:3229 hci_event_packet+0x1238/0x1bd0 net/bluetooth/hci_event.c:6400 hci_rx_work+0x229/0x410 net/bluetooth/hci_core.c:5120 process_one_work+0x833/0x10c0 kernel/workqueue.c:2276 worker_thread+0xac1/0x1320 kernel/workqueue.c:2422 kthread+0x453/0x480 kernel/kthread.c:319 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:295 The buggy address belongs to the object at ffff888025f8c3c0 which belongs to the cache skbuff_head_cache of size 232 The buggy address is located 0 bytes inside of 232-byte region [ffff888025f8c3c0, ffff888025f8c4a8) The buggy address belongs to the page: page:ffffea000097e300 refcount:1 mapcount:0 mapping:0000000000000000 index:0xffff888025f8cc80 pfn:0x25f8c flags: 0xfff00000000200(slab|node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000200 ffffea0000aa2380 0000000400000004 ffff8880122e9b40 raw: ffff888025f8cc80 00000000800c0008 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x12cc0(GFP_KERNEL|__GFP_NOWARN|__GFP_NORETRY), pid 1, ts 16939168005, free_ts 16936927313 prep_new_page mm/page_alloc.c:2436 [inline] get_page_from_freelist+0x779/0xa30 mm/page_alloc.c:4169 __alloc_pages+0x26c/0x5f0 mm/page_alloc.c:5391 alloc_slab_page mm/slub.c:1691 [inline] allocate_slab+0xf1/0x540 mm/slub.c:1831 ___slab