syzbot


general protection fault in rcu_segcblist_enqueue

Status: fixed on 2022/03/08 16:11
Reported-by: syzbot+7590ddacf9f333c18f6c@syzkaller.appspotmail.com
Fix commit: eb7511bf9182 KVM: x86: Handle SRCU initialization failure during page track init
First crash: 587d, last: 518d

Cause bisection: introduced by (bisect log) :
commit 71217df39dc67a0aeed83352b0d712b7892036a2
Author: Paolo Valente <paolo.valente@linaro.org>
Date: Mon Jan 25 19:02:48 2021 +0000

  block, bfq: make waker-queue detection more robust

Crash: BUG: spinlock bad magic in synchronize_srcu (log)
Repro: syz .config

Fix bisection: fixed by (bisect log) :
commit 067a456d091d05fdae32cae350410d905968b645
Author: Sean Christopherson <seanjc@google.com>
Date: Tue Jul 13 16:32:43 2021 +0000

  KVM: SVM: Require exact CPUID.0x1 match when stuffing EDX at INIT


Sample crash report:
general protection fault, probably for non-canonical address 0xdffffc0000000000: 0000 [#1] PREEMPT SMP KASAN
KASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007]
CPU: 0 PID: 8358 Comm: syz-executor858 Not tainted 5.14.0-rc5-next-20210813-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:rcu_segcblist_enqueue+0xb9/0x130 kernel/rcu/rcu_segcblist.c:348
Code: 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 80 3c 02 00 75 4e 48 b8 00 00 00 00 00 fc ff df 48 8b 6b 20 48 89 ea 48 c1 ea 03 <80> 3c 02 00 75 21 48 89 75 00 48 89 73 20 48 83 c4 08 5b 5d c3 48
RSP: 0018:ffffc90002d1fbe0 EFLAGS: 00010046
RAX: dffffc0000000000 RBX: ffff8880b9c00080 RCX: ffffffff815b8cb0
RDX: 0000000000000000 RSI: ffffc90002d1fcc8 RDI: ffff8880b9c000a0
RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000003
R10: fffff520005a3f6e R11: 0000000000000000 R12: ffffc90002d1fcc8
R13: ffff8880b9c00080 R14: 0000000000000000 R15: ffff8880b9c00040
FS:  00007f6a0b6c7700(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00000000004d2700 CR3: 0000000073719000 CR4: 00000000001526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 srcu_gp_start_if_needed+0x116/0xbc0 kernel/rcu/srcutree.c:823
 __call_srcu kernel/rcu/srcutree.c:883 [inline]
 __synchronize_srcu+0x21f/0x290 kernel/rcu/srcutree.c:929
 kvm_mmu_uninit_vm+0x18/0x30 arch/x86/kvm/mmu/mmu.c:5625
 kvm_arch_destroy_vm+0x4e7/0x680 arch/x86/kvm/x86.c:11317
 kvm_create_vm arch/x86/kvm/../../../virt/kvm/kvm_main.c:1075 [inline]
 kvm_dev_ioctl_create_vm arch/x86/kvm/../../../virt/kvm/kvm_main.c:4548 [inline]
 kvm_dev_ioctl+0xfe6/0x1a40 arch/x86/kvm/../../../virt/kvm/kvm_main.c:4603
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:874 [inline]
 __se_sys_ioctl fs/ioctl.c:860 [inline]
 __x64_sys_ioctl+0x193/0x200 fs/ioctl.c:860
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae
RIP: 0033:0x446a69
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 a1 15 00 00 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 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f6a0b6c7278 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00000000004cb4d0 RCX: 0000000000446a69
RDX: 0000000000000000 RSI: 000000000000ae01 RDI: 0000000000000003
RBP: 00000000004cb4dc R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 000000000049b2a8
R13: 00007f6a0b6c7280 R14: 6d766b2f7665642f R15: 00000000004cb4d8
Modules linked in:
---[ end trace 87a789ef23d34c4d ]---
RIP: 0010:rcu_segcblist_enqueue+0xb9/0x130 kernel/rcu/rcu_segcblist.c:348
Code: 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 80 3c 02 00 75 4e 48 b8 00 00 00 00 00 fc ff df 48 8b 6b 20 48 89 ea 48 c1 ea 03 <80> 3c 02 00 75 21 48 89 75 00 48 89 73 20 48 83 c4 08 5b 5d c3 48
RSP: 0018:ffffc90002d1fbe0 EFLAGS: 00010046
RAX: dffffc0000000000 RBX: ffff8880b9c00080 RCX: ffffffff815b8cb0
RDX: 0000000000000000 RSI: ffffc90002d1fcc8 RDI: ffff8880b9c000a0
RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000003
R10: fffff520005a3f6e R11: 0000000000000000 R12: ffffc90002d1fcc8
R13: ffff8880b9c00080 R14: 0000000000000000 R15: ffff8880b9c00040
FS:  00007f6a0b6c7700(0000) GS:ffff8880b9c00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00000000004d2700 CR3: 0000000073719000 CR4: 00000000001526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess), 7 bytes skipped:
   0:	df 48 89             	fisttps -0x77(%rax)
   3:	fa                   	cli    
   4:	48 c1 ea 03          	shr    $0x3,%rdx
   8:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1)
   c:	75 4e                	jne    0x5c
   e:	48 b8 00 00 00 00 00 	movabs $0xdffffc0000000000,%rax
  15:	fc ff df 
  18:	48 8b 6b 20          	mov    0x20(%rbx),%rbp
  1c:	48 89 ea             	mov    %rbp,%rdx
  1f:	48 c1 ea 03          	shr    $0x3,%rdx
  23:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1) <-- trapping instruction
  27:	75 21                	jne    0x4a
  29:	48 89 75 00          	mov    %rsi,0x0(%rbp)
  2d:	48 89 73 20          	mov    %rsi,0x20(%rbx)
  31:	48 83 c4 08          	add    $0x8,%rsp
  35:	5b                   	pop    %rbx
  36:	5d                   	pop    %rbp
  37:	c3                   	retq   
  38:	48                   	rex.W

