syzbot


general protection fault in __hugetlb_zap_begin

Status: auto-obsoleted due to no activity on 2024/02/11 18:26
Subsystems: mm
[Documentation on labels]
Reported-by: syzbot+ec9435c038e451be48ff@syzkaller.appspotmail.com
First crash: 394d, last: 355d
Cause bisection: introduced by (bisect log) :
commit bf4916922c60f43efaa329744b3eef539aa6a2b2
Author: Rik van Riel <riel@surriel.com>
Date: Fri Oct 6 03:59:07 2023 +0000

  hugetlbfs: extend hugetlb_vma_lock to private VMAs

Crash: BUG: unable to handle kernel NULL pointer dereference in __unmap_hugepage_range_final (log)
Repro: C syz .config
  
Fix bisection: fixed by (bisect log) :
commit 187da0f8250aa94bd96266096aef6f694e0b4cd2
Author: Mike Kravetz <mike.kravetz@oracle.com>
Date: Tue Nov 14 01:20:33 2023 +0000

  hugetlb: fix null-ptr-deref in hugetlb_vma_lock_write

  
Discussions (4)
Title Replies (including bot) Last reply
[syzbot] [mm?] general protection fault in __hugetlb_zap_begin 0 (2) 2024/01/09 18:17
[syzbot] Monthly mm report (Dec 2023) 0 (1) 2023/12/18 10:47
Re: [syzbot] [mm?] general protection fault in __hugetlb_zap_begin 1 (1) 2023/11/03 18:12
Re: [syzbot] [PATCH] Test for 2030579113a1 0 (1) 2023/11/03 11:36
Last patch testing requests (10)
Created Duration User Patch Repo Result
2023/12/17 19:47 40m retest repro upstream OK log
2023/12/17 19:47 22m retest repro upstream OK log
2023/12/17 19:47 22m retest repro upstream OK log
2023/12/17 19:47 33m retest repro upstream OK log
2023/11/03 11:36 14m eadavis@qq.com patch https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git 2dac75696c6d report log
2023/11/02 11:26 22m eadavis@qq.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 888cf78c29e2 OK log
2023/11/01 07:15 26m eadavis@qq.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 888cf78c29e2 OK log
2023/10/30 08:36 27m lizhi.xu@windriver.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 888cf78c29e2 report log
2023/10/30 07:46 16m lizhi.xu@windriver.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 888cf78c29e2 report log
2023/10/30 04:54 35m lizhi.xu@windriver.com patch https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 888cf78c29e2 report log

