syzbot


kernel BUG in ext4_free_blocks (2)

Status: fixed on 2023/05/04 14:51
Subsystems: ext4
[Documentation on labels]
Reported-by: syzbot+15cd994e273307bf5cfa@syzkaller.appspotmail.com
Fix commit: beda74302101 UPSTREAM: ext4: block range must be validated before use in ext4_mb_clear_bb() 7550aade9783 ext4: block range must be validated before use in ext4_mb_clear_bb()
First crash: 871d, last: 569d
Cause bisection: failed (error log, bisect log)
  
Discussions (8)
Title Replies (including bot) Last reply
[PATCH][for stable 5.{15, 10} 0/4] ext4: Fix kernel BUG in ext4_free_blocks 6 (6) 2023/03/15 08:17
[PATCH 0/2] feat: checkpatch: prohibit Buglink: and warn about missing Link: 37 (37) 2023/03/07 11:36
Re: [Android 5.10] kernel BUG in ext4_free_blocks (2) 1 (1) 2023/03/01 13:51
Re: kernel BUG in ext4_free_blocks (2) 10 (10) 2022/12/21 11:34
[PATCH 5.19 000/365] 5.19.4-rc1 review 384 (384) 2022/08/29 09:33
[PATCH AUTOSEL 5.19 01/64] thunderbolt: Change downstream router's TMU rate in both TMU uni/bidir mode 66 (66) 2022/08/20 14:37
[PATCH AUTOSEL 5.18 01/56] thunderbolt: Change downstream router's TMU rate in both TMU uni/bidir mode 56 (56) 2022/08/14 15:30
[PATCH] ext4: fix kernel BUG in ext4_free_blocks 7 (7) 2022/07/22 13:58
Similar bugs (11)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
android-5-10 kernel BUG in ext4_free_blocks 3 1074d 1106d 0/2 auto-closed as invalid on 2022/03/13 09:34
android-5-15 kernel BUG in ext4_free_blocks ext4 1 669d 669d 0/2 auto-obsoleted due to no activity on 2023/04/30 03:35
linux-4.14 kernel BUG in ext4_mb_load_buddy_gfp ext4 C 6 628d 1302d 0/1 upstream: reported C repro on 2021/04/29 16:39
linux-4.19 kernel BUG at fs/ext4/ext4.h:LINE! ext4 C error 13 648d 1467d 0/1 upstream: reported C repro on 2020/11/15 12:08
android-54 kernel BUG at fs/ext4/ext4.h:LINE! ext4 C 438 12d 1505d 0/2 upstream: reported C repro on 2020/10/08 13:59
upstream kernel BUG at fs/ext4/ext4.h:LINE! ext4 1 1420d 1416d 0/28 auto-closed as invalid on 2021/05/01 06:31
upstream kernel BUG in ext4_get_group_info ext4 C error 237 557d 1190d 22/28 fixed on 2023/07/01 16:05
android-5-15 kernel BUG in ext4_mb_load_buddy_gfp (2) origin:upstream missing-backport C error done 24 518d 565d 0/2 upstream: reported C repro on 2023/05/06 10:12
android-6-1 kernel BUG in ext4_mb_load_buddy_gfp C error done 42 398d 554d 0/2 auto-obsoleted due to no activity on 2023/12/29 16:31
android-5-15 kernel BUG in ext4_mb_load_buddy_gfp ext4 C error 9 608d 725d 2/2 fixed on 2023/03/28 12:29
android-5-10 kernel BUG in ext4_mb_load_buddy_gfp C error error 28 81d 566d 0/2 upstream: reported C repro on 2023/05/04 23:52
Last patch testing requests (3)
Created Duration User Patch Repo Result
2022/07/14 17:20 15m tadeusz.struk@linaro.org patch git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master OK log
2022/07/13 17:28 15m tadeusz.struk@linaro.org patch git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master OK log
2022/07/12 19:56 7m tadeusz.struk@linaro.org git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master report log