Crashes (368):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets Title
ci-upstream-linux-next-kasan-gce-root 2021/08/14 08:04 linux-next 4b358aabb93a 2489ab88 .config console log report syz C general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/06 06:46 upstream 0319b848b155 d236a457 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/04 23:34 upstream f1583cb1be35 d236a457 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/04 21:37 upstream f1583cb1be35 d236a457 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 10:10 upstream 7cca308cfdc0 d236a457 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/04 06:56 upstream 7cca308cfdc0 d236a457 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/03 17:31 upstream a9c9a6f741cd f62a5829 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/02 02:08 upstream 835d31d319d9 7eb7e152 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/07/13 22:59 upstream 40226a3d96ef fa0594c3 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/07/11 03:00 upstream 3dbdb38e2869 8f5a7b8c .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/07/09 04:39 upstream 3dbdb38e2869 1b20171a .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/07/02 15:09 upstream 3dbdb38e2869 658ebc66 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/07/02 07:41 upstream e058a84bfddc 658ebc66 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/07/02 03:21 upstream e04360a2ea01 658ebc66 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/07/01 07:17 upstream df04fbe8680b 38a885d1 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/06/30 23:17 upstream df04fbe8680b 38a885d1 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/03 03:32 upstream 4ac6d90867a4 15cea0a3 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/01 15:20 upstream 9c849ce86e0f 7eb7e152 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/01 14:05 upstream 9c849ce86e0f 7eb7e152 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/01 05:39 upstream 9c849ce86e0f 7eb7e152 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/01 00:39 upstream 9c849ce86e0f 7eb7e152 .config console log report syz general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-smack-root 2021/09/06 15:35 upstream 0319b848b155 6ca60148 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/06 10:42 upstream 0319b848b155 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/06 06:00 upstream 0319b848b155 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/06 04:48 upstream 0319b848b155 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/06 00:19 upstream 0319b848b155 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/05 22:06 upstream 0319b848b155 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/05 15:05 upstream 49624efa65ac d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/05 08:37 upstream 49624efa65ac d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/05 07:19 upstream 49624efa65ac d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/05 03:37 upstream f1583cb1be35 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/05 01:15 upstream f1583cb1be35 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 20:01 upstream f1583cb1be35 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 17:34 upstream f1583cb1be35 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 16:29 upstream f1583cb1be35 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 11:53 upstream 7cca308cfdc0 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 09:23 upstream 7cca308cfdc0 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 05:33 upstream 7cca308cfdc0 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 05:10 upstream 7cca308cfdc0 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/04 01:39 upstream 7cca308cfdc0 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/03 13:45 upstream a9c9a6f741cd f62a5829 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/03 11:35 upstream a9c9a6f741cd f62a5829 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-smack-root 2021/09/03 10:11 upstream a9c9a6f741cd f62a5829 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/03 08:40 upstream a9c9a6f741cd f62a5829 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/03 07:28 upstream a9c9a6f741cd 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/03 06:11 upstream a9c9a6f741cd 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-smack-root 2021/09/03 05:07 upstream 4ac6d90867a4 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/03 01:02 upstream 4ac6d90867a4 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/02 23:53 upstream 4ac6d90867a4 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/02 22:51 upstream 4ac6d90867a4 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/02 21:07 upstream 4ac6d90867a4 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/02 10:11 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/02 06:42 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/02 03:39 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-selinux-root 2021/09/02 01:44 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/01 23:44 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/01 22:35 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce 2021/09/01 22:05 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/06 00:59 upstream 0319b848b155 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/05 10:57 upstream 49624efa65ac d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/05 04:46 upstream 49624efa65ac d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/04 15:24 upstream f1583cb1be35 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/04 14:02 upstream f1583cb1be35 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/03 23:01 upstream 7cca308cfdc0 d236a457 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/03 20:28 upstream a9c9a6f741cd f62a5829 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/02 17:03 upstream 4ac6d90867a4 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/02 15:06 upstream 4ac6d90867a4 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/02 14:53 upstream 4ac6d90867a4 15cea0a3 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/02 09:08 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/09/02 07:52 upstream 835d31d319d9 7eb7e152 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-kasan-gce-386 2021/06/30 11:33 upstream 007b350a5875 84fd4c77 .config console log report info general protection fault in rcu_segcblist_enqueue
ci-upstream-linux-next-kasan-gce-root 2021/08/23 17:45 linux-next 46debfec12b4 b599f2fc .config console log report info general protection fault in rcu_segcblist_enqueue
* Struck through repros no longer work on HEAD.