bisecting fixing commit since c196b3a9c83ae3491280b739d231d02b3cb9d041 building syzkaller on 0ef84591d219e3142621dc31dcec970300f7ec0c testing commit c196b3a9c83ae3491280b739d231d02b3cb9d041 with gcc (GCC) 8.4.1 20210217 kernel signature: 9cd59a74db68a78940ed27b7c9d8a0296cc86129598c099a1d908830ae66af2e run #0: crashed: WARNING in mutex_destroy run #1: crashed: WARNING in mutex_destroy run #2: crashed: WARNING in mutex_destroy run #3: crashed: general protection fault in vgem_fence_attach_ioctl run #4: crashed: general protection fault in vgem_fence_attach_ioctl run #5: crashed: general protection fault in vgem_fence_attach_ioctl run #6: crashed: general protection fault in vgem_fence_attach_ioctl run #7: crashed: WARNING in mutex_destroy run #8: crashed: general protection fault in vgem_fence_attach_ioctl run #9: crashed: general protection fault in vgem_fence_attach_ioctl run #10: crashed: general protection fault in vgem_fence_attach_ioctl run #11: crashed: general protection fault in vgem_fence_attach_ioctl run #12: crashed: general protection fault in vgem_fence_attach_ioctl run #13: crashed: general protection fault in vgem_fence_attach_ioctl run #14: crashed: general protection fault in vgem_fence_attach_ioctl run #15: crashed: general protection fault in vgem_fence_attach_ioctl run #16: crashed: WARNING in mutex_destroy run #17: crashed: general protection fault in vgem_fence_attach_ioctl run #18: crashed: general protection fault in vgem_fence_attach_ioctl run #19: crashed: WARNING in mutex_destroy testing current HEAD 3242aa3a635c0958671ee1e4b0958dcc7c4e5c79 testing commit 3242aa3a635c0958671ee1e4b0958dcc7c4e5c79 with gcc (GCC) 8.4.1 20210217 kernel signature: 84bf1b7bc8e05f095b411a9e5b58f4b7911f6ecabafabb3e323dc1208641d535 run #0: crashed: general protection fault in vgem_fence_attach_ioctl run #1: crashed: general protection fault in vgem_fence_attach_ioctl run #2: crashed: general protection fault in vgem_fence_attach_ioctl run #3: crashed: WARNING in mutex_destroy run #4: crashed: general protection fault in vgem_fence_attach_ioctl run #5: crashed: general protection fault in vgem_fence_attach_ioctl run #6: crashed: general protection fault in vgem_fence_attach_ioctl run #7: crashed: KASAN: use-after-free Read in vgem_fence_attach_ioctl run #8: crashed: general protection fault in vgem_fence_attach_ioctl run #9: crashed: general protection fault in vgem_fence_attach_ioctl revisions tested: 2, total time: 22m17.625928112s (build: 14m53.293955075s, test: 6m24.414567151s) the crash still happens on HEAD commit msg: Linux 4.14.222 crash: general protection fault in vgem_fence_attach_ioctl IPv6: ADDRCONF(NETDEV_CHANGE): batadv_slave_1: link becomes ready IPv6: ADDRCONF(NETDEV_CHANGE): veth1_to_batadv: link becomes ready kasan: CONFIG_KASAN_INLINE enabled kasan: GPF could be caused by NULL-ptr deref or user memory access general protection fault: 0000 [#1] PREEMPT SMP KASAN Modules linked in: CPU: 1 PID: 10695 Comm: syz-executor.2 Not tainted 4.14.222-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 task: ffff8880ab72a040 task.stack: ffff8880870d0000 RIP: 0010:vgem_fence_attach_ioctl+0x2f2/0x6d0 drivers/gpu/drm/vgem/vgem_fence.c:184 RSP: 0018:ffff8880870d7b40 EFLAGS: 00010202 RAX: dffffc0000000000 RBX: ffff8880af41e040 RCX: 0000000000000000 RDX: 000000000000001c RSI: 0000000000000001 RDI: 00000000000000e0 RBP: ffff8880870d7be8 R08: 0000000000000001 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: ffff8880a54dda00 R13: ffff8880a89dc500 R14: ffff8880a54dda04 R15: 0000000000000000 FS: 00007f0b41dc3700(0000) GS:ffff8880ba700000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000002920808 CR3: 00000000a562e000 CR4: 00000000001406e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: drm_ioctl_kernel+0x133/0x1d0 drivers/gpu/drm/drm_ioctl.c:736 drm_ioctl+0x417/0x900 drivers/gpu/drm/drm_ioctl.c:836 vfs_ioctl fs/ioctl.c:46 [inline] file_ioctl fs/ioctl.c:500 [inline] do_vfs_ioctl+0x180/0xfb0 fs/ioctl.c:684 SYSC_ioctl fs/ioctl.c:701 [inline] SyS_ioctl+0x74/0x80 fs/ioctl.c:692 do_syscall_64+0x1c7/0x5b0 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x46/0xbb RIP: 0033:0x465889 RSP: 002b:00007f0b41dc3188 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 000000000055bf00 RCX: 0000000000465889 RDX: 0000000020000140 RSI: 00000000c10c5541 RDI: 0000000000000003 RBP: 00000000004af688 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000055bf00 R13: 00007ffdbd089ecf R14: 00007f0b41dc3300 R15: 0000000000022000 Code: ea 03 80 3c 02 00 0f 85 93 03 00 00 4d 8b bd 18 01 00 00 48 b8 00 00 00 00 00 fc ff df 49 8d bf e0 00 00 00 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 8f 03 00 00 49 8b 87 e0 00 00 00 4c 89 f2 48 RIP: vgem_fence_attach_ioctl+0x2f2/0x6d0 drivers/gpu/drm/vgem/vgem_fence.c:184 RSP: ffff8880870d7b40 ---[ end trace 387ef637aacc2ed5 ]---