syzbot


KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages (2)

Status: auto-obsoleted due to no activity on 2023/05/25 03:03
Subsystems: mm
[Documentation on labels]
First crash: 552d, last: 431d
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages (4) mm 5 41d 72d 0/27 auto-obsoleted due to no activity on 2024/06/18 09:41
upstream KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages (3) mm 26 116d 198d 0/27 auto-obsoleted due to no activity on 2024/04/03 15:08
upstream KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages block 4 846d 892d 0/27 auto-closed as invalid on 2022/04/05 12:28

Sample crash report:
==================================================================
BUG: KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages

read-write to 0xffff888102350c88 of 8 bytes by task 3156 on cpu 0:
 page_cache_delete mm/filemap.c:147 [inline]
 __filemap_remove_folio+0x22f/0x330 mm/filemap.c:225
 __remove_mapping+0x35b/0x480 mm/vmscan.c:1410
 remove_mapping+0x23/0xa0 mm/vmscan.c:1443
 mapping_evict_folio mm/truncate.c:282 [inline]
 invalidate_mapping_pagevec+0x2a9/0x3f0 mm/truncate.c:521
 invalidate_mapping_pages+0x27/0x30 mm/truncate.c:559
 invalidate_bdev+0x6b/0x80 block/bdev.c:87
 ext4_put_super+0x4f8/0x7f0 fs/ext4/super.c:1273
 generic_shutdown_super+0xd9/0x260 fs/super.c:500
 kill_block_super+0x4e/0xa0 fs/super.c:1407
 deactivate_locked_super+0x6b/0xd0 fs/super.c:331
 deactivate_super+0x9b/0xb0 fs/super.c:362
 cleanup_mnt+0x272/0x2e0 fs/namespace.c:1177
 __cleanup_mnt+0x19/0x20 fs/namespace.c:1184
 task_work_run+0x123/0x160 kernel/task_work.c:179
 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
 exit_to_user_mode_loop+0xd1/0xe0 kernel/entry/common.c:171
 exit_to_user_mode_prepare+0x6c/0xb0 kernel/entry/common.c:204
 __syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline]
 syscall_exit_to_user_mode+0x26/0x140 kernel/entry/common.c:297
 do_syscall_64+0x4d/0xc0 arch/x86/entry/common.c:86
 entry_SYSCALL_64_after_hwframe+0x63/0xcd

read to 0xffff888102350c88 of 8 bytes by task 23936 on cpu 1:
 nr_blockdev_pages+0x7f/0xd0 block/bdev.c:445
 si_meminfo+0x3e/0x60 mm/page_alloc.c:6021
 update_defense_level+0x43/0x580 net/netfilter/ipvs/ip_vs_ctl.c:101
 defense_work_handler+0x1f/0x80 net/netfilter/ipvs/ip_vs_ctl.c:235
 process_one_work+0x3e6/0x750 kernel/workqueue.c:2390
 worker_thread+0x5f2/0xa10 kernel/workqueue.c:2537
 kthread+0x1a6/0x1e0 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:308

value changed: 0x0000000000000007 -> 0x0000000000000002

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 23936 Comm: kworker/1:2 Not tainted 6.3.0-rc7-syzkaller-00060-g789b4a41c247 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/30/2023
Workqueue: events_long defense_work_handler
==================================================================

Crashes (6):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/04/20 02:54 upstream 789b4a41c247 a219f34e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages
2023/04/13 07:39 upstream 0bcc40255504 82d5e53e .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages
2023/04/07 00:39 upstream f2afccfefe7b 00ce4c67 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages
2023/04/06 01:57 upstream 99ddf2254feb 8b834965 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages
2023/02/05 21:45 upstream 837c07cf68fe be607b78 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages
2022/12/20 09:59 upstream aeba12b26c79 c52b2efb .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __filemap_remove_folio / nr_blockdev_pages
* Struck through repros no longer work on HEAD.