syzbot


BUG: unable to handle kernel NULL pointer dereference in gfs2_rgrp_dump

Status: fixed on 2024/01/30 15:47
Subsystems: gfs2
[Documentation on labels]
Reported-by: syzbot+da0fc229cc1ff4bb2e6d@syzkaller.appspotmail.com
Fix commit: 8877243beafa gfs2: Fix kernel NULL pointer dereference in gfs2_rgrp_dump
First crash: 452d, last: 105d
Cause bisection: introduced by (bisect log) :
commit 72244b6bc752b5c496f09de9a13c18adc314a53c
Author: Bob Peterson <rpeterso@redhat.com>
Date: Wed Aug 15 17:09:49 2018 +0000

  gfs2: improve debug information when lvb mismatches are found

Crash: BUG: unable to handle kernel NULL pointer dereference in gfs2_rgrp_dump (log)
Repro: C syz .config
  
Discussions (7)
Title Replies (including bot) Last reply
[syzbot] Monthly gfs2 report (Dec 2023) 0 (1) 2023/12/07 09:56
[syzbot] Monthly gfs2 report (Nov 2023) 0 (1) 2023/11/06 23:07
[PATCH] fs:gfs2:rgrp.c: Fix kernel NULL pointer dereference 1 (1) 2023/11/06 16:21
[syzbot] [gfs2?] BUG: unable to handle kernel NULL pointer dereference in gfs2_rgrp_dump 0 (3) 2023/11/05 14:34
[syzbot] Monthly gfs2 report (Oct 2023) 0 (1) 2023/10/05 13:58
[syzbot] Monthly gfs2 report (Sep 2023) 0 (1) 2023/09/04 08:33
[syzbot] Monthly gfs2 report (Aug 2023) 0 (1) 2023/08/02 11:18
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream general protection fault in gfs2_rgrp_dump gfs2 1 1259d 1259d 15/26 fixed on 2020/11/16 12:12
Last patch testing requests (8)
Created Duration User Patch Repo Result
2023/12/05 03:27 24m retest repro upstream report log
2023/11/19 17:42 14m retest repro upstream report log
2023/11/05 16:15 17m retest repro git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci report log
2023/11/05 14:34 40m osmtendev@gmail.com patch git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci OK log
2023/10/10 05:43 55m retest repro upstream report log
2023/09/26 03:09 13m retest repro upstream report log
2023/08/22 03:57 24m retest repro git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci report log
2023/08/22 03:57 35m retest repro upstream report log
Fix bisection attempts (6)
Created Duration User Patch Repo Result
2023/07/20 09:48 1h20m bisect fix upstream job log (0) log
2023/06/02 18:31 50m bisect fix upstream job log (0) log
2023/05/03 16:45 1h18m bisect fix upstream job log (0) log
2023/04/02 18:45 46m bisect fix upstream job log (0) log
2023/03/03 17:39 43m bisect fix upstream job log (0) log
2023/02/01 11:43 42m bisect fix upstream job log (0) log
Cause bisection attempts (2)
Created Duration User Patch Repo Result
2023/08/28 18:17 6h27m bisect upstream job log (1) log
2022/12/23 23:03 8h16m bisect upstream error job log (0)
marked invalid by nogikh@google.com

Sample crash report:
ri_length = 1
ri_data0 = 19
ri_data = 2060
ri_bitbytes = 514
start=0 len=514 offset=128
gfs2: fsid=syz:syz.s:  R: n:18 f:00 b:0/0 i:0 q:0 r:0 e:0
Unable to handle kernel NULL pointer dereference at virtual address 0000000000000004
Mem abort info:
  ESR = 0x0000000096000006
  EC = 0x25: DABT (current EL), IL = 32 bits
  SET = 0, FnV = 0
  EA = 0, S1PTW = 0
  FSC = 0x06: level 2 translation fault
Data abort info:
  ISV = 0, ISS = 0x00000006
  CM = 0, WnR = 0
