================================================================== BUG: KCSAN: data-race in mlock_folio_batch / need_mlock_drain write to 0xffff888237d29e68 of 1 bytes by task 17526 on cpu 1: folio_batch_reinit include/linux/pagevec.h:48 [inline] mlock_folio_batch+0x197d/0x19a0 mm/mlock.c:210 mlock_new_folio+0x19b/0x200 mm/mlock.c:283 folio_add_lru_vma+0x152/0x160 mm/swap.c:535 do_anonymous_page mm/memory.c:4146 [inline] do_pte_missing mm/memory.c:3662 [inline] handle_pte_fault mm/memory.c:4939 [inline] __handle_mm_fault mm/memory.c:5079 [inline] handle_mm_fault+0x1c27/0x2c10 mm/memory.c:5233 faultin_page mm/gup.c:959 [inline] __get_user_pages+0x42e/0xd20 mm/gup.c:1258 populate_vma_page_range mm/gup.c:1649 [inline] __mm_populate+0x23b/0x360 mm/gup.c:1758 mm_populate include/linux/mm.h:3196 [inline] vm_mmap_pgoff+0x1a3/0x240 mm/util.c:548 ksys_mmap_pgoff+0xc5/0x330 mm/mmap.c:1408 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd read to 0xffff888237d29e68 of 1 bytes by task 17535 on cpu 0: folio_batch_count include/linux/pagevec.h:53 [inline] need_mlock_drain+0x30/0x50 mm/mlock.c:236 cpu_needs_drain mm/swap.c:801 [inline] __lru_add_drain_all+0x240/0x420 mm/swap.c:889 lru_add_drain_all+0x10/0x20 mm/swap.c:905 invalidate_bdev+0x5a/0x80 block/bdev.c:86 bdev_disk_changed+0x11b/0xbd0 block/partitions/core.c:667 blkdev_get_whole+0x227/0x240 block/bdev.c:670 blkdev_get_by_dev+0x236/0x390 block/bdev.c:812 blkdev_open+0xf7/0x1e0 block/fops.c:517 do_dentry_open+0x5cd/0xaf0 fs/open.c:914 vfs_open+0x4a/0x50 fs/open.c:1048 do_open fs/namei.c:3636 [inline] path_openat+0x17f2/0x1d10 fs/namei.c:3793 do_filp_open+0xf6/0x200 fs/namei.c:3820 do_sys_openat2+0xab/0x110 fs/open.c:1407 do_sys_open fs/open.c:1422 [inline] __do_sys_openat fs/open.c:1438 [inline] __se_sys_openat fs/open.c:1433 [inline] __x64_sys_openat+0xf3/0x120 fs/open.c:1433 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd value changed: 0x0f -> 0x01 Reported by Kernel Concurrency Sanitizer on: CPU: 0 PID: 17535 Comm: syz-executor.0 Tainted: G W 6.5.0-rc1-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/03/2023 ================================================================== loop0: detected capacity change from 0 to 256 vfat filesystem being mounted at /root/syzkaller-testdir2903013226/syzkaller.LKj1c3/929/file0 supports timestamps until 2107-12-31 (0x10391447e)