bisecting cause commit starting from 03bd4773d898783fe3bc321287e4838e515fea92 building syzkaller on fc17ba4941e5e2cae9663b84e13627981c29d381 testing commit 03bd4773d898783fe3bc321287e4838e515fea92 with gcc (GCC) 8.1.0 all runs: crashed: general protection fault in ovs_vport_add testing release v5.3 testing commit 4d856f72c10ecb060868ed10ff1b1453943fc6c8 with gcc (GCC) 8.1.0 run #0: crashed: WARNING: ODEBUG bug in netdev_freemem run #1: OK run #2: OK run #3: OK run #4: OK run #5: OK run #6: OK run #7: OK run #8: OK run #9: OK testing release v5.2 testing commit 0ecfebd2b52404ae0c54a878c872bb93363ada36 with gcc (GCC) 8.1.0 all runs: OK # git bisect start v5.3 v5.2 Bisecting: 7848 revisions left to test after this (roughly 13 steps) [43c95d3694cc448fdf50bd53b7ff3a5bb4655883] Merge tag 'pinctrl-v5.3-1' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl testing commit 43c95d3694cc448fdf50bd53b7ff3a5bb4655883 with gcc (GCC) 8.1.0 run #0: crashed: general protection fault in send_hsr_supervision_frame run #1: crashed: general protection fault in send_hsr_supervision_frame run #2: crashed: general protection fault in send_hsr_supervision_frame run #3: crashed: general protection fault in send_hsr_supervision_frame run #4: crashed: general protection fault in send_hsr_supervision_frame run #5: crashed: general protection fault in send_hsr_supervision_frame run #6: crashed: general protection fault in send_hsr_supervision_frame run #7: OK run #8: OK run #9: OK # git bisect bad 43c95d3694cc448fdf50bd53b7ff3a5bb4655883 Bisecting: 4619 revisions left to test after this (roughly 12 steps) [8f6ccf6159aed1f04c6d179f61f6fb2691261e84] Merge tag 'clone3-v5.3' of git://git.kernel.org/pub/scm/linux/kernel/git/brauner/linux testing commit 8f6ccf6159aed1f04c6d179f61f6fb2691261e84 with gcc (GCC) 8.1.0 run #0: crashed: WARNING: ODEBUG bug in netdev_freemem run #1: OK run #2: OK run #3: OK run #4: OK run #5: OK run #6: OK run #7: OK run #8: OK run #9: OK # git bisect bad 8f6ccf6159aed1f04c6d179f61f6fb2691261e84 Bisecting: 1595 revisions left to test after this (roughly 11 steps) [ed63b9c873601ca113da5c7b1745e3946493e9f3] Merge tag 'media/v5.3-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media testing commit ed63b9c873601ca113da5c7b1745e3946493e9f3 with gcc (GCC) 8.1.0 all runs: OK # git bisect good ed63b9c873601ca113da5c7b1745e3946493e9f3 Bisecting: 798 revisions left to test after this (roughly 10 steps) [4b4704520d97b74e045154fc3b844b73ae4e7ebd] Merge tag 'acpi-5.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm testing commit 4b4704520d97b74e045154fc3b844b73ae4e7ebd with gcc (GCC) 8.1.0 all runs: OK # git bisect good 4b4704520d97b74e045154fc3b844b73ae4e7ebd Bisecting: 345 revisions left to test after this (roughly 9 steps) [608745f12462e2d8d94d5cc5dc94bf0960a881e3] Merge branch 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip testing commit 608745f12462e2d8d94d5cc5dc94bf0960a881e3 with gcc (GCC) 8.1.0 all runs: OK # git bisect good 608745f12462e2d8d94d5cc5dc94bf0960a881e3 Bisecting: 175 revisions left to test after this (roughly 8 steps) [988052f47adc5c3b0b004180b59bb3761d91b752] Merge tag 'locks-v5.3-1' of git://git.kernel.org/pub/scm/linux/kernel/git/jlayton/linux testing commit 988052f47adc5c3b0b004180b59bb3761d91b752 with gcc (GCC) 8.1.0 all runs: OK # git bisect good 988052f47adc5c3b0b004180b59bb3761d91b752 Bisecting: 83 revisions left to test after this (roughly 7 steps) [2e756758e5cb4ea29cba5865d00fad476ce94a93] Merge tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 testing commit 2e756758e5cb4ea29cba5865d00fad476ce94a93 with gcc (GCC) 8.1.0 all runs: OK # git bisect good 2e756758e5cb4ea29cba5865d00fad476ce94a93 Bisecting: 49 revisions left to test after this (roughly 5 steps) [b78fa45d4edb92fd7b882b2ec25b936cad412670] nfsd: Make __get_nfsdfs_client() static testing commit b78fa45d4edb92fd7b882b2ec25b936cad412670 with gcc (GCC) 8.1.0 all runs: crashed: KASAN: use-after-free Read in internal_dev_create # git bisect bad b78fa45d4edb92fd7b882b2ec25b936cad412670 Bisecting: 16 revisions left to test after this (roughly 4 steps) [59f8e91b75ecf16f22d62eca0659c13901eff5f3] nfsd4: use reference count to free client testing commit 59f8e91b75ecf16f22d62eca0659c13901eff5f3 with gcc (GCC) 8.1.0 fs/nfsd/nfs4state.c:1890:11: error: ‘struct nfs4_client’ has no member named ‘cl_nfsd_dentry’; did you mean ‘cl_cb_ident’? # git bisect skip 59f8e91b75ecf16f22d62eca0659c13901eff5f3 Bisecting: 16 revisions left to test after this (roughly 4 steps) [297e57a24f6e2d5a041822003816124e48164eef] nfsd: Make two functions static testing commit 297e57a24f6e2d5a041822003816124e48164eef with gcc (GCC) 8.1.0 all runs: crashed: KASAN: use-after-free Read in internal_dev_create # git bisect bad 297e57a24f6e2d5a041822003816124e48164eef Bisecting: 16 revisions left to test after this (roughly 4 steps) [14ed14cc7c062bbed7821be0a93938dc78a49803] nfsd: rename cl_refcount testing commit 14ed14cc7c062bbed7821be0a93938dc78a49803 with gcc (GCC) 8.1.0 all runs: crashed: KASAN: use-after-free Read in internal_dev_create # git bisect bad 14ed14cc7c062bbed7821be0a93938dc78a49803 Bisecting: 7 revisions left to test after this (roughly 3 steps) [f85d93385e9fe6886a751f647f6812a89bf6bee3] locks: Cleanup lm_compare_owner and lm_owner_key testing commit f85d93385e9fe6886a751f647f6812a89bf6bee3 with gcc (GCC) 8.1.0 all runs: crashed: KASAN: use-after-free Read in internal_dev_create # git bisect bad f85d93385e9fe6886a751f647f6812a89bf6bee3 Bisecting: 3 revisions left to test after this (roughly 2 steps) [9de3ec1d57113e270638254868675d9c048b071e] lockd: prepare nlm_lockowner for use by the server testing commit 9de3ec1d57113e270638254868675d9c048b071e with gcc (GCC) 8.1.0 all runs: crashed: KASAN: use-after-free Read in internal_dev_create # git bisect bad 9de3ec1d57113e270638254868675d9c048b071e Bisecting: 1 revision left to test after this (roughly 1 step) [3ba75830ce175550ef45c6524ec62faab8f62c1b] nfsd4: drc containerization testing commit 3ba75830ce175550ef45c6524ec62faab8f62c1b with gcc (GCC) 8.1.0 all runs: crashed: KASAN: use-after-free Read in internal_dev_create # git bisect bad 3ba75830ce175550ef45c6524ec62faab8f62c1b Bisecting: 0 revisions left to test after this (roughly 0 steps) [b401170f6d9cd4270e0159d9b016f4ccb06caa85] nfsd: don't call nfsd_reply_cache_shutdown twice testing commit b401170f6d9cd4270e0159d9b016f4ccb06caa85 with gcc (GCC) 8.1.0 all runs: crashed: KASAN: use-after-free Read in internal_dev_create # git bisect bad b401170f6d9cd4270e0159d9b016f4ccb06caa85 b401170f6d9cd4270e0159d9b016f4ccb06caa85 is the first bad commit commit b401170f6d9cd4270e0159d9b016f4ccb06caa85 Author: J. Bruce Fields Date: Thu May 16 14:24:40 2019 -0400 nfsd: don't call nfsd_reply_cache_shutdown twice The caller is cleaning up on ENOMEM, don't try to do it here too. Signed-off-by: J. Bruce Fields :040000 040000 46cf53503c199f5bfda852526baa156c0fb21e50 2c6e4a698067ccf7f8b88bf2aef115f8197d1b40 M fs revisions tested: 18, total time: 3h57m21.923402003s (build: 1h41m57.807623983s, test: 2h9m54.371689371s) first bad commit: b401170f6d9cd4270e0159d9b016f4ccb06caa85 nfsd: don't call nfsd_reply_cache_shutdown twice cc: ["bfields@fieldses.org" "bfields@redhat.com" "chuck.lever@oracle.com" "linux-kernel@vger.kernel.org" "linux-nfs@vger.kernel.org"] crash: KASAN: use-after-free Read in internal_dev_create R10: 0000000000000000 R11: 0000000000000246 R12: 00007f2e710336d4 R13: 00000000004c7af5 R14: 00000000004dd840 R15: 0000000000000004 ================================================================== BUG: KASAN: use-after-free in internal_dev_create+0x4da/0x4e0 net/openvswitch/vport-internal_dev.c:214 Read of size 8 at addr ffff888092a2c600 by task syz-executor.1/7377 CPU: 0 PID: 7377 Comm: syz-executor.1 Not tainted 5.2.0-rc2+ #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+0x113/0x167 lib/dump_stack.c:113 print_address_description.cold.5+0x9/0x1ff mm/kasan/report.c:188 __kasan_report.cold.6+0x1b/0x39 mm/kasan/report.c:317 kasan_report+0x12/0x20 mm/kasan/common.c:614 __asan_report_load8_noabort+0x14/0x20 mm/kasan/generic_report.c:132 internal_dev_create+0x4da/0x4e0 net/openvswitch/vport-internal_dev.c:214 ovs_vport_add+0x25c/0x500 net/openvswitch/vport.c:212 new_vport+0x15/0x1f0 net/openvswitch/datapath.c:207 ovs_dp_cmd_new+0x48a/0xce0 net/openvswitch/datapath.c:1627 genl_family_rcv_msg+0x5cc/0x1150 net/netlink/genetlink.c:629 genl_rcv_msg+0xa7/0x13e net/netlink/genetlink.c:654 netlink_rcv_skb+0x13c/0x380 net/netlink/af_netlink.c:2486 genl_rcv+0x23/0x40 net/netlink/genetlink.c:665 netlink_unicast_kernel net/netlink/af_netlink.c:1311 [inline] netlink_unicast+0x43f/0x630 net/netlink/af_netlink.c:1337 netlink_sendmsg+0x765/0xc50 net/netlink/af_netlink.c:1926 sock_sendmsg_nosec net/socket.c:652 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:671 ___sys_sendmsg+0x647/0x950 net/socket.c:2292 __sys_sendmsg+0xd9/0x180 net/socket.c:2330 __do_sys_sendmsg net/socket.c:2339 [inline] __se_sys_sendmsg net/socket.c:2337 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2337 do_syscall_64+0xd0/0x530 arch/x86/entry/common.c:301 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x459a29 Code: fd b7 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 cb b7 fb ff c3 66 2e 0f 1f 84 00 00 00 00 RSP: 002b:00007f2e71032c78 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 00007f2e71032c90 RCX: 0000000000459a29 RDX: 0000000000000000 RSI: 0000000020000280 RDI: 0000000000000003 RBP: 000000000075bf20 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00007f2e710336d4 R13: 00000000004c7af5 R14: 00000000004dd840 R15: 0000000000000004 Allocated by task 7377: save_stack+0x21/0x90 mm/kasan/common.c:71 set_track mm/kasan/common.c:79 [inline] __kasan_kmalloc.constprop.8+0xc7/0xd0 mm/kasan/common.c:489 kasan_kmalloc+0x9/0x10 mm/kasan/common.c:503 kmem_cache_alloc_trace+0x154/0x740 mm/slab.c:3555 kmalloc include/linux/slab.h:547 [inline] kzalloc include/linux/slab.h:742 [inline] ovs_vport_alloc+0x51/0x250 net/openvswitch/vport.c:143 internal_dev_create+0x23/0x4e0 net/openvswitch/vport-internal_dev.c:175 ovs_vport_add+0x25c/0x500 net/openvswitch/vport.c:212 new_vport+0x15/0x1f0 net/openvswitch/datapath.c:207 ovs_dp_cmd_new+0x48a/0xce0 net/openvswitch/datapath.c:1627 genl_family_rcv_msg+0x5cc/0x1150 net/netlink/genetlink.c:629 genl_rcv_msg+0xa7/0x13e net/netlink/genetlink.c:654 netlink_rcv_skb+0x13c/0x380 net/netlink/af_netlink.c:2486 genl_rcv+0x23/0x40 net/netlink/genetlink.c:665 netlink_unicast_kernel net/netlink/af_netlink.c:1311 [inline] netlink_unicast+0x43f/0x630 net/netlink/af_netlink.c:1337 netlink_sendmsg+0x765/0xc50 net/netlink/af_netlink.c:1926 sock_sendmsg_nosec net/socket.c:652 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:671 ___sys_sendmsg+0x647/0x950 net/socket.c:2292 __sys_sendmsg+0xd9/0x180 net/socket.c:2330 __do_sys_sendmsg net/socket.c:2339 [inline] __se_sys_sendmsg net/socket.c:2337 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2337 do_syscall_64+0xd0/0x530 arch/x86/entry/common.c:301 entry_SYSCALL_64_after_hwframe+0x49/0xbe Freed by task 7377: save_stack+0x21/0x90 mm/kasan/common.c:71 set_track mm/kasan/common.c:79 [inline] __kasan_slab_free+0x102/0x150 mm/kasan/common.c:451 kasan_slab_free+0xe/0x10 mm/kasan/common.c:459 __cache_free mm/slab.c:3432 [inline] kfree+0xcf/0x220 mm/slab.c:3755 ovs_vport_free+0x34/0x40 net/openvswitch/vport.c:177 internal_dev_destructor+0x5f/0x70 net/openvswitch/vport-internal_dev.c:96 register_netdevice+0xa84/0x1100 net/core/dev.c:8793 internal_dev_create+0x2b6/0x4e0 net/openvswitch/vport-internal_dev.c:202 ovs_vport_add+0x25c/0x500 net/openvswitch/vport.c:212 new_vport+0x15/0x1f0 net/openvswitch/datapath.c:207 ovs_dp_cmd_new+0x48a/0xce0 net/openvswitch/datapath.c:1627 genl_family_rcv_msg+0x5cc/0x1150 net/netlink/genetlink.c:629 genl_rcv_msg+0xa7/0x13e net/netlink/genetlink.c:654 netlink_rcv_skb+0x13c/0x380 net/netlink/af_netlink.c:2486 genl_rcv+0x23/0x40 net/netlink/genetlink.c:665 netlink_unicast_kernel net/netlink/af_netlink.c:1311 [inline] netlink_unicast+0x43f/0x630 net/netlink/af_netlink.c:1337 netlink_sendmsg+0x765/0xc50 net/netlink/af_netlink.c:1926 sock_sendmsg_nosec net/socket.c:652 [inline] sock_sendmsg+0xb5/0xf0 net/socket.c:671 ___sys_sendmsg+0x647/0x950 net/socket.c:2292 __sys_sendmsg+0xd9/0x180 net/socket.c:2330 __do_sys_sendmsg net/socket.c:2339 [inline] __se_sys_sendmsg net/socket.c:2337 [inline] __x64_sys_sendmsg+0x73/0xb0 net/socket.c:2337 do_syscall_64+0xd0/0x530 arch/x86/entry/common.c:301 entry_SYSCALL_64_after_hwframe+0x49/0xbe The buggy address belongs to the object at ffff888092a2c600 which belongs to the cache kmalloc-128 of size 128 The buggy address is located 0 bytes inside of 128-byte region [ffff888092a2c600, ffff888092a2c680) The buggy address belongs to the page: page:ffffea00024a8b00 refcount:1 mapcount:0 mapping:ffff8880aa400640 index:0x0 flags: 0x1fffc0000000200(slab) raw: 01fffc0000000200 ffffea000242a308 ffffea000249fbc8 ffff8880aa400640 raw: 0000000000000000 ffff888092a2c000 0000000100000015 0000000000000000 page dumped because: kasan: bad access detected Memory state around the buggy address: ffff888092a2c500: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ffff888092a2c580: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc >ffff888092a2c600: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb ^ ffff888092a2c680: fc fc fc fc fc fc fc fc fb fb fb fb fb fb fb fb ffff888092a2c700: fb fb fb fb fb fb fb fb fc fc fc fc fc fc fc fc ==================================================================