syzbot


BUG: unable to handle kernel paging request in ext4_calculate_overhead

Status: fixed on 2023/10/12 12:47
Subsystems: ext4
[Documentation on labels]
Reported-by: syzbot+b3123e6d9842e526de39@syzkaller.appspotmail.com
Fix commit: ee5c807137ce ext4: ext4_get_{dev}_journal return proper error value
First crash: 250d, last: 244d
Cause bisection: introduced by (bisect log) :
commit 99d6c5d892bfff3be40f83ec34d91d562125afd4
Author: Zhang Yi <yi.zhang@huawei.com>
Date: Fri Aug 11 06:36:10 2023 +0000

  ext4: ext4_get_{dev}_journal return proper error value

Crash: BUG: unable to handle kernel paging request in ext4_calculate_overhead (log)
Repro: C syz .config
  
Discussions (3)
Title Replies (including bot) Last reply
Re: [PATCH] ext4: fix ext4_calculate_overhead use invliad j_inode 1 (1) 2023/08/28 10:17
[PATCH] ext4: correct error handling of ext4_get_journal_inode() 2 (2) 2023/08/27 15:27
[syzbot] [ext4?] BUG: unable to handle kernel paging request in ext4_calculate_overhead 1 (2) 2023/08/25 12:22
Last patch testing requests (1)
Created Duration User Patch Repo Result
2023/08/26 03:40 21m eadavis@sina.com patch https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git 47d9bb711707 OK log

