syzbot


KCSAN: data-race in ext4_mb_free_metadata / ext4_should_retry_alloc (3)

Status: closed as invalid on 2022/05/13 11:20
Subsystems: ext4
[Documentation on labels]
First crash: 689d, last: 689d
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in ext4_mb_free_metadata / ext4_should_retry_alloc ext4 1 891d 891d 0/26 auto-closed as invalid on 2021/11/24 05:46
upstream KCSAN: data-race in ext4_mb_free_metadata / ext4_should_retry_alloc (2) ext4 1 831d 831d 0/26 auto-closed as invalid on 2022/01/23 07:11

Sample crash report:
==================================================================
BUG: KCSAN: data-race in ext4_mb_free_metadata / ext4_should_retry_alloc

read-write to 0xffff888103f5f2e4 of 4 bytes by task 26424 on cpu 0:
 ext4_mb_free_metadata+0x3e9/0x590 fs/ext4/mballoc.c:5773
 ext4_mb_clear_bb+0x941/0x11f0 fs/ext4/mballoc.c:6000
 ext4_free_blocks+0x736/0x840 fs/ext4/mballoc.c:6164
 ext4_remove_blocks+0x724/0x950 fs/ext4/extents.c:2538
 ext4_ext_rm_leaf+0x6d1/0xf30 fs/ext4/extents.c:2704
 ext4_ext_remove_space+0x86a/0x1470 fs/ext4/extents.c:2952
 ext4_ext_truncate+0x11c/0x1a0 fs/ext4/extents.c:4412
 ext4_truncate+0x74d/0xab0 fs/ext4/inode.c:4238
 ext4_evict_inode+0xa1d/0xe40 fs/ext4/inode.c:286
 evict+0x1aa/0x410 fs/inode.c:664
 iput_final fs/inode.c:1744 [inline]
 iput+0x3f9/0x580 fs/inode.c:1770
 do_unlinkat+0x2b3/0x510 fs/namei.c:4223
 __do_sys_unlink fs/namei.c:4264 [inline]
 __se_sys_unlink fs/namei.c:4262 [inline]
 __x64_sys_unlink+0x2c/0x30 fs/namei.c:4262
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

read to 0xffff888103f5f2e4 of 4 bytes by task 27607 on cpu 1:
 ext4_should_retry_alloc+0xba/0x160 fs/ext4/balloc.c:656
 ext4_alloc_file_blocks+0x6ab/0x730 fs/ext4/extents.c:4497
 ext4_fallocate+0x32f/0x420 fs/ext4/extents.c:4751
 vfs_fallocate+0x355/0x3d0 fs/open.c:308
 ksys_fallocate fs/open.c:331 [inline]
 __do_sys_fallocate fs/open.c:339 [inline]
 __se_sys_fallocate fs/open.c:337 [inline]
 __x64_sys_fallocate+0x75/0xc0 fs/open.c:337
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

value changed: 0x00015c24 -> 0x00015c67

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 27607 Comm: syz-executor.5 Not tainted 5.18.0-rc6-syzkaller-00007-g9be9ed2612b5 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/05/09 20:59 upstream 9be9ed2612b5 8b277b8e .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in ext4_mb_free_metadata / ext4_should_retry_alloc
* Struck through repros no longer work on HEAD.