================================================================== BUG: KASAN: use-after-free in atomic_read include/asm-generic/atomic-instrumented.h:26 [inline] BUG: KASAN: use-after-free in refcount_read include/linux/refcount.h:43 [inline] BUG: KASAN: use-after-free in skb_unref include/linux/skbuff.h:1010 [inline] BUG: KASAN: use-after-free in kfree_skb+0x38/0x3c0 net/core/skbuff.c:693 Read of size 4 at addr ffff8880a00ddf54 by task syz-executor.0/8970 CPU: 1 PID: 8970 Comm: syz-executor.0 Not tainted 5.4.0-rc5+ #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x172/0x1f0 lib/dump_stack.c:113 print_address_description.constprop.0.cold+0xd4/0x30b mm/kasan/report.c:374 __kasan_report.cold+0x1b/0x41 mm/kasan/report.c:506 kasan_report+0x12/0x20 mm/kasan/common.c:634 check_memory_region_inline mm/kasan/generic.c:185 [inline] check_memory_region+0x134/0x1a0 mm/kasan/generic.c:192 __kasan_check_read+0x11/0x20 mm/kasan/common.c:92 atomic_read include/asm-generic/atomic-instrumented.h:26 [inline] refcount_read include/linux/refcount.h:43 [inline] skb_unref include/linux/skbuff.h:1010 [inline] kfree_skb+0x38/0x3c0 net/core/skbuff.c:693 bcsp_close+0xc7/0x130 drivers/bluetooth/hci_bcsp.c:748 hci_uart_tty_close+0x21e/0x280 drivers/bluetooth/hci_ldisc.c:548 tty_ldisc_close.isra.0+0x119/0x1a0 drivers/tty/tty_ldisc.c:494 tty_ldisc_kill+0x9c/0x160 drivers/tty/tty_ldisc.c:642 tty_ldisc_release+0xe9/0x2b0 drivers/tty/tty_ldisc.c:814 tty_release_struct+0x1b/0x50 drivers/tty/tty_io.c:1612 tty_release+0xbcb/0xe90 drivers/tty/tty_io.c:1785 __fput+0x2ff/0x890 fs/file_table.c:280 ____fput+0x16/0x20 fs/file_table.c:313 task_work_run+0x145/0x1c0 kernel/task_work.c:113 tracehook_notify_resume include/linux/tracehook.h:188 [inline] exit_to_usermode_loop+0x316/0x380 arch/x86/entry/common.c:163 prepare_exit_to_usermode arch/x86/entry/common.c:194 [inline] syscall_return_slowpath arch/x86/entry/common.c:274 [inline] do_syscall_32_irqs_on arch/x86/entry/common.c:348 [inline] do_fast_syscall_32+0xb87/0xdb3 arch/x86/entry/common.c:404 entry_SYSENTER_compat+0x70/0x7f arch/x86/entry/entry_64_compat.S:139 RIP: 0023:0xf7f7da39 Code: 00 00 00 89 d3 5b 5e 5f 5d c3 b8 80 96 98 00 eb c4 8b 04 24 c3 8b 1c 24 c3 8b 34 24 c3 8b 3c 24 c3 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 eb 0d 90 90 90 90 90 90 90 90 90 90 90 90 RSP: 002b:00000000ffd6bcac EFLAGS: 00000296 ORIG_RAX: 0000000000000006 RAX: 0000000000000000 RBX: 0000000000000005 RCX: 0000000000000000 RDX: 0000000000000006 RSI: 000000000816b680 RDI: 000000000816b680 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 Allocated by task 8932: save_stack+0x23/0x90 mm/kasan/common.c:69 set_track mm/kasan/common.c:77 [inline] __kasan_kmalloc mm/kasan/common.c:510 [inline] __kasan_kmalloc.constprop.0+0xcf/0xe0 mm/kasan/common.c:483 kasan_slab_alloc+0xf/0x20 mm/kasan/common.c:518 slab_post_alloc_hook mm/slab.h:584 [inline] slab_alloc_node mm/slab.c:3262 [inline] kmem_cache_alloc_node+0x138/0x740 mm/slab.c:3574 __alloc_skb+0xd5/0x5e0 net/core/skbuff.c:197 alloc_skb include/linux/skbuff.h:1049 [inline] bt_skb_alloc include/net/bluetooth/bluetooth.h:339 [inline] bcsp_recv+0x8c1/0x13a0 drivers/bluetooth/hci_bcsp.c:670 hci_uart_tty_receive+0x279/0x6e0 drivers/bluetooth/hci_ldisc.c:613 tty_ldisc_receive_buf+0x15f/0x1c0 drivers/tty/tty_buffer.c:465 tty_port_default_receive_buf+0x7d/0xb0 drivers/tty/tty_port.c:38 receive_buf drivers/tty/tty_buffer.c:481 [inline] flush_to_ldisc+0x222/0x390 drivers/tty/tty_buffer.c:533 process_one_work+0x9af/0x1740 kernel/workqueue.c:2269 worker_thread+0x98/0xe40 kernel/workqueue.c:2415 kthread+0x361/0x430 kernel/kthread.c:255 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:352 Freed by task 8932: save_stack+0x23/0x90 mm/kasan/common.c:69 set_track mm/kasan/common.c:77 [inline] kasan_set_free_info mm/kasan/common.c:332 [inline] __kasan_slab_free+0x102/0x150 mm/kasan/common.c:471 kasan_slab_free+0xe/0x10 mm/kasan/common.c:480 __cache_free mm/slab.c:3425 [inline] kmem_cache_free+0x86/0x320 mm/slab.c:3693 kfree_skbmem net/core/skbuff.c:623 [inline] kfree_skbmem+0xc5/0x150 net/core/skbuff.c:617 __kfree_skb net/core/skbuff.c:680 [inline] kfree_skb net/core/skbuff.c:697 [inline] kfree_skb+0x109/0x3c0 net/core/skbuff.c:691 bcsp_recv+0x2d8/0x13a0 drivers/bluetooth/hci_bcsp.c:608 hci_uart_tty_receive+0x279/0x6e0 drivers/bluetooth/hci_ldisc.c:613 tty_ldisc_receive_buf+0x15f/0x1c0 drivers/tty/tty_buffer.c:465 tty_port_default_receive_buf+0x7d/0xb0 drivers/tty/tty_port.c:38 receive_buf drivers/tty/tty_buffer.c:481 [inline] flush_to_ldisc+0x222/0x390 drivers/tty/tty_buffer.c:533 process_one_work+0x9af/0x1740 kernel/workqueue.c:2269 worker_thread+0x98/0xe40 kernel/workqueue.c:2415 kthread+0x361/0x430 kernel/kthread.c:255 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:352 The buggy address belongs to the object at ffff8880a00dde80 which belongs to the cache skbuff_head_cache of size 224 The buggy address is located 212 bytes inside of 224-byte region [ffff8880a00dde80, ffff8880a00ddf60) The buggy address belongs to the page: page:ffffea0002803740 refcount:1 mapcount:0 mapping:ffff8880a99ce8c0 index:0x0 flags: 0x1fffc0000000200(slab) raw: 01fffc0000000200 ffffea0002894e88 ffffea0002867888 ffff8880a99ce8c0 raw: 0000000000000000 ffff8880a00dd0c0 000000010000000c 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff8880a00dde00: fb fb fb fb fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a00dde80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb >ffff8880a00ddf00: fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc fc ^ ffff8880a00ddf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff8880a00de000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================