Sample crash report:
general protection fault, probably for non-canonical address 0xdffffc000000001d: 0000 [#1] PREEMPT SMP KASAN
KASAN: null-ptr-deref in range [0x00000000000000e8-0x00000000000000ef]
CPU: 0 PID: 5068 Comm: syz-executor344 Not tainted 6.7.0-rc2-syzkaller-00029-g9b6de136b5f0 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/10/2023
RIP: 0010:__lock_acquire+0x69/0x1fd0 kernel/locking/lockdep.c:5004
Code: df 0f b6 04 30 84 c0 0f 85 47 16 00 00 83 3d a9 c7 93 0d 00 0f 84 1c 11 00 00 83 3d 80 78 12 0c 00 74 2c 4c 89 e0 48 c1 e8 03 <80> 3c 30 00 74 12 4c 89 e7 e8 b9 2c 7d 00 48 be 00 00 00 00 00 fc
RSP: 0018:ffffc9000432f650 EFLAGS: 00010006
RAX: 000000000000001d RBX: 0000000000000000 RCX: 0000000000000000
RDX: 0000000000000000 RSI: dffffc0000000000 RDI: 00000000000000e8
RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000000
R10: dffffc0000000000 R11: fffffbfff1e01806 R12: 00000000000000e8
R13: 0000000000000000 R14: ffff888079fb8000 R15: 0000000000000000
FS:  0000000000000000(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7ae89d4790 CR3: 000000001c455000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 lock_acquire+0x1e3/0x530 kernel/locking/lockdep.c:5753
 down_write+0x3a/0x50 kernel/locking/rwsem.c:1579
 __hugetlb_zap_begin+0x2e0/0x380 mm/hugetlb.c:5708
 hugetlb_zap_begin include/linux/hugetlb.h:258 [inline]
 unmap_vmas+0x364/0x5c0 mm/memory.c:1742
 exit_mmap+0x297/0xc60 mm/mmap.c:3308
 __mmput+0x115/0x3c0 kernel/fork.c:1349
 exit_mm+0x21f/0x300 kernel/exit.c:567
 do_exit+0x9b7/0x2750 kernel/exit.c:858
 __do_sys_exit kernel/exit.c:988 [inline]
 __se_sys_exit kernel/exit.c:986 [inline]
 __x64_sys_exit+0x40/0x40 kernel/exit.c:986
 do_syscall_x64 arch/x86/entry/common.c:51 [inline]
 do_syscall_64+0x45/0x110 arch/x86/entry/common.c:82
 entry_SYSCALL_64_after_hwframe+0x63/0x6b
RIP: 0033:0x7f7ae899ae79
Code: Unable to access opcode bytes at 0x7f7ae899ae4f.
RSP: 002b:00007fff0b9c2e08 EFLAGS: 00000246 ORIG_RAX: 000000000000003c
RAX: ffffffffffffffda RBX: 00007f7ae899ae79 RCX: 00007f7ae899ae79
RDX: 00007f7ae89d47b3 RSI: 0000000000000000 RDI: 0000000000000000
RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000006
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 0000000000000000 R14: 0000000000000001 R15: 0000000000000001
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:__lock_acquire+0x69/0x1fd0 kernel/locking/lockdep.c:5004
Code: df 0f b6 04 30 84 c0 0f 85 47 16 00 00 83 3d a9 c7 93 0d 00 0f 84 1c 11 00 00 83 3d 80 78 12 0c 00 74 2c 4c 89 e0 48 c1 e8 03 <80> 3c 30 00 74 12 4c 89 e7 e8 b9 2c 7d 00 48 be 00 00 00 00 00 fc
RSP: 0018:ffffc9000432f650 EFLAGS: 00010006
RAX: 000000000000001d RBX: 0000000000000000 RCX: 0000000000000000
RDX: 0000000000000000 RSI: dffffc0000000000 RDI: 00000000000000e8
RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000000
R10: dffffc0000000000 R11: fffffbfff1e01806 R12: 00000000000000e8
R13: 0000000000000000 R14: ffff888079fb8000 R15: 0000000000000000
FS:  0000000000000000(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f7ae89d4790 CR3: 000000001c455000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	df 0f                	fisttps (%rdi)
   2:	b6 04                	mov    $0x4,%dh
   4:	30 84 c0 0f 85 47 16 	xor    %al,0x1647850f(%rax,%rax,8)
   b:	00 00                	add    %al,(%rax)
   d:	83 3d a9 c7 93 0d 00 	cmpl   $0x0,0xd93c7a9(%rip)        # 0xd93c7bd
  14:	0f 84 1c 11 00 00    	je     0x1136
  1a:	83 3d 80 78 12 0c 00 	cmpl   $0x0,0xc127880(%rip)        # 0xc1278a1
  21:	74 2c                	je     0x4f
  23:	4c 89 e0             	mov    %r12,%rax
  26:	48 c1 e8 03          	shr    $0x3,%rax
* 2a:	80 3c 30 00          	cmpb   $0x0,(%rax,%rsi,1) <-- trapping instruction
  2e:	74 12                	je     0x42
  30:	4c 89 e7             	mov    %r12,%rdi
  33:	e8 b9 2c 7d 00       	call   0x7d2cf1
  38:	48                   	rex.W
  39:	be 00 00 00 00       	mov    $0x0,%esi
  3e:	00 fc                	add    %bh,%ah

Crashes (21):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/11/23 18:21 upstream 9b6de136b5f0 fc59b78e .config console log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/11/04 01:51 upstream 8f6f76a6a29f 500bfdc4 .config console log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/28 04:54 upstream 888cf78c29e2 3c418d72 .config strace log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/27 07:08 upstream 3a568e3a961b bf285f0c .config strace log report syz C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/12/03 18:26 upstream 33cc938e65a9 f819d6f7 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/11/30 18:29 upstream 3b47bc037bd4 f819d6f7 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/11/23 23:57 upstream d3fa86b1a7b4 fc59b78e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/11/22 17:10 upstream c2d5304e6c64 03e12510 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/11/20 04:27 upstream 98b1cc82c4af cb976f63 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/11/10 12:02 upstream 89cdf9d55601 45e9b83e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/11/10 03:41 upstream 4bbdb725a36b 56230772 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/31 00:30 upstream 14ab6d425e80 b5729d82 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/30 18:51 upstream ffc253263a13 b5729d82 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/29 23:41 upstream 2af9b20dbb39 3c418d72 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/29 05:39 upstream 2af9b20dbb39 3c418d72 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/27 04:22 upstream 3a568e3a961b bf285f0c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/27 02:31 upstream 3a568e3a961b bf285f0c .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/26 22:16 upstream 3a568e3a961b 23afc60f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/26 21:59 upstream 3a568e3a961b 23afc60f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/26 21:13 upstream 3a568e3a961b 23afc60f .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
2023/10/25 17:03 upstream 4f82870119a4 72e794c4 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in __hugetlb_zap_begin
* Struck through repros no longer work on HEAD.