user pgtable: 4k pages, 48-bit VAs, pgdp=000000010e23f000
[0000000000000004] pgd=080000010b804003, p4d=080000010b804003, pud=080000010a4e8003, pmd=0000000000000000
Internal error: Oops: 0000000096000006 [#1] PREEMPT SMP
Modules linked in:
CPU: 0 PID: 3072 Comm: syz-executor147 Not tainted 6.1.0-rc8-syzkaller-33330-ga5541c0811a0 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022
pstate: 80400005 (Nzcv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : gfs2_rgrp_dump+0xa0/0x138 fs/gfs2/rgrp.c:2313
lr : gfs2_rgrp_dump+0x90/0x138
sp : ffff80000fb93780
x29: ffff80000fb937a0 x28: ffff0000cb82a000 x27: ffff0000cb82a000
x26: ffff0000ca4de000 x25: 0000000000000808 x24: 000000000000080c
x23: 000000000001c103 x22: ffff0000ca4de000 x21: 0000000000000000
x20: ffff80000fb937e0 x19: ffff0000ca4de080 x18: 00000000000000c0
x17: ffff80000dda8198 x16: ffff80000dbe6158 x15: ffff0000c6800000
x14: 0000000000000000 x13: 00000000ffffffff x12: ffff0000c6800000
x11: ff808000092a5154 x10: 0000000000000000 x9 : ffff8000092a5154
x8 : 0000000000000000 x7 : ffff80000c091ebc x6 : 0000000000000000
x5 : 0000000000000080 x4 : 0000000000000001 x3 : 0000000000000000
x2 : ffff0001fefbecd0 x1 : ffff80000cc9c685 x0 : 0000000000000000
Call trace:
 gfs2_rgrp_dump+0xa0/0x138 fs/gfs2/rgrp.c:2312
 gfs2_consist_rgrpd_i+0x78/0xe4 fs/gfs2/util.c:480
 read_rindex_entry fs/gfs2/rgrp.c:931 [inline]
 gfs2_ri_update+0x398/0x7e4 fs/gfs2/rgrp.c:1001
 gfs2_rindex_update+0x1b0/0x21c fs/gfs2/rgrp.c:1051
 init_inodes+0x11c/0x184 fs/gfs2/ops_fstype.c:917
 gfs2_fill_super+0x630/0x874 fs/gfs2/ops_fstype.c:1247
 get_tree_bdev+0x1e8/0x2a0 fs/super.c:1324
 gfs2_get_tree+0x30/0xc0 fs/gfs2/ops_fstype.c:1330
 vfs_get_tree+0x40/0x140 fs/super.c:1531
 do_new_mount+0x1dc/0x4e4 fs/namespace.c:3040
 path_mount+0x358/0x890 fs/namespace.c:3370
 do_mount fs/namespace.c:3383 [inline]
 __do_sys_mount fs/namespace.c:3591 [inline]
 __se_sys_mount fs/namespace.c:3568 [inline]
 __arm64_sys_mount+0x2c4/0x3c4 fs/namespace.c:3568
 __invoke_syscall arch/arm64/kernel/syscall.c:38 [inline]
 invoke_syscall arch/arm64/kernel/syscall.c:52 [inline]
 el0_svc_common+0x138/0x220 arch/arm64/kernel/syscall.c:142
 do_el0_svc+0x48/0x140 arch/arm64/kernel/syscall.c:197
 el0_svc+0x58/0x150 arch/arm64/kernel/entry-common.c:637
 el0t_64_sync_handler+0x84/0xf0 arch/arm64/kernel/entry-common.c:655
 el0t_64_sync+0x190/0x194 arch/arm64/kernel/entry.S:584
Code: f94036c8 f001cfa1 911a1421 aa1503e0 (2940a909) 
---[ end trace 0000000000000000 ]---
----------------
Code disassembly (best guess):
   0:	f94036c8 	ldr	x8, [x22, #104]
   4:	f001cfa1 	adrp	x1, 0x39f7000
   8:	911a1421 	add	x1, x1, #0x685
   c:	aa1503e0 	mov	x0, x21
* 10:	2940a909 	ldp	w9, w10, [x8, #4] <-- trapping instruction

Crashes (9):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/12/22 20:28 git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git for-kernelci a5541c0811a0 c692fab1 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-gce-arm64 BUG: unable to handle kernel NULL pointer dereference in gfs2_rgrp_dump
2023/08/04 17:51 upstream c1a515d3c027 74621247 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-kasan-gce-selinux-root general protection fault in gfs2_rgrp_dump
2023/06/14 19:14 upstream b6dad5178cea d2ee9228 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-kasan-gce-smack-root general protection fault in gfs2_rgrp_dump
2022/12/22 21:37 upstream 0a924817d2ed 9da18ae8 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs general protection fault in gfs2_rgrp_dump
2023/10/22 16:13 upstream 1acfd2bd3f0d 361b23dc .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-fs general protection fault in gfs2_rgrp_dump
2023/09/02 20:20 upstream 0468be89b3fa 696ea0d2 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root general protection fault in gfs2_rgrp_dump
2023/09/12 02:14 linux-next 7bc675554773 59da8366 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in gfs2_rgrp_dump
2023/09/02 15:55 linux-next a47fc304d2b6 696ea0d2 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in gfs2_rgrp_dump
2023/09/02 15:31 linux-next a47fc304d2b6 696ea0d2 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in gfs2_rgrp_dump
* Struck through repros no longer work on HEAD.