syzbot


general protection fault in hpage_collapse_scan_file

Status: upstream: reported C repro on 2024/04/09 10:16
Subsystems: mm
[Documentation on labels]
Reported-by: syzbot+57adb2a4b9d206521bc2@syzkaller.appspotmail.com
First crash: 24d, last: 21d
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [mm?] general protection fault in hpage_collapse_scan_file 4 (5) 2024/04/17 18:56
Last patch testing requests (1)
Created Duration User Patch Repo Result
2024/04/23 22:23 23m retest repro linux-next error OK

Sample crash report:
Oops: general protection fault, probably for non-canonical address 0xdffffc0000000000: 0000 [#1] PREEMPT SMP KASAN PTI
KASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007]
CPU: 1 PID: 5080 Comm: syz-executor931 Not tainted 6.9.0-rc2-next-20240405-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024
RIP: 0010:PageTail include/linux/page-flags.h:284 [inline]
RIP: 0010:const_folio_flags include/linux/page-flags.h:312 [inline]
RIP: 0010:folio_test_locked include/linux/page-flags.h:512 [inline]
RIP: 0010:collapse_file mm/khugepaged.c:1907 [inline]
RIP: 0010:hpage_collapse_scan_file+0x1ea3/0x63e0 mm/khugepaged.c:2292
Code: 48 8d bc 24 30 02 00 00 e8 9a a1 f9 ff 4c 8b bc 24 30 02 00 00 49 8d 5f 08 48 89 d8 48 c1 e8 03 48 b9 00 00 00 00 00 fc ff df <80> 3c 08 00 74 08 48 89 df e8 6f a1 f9 ff 48 8b 1b 48 89 de 48 83
RSP: 0018:ffffc9000340f420 EFLAGS: 00010247
RAX: 0000000000000000 RBX: 0000000000000006 RCX: dffffc0000000000
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc9000340f7d0 R08: ffffffff81cb9212 R09: 1ffffffff1f5802d
R10: dffffc0000000000 R11: fffffbfff1f5802e R12: ffffc9000340f6b0
R13: 0000000000000000 R14: ffffc9000340f5f0 R15: fffffffffffffffe
FS:  000055558dc18380(0000) GS:ffff8880b9500000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020000240 CR3: 000000006ee40000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 madvise_collapse+0x561/0xcc0 mm/khugepaged.c:2736
 madvise_vma_behavior mm/madvise.c:1081 [inline]
 madvise_walk_vmas mm/madvise.c:1255 [inline]
 do_madvise+0xc3c/0x44a0 mm/madvise.c:1441
 __do_sys_madvise mm/madvise.c:1456 [inline]
 __se_sys_madvise mm/madvise.c:1454 [inline]
 __x64_sys_madvise+0xa6/0xc0 mm/madvise.c:1454
 do_syscall_64+0xfb/0x240
 entry_SYSCALL_64_after_hwframe+0x72/0x7a
RIP: 0033:0x7f4cdb4292e9
Code: 48 83 c4 28 c3 e8 37 17 00 00 0f 1f 80 00 00 00 00 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:00007fff99038cd8 EFLAGS: 00000246 ORIG_RAX: 000000000000001c
RAX: ffffffffffffffda RBX: 00007fff99038eb8 RCX: 00007f4cdb4292e9
RDX: 0000000000000019 RSI: 0000000000600722 RDI: 0000000020000000
RBP: 00007f4cdb49c610 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000003 R11: 0000000000000246 R12: 0000000000000001
R13: 00007fff99038ea8 R14: 0000000000000001 R15: 0000000000000001
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:PageTail include/linux/page-flags.h:284 [inline]
RIP: 0010:const_folio_flags include/linux/page-flags.h:312 [inline]
RIP: 0010:folio_test_locked include/linux/page-flags.h:512 [inline]
RIP: 0010:collapse_file mm/khugepaged.c:1907 [inline]
RIP: 0010:hpage_collapse_scan_file+0x1ea3/0x63e0 mm/khugepaged.c:2292
Code: 48 8d bc 24 30 02 00 00 e8 9a a1 f9 ff 4c 8b bc 24 30 02 00 00 49 8d 5f 08 48 89 d8 48 c1 e8 03 48 b9 00 00 00 00 00 fc ff df <80> 3c 08 00 74 08 48 89 df e8 6f a1 f9 ff 48 8b 1b 48 89 de 48 83
RSP: 0018:ffffc9000340f420 EFLAGS: 00010247
RAX: 0000000000000000 RBX: 0000000000000006 RCX: dffffc0000000000
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc9000340f7d0 R08: ffffffff81cb9212 R09: 1ffffffff1f5802d
R10: dffffc0000000000 R11: fffffbfff1f5802e R12: ffffc9000340f6b0
R13: 0000000000000000 R14: ffffc9000340f5f0 R15: fffffffffffffffe
FS:  000055558dc18380(0000) GS:ffff8880b9500000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020000240 CR3: 000000006ee40000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	48 8d bc 24 30 02 00 	lea    0x230(%rsp),%rdi
   7:	00
   8:	e8 9a a1 f9 ff       	call   0xfff9a1a7
   d:	4c 8b bc 24 30 02 00 	mov    0x230(%rsp),%r15
  14:	00
  15:	49 8d 5f 08          	lea    0x8(%r15),%rbx
  19:	48 89 d8             	mov    %rbx,%rax
  1c:	48 c1 e8 03          	shr    $0x3,%rax
  20:	48 b9 00 00 00 00 00 	movabs $0xdffffc0000000000,%rcx
  27:	fc ff df
* 2a:	80 3c 08 00          	cmpb   $0x0,(%rax,%rcx,1) <-- trapping instruction
  2e:	74 08                	je     0x38
  30:	48 89 df             	mov    %rbx,%rdi
  33:	e8 6f a1 f9 ff       	call   0xfff9a1a7
  38:	48 8b 1b             	mov    (%rbx),%rbx
  3b:	48 89 de             	mov    %rbx,%rsi
  3e:	48                   	rex.W
  3f:	83                   	.byte 0x83

Crashes (22):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/04/05 11:40 linux-next 8568bb2ccc27 0ee3535e .config strace log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/08 18:33 linux-next 11cb68ad52ac 53df08b6 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/08 14:16 linux-next 11cb68ad52ac ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/08 12:47 linux-next 11cb68ad52ac ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/08 12:12 linux-next 11cb68ad52ac ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/08 09:33 linux-next 11cb68ad52ac ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/08 00:42 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/07 22:23 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/07 15:13 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/07 14:13 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/07 13:19 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/07 03:33 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/07 01:04 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/07 00:11 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/06 23:08 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/06 21:19 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/06 18:58 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/06 10:42 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/06 06:04 linux-next 8568bb2ccc27 ca620dd8 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/05 10:19 linux-next 8568bb2ccc27 0ee3535e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/05 10:17 linux-next 8568bb2ccc27 0ee3535e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
2024/04/05 10:07 linux-next 8568bb2ccc27 0ee3535e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in hpage_collapse_scan_file
* Struck through repros no longer work on HEAD.