Sample crash report:
EXT4-fs (loop0): ext4_check_descriptors: Checksum for group 0 failed (14603!=0)
EXT4-fs (loop0): orphan cleanup on readonly fs
EXT4-fs error (device loop0): ext4_free_blocks:5434: comm syz-executor392: Freeing blocks in system zone - Block = 16, count = 16
EXT4-fs (loop0): Remounting filesystem read-only
------------[ cut here ]------------
kernel BUG at fs/ext4/ext4.h:3254!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 371 Comm: syz-executor392 Not tainted 5.10.118-syzkaller-00163-gfa7f6a5f56d9 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/29/2022
RIP: 0010:ext4_get_group_info fs/ext4/ext4.h:3254 [inline]
RIP: 0010:ext4_free_blocks+0x29ed/0x2ad0 fs/ext4/mballoc.c:5400
Code: f6 48 0f a3 05 f4 8e bf 04 0f 92 c3 40 0f 92 c6 31 ff e8 c6 62 8d ff 84 db 75 18 e8 ad 5f 8d ff e9 b8 00 00 00 e8 a3 5f 8d ff <0f> 0b e8 9c 5f 8d ff 0f 0b 65 ff 05 2f 1a 23 7e 48 c7 c0 68 bd 9c
RSP: 0018:ffffc900002aef80 EFLAGS: 00010293
RAX: ffffffff81df534d RBX: 0000000000000001 RCX: ffff888106992780
RDX: 0000000000000000 RSI: 00000000ffffffff RDI: 0000000000000001
RBP: ffffc900002af200 R08: ffffffff81df350e R09: ffffc900002af140
R10: fffff52000055e2f R11: 1ffff92000055e28 R12: 0000000000000000
R13: dffffc0000000000 R14: 00000000ffffffff R15: ffff8881065e1000
FS:  00005555557bf300(0000) GS:ffff8881f7100000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ffe40c84cd8 CR3: 000000011e1bf000 CR4: 00000000003506a0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 ext4_clear_blocks+0x3b5/0x420 fs/ext4/indirect.c:877
 ext4_free_data fs/ext4/indirect.c:950 [inline]
 ext4_ind_truncate+0x83f/0x1040 fs/ext4/indirect.c:1141
 ext4_truncate+0xae6/0x1270 fs/ext4/inode.c:4347
 ext4_evict_inode+0xecf/0x16d0 fs/ext4/inode.c:288
 evict+0x2a3/0x6c0 fs/inode.c:578
 iput_final fs/inode.c:1656 [inline]
 iput+0x61f/0x7d0 fs/inode.c:1682
 ext4_quota_enable fs/ext4/super.c:6406 [inline]
 ext4_enable_quotas+0x5a5/0x960 fs/ext4/super.c:6429
 ext4_orphan_cleanup+0x2ee/0xdb0 fs/ext4/super.c:3058
 ext4_fill_super+0x896c/0x9240 fs/ext4/super.c:5089
 mount_bdev+0x25f/0x370 fs/super.c:1419
 ext4_mount+0x34/0x40 fs/ext4/super.c:6607
 legacy_get_tree+0xf0/0x190 fs/fs_context.c:592
 vfs_get_tree+0x88/0x290 fs/super.c:1549
 do_new_mount+0x289/0xad0 fs/namespace.c:2899
 path_mount+0x58d/0xce0 fs/namespace.c:3229
 do_mount fs/namespace.c:3242 [inline]
 __do_sys_mount fs/namespace.c:3450 [inline]
 __se_sys_mount+0x2d2/0x3c0 fs/namespace.c:3427
 __x64_sys_mount+0xbf/0xd0 fs/namespace.c:3427
 do_syscall_64+0x34/0x70 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9
