syzbot


KCSAN: data-race in munlock_page / need_mlock_page_drain (2)

Status: auto-closed as invalid on 2022/07/21 00:35
Subsystems: mm
[Documentation on labels]
First crash: 679d, last: 673d
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in munlock_page / need_mlock_page_drain (4) mm 1 545d 545d 0/26 auto-obsoleted due to no activity on 2022/11/25 22:03
upstream KCSAN: data-race in munlock_page / need_mlock_page_drain (3) mm 1 599d 599d 0/26 auto-closed as invalid on 2022/10/02 16:17
upstream KCSAN: data-race in munlock_page / need_mlock_page_drain mm 2 739d 742d 0/26 auto-closed as invalid on 2022/05/16 01:29

Sample crash report:
==================================================================
BUG: KCSAN: data-race in munlock_page / need_mlock_page_drain

read-write to 0xffff888237c27ec0 of 1 bytes by task 4155 on cpu 0:
 pagevec_add include/linux/pagevec.h:75 [inline]
 munlock_page+0x86/0x2a0 mm/mlock.c:302
 munlock_vma_page mm/internal.h:539 [inline]
 page_remove_rmap+0x17e/0x220 mm/rmap.c:1467
 try_to_migrate_one+0x96f/0xed0 mm/rmap.c:2098
 rmap_walk_anon+0x55c/0x670 mm/rmap.c:2419
 try_to_migrate+0x110/0x140
 __unmap_and_move+0x386/0xbd0 mm/migrate.c:1030
 unmap_and_move+0x13c/0x950 mm/migrate.c:1109
 migrate_pages+0x29e/0x7b0 mm/migrate.c:1388
 do_mbind+0x79b/0x8b0 mm/mempolicy.c:1323
 kernel_mbind mm/mempolicy.c:1470 [inline]
 __do_sys_mbind mm/mempolicy.c:1548 [inline]
 __se_sys_mbind+0x13b/0x3f0 mm/mempolicy.c:1544
 __x64_sys_mbind+0x74/0x80 mm/mempolicy.c:1544
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x46/0xb0

read to 0xffff888237c27ec0 of 1 bytes by task 4148 on cpu 1:
 pagevec_count include/linux/pagevec.h:62 [inline]
 need_mlock_page_drain+0x2c/0x50 mm/mlock.c:236
 __lru_add_drain_all+0x24c/0x3e0 mm/swap.c:832
 lru_add_drain_all+0xc/0x10 mm/swap.c:849
 check_and_migrate_movable_pages+0x1e6/0x720 mm/gup.c:1908
 __gup_longterm_locked+0x193/0x280 mm/gup.c:1988
 __gup_longterm_unlocked+0x98/0x100 mm/gup.c:2787
 internal_get_user_pages_fast+0x818/0x8c0 mm/gup.c:2882
 pin_user_pages_fast+0x49/0x70 mm/gup.c:3005
 rds_pin_pages net/rds/rdma.c:163 [inline]
 rds_cmsg_rdma_args+0x6ca/0xc60 net/rds/rdma.c:718
 rds_cmsg_send+0x18b/0x3a0 net/rds/send.c:1005
 rds_sendmsg+0xc90/0x1430 net/rds/send.c:1316
 sock_sendmsg_nosec net/socket.c:714 [inline]
 sock_sendmsg net/socket.c:734 [inline]
 ____sys_sendmsg+0x38f/0x500 net/socket.c:2492
 ___sys_sendmsg net/socket.c:2546 [inline]
 __sys_sendmsg+0x197/0x230 net/socket.c:2575
 __do_sys_sendmsg net/socket.c:2584 [inline]
 __se_sys_sendmsg net/socket.c:2582 [inline]
 __x64_sys_sendmsg+0x42/0x50 net/socket.c:2582
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x46/0xb0

value changed: 0x00 -> 0x01

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 4148 Comm: syz-executor.2 Not tainted 5.19.0-rc2-syzkaller-00060-g30306f6194ca-dirty #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
2022/06/16 00:32 upstream 30306f6194ca 1719ee24 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in munlock_page / need_mlock_page_drain
2022/06/10 00:05 upstream 3d9f55c57bc3 0d5abf15 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in munlock_page / need_mlock_page_drain
* Struck through repros no longer work on HEAD.