syzbot


KCSAN: data-race in __delete_from_page_cache / invalidate_inode_pages2_range

Status: auto-closed as invalid on 2020/05/01 15:10
Subsystems: iomap
[Documentation on labels]
First crash: 2022d, last: 1983d
Similar bugs (1)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __delete_from_page_cache / invalidate_inode_pages2_range (2) iomap 6 1 1809d 1809d 0/29 auto-closed as invalid on 2020/09/17 21:31

Sample crash report:
==================================================================
BUG: KCSAN: data-race in __delete_from_page_cache / invalidate_inode_pages2_range

write to 0xffff8881250c72b8 of 8 bytes by task 28667 on cpu 0:
 page_cache_delete mm/filemap.c:153 [inline]
 __delete_from_page_cache+0x1d8/0x490 mm/filemap.c:238
 invalidate_complete_page2 mm/truncate.c:651 [inline]
 invalidate_inode_pages2_range+0x757/0xbb0 mm/truncate.c:744
 iomap_dio_complete+0x307/0x400 fs/iomap/direct-io.c:108
 iomap_dio_rw+0x8e3/0x9a0 fs/iomap/direct-io.c:569
 ext4_dio_write_iter fs/ext4/file.c:532 [inline]
 ext4_file_write_iter+0xb15/0xd70 fs/ext4/file.c:640
 call_write_iter include/linux/fs.h:1901 [inline]
 do_iter_readv_writev+0x487/0x5b0 fs/read_write.c:693
 do_iter_write fs/read_write.c:998 [inline]
 do_iter_write+0x13b/0x3c0 fs/read_write.c:979
 vfs_iter_write+0x5c/0x80 fs/read_write.c:1039
 iter_file_splice_write+0x536/0x850 fs/splice.c:760
 do_splice_from fs/splice.c:863 [inline]
 direct_splice_actor+0xa0/0xc0 fs/splice.c:1037
 splice_direct_to_actor+0x22b/0x540 fs/splice.c:992
 do_splice_direct+0x161/0x1e0 fs/splice.c:1080
 do_sendfile+0x384/0x7f0 fs/read_write.c:1520
 __do_sys_sendfile64 fs/read_write.c:1581 [inline]
 __se_sys_sendfile64 fs/read_write.c:1567 [inline]
 __x64_sys_sendfile64+0x12a/0x140 fs/read_write.c:1567
 do_syscall_64+0xcc/0x3a0 arch/x86/entry/common.c:294
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

read to 0xffff8881250c72b8 of 8 bytes by task 28671 on cpu 1:
 invalidate_inode_pages2_range+0x52/0xbb0 mm/truncate.c:695
 iomap_dio_rw+0x540/0x9a0 fs/iomap/direct-io.c:481
 ext4_dio_write_iter fs/ext4/file.c:532 [inline]
 ext4_file_write_iter+0xb15/0xd70 fs/ext4/file.c:640
 call_write_iter include/linux/fs.h:1901 [inline]
 do_iter_readv_writev+0x487/0x5b0 fs/read_write.c:693
 do_iter_write fs/read_write.c:998 [inline]
 do_iter_write+0x13b/0x3c0 fs/read_write.c:979
 vfs_iter_write+0x5c/0x80 fs/read_write.c:1039
 iter_file_splice_write+0x536/0x850 fs/splice.c:760
 do_splice_from fs/splice.c:863 [inline]
 direct_splice_actor+0xa0/0xc0 fs/splice.c:1037
 splice_direct_to_actor+0x22b/0x540 fs/splice.c:992
 do_splice_direct+0x161/0x1e0 fs/splice.c:1080
 do_sendfile+0x384/0x7f0 fs/read_write.c:1520
 __do_sys_sendfile64 fs/read_write.c:1581 [inline]
 __se_sys_sendfile64 fs/read_write.c:1567 [inline]
 __x64_sys_sendfile64+0x12a/0x140 fs/read_write.c:1567
 do_syscall_64+0xcc/0x3a0 arch/x86/entry/common.c:294
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

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

Crashes (9):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2020/02/21 15:03 https://github.com/google/ktsan.git kcsan 766d004d1b85 bd2a74a3 .config console log report ci2-upstream-kcsan-gce
2020/02/20 17:42 https://github.com/google/ktsan.git kcsan b12d66a6c34f 81230308 .config console log report ci2-upstream-kcsan-gce
2020/02/17 06:39 https://github.com/google/ktsan.git kcsan b12d66a6c34f 1f448cd6 .config console log report ci2-upstream-kcsan-gce
2020/02/17 06:38 https://github.com/google/ktsan.git kcsan b12d66a6c34f 1f448cd6 .config console log report ci2-upstream-kcsan-gce
2020/02/14 12:40 https://github.com/google/ktsan.git kcsan b12d66a6c34f 5d7b90f1 .config console log report ci2-upstream-kcsan-gce
2020/02/12 16:43 https://github.com/google/ktsan.git kcsan f60f0f543333 a75b198c .config console log report ci2-upstream-kcsan-gce
2020/02/03 05:33 https://github.com/google/ktsan.git kcsan 245a43005292 93e5e335 .config console log report ci2-upstream-kcsan-gce
2020/02/01 00:30 https://github.com/google/ktsan.git kcsan 245a43005292 0eb59c27 .config console log report ci2-upstream-kcsan-gce
2020/01/13 19:16 https://github.com/google/ktsan.git kcsan 245a43005292 99565c1a .config console log report ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.