syzbot


KCSAN: data-race in ext4_file_write_iter / ext4_setattr (3)

Status: auto-closed as invalid on 2021/05/14 00:08
Subsystems: ext4
[Documentation on labels]
First crash: 1604d, last: 1603d
Similar bugs (6)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in ext4_file_write_iter / ext4_setattr (2) ext4 6 1 1726d 1726d 0/29 auto-closed as invalid on 2021/01/11 11:39
upstream KCSAN: data-race in ext4_file_write_iter / ext4_setattr (7) ext4 6 1 1304d 1304d 0/29 auto-closed as invalid on 2022/03/09 13:22
upstream KCSAN: data-race in ext4_file_write_iter / ext4_setattr (4) ext4 6 1 1568d 1568d 0/29 auto-closed as invalid on 2021/06/18 10:04
upstream KCSAN: data-race in ext4_file_write_iter / ext4_setattr ext4 6 3 1795d 1818d 0/29 auto-closed as invalid on 2020/11/03 10:53
upstream KCSAN: data-race in ext4_file_write_iter / ext4_setattr (5) ext4 6 3 1476d 1512d 0/29 auto-closed as invalid on 2021/09/18 07:46
upstream KCSAN: data-race in ext4_file_write_iter / ext4_setattr (6) ext4 6 8 1381d 1433d 0/29 auto-closed as invalid on 2021/12/21 17:24

Sample crash report:
==================================================================
BUG: KCSAN: data-race in ext4_file_write_iter / ext4_setattr

write to 0xffff888028d27670 of 8 bytes by task 15729 on cpu 0:
 i_size_write include/linux/fs.h:872 [inline]
 ext4_setattr+0xe1f/0xf60 fs/ext4/inode.c:5483
 notify_change+0x88f/0xa80 fs/attr.c:398
 do_truncate+0xe8/0x130 fs/open.c:64
 handle_truncate fs/namei.c:3020 [inline]
 do_open fs/namei.c:3371 [inline]
 path_openat+0x1b78/0x21b0 fs/namei.c:3500
 do_filp_open+0xd9/0x1f0 fs/namei.c:3527
 do_sys_openat2+0xa3/0x250 fs/open.c:1187
 do_sys_open fs/open.c:1203 [inline]
 __do_sys_openat fs/open.c:1219 [inline]
 __se_sys_openat fs/open.c:1214 [inline]
 __x64_sys_openat+0xef/0x110 fs/open.c:1214
 do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xae

read to 0xffff888028d27670 of 8 bytes by task 15716 on cpu 1:
 i_size_read include/linux/fs.h:850 [inline]
 ext4_dio_write_iter fs/ext4/file.c:478 [inline]
 ext4_file_write_iter+0x1b5/0x10b0 fs/ext4/file.c:661
 call_write_iter include/linux/fs.h:1977 [inline]
 do_iter_readv_writev+0x2cb/0x360 fs/read_write.c:740
 do_iter_write+0x112/0x4c0 fs/read_write.c:866
 vfs_iter_write+0x4c/0x70 fs/read_write.c:907
 iter_file_splice_write+0x40a/0x750 fs/splice.c:689
 do_splice_from fs/splice.c:767 [inline]
 direct_splice_actor+0x80/0xa0 fs/splice.c:936
 splice_direct_to_actor+0x345/0x650 fs/splice.c:891
 do_splice_direct+0xf5/0x170 fs/splice.c:979
 do_sendfile+0x7a6/0xe20 fs/read_write.c:1260
 __do_sys_sendfile64 fs/read_write.c:1319 [inline]
 __se_sys_sendfile64 fs/read_write.c:1311 [inline]
 __x64_sys_sendfile64+0xa9/0x130 fs/read_write.c:1311
 do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xae

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 15716 Comm: syz-executor.2 Tainted: G        W         5.12.0-rc6-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2021/04/09 00:00 upstream 3fb4f979b4fa 6a81331a .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in ext4_file_write_iter / ext4_setattr
2021/04/08 02:25 upstream 3a22981230f9 6a81331a .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in ext4_file_write_iter / ext4_setattr
* Struck through repros no longer work on HEAD.