syzbot


KCSAN: data-race in __xa_set_mark / sync_inodes_sb

Status: auto-closed as invalid on 2020/12/03 09:20
Subsystems: ext4
[Documentation on labels]
First crash: 1305d, last: 1274d

Sample crash report:
==================================================================
BUG: KCSAN: data-race in __xa_set_mark / sync_inodes_sb

write to 0xffff8880095e23c4 of 4 bytes by task 10080 on cpu 0:
 xa_mark_set lib/xarray.c:69 [inline]
 xas_set_mark lib/xarray.c:889 [inline]
 __xa_set_mark+0x166/0x190 lib/xarray.c:1898
 __set_page_dirty+0x17e/0x1d0 fs/buffer.c:609
 mark_buffer_dirty+0x126/0x230 fs/buffer.c:1137
 __block_commit_write fs/buffer.c:2084 [inline]
 block_write_end+0x13d/0x230 fs/buffer.c:2162
 generic_write_end+0x5b/0x250 fs/buffer.c:2176
 ext4_da_write_end+0x59b/0x760 fs/ext4/inode.c:3100
 generic_perform_write+0x23e/0x3a0 mm/filemap.c:3322
 ext4_buffered_write_iter+0x2e5/0x3d0 fs/ext4/file.c:270
 ext4_file_write_iter+0x45e/0x1090 fs/ext4/file.c:503
 call_write_iter include/linux/fs.h:1887 [inline]
 new_sync_write fs/read_write.c:518 [inline]
 vfs_write+0x617/0x690 fs/read_write.c:605
 ksys_write+0xce/0x180 fs/read_write.c:658
 __do_sys_write fs/read_write.c:670 [inline]
 __se_sys_write fs/read_write.c:667 [inline]
 __x64_sys_write+0x3e/0x50 fs/read_write.c:667
 do_syscall_64+0x39/0x80 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

read to 0xffff8880095e23c4 of 4 bytes by task 4053 on cpu 1:
 xa_marked include/linux/xarray.h:416 [inline]
 mapping_tagged include/linux/fs.h:488 [inline]
 wait_sb_inodes fs/fs-writeback.c:2419 [inline]
 sync_inodes_sb+0x30e/0x450 fs/fs-writeback.c:2562
 __sync_filesystem fs/sync.c:34 [inline]
 sync_filesystem+0xe4/0x160 fs/sync.c:67
 ovl_sync_fs+0x94/0xc0 fs/overlayfs/super.c:283
 __sync_filesystem fs/sync.c:39 [inline]
 sync_filesystem+0x112/0x160 fs/sync.c:67
 generic_shutdown_super+0x3c/0x1f0 fs/super.c:448
 kill_anon_super+0x23/0x40 fs/super.c:1108
 deactivate_locked_super+0x6a/0xb0 fs/super.c:335
 deactivate_super+0x85/0x90 fs/super.c:366
 cleanup_mnt+0x277/0x2e0 fs/namespace.c:1118
 __cleanup_mnt+0x15/0x20 fs/namespace.c:1125
 task_work_run+0x8e/0x110 kernel/task_work.c:151
 tracehook_notify_resume include/linux/tracehook.h:188 [inline]
 exit_to_user_mode_loop kernel/entry/common.c:164 [inline]
 exit_to_user_mode_prepare+0x13c/0x170 kernel/entry/common.c:191
 syscall_exit_to_user_mode+0x16/0x30 kernel/entry/common.c:266
 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: 1 PID: 4053 Comm: syz-executor.3 Not tainted 5.10.0-rc1-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
2020/10/29 09:13 upstream 23859ae44402 f24824d3 .config console log report info ci2-upstream-kcsan-gce
2020/09/28 08:39 upstream a1b8638ba132 6bfdbe89 .config console log report info ci2-upstream-kcsan-gce
* Struck through repros no longer work on HEAD.