RIP: 0033:0x7fc08f7344da
Code: 83 c4 08 5b 5d c3 66 2e 0f 1f 84 00 00 00 00 00 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 c0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffc5770e458 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007ffc5770e4b0 RCX: 00007fc08f7344da
RDX: 0000000020000000 RSI: 0000000020000040 RDI: 00007ffc5770e470
RBP: 00007ffc5770e470 R08: 00007ffc5770e4b0 R09: 0000000800000015
R10: 0000000000000081 R11: 0000000000000202 R12: 0000000000000004
R13: 0000000000000003 R14: 0000000000000003 R15: 0000000000000010
Modules linked in:
---[ end trace 8d6b13b82edeee5a ]---
RIP: 0010:ext4_get_group_info fs/ext4/ext4.h:3254 [inline]
RIP: 0010:ext4_free_blocks+0x29ed/0x2ad0 fs/ext4/mballoc.c:5400
Code: f6 48 0f a3 05 f4 8e bf 04 0f 92 c3 40 0f 92 c6 31 ff e8 c6 62 8d ff 84 db 75 18 e8 ad 5f 8d ff e9 b8 00 00 00 e8 a3 5f 8d ff <0f> 0b e8 9c 5f 8d ff 0f 0b 65 ff 05 2f 1a 23 7e 48 c7 c0 68 bd 9c
RSP: 0018:ffffc900002aef80 EFLAGS: 00010293
RAX: ffffffff81df534d RBX: 0000000000000001 RCX: ffff888106992780
RDX: 0000000000000000 RSI: 00000000ffffffff RDI: 0000000000000001
RBP: ffffc900002af200 R08: ffffffff81df350e R09: ffffc900002af140
R10: fffff52000055e2f R11: 1ffff92000055e28 R12: 0000000000000000
R13: dffffc0000000000 R14: 00000000ffffffff R15: ffff8881065e1000
FS:  00005555557bf300(0000) GS:ffff8881f7100000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ffe40c84cd8 CR3: 000000011e1bf000 CR4: 00000000003506a0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400

Crashes (25):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/07/04 02:03 android12-5.10-lts fa7f6a5f56d9 1434eec0 .config strace log report syz C ci2-android-5-10 kernel BUG in ext4_free_blocks
2023/03/30 10:08 android12-5.10-lts 416c4356f372 f325deb0 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/02/22 11:04 android12-5.10-lts 416c4356f372 42a4d508 .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/02/02 09:54 android12-5.10-lts 416c4356f372 9a6f477c .config console log report syz C [mounted in repro] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2022/11/27 06:37 android12-5.10-lts 673a7341bdab f4470a7b .config strace log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2022/10/02 16:49 android12-5.10-lts 391716695e71 feb56351 .config strace log report syz C [disk image] [vmlinux] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/01/19 17:35 android12-5.10-lts 416c4356f372 66fca3ae .config console log report info ci2-android-5-10 kernel BUG in ext4_free_blocks
2022/07/04 01:42 android12-5.10-lts fa7f6a5f56d9 1434eec0 .config console log report info ci2-android-5-10 kernel BUG in ext4_free_blocks
2023/05/02 00:14 android12-5.10-lts 416c4356f372 62df2017 .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/05/01 23:55 android12-5.10-lts 416c4356f372 62df2017 .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/04/20 01:38 android12-5.10-lts 416c4356f372 a219f34e .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/04/17 07:30 android12-5.10-lts 416c4356f372 ec410564 .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/04/16 21:45 android12-5.10-lts 416c4356f372 ec410564 .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/04/09 18:00 android12-5.10-lts 416c4356f372 71147e29 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/03/27 14:28 android12-5.10-lts 416c4356f372 f8f96aa9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/03/24 03:11 android12-5.10-lts 416c4356f372 f94b4a29 .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/03/18 21:06 android12-5.10-lts 416c4356f372 7939252e .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/03/09 16:28 android12-5.10-lts 416c4356f372 f08b59ac .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/02/16 03:54 android12-5.10-lts 416c4356f372 6be0f1f5 .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/02/15 09:29 android12-5.10-lts 416c4356f372 e62ba3c1 .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/02/06 04:45 android12-5.10-lts 416c4356f372 be607b78 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/01/30 00:42 android12-5.10-lts 416c4356f372 9dfcf09c .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/01/10 13:00 android12-5.10-lts 416c4356f372 48bc529a .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2023/01/08 13:17 android12-5.10-lts 416c4356f372 1dac8c7a .config console log report info ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
2022/12/26 14:02 android12-5.10-lts 003c389455eb 9da18ae8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-5-10 kernel BUG in ext4_mb_load_buddy_gfp
* Struck through repros no longer work on HEAD.