Sample crash report:
EXT4-fs (loop0): ext4_check_descriptors: Checksum for group 0 failed (394!=20869)
EXT4-fs error (device loop0): ext4_get_journal_inode:5719: comm syz-executor999: inode #33: comm syz-executor999: iget: illegal inode #
EXT4-fs (loop0): no journal found
BUG: unable to handle page fault for address: ffffffffffffffdb
#PF: supervisor read access in kernel mode
#PF: error_code(0x0000) - not-present page
PGD c979067 P4D c979067 PUD c97b067 PMD 0 
Oops: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 5041 Comm: syz-executor999 Not tainted 6.5.0-rc7-next-20230821-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:ext4_calculate_overhead+0xfd2/0x1380 fs/ext4/super.c:4182
Code: 7b 50 48 89 fa 48 c1 ea 03 44 0f b6 60 14 48 b8 00 00 00 00 00 fc ff df 80 3c 02 00 0f 85 72 03 00 00 44 89 e6 bf 3f 00 00 00 <48> 8b 6b 50 e8 95 20 43 ff 41 80 fc 3f 0f 87 cb 20 ef 07 e8 56 25
RSP: 0018:ffffc9000399fa00 EFLAGS: 00010246
RAX: dffffc0000000000 RBX: ffffffffffffff8b RCX: 0000000000000000
RDX: 1ffffffffffffffb RSI: 000000000000000a RDI: 000000000000003f
RBP: 0000000000000001 R08: 0000000000000005 R09: 0000000000000000
R10: 0000000080000000 R11: 0000000000000001 R12: 000000000000000a
R13: ffff888020936000 R14: dffffc0000000000 R15: ffff8880242a4000
FS:  0000555555f06380(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffdb CR3: 0000000074f9b000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 __ext4_fill_super fs/ext4/super.c:5391 [inline]
 ext4_fill_super+0x85e3/0xade0 fs/ext4/super.c:5643
 get_tree_bdev+0x390/0x630 fs/super.c:1351
 vfs_get_tree+0x88/0x350 fs/super.c:1524
 do_new_mount fs/namespace.c:3335 [inline]
 path_mount+0x1492/0x1ed0 fs/namespace.c:3662
 do_mount fs/namespace.c:3675 [inline]
 __do_sys_mount fs/namespace.c:3884 [inline]
 __se_sys_mount fs/namespace.c:3861 [inline]
 __x64_sys_mount+0x293/0x310 fs/namespace.c:3861
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f73494babba
Code: d8 64 89 02 48 c7 c0 ff ff ff ff eb a6 e8 5e 04 00 00 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 49 89 ca b8 a5 00 00 00 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:00007fffae0148e8 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007fffae0148f0 RCX: 00007f73494babba
RDX: 00000000200000c0 RSI: 0000000020000040 RDI: 00007fffae0148f0
RBP: 0000000000000004 R08: 00007fffae014930 R09: 00007fffae014930
R10: 0000000001000403 R11: 0000000000000202 R12: 00007fffae014930
R13: 0000000000000003 R14: 0000000000080000 R15: 0000000000000001
 </TASK>
Modules linked in:
CR2: ffffffffffffffdb
---[ end trace 0000000000000000 ]---
RIP: 0010:ext4_calculate_overhead+0xfd2/0x1380 fs/ext4/super.c:4182
Code: 7b 50 48 89 fa 48 c1 ea 03 44 0f b6 60 14 48 b8 00 00 00 00 00 fc ff df 80 3c 02 00 0f 85 72 03 00 00 44 89 e6 bf 3f 00 00 00 <48> 8b 6b 50 e8 95 20 43 ff 41 80 fc 3f 0f 87 cb 20 ef 07 e8 56 25
RSP: 0018:ffffc9000399fa00 EFLAGS: 00010246
RAX: dffffc0000000000 RBX: ffffffffffffff8b RCX: 0000000000000000
RDX: 1ffffffffffffffb RSI: 000000000000000a RDI: 000000000000003f
RBP: 0000000000000001 R08: 0000000000000005 R09: 0000000000000000
R10: 0000000080000000 R11: 0000000000000001 R12: 000000000000000a
R13: ffff888020936000 R14: dffffc0000000000 R15: ffff8880242a4000
FS:  0000555555f06380(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffffffffffdb CR3: 0000000074f9b000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	7b 50                	jnp    0x52
   2:	48 89 fa             	mov    %rdi,%rdx
   5:	48 c1 ea 03          	shr    $0x3,%rdx
   9:	44 0f b6 60 14       	movzbl 0x14(%rax),%r12d
   e:	48 b8 00 00 00 00 00 	movabs $0xdffffc0000000000,%rax
  15:	fc ff df
  18:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1)
  1c:	0f 85 72 03 00 00    	jne    0x394
  22:	44 89 e6             	mov    %r12d,%esi
  25:	bf 3f 00 00 00       	mov    $0x3f,%edi
* 2a:	48 8b 6b 50          	mov    0x50(%rbx),%rbp <-- trapping instruction
  2e:	e8 95 20 43 ff       	call   0xff4320c8
  33:	41 80 fc 3f          	cmp    $0x3f,%r12b
  37:	0f 87 cb 20 ef 07    	ja     0x7ef2108
  3d:	e8                   	.byte 0xe8
  3e:	56                   	push   %rsi
  3f:	25                   	.byte 0x25

Crashes (31):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/08/21 15:41 linux-next 47d9bb711707 d216d8a0 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/27 03:43 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/27 02:16 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/27 00:10 linux-next 626932085009 03d9c195 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/25 05:20 linux-next 2b3bd393093b 49be837e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/25 02:44 linux-next 2b3bd393093b 49be837e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 15:21 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 15:20 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 15:20 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 14:41 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 14:40 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 12:13 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 11:23 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 11:22 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 11:14 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 11:14 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 11:12 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 11:11 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 11:08 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 10:44 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 10:44 linux-next 2b3bd393093b 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 03:11 linux-next e3f80d3eae76 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/24 01:11 linux-next e3f80d3eae76 4d7ae7ab .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/22 17:05 linux-next 28c736b0e92e b81ca3f6 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/21 17:22 linux-next 47d9bb711707 6b415825 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/21 14:39 linux-next 47d9bb711707 d216d8a0 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/21 12:09 linux-next 47d9bb711707 d216d8a0 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/21 11:27 linux-next 47d9bb711707 d216d8a0 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/21 11:12 linux-next 47d9bb711707 d216d8a0 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/21 10:34 linux-next 47d9bb711707 d216d8a0 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
2023/08/21 09:37 linux-next 47d9bb711707 d216d8a0 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root BUG: unable to handle kernel paging request in ext4_calculate_overhead
* Struck through repros no longer work on HEAD.