syzbot


KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (2)

Status: auto-closed as invalid on 2022/10/03 06:12
Subsystems: fs
[Documentation on labels]
First crash: 1003d, last: 797d
Similar bugs (11)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (3) fs 1 753d 753d 0/28 auto-obsoleted due to no activity on 2022/11/16 21:51
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (5) fs 2 558d 570d 0/28 auto-obsoleted due to no activity on 2023/05/30 05:48
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (7) ext4 3 384d 411d 0/28 auto-obsoleted due to no activity on 2023/11/20 11:49
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (9) fs 1 289d 289d 0/28 auto-obsoleted due to no activity on 2024/02/23 17:16
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (11) exfat 1 62d 62d 0/28 auto-obsoleted due to no activity on 2024/10/07 09:54
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (6) ext4 1 448d 448d 0/28 auto-obsoleted due to no activity on 2023/09/17 01:43
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (10) fs 1 204d 204d 0/28 auto-obsoleted due to no activity on 2024/05/17 23:40
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (8) ext4 1 339d 327d 0/28 auto-obsoleted due to no activity on 2024/01/04 10:47
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu ext4 137 1076d 1234d 0/28 auto-closed as invalid on 2021/12/28 13:59
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (12) fs 1 18d 18d 0/28 moderation: reported on 2024/10/16 10:12
upstream KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu (4) ext4 3 663d 714d 0/28 auto-obsoleted due to no activity on 2023/03/11 22:09

Sample crash report:
EXT4-fs (loop1): Invalid log cluster size: 39424
==================================================================
BUG: KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu

write to 0xffff888237c28478 of 8 bytes by task 20319 on cpu 0:
 __invalidate_bh_lrus fs/buffer.c:1392 [inline]
 invalidate_bh_lrus_cpu+0xad/0xe0 fs/buffer.c:1437
 lru_add_and_bh_lrus_drain mm/swap.c:746 [inline]
 lru_add_drain_per_cpu+0x4e/0x70 mm/swap.c:765
 process_one_work+0x3d3/0x720 kernel/workqueue.c:2289
 process_scheduled_works kernel/workqueue.c:2352 [inline]
 worker_thread+0x78f/0xa70 kernel/workqueue.c:2441
 kthread+0x1a9/0x1e0 kernel/kthread.c:376
 ret_from_fork+0x1f/0x30

read to 0xffff888237c28478 of 8 bytes by task 29281 on cpu 1:
 has_bh_in_lru+0x31/0x1c0 fs/buffer.c:1414
 smp_call_function_many_cond+0x34a/0x790 kernel/smp.c:936
 on_each_cpu_cond_mask+0x3b/0x80 kernel/smp.c:1154
 on_each_cpu_cond include/linux/smp.h:105 [inline]
 invalidate_bh_lrus+0x26/0x30 fs/buffer.c:1423
 invalidate_bdev+0x51/0x80 block/bdev.c:84
 invalidate_disk+0x25/0xb0 block/genhd.c:672
 __loop_clr_fd+0x176/0x3c0 drivers/block/loop.c:1164
 loop_clr_fd drivers/block/loop.c:1257 [inline]
 lo_ioctl+0xd8c/0x1290 drivers/block/loop.c:1563
 blkdev_ioctl+0x20e/0x440 block/ioctl.c:614
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:870 [inline]
 __se_sys_ioctl+0xcb/0x140 fs/ioctl.c:856
 __x64_sys_ioctl+0x3f/0x50 fs/ioctl.c:856
 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+0x63/0xcd

value changed: 0x0000000000000000 -> 0xffff888102470d68

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 29281 Comm: syz-executor.1 Not tainted 6.0.0-rc2-syzkaller-00327-g8379c0b31fbc-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/22/2022
==================================================================

Crashes (14):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/08/29 06:01 upstream 8379c0b31fbc 07177916 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/08/28 16:43 upstream 10d4879f9ef0 07177916 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/08/19 03:17 upstream 573ae4f13f63 26a13b38 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/08/17 05:44 upstream 7ebfc85e2cd7 9e4b39c2 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/07/23 00:33 upstream 4ba1329cbb94 22343af4 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/07/17 13:58 upstream 972a278fe60c 95cb00d1 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/07/14 19:00 upstream 4a57a8400075 5d921b08 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/06/18 04:35 upstream 462abc9de7a1 8f633d84 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/05/14 04:56 upstream f2dd007445b1 107f6434 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/05/02 17:33 upstream 672c0c517342 2df221f6 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/04/11 14:25 upstream ce522ba9ef7e e22c3da3 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/03/12 11:13 upstream 68453767131a 9e8eaa75 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/02/19 11:34 upstream 4f12b742eb2b 3cd800e4 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
2022/02/03 22:22 upstream c36c04c2e132 30646bfe .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in has_bh_in_lru / invalidate_bh_lrus_cpu
* Struck through repros no longer work on HEAD.