bisecting fixing commit since 5692097116094a4a7045abcc1dbc172dbdc5657e building syzkaller on 749688d22abef3f3cb9a0480e15c19a3f2ed8e13 testing commit 5692097116094a4a7045abcc1dbc172dbdc5657e with gcc (GCC) 8.1.0 kernel signature: 028596d34662c04532ee810ba990cd0cfbde5748d2ad72f6c72e815f3d876d9f all runs: crashed: KASAN: slab-out-of-bounds Read in xt_find_match testing current HEAD 6dd0e32665e591e9debe3edaf73c2f8135bf047e testing commit 6dd0e32665e591e9debe3edaf73c2f8135bf047e with gcc (GCC) 8.1.0 kernel signature: 23d968b097c978d452b6f4586423708afcf4d2dc34f155784a37cd21bbbaa03f all runs: crashed: KASAN: slab-out-of-bounds Read in xt_find_match revisions tested: 2, total time: 25m4.599993733s (build: 18m7.1519167s, test: 6m13.760798165s) the crash still happens on HEAD commit msg: Linux 4.19.115 crash: KASAN: slab-out-of-bounds Read in xt_find_match IPv6: ADDRCONF(NETDEV_UP): batadv_slave_1: link is not ready batman_adv: batadv0: Interface activated: batadv_slave_1 IPv6: ADDRCONF(NETDEV_CHANGE): batadv_slave_1: link becomes ready IPv6: ADDRCONF(NETDEV_CHANGE): veth1_to_batadv: link becomes ready ================================================================== BUG: KASAN: slab-out-of-bounds in __lock_acquire+0x3426/0x4980 kernel/locking/lockdep.c:3290 Read of size 8 at addr ffff888216159a30 by task syz-executor.0/7833 CPU: 1 PID: 7833 Comm: syz-executor.0 Not tainted 4.19.115-syzkaller #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+0x123/0x177 lib/dump_stack.c:118 print_address_description.cold.8+0x9/0x1ff mm/kasan/report.c:256 kasan_report_error mm/kasan/report.c:354 [inline] kasan_report.cold.9+0x242/0x309 mm/kasan/report.c:412 __asan_report_load8_noabort+0x14/0x20 mm/kasan/report.c:433 __lock_acquire+0x3426/0x4980 kernel/locking/lockdep.c:3290 lock_acquire+0x173/0x3d0 kernel/locking/lockdep.c:3903 __mutex_lock_common kernel/locking/mutex.c:925 [inline] __mutex_lock+0xf5/0x1210 kernel/locking/mutex.c:1072 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:1087 xt_find_match+0x61/0x1b0 net/netfilter/x_tables.c:189 xt_request_find_match+0x4e/0xc0 net/netfilter/x_tables.c:219 get_xt_match net/sched/em_ipt.c:112 [inline] em_ipt_change+0x21c/0x590 net/sched/em_ipt.c:132 tcf_em_validate net/sched/ematch.c:248 [inline] tcf_em_tree_validate+0x96f/0x1383 net/sched/ematch.c:365 flow_change+0x370/0x2000 net/sched/cls_flow.c:439 tc_new_tfilter+0x613/0x1550 net/sched/cls_api.c:1320 rtnetlink_rcv_msg+0x34f/0x8f0 net/core/rtnetlink.c:4777 netlink_rcv_skb+0x142/0x390 net/netlink/af_netlink.c:2455 rtnetlink_rcv+0x10/0x20 net/core/rtnetlink.c:4795 netlink_unicast_kernel net/netlink/af_netlink.c:1318 [inline] netlink_unicast+0x443/0x650 net/netlink/af_netlink.c:1344 netlink_sendmsg+0x765/0xc40 net/netlink/af_netlink.c:1909 sock_sendmsg_nosec net/socket.c:622 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:632 ___sys_sendmsg+0x647/0x950 net/socket.c:2115 __sys_sendmsg+0xd9/0x180 net/socket.c:2153 __do_sys_sendmsg net/socket.c:2162 [inline] __se_sys_sendmsg net/socket.c:2160 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2160 do_syscall_64+0xd0/0x4e0 arch/x86/entry/common.c:293 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x45c849 Code: ad b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 7b b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f81e42ddc78 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 00007f81e42de6d4 RCX: 000000000045c849 RDX: 0000000000000000 RSI: 00000000200001c0 RDI: 0000000000000003 RBP: 000000000076bf00 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff R13: 00000000000009fa R14: 00000000004ccb28 R15: 000000000076bf0c Allocated by task 1: save_stack+0x43/0xd0 mm/kasan/kasan.c:448 set_track mm/kasan/kasan.c:460 [inline] kasan_kmalloc+0xc7/0xe0 mm/kasan/kasan.c:553 kmem_cache_alloc_trace+0x152/0x740 mm/slab.c:3625 kmalloc include/linux/slab.h:515 [inline] kmalloc_array include/linux/slab.h:636 [inline] kcalloc include/linux/slab.h:648 [inline] xt_init+0x124/0x27c net/netfilter/x_tables.c:1902 do_one_initcall+0xbc/0x518 init/main.c:883 do_initcall_level init/main.c:951 [inline] do_initcalls init/main.c:959 [inline] do_basic_setup init/main.c:977 [inline] kernel_init_freeable+0x461/0x505 init/main.c:1144 kernel_init+0xc/0x119 init/main.c:1061 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:415 Freed by task 0: (stack is not available) The buggy address belongs to the object at ffff888216158800 which belongs to the cache kmalloc-4096 of size 4096 The buggy address is located 560 bytes to the right of 4096-byte region [ffff888216158800, ffff888216159800) The buggy address belongs to the page: page:ffffea0008585600 count:1 mapcount:0 mapping:ffff88812c29cdc0 index:0x0 compound_mapcount: 0 flags: 0x57ffe0000008100(slab|head) raw: 057ffe0000008100 ffffea0008585588 ffffea0008585708 ffff88812c29cdc0 raw: 0000000000000000 ffff888216158800 0000000100000001 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888216159900: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888216159980: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc >ffff888216159a00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff888216159a80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff888216159b00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ==================================================================