syzbot


KCSAN: data-race in ext4_alloc_file_blocks / mpage_process_page_bufs

Status: auto-closed as invalid on 2020/10/01 02:48
Subsystems: ext4
[Documentation on labels]
First crash: 1350d, last: 1310d
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in ext4_alloc_file_blocks / mpage_process_page_bufs (3) ext4 1 1093d 1093d 0/26 auto-closed as invalid on 2021/05/05 19:41
upstream KCSAN: data-race in ext4_alloc_file_blocks / mpage_process_page_bufs (4) ext4 1 847d 847d 0/26 auto-closed as invalid on 2022/01/07 07:28
upstream KCSAN: data-race in ext4_alloc_file_blocks / mpage_process_page_bufs (2) ext4 1 1258d 1258d 0/26 auto-closed as invalid on 2020/11/21 16:04

Sample crash report:
==================================================================
BUG: KCSAN: data-race in ext4_alloc_file_blocks / mpage_process_page_bufs

write to 0xffff8880b4e3b238 of 8 bytes by task 19796 on cpu 1:
 i_size_write include/linux/fs.h:876 [inline]
 ext4_update_inode_size fs/ext4/ext4.h:3141 [inline]
 ext4_alloc_file_blocks+0x325/0x6e0 fs/ext4/extents.c:4444
 ext4_zero_range+0x2c6/0xa30 fs/ext4/extents.c:4538
 ext4_fallocate+0x214/0x560 fs/ext4/extents.c:4666
 vfs_fallocate+0x43c/0x5d0 fs/open.c:309
 ksys_fallocate fs/open.c:332 [inline]
 __do_sys_fallocate fs/open.c:340 [inline]
 __se_sys_fallocate fs/open.c:338 [inline]
 __x64_sys_fallocate+0x75/0xc0 fs/open.c:338
 do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

read to 0xffff8880b4e3b238 of 8 bytes by task 19638 on cpu 0:
 i_size_read include/linux/fs.h:854 [inline]
 mpage_process_page_bufs+0x34/0x600 fs/ext4/inode.c:2173
 mpage_prepare_extent_to_map+0x4ec/0x650 fs/ext4/inode.c:2607
 ext4_writepages+0x97d/0x1ef0 fs/ext4/inode.c:2779
 do_writepages+0x7b/0x150 mm/page-writeback.c:2352
 __filemap_fdatawrite_range+0x19b/0x1d0 mm/filemap.c:422
 __filemap_fdatawrite mm/filemap.c:430 [inline]
 filemap_flush+0x1f/0x30 mm/filemap.c:457
 ext4_alloc_da_blocks+0x4c/0x130 fs/ext4/inode.c:3145
 ext4_release_file+0x5b/0x1c0 fs/ext4/file.c:142
 __fput+0x246/0x4d0 fs/file_table.c:281
 ____fput+0x11/0x20 fs/file_table.c:314
 task_work_run+0x8e/0x110 kernel/task_work.c:141
 tracehook_notify_resume include/linux/tracehook.h:188 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:140 [inline]
 exit_to_user_mode_prepare+0x1b2/0x210 kernel/entry/common.c:167
 syscall_exit_to_user_mode+0x16/0x30 kernel/entry/common.c:242
 do_syscall_64+0x45/0x80 arch/x86/entry/common.c:56
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 19638 Comm: syz-executor.0 Not tainted 5.9.0-rc2-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (4):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2020/08/27 02:39 upstream 15bc20c6af4c 318430cb .config console log report ci2-upstream-kcsan-gce
2020/08/22 03:32 upstream cd02217a5d81 6436ce4b .config console log report ci2-upstream-kcsan-gce
2020/08/05 01:56 upstream c0842fbc1b18 02034dac .config console log report ci2-upstream-kcsan-gce
2020/07/17 16:24 upstream 8882572675c1 9c812472 .config console log report ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.