syzbot


general protection fault in restart_apic_timer

Status: fixed on 2023/05/02 12:05
Reported-by: syzbot+b6a74be92b5063a0f1ff@syzkaller.appspotmail.com
Fix commit: 4483dc41d123 KVM: VMX: Move preemption timer <=> hrtimer dance to common x86
First crash: 611d, last: 611d
Cause bisection: failed (error log, bisect log)
  
Discussions (1)
Title Replies (including bot) Last reply
[PATCH][for stable/linux-5.15.y] KVM: VMX: Move preemption timer <=> hrtimer dance to common x86 3 (3) 2023/04/03 13:08
Last patch testing requests (3)
Created Duration User Patch Repo Result
2023/03/28 07:53 16m tudor.ambarus@linaro.org git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git v5.17 OK log
2023/03/28 06:50 25m tudor.ambarus@linaro.org git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git v6.3-rc4 OK log
2023/03/24 08:02 7m tudor.ambarus@linaro.org lts report log

Sample crash report:
general protection fault, probably for non-canonical address 0xdffffc000000000d: 0000 [#1] PREEMPT SMP KASAN
KASAN: null-ptr-deref in range [0x0000000000000068-0x000000000000006f]
CPU: 1 PID: 328 Comm: syz-executor204 Not tainted 5.15.94-syzkaller-03204-g5448b2fda85f #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023
RIP: 0010:apic_lvtt_period arch/x86/kvm/lapic.c:355 [inline]
RIP: 0010:restart_apic_timer+0x99/0x990 arch/x86/kvm/lapic.c:1917
Code: f2 01 66 43 c7 44 3c 0d f3 f3 43 c6 44 3c 0f f3 e8 6c e4 58 00 bf 01 00 00 00 e8 a2 e1 35 00 49 8d 5e 68 49 89 dd 49 c1 ed 03 <43> 0f b6 44 3d 00 84 c0 0f 85 e8 05 00 00 48 89 5c 24 20 8b 1b bf
RSP: 0018:ffffc90000947a40 EFLAGS: 00010202
RAX: 1ffff11020e35da8 RBX: 0000000000000068 RCX: ffffffff84b88c00
RDX: 0000000000000000 RSI: 0000000000030d40 RDI: ffffffff81168d5e
RBP: ffffc90000947b60 R08: ffffffff8108d82b R09: ffffed1020e35c59
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff92000128f50
R13: 000000000000000d R14: 0000000000000000 R15: dffffc0000000000
FS:  00005555574d3300(0000) GS:ffff8881f7100000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f973d5e9130 CR3: 000000011fa0a000 CR4: 00000000003526a0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 kvm_lapic_switch_to_hv_timer+0x3b/0x40 arch/x86/kvm/lapic.c:1949
 vmx_post_block+0x4b/0x60 arch/x86/kvm/vmx/vmx.c:7589
 vcpu_block arch/x86/kvm/x86.c:10052 [inline]
 vcpu_run arch/x86/kvm/x86.c:10106 [inline]
 kvm_arch_vcpu_ioctl_run+0xdff/0x2150 arch/x86/kvm/x86.c:10336
 kvm_vcpu_ioctl+0x7eb/0xcf0 arch/x86/kvm/../../../virt/kvm/kvm_main.c:3843
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:874 [inline]
 __se_sys_ioctl+0x114/0x190 fs/ioctl.c:860
 __x64_sys_ioctl+0x7b/0x90 fs/ioctl.c:860
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f973d577b99
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 b1 14 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 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fff76e02538 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f973d577b99
RDX: 0000000000000000 RSI: 000000000000ae80 RDI: 0000000000000005
RBP: 0000000000000000 R08: 0000000000000000 R09: 00007fff76e026d8
R10: 0000000000009120 R11: 0000000000000246 R12: 00007f973d53ae00
R13: 431bde82d7b634db R14: 0000000000000000 R15: 0000000000000000
 </TASK>
Modules linked in:
---[ end trace f6414f99fcc491c7 ]---
RIP: 0010:apic_lvtt_period arch/x86/kvm/lapic.c:355 [inline]
RIP: 0010:restart_apic_timer+0x99/0x990 arch/x86/kvm/lapic.c:1917
Code: f2 01 66 43 c7 44 3c 0d f3 f3 43 c6 44 3c 0f f3 e8 6c e4 58 00 bf 01 00 00 00 e8 a2 e1 35 00 49 8d 5e 68 49 89 dd 49 c1 ed 03 <43> 0f b6 44 3d 00 84 c0 0f 85 e8 05 00 00 48 89 5c 24 20 8b 1b bf
RSP: 0018:ffffc90000947a40 EFLAGS: 00010202
RAX: 1ffff11020e35da8 RBX: 0000000000000068 RCX: ffffffff84b88c00
RDX: 0000000000000000 RSI: 0000000000030d40 RDI: ffffffff81168d5e
RBP: ffffc90000947b60 R08: ffffffff8108d82b R09: ffffed1020e35c59
R10: 0000000000000000 R11: dffffc0000000001 R12: 1ffff92000128f50
R13: 000000000000000d R14: 0000000000000000 R15: dffffc0000000000
FS:  00005555574d3300(0000) GS:ffff8881f7100000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f973d5e9130 CR3: 000000011fa0a000 CR4: 00000000003526a0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	f2 01 66 43          	repnz add %esp,0x43(%rsi)
   4:	c7 44 3c 0d f3 f3 43 	movl   $0xc643f3f3,0xd(%rsp,%rdi,1)
   b:	c6
   c:	44 3c 0f             	rex.R cmp $0xf,%al
   f:	f3 e8 6c e4 58 00    	repz callq 0x58e481
  15:	bf 01 00 00 00       	mov    $0x1,%edi
  1a:	e8 a2 e1 35 00       	callq  0x35e1c1
  1f:	49 8d 5e 68          	lea    0x68(%r14),%rbx
  23:	49 89 dd             	mov    %rbx,%r13
  26:	49 c1 ed 03          	shr    $0x3,%r13
* 2a:	43 0f b6 44 3d 00    	movzbl 0x0(%r13,%r15,1),%eax <-- trapping instruction
  30:	84 c0                	test   %al,%al
  32:	0f 85 e8 05 00 00    	jne    0x620
  38:	48 89 5c 24 20       	mov    %rbx,0x20(%rsp)
  3d:	8b 1b                	mov    (%rbx),%ebx
  3f:	bf                   	.byte 0xbf

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/03/23 06:50 android13-5.15-lts 5448b2fda85f f94b4a29 .config strace log report syz C ci2-android-5-15 general protection fault in restart_apic_timer
* Struck through repros no longer work on HEAD.