bisecting fixing commit since b98aebd298246df37b472c52a2ee1023256d02e3 building syzkaller on 8c88c9c1c99c8cd8dabc951164c820b9c9f25114 testing commit b98aebd298246df37b472c52a2ee1023256d02e3 with gcc (GCC) 8.1.0 kernel signature: f6a14ecfcb7bb932ddb8bd93bf9a064ce7743f83 all runs: crashed: KASAN: slab-out-of-bounds Read in tcf_exts_destroy testing current HEAD b0cdffaa546e24acf92ab3b0d4e917a51aff6a82 testing commit b0cdffaa546e24acf92ab3b0d4e917a51aff6a82 with gcc (GCC) 8.1.0 kernel signature: 234e0da12f6aff112b469b4eb392659c3ec9d446 all runs: crashed: KASAN: slab-out-of-bounds Read in tcf_exts_destroy revisions tested: 2, total time: 23m4.265558277s (build: 16m21.057496456s, test: 6m21.258831703s) the crash still happens on HEAD commit msg: Linux 4.14.163 crash: KASAN: slab-out-of-bounds Read in tcf_exts_destroy IPv6: ADDRCONF(NETDEV_CHANGE): veth0_to_bond: link becomes ready 8021q: adding VLAN 0 to HW filter on device bond0 IPv6: ADDRCONF(NETDEV_UP): veth1_to_bond: link is not ready IPv6: ADDRCONF(NETDEV_UP): veth1_to_bridge: link is not ready ================================================================== BUG: KASAN: slab-out-of-bounds in tcf_exts_to_list include/net/pkt_cls.h:150 [inline] BUG: KASAN: slab-out-of-bounds in tcf_exts_destroy+0x2b4/0x3b0 net/sched/cls_api.c:897 Read of size 4 at addr ffff888089e0bf74 by task syz-executor.0/6894 CPU: 0 PID: 6894 Comm: syz-executor.0 Not tainted 4.14.163-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 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 __asan_report_load4_noabort+0x14/0x20 mm/kasan/report.c:429 tcf_exts_to_list include/net/pkt_cls.h:150 [inline] tcf_exts_destroy+0x2b4/0x3b0 net/sched/cls_api.c:897 tcindex_free_perfect_hash.isra.6+0x8e/0x110 net/sched/cls_tcindex.c:291 tcindex_set_parms+0xe11/0x1ae0 net/sched/cls_tcindex.c:502 tcindex_change+0x1b7/0x24e net/sched/cls_tcindex.c:535 tc_ctl_tfilter+0x1151/0x1b2e net/sched/cls_api.c:738 rtnetlink_rcv_msg+0x34f/0x9d0 net/core/rtnetlink.c:4306 netlink_rcv_skb+0x133/0x370 net/netlink/af_netlink.c:2432 rtnetlink_rcv+0x10/0x20 net/core/rtnetlink.c:4318 netlink_unicast_kernel net/netlink/af_netlink.c:1286 [inline] netlink_unicast+0x40d/0x5f0 net/netlink/af_netlink.c:1312 netlink_sendmsg+0x730/0xbd0 net/netlink/af_netlink.c:1877 sock_sendmsg_nosec net/socket.c:646 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:656 ___sys_sendmsg+0x282/0x920 net/socket.c:2062 __sys_sendmmsg+0x126/0x300 net/socket.c:2152 SYSC_sendmmsg net/socket.c:2183 [inline] SyS_sendmmsg+0xd/0x20 net/socket.c:2178 do_syscall_64+0x1c7/0x5b0 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x459a59 RSP: 002b:00007f0a1d630c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000133 RAX: ffffffffffffffda RBX: 0000000000000004 RCX: 0000000000459a59 RDX: 0000000000000332 RSI: 0000000020000140 RDI: 0000000000000008 RBP: 000000000075bfc8 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007f0a1d6316d4 R13: 00000000004c74c1 R14: 00000000004dd1c0 R15: 00000000ffffffff Allocated by task 6894: 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 mm/slab.c:3720 [inline] __kmalloc+0x15b/0x7b0 mm/slab.c:3729 kmalloc_array include/linux/slab.h:607 [inline] kcalloc include/linux/slab.h:618 [inline] tcindex_alloc_perfect_hash+0x4f/0x2e0 net/sched/cls_tcindex.c:299 tcindex_set_parms+0x3b8/0x1ae0 net/sched/cls_tcindex.c:357 tcindex_change+0x1b7/0x24e net/sched/cls_tcindex.c:535 tc_ctl_tfilter+0x1151/0x1b2e net/sched/cls_api.c:738 rtnetlink_rcv_msg+0x34f/0x9d0 net/core/rtnetlink.c:4306 netlink_rcv_skb+0x133/0x370 net/netlink/af_netlink.c:2432 rtnetlink_rcv+0x10/0x20 net/core/rtnetlink.c:4318 netlink_unicast_kernel net/netlink/af_netlink.c:1286 [inline] netlink_unicast+0x40d/0x5f0 net/netlink/af_netlink.c:1312 netlink_sendmsg+0x730/0xbd0 net/netlink/af_netlink.c:1877 sock_sendmsg_nosec net/socket.c:646 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:656 ___sys_sendmsg+0x282/0x920 net/socket.c:2062 __sys_sendmmsg+0x126/0x300 net/socket.c:2152 SYSC_sendmmsg net/socket.c:2183 [inline] SyS_sendmmsg+0xd/0x20 net/socket.c:2178 do_syscall_64+0x1c7/0x5b0 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x42/0xb7 Freed by task 0: (stack is not available) The buggy address belongs to the object at ffff888089e0bf00 which belongs to the cache kmalloc-128 of size 128 The buggy address is located 116 bytes inside of 128-byte region [ffff888089e0bf00, ffff888089e0bf80) The buggy address belongs to the page: page:ffffea00022782c0 count:1 mapcount:0 mapping:ffff888089e0b000 index:0x0 flags: 0x1fffc0000000100(slab) raw: 01fffc0000000100 ffff888089e0b000 0000000000000000 0000000100000015 raw: ffffea00022736a0 ffff8880aa801548 ffff8880aa800640 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888089e0be00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888089e0be80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff888089e0bf00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc fc ^ ffff888089e0bf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888089e0c000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================