syzbot


general protection fault in ksm_do_scan

Status: upstream: reported on 2024/08/27 09:55
Subsystems: mm
[Documentation on labels]
Reported-by: syzbot+ab2cf748d72119c9c291@syzkaller.appspotmail.com
First crash: 75d, last: 17d
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [mm?] general protection fault in ksm_do_scan 0 (1) 2024/08/27 09:55

Sample crash report:
Oops: general protection fault, probably for non-canonical address 0xdffffc0000000084: 0000 [#1] PREEMPT SMP KASAN NOPTI
KASAN: null-ptr-deref in range [0x0000000000000420-0x0000000000000427]
CPU: 1 UID: 0 PID: 36 Comm: ksmd Not tainted 6.11.0-rc5-syzkaller-00057-g86987d84b968 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 08/06/2024
RIP: 0010:scan_get_next_rmap_item mm/ksm.c:2557 [inline]
RIP: 0010:ksm_do_scan+0x792/0x6700 mm/ksm.c:2669
Code: 89 e7 48 c7 c6 ff ff ff ff e8 8a 72 b2 09 49 89 c6 48 85 c0 4c 89 7c 24 58 0f 84 c9 0a 00 00 49 8d 5e 20 48 89 d8 48 c1 e8 03 <42> 80 3c 28 00 74 08 48 89 df e8 ff 60 01 00 48 8b 1b be 00 00 00
RSP: 0018:ffffc90000ac7b60 EFLAGS: 00010217
RAX: 0000000000000084 RBX: 0000000000000426 RCX: ffff88801bef0000
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: ffffc90000ac7d90 R08: ffffffff8babb624 R09: ffffffff8babb4a9
R10: 0000000000000004 R11: ffff88801bef0000 R12: ffffc90000ac7ce0
R13: dffffc0000000000 R14: 0000000000000406 R15: ffff888011cec344
FS:  0000000000000000(0000) GS:ffff8880b9300000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 000000002e0b4000 CR4: 0000000000350ef0
Call Trace:
 <TASK>
 ksm_scan_thread+0x110/0x490 mm/ksm.c:2694
 kthread+0x2f2/0x390 kernel/kthread.c:389
 ret_from_fork+0x4d/0x80 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:scan_get_next_rmap_item mm/ksm.c:2557 [inline]
RIP: 0010:ksm_do_scan+0x792/0x6700 mm/ksm.c:2669
Code: 89 e7 48 c7 c6 ff ff ff ff e8 8a 72 b2 09 49 89 c6 48 85 c0 4c 89 7c 24 58 0f 84 c9 0a 00 00 49 8d 5e 20 48 89 d8 48 c1 e8 03 <42> 80 3c 28 00 74 08 48 89 df e8 ff 60 01 00 48 8b 1b be 00 00 00
RSP: 0018:ffffc90000ac7b60 EFLAGS: 00010217
RAX: 0000000000000084 RBX: 0000000000000426 RCX: ffff88801bef0000
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: ffffc90000ac7d90 R08: ffffffff8babb624 R09: ffffffff8babb4a9
R10: 0000000000000004 R11: ffff88801bef0000 R12: ffffc90000ac7ce0
R13: dffffc0000000000 R14: 0000000000000406 R15: ffff888011cec344
FS:  0000000000000000(0000) GS:ffff8880b9300000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fea96ae7ab8 CR3: 000000002983e000 CR4: 0000000000350ef0
----------------
Code disassembly (best guess):
   0:	89 e7                	mov    %esp,%edi
   2:	48 c7 c6 ff ff ff ff 	mov    $0xffffffffffffffff,%rsi
   9:	e8 8a 72 b2 09       	call   0x9b27298
   e:	49 89 c6             	mov    %rax,%r14
  11:	48 85 c0             	test   %rax,%rax
  14:	4c 89 7c 24 58       	mov    %r15,0x58(%rsp)
  19:	0f 84 c9 0a 00 00    	je     0xae8
  1f:	49 8d 5e 20          	lea    0x20(%r14),%rbx
  23:	48 89 d8             	mov    %rbx,%rax
  26:	48 c1 e8 03          	shr    $0x3,%rax
* 2a:	42 80 3c 28 00       	cmpb   $0x0,(%rax,%r13,1) <-- trapping instruction
  2f:	74 08                	je     0x39
  31:	48 89 df             	mov    %rbx,%rdi
  34:	e8 ff 60 01 00       	call   0x16138
  39:	48 8b 1b             	mov    (%rbx),%rbx
  3c:	be                   	.byte 0xbe
  3d:	00 00                	add    %al,(%rax)

Crashes (6):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/08/28 17:14 upstream 86987d84b968 940f38c1 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root general protection fault in ksm_do_scan
2024/08/27 09:54 upstream 3e9bff3bbe13 9aee4e0b .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root general protection fault in ksm_do_scan
2024/08/09 16:38 upstream ee9a43b7cfe2 a9e7e9e3 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in ksm_do_scan
2024/08/09 10:23 upstream cf6d429eb656 61405512 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in ksm_do_scan
2024/07/07 09:54 upstream 22f902dfc51e bc4ebbb5 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root general protection fault in ksm_do_scan
2024/07/01 06:11 upstream 3ffea9a7a6f7 757f06b1 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce general protection fault in ksm_do_scan
* Struck through repros no longer work on HEAD.