bisecting fixing commit since fa5941f45d7ed070118b7c209b7f2c3a034293bd building syzkaller on 7516d9fa9301d2dfa5beaf49d93563f8048694aa testing commit fa5941f45d7ed070118b7c209b7f2c3a034293bd with gcc (GCC) 8.1.0 kernel signature: 0ee9e6ea05dbb3b97dccf4bdc9ee697349db086e all runs: crashed: KASAN: slab-out-of-bounds Read in bacpy testing current HEAD fbc5fe7a54d02e11972e3b2a5ddb6ffc88162c8f testing commit fbc5fe7a54d02e11972e3b2a5ddb6ffc88162c8f with gcc (GCC) 8.1.0 kernel signature: 792fd6ec76c67b2ac65df2636e713578ebb55b01 all runs: crashed: KASAN: slab-out-of-bounds Read in bacpy revisions tested: 2, total time: 23m20.551701061s (build: 16m11.003657496s, test: 6m9.997448001s) the crash still happens on HEAD commit msg: Linux 4.14.157 crash: KASAN: slab-out-of-bounds Read in bacpy IPv6: ADDRCONF(NETDEV_CHANGE): veth1: link becomes ready IPv6: ADDRCONF(NETDEV_CHANGE): veth0: link becomes ready IPv6: ADDRCONF(NETDEV_UP): vxcan1: link is not ready IPv6: ADDRCONF(NETDEV_UP): veth0: link is not ready ================================================================== BUG: KASAN: slab-out-of-bounds in memcpy include/linux/string.h:347 [inline] BUG: KASAN: slab-out-of-bounds in bacpy+0xe/0x10 include/net/bluetooth/bluetooth.h:233 Read of size 6 at addr ffff88809c0eabfb by task kworker/u5:0/1141 CPU: 0 PID: 1141 Comm: kworker/u5:0 Not tainted 4.14.157-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: hci0 hci_rx_work Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0xf7/0x13b lib/dump_stack.c:58 print_address_description.cold.7+0x9/0x1c9 mm/kasan/report.c:252 kasan_report_error mm/kasan/report.c:351 [inline] kasan_report.cold.8+0x11a/0x2d3 mm/kasan/report.c:409 check_memory_region_inline mm/kasan/kasan.c:260 [inline] check_memory_region+0x13e/0x1b0 mm/kasan/kasan.c:267 memcpy+0x23/0x50 mm/kasan/kasan.c:302 memcpy include/linux/string.h:347 [inline] bacpy+0xe/0x10 include/net/bluetooth/bluetooth.h:233 hci_inquiry_result_with_rssi_evt net/bluetooth/hci_event.c:3629 [inline] hci_event_packet+0x1f26/0x9c3d net/bluetooth/hci_event.c:5363 hci_rx_work+0x342/0x890 net/bluetooth/hci_core.c:4237 process_one_work+0x7a3/0x16c0 kernel/workqueue.c:2114 worker_thread+0xcc/0xee0 kernel/workqueue.c:2248 kthread+0x33b/0x410 kernel/kthread.c:232 ret_from_fork+0x3a/0x50 arch/x86/entry/entry_64.S:404 Allocated by task 6861: save_stack_trace+0x16/0x20 arch/x86/kernel/stacktrace.c:59 save_stack+0x43/0xd0 mm/kasan/kasan.c:447 set_track mm/kasan/kasan.c:459 [inline] kasan_kmalloc+0xc7/0xe0 mm/kasan/kasan.c:551 __do_kmalloc_node mm/slab.c:3682 [inline] __kmalloc_node_track_caller+0x50/0x70 mm/slab.c:3696 __kmalloc_reserve.isra.36+0x2c/0xc0 net/core/skbuff.c:137 __alloc_skb+0xc1/0x500 net/core/skbuff.c:205 alloc_skb include/linux/skbuff.h:980 [inline] bt_skb_alloc include/net/bluetooth/bluetooth.h:336 [inline] vhci_get_user drivers/bluetooth/hci_vhci.c:180 [inline] vhci_write+0xa8/0x3e2 drivers/bluetooth/hci_vhci.c:299 call_write_iter include/linux/fs.h:1777 [inline] new_sync_write fs/read_write.c:469 [inline] __vfs_write+0x41b/0x850 fs/read_write.c:482 vfs_write+0x150/0x4f0 fs/read_write.c:544 SYSC_write fs/read_write.c:590 [inline] SyS_write+0x100/0x250 fs/read_write.c:582 do_syscall_64+0x1c9/0x5b0 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x42/0xb7 device hsr_slave_0 entered promiscuous mode Freed by task 0: (stack is not available) The buggy address belongs to the object at ffff88809c0eaa00 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 507 bytes inside of 512-byte region [ffff88809c0eaa00, ffff88809c0eac00) The buggy address belongs to the page: page:ffffea0002703a80 count:1 mapcount:0 mapping:ffff88809c0ea000 index:0x0 flags: 0x1fffc0000000100(slab) raw: 01fffc0000000100 ffff88809c0ea000 0000000000000000 0000000100000006 raw: ffffea0001fc2020 ffff8880aa801748 ffff8880aa800940 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff88809c0eab00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88809c0eab80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff88809c0eac00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88809c0eac80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ffff88809c0ead00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ==================================================================