================================================================== BUG: KCSAN: data-race in shmem_file_read_iter / shmem_write_end write to 0xffff888137682ce0 of 8 bytes by task 24994 on cpu 1: i_size_write include/linux/fs.h:932 [inline] shmem_write_end+0x9a/0x470 mm/shmem.c:2743 generic_perform_write+0x267/0x410 mm/filemap.c:3929 shmem_file_write_iter+0xc8/0xe0 mm/shmem.c:2895 do_iter_write+0x4ad/0x770 fs/read_write.c:860 vfs_writev+0x1a8/0x320 fs/read_write.c:933 do_pwritev fs/read_write.c:1030 [inline] __do_sys_pwritev fs/read_write.c:1077 [inline] __se_sys_pwritev fs/read_write.c:1072 [inline] __x64_sys_pwritev+0x100/0x1c0 fs/read_write.c:1072 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0x44/0x110 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x63/0x6b read to 0xffff888137682ce0 of 8 bytes by task 47 on cpu 0: i_size_read include/linux/fs.h:910 [inline] shmem_file_read_iter+0x1ee/0x550 mm/shmem.c:2812 do_iter_read+0x4af/0x780 fs/read_write.c:795 vfs_iter_read+0x56/0x70 fs/read_write.c:837 lo_read_simple drivers/block/loop.c:290 [inline] do_req_filebacked drivers/block/loop.c:500 [inline] loop_handle_cmd drivers/block/loop.c:1915 [inline] loop_process_work+0x98c/0x12e0 drivers/block/loop.c:1950 loop_workfn+0x31/0x40 drivers/block/loop.c:1974 process_one_work kernel/workqueue.c:2627 [inline] process_scheduled_works+0x5b8/0xa30 kernel/workqueue.c:2700 worker_thread+0x525/0x730 kernel/workqueue.c:2781 kthread+0x1d7/0x210 kernel/kthread.c:388 ret_from_fork+0x48/0x60 arch/x86/kernel/process.c:147 ret_from_fork_asm+0x11/0x20 arch/x86/entry/entry_64.S:242 value changed: 0x000000000077f000 -> 0x0000000000784000 Reported by Kernel Concurrency Sanitizer on: CPU: 0 PID: 47 Comm: kworker/u4:3 Not tainted 6.7.0-rc7-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/17/2023 Workqueue: loop7 loop_workfn ==================================================================