syzbot


KCSAN: data-race in ext4_write_end / mpage_process_page_bufs (4)

Status: closed as invalid on 2022/05/13 11:20
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 208d, last: 208d
similar bugs (3):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in ext4_write_end / mpage_process_page_bufs 1 1076d 1076d 0/24 auto-closed as invalid on 2020/03/01 21:02
upstream KCSAN: data-race in ext4_write_end / mpage_process_page_bufs (2) 6 915d 986d 0/24 closed as invalid on 2020/06/18 14:24
upstream KCSAN: data-race in ext4_write_end / mpage_process_page_bufs (3) 150 360d 727d 0/24 auto-closed as invalid on 2022/01/12 03:52

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

write to 0xffff8881218b0748 of 8 bytes by task 4557 on cpu 1:
 i_size_write include/linux/fs.h:878 [inline]
 ext4_update_inode_size fs/ext4/ext4.h:3435 [inline]
 ext4_write_end+0x16a/0x7c0 fs/ext4/inode.c:1303
 ext4_da_write_end+0x6d/0x620 fs/ext4/inode.c:3035
 generic_perform_write+0x26a/0x3f0 mm/filemap.c:3798
 ext4_buffered_write_iter+0x222/0x330 fs/ext4/file.c:270
 ext4_file_write_iter+0x2e3/0x1210
 call_write_iter include/linux/fs.h:2050 [inline]
 new_sync_write fs/read_write.c:504 [inline]
 vfs_write+0x71c/0x890 fs/read_write.c:591
 ksys_write+0xe8/0x1a0 fs/read_write.c:644
 __do_sys_write fs/read_write.c:656 [inline]
 __se_sys_write fs/read_write.c:653 [inline]
 __x64_sys_write+0x3e/0x50 fs/read_write.c:653
 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 0xffff8881218b0748 of 8 bytes by task 3163 on cpu 0:
 i_size_read include/linux/fs.h:856 [inline]
 mpage_process_page_bufs+0x34/0x530 fs/ext4/inode.c:2182
 mpage_prepare_extent_to_map+0x5b7/0xa50 fs/ext4/inode.c:2630
 ext4_writepages+0x9b8/0x1d00 fs/ext4/inode.c:2802
 do_writepages+0x1db/0x350 mm/page-writeback.c:2352
 __writeback_single_inode+0x81/0x590 fs/fs-writeback.c:1581
 writeback_sb_inodes+0x69e/0xdd0 fs/fs-writeback.c:1854
 wb_writeback+0x26b/0x650 fs/fs-writeback.c:2026
 wb_do_writeback+0x101/0x600 fs/fs-writeback.c:2169
 wb_workfn+0x88/0x260 fs/fs-writeback.c:2209
 process_one_work+0x3d3/0x720 kernel/workqueue.c:2289
 worker_thread+0x618/0xa70 kernel/workqueue.c:2436
 kthread+0x1a9/0x1e0 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30

value changed: 0x0000000000911000 -> 0x0000000000912000

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 3163 Comm: kworker/u4:7 Not tainted 5.18.0-rc5-syzkaller-00207-g379c72654524 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: writeback wb_workfn (flush-8:0)
==================================================================

Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2022/05/08 18:54 upstream 379c72654524 e60b1103 .config log report info KCSAN: data-race in ext4_write_end / mpage_process_page_bufs
* Struck through repros no longer work on HEAD.