syzbot


KCSAN: data-race in __lru_add_drain_all / folio_activate (3)

Status: auto-obsoleted due to no activity on 2023/05/29 00:21
Subsystems: mm
[Documentation on labels]
First crash: 597d, last: 597d
Similar bugs (5)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __lru_add_drain_all / folio_activate mm 2 772d 791d 0/28 auto-obsoleted due to no activity on 2022/12/05 13:00
upstream KCSAN: data-race in __lru_add_drain_all / folio_activate (6) mm 1 155d 155d 0/28 auto-obsoleted due to no activity on 2024/08/13 15:34
upstream KCSAN: data-race in __lru_add_drain_all / folio_activate (2) mm 2 668d 704d 0/28 auto-obsoleted due to no activity on 2023/04/01 02:31
upstream KCSAN: data-race in __lru_add_drain_all / folio_activate (5) mm 2 206d 231d 0/28 auto-obsoleted due to no activity on 2024/06/23 21:11
upstream KCSAN: data-race in __lru_add_drain_all / folio_activate (4) mm 23 305d 368d 0/28 auto-obsoleted due to no activity on 2024/03/16 06:00

Sample crash report:
EXT4-fs (loop1): ext4_check_descriptors: Inode bitmap for group 0 overlaps block group descriptors
EXT4-fs (loop1): group descriptors corrupted!
==================================================================
BUG: KCSAN: data-race in __lru_add_drain_all / folio_activate

read-write to 0xffff888237c29ac8 of 1 bytes by task 1049 on cpu 0:
 folio_batch_add include/linux/pagevec.h:126 [inline]
 folio_batch_add_and_move mm/swap.c:231 [inline]
 folio_activate+0xbb/0x1c0 mm/swap.c:361
 folio_mark_accessed+0x114/0x190 mm/swap.c:481
 shmem_file_read_iter+0x2f3/0x570 mm/shmem.c:2679
 do_iter_read+0x3fd/0x6d0 fs/read_write.c:796
 vfs_iter_read+0x50/0x70 fs/read_write.c:838
 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:1888 [inline]
 loop_process_work+0x9b8/0x1310 drivers/block/loop.c:1923
 loop_rootcg_workfn+0x22/0x30 drivers/block/loop.c:1954
 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

read to 0xffff888237c29ac8 of 1 bytes by task 12486 on cpu 1:
 folio_batch_count include/linux/pagevec.h:105 [inline]
 cpu_needs_drain mm/swap.c:800 [inline]
 __lru_add_drain_all+0x21d/0x420 mm/swap.c:889
 lru_add_drain_all+0x10/0x20 mm/swap.c:905
 invalidate_bdev+0x5a/0x80 block/bdev.c:86
 invalidate_disk+0x29/0xc0 block/genhd.c:718
 __loop_clr_fd+0x163/0x3b0 drivers/block/loop.c:1164
 loop_clr_fd drivers/block/loop.c:1257 [inline]
 lo_ioctl+0xe9e/0x12f0 drivers/block/loop.c:1563
 blkdev_ioctl+0x3a0/0x490 block/ioctl.c:615
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:870 [inline]
 __se_sys_ioctl+0xc9/0x140 fs/ioctl.c:856
 __x64_sys_ioctl+0x43/0x50 fs/ioctl.c:856
 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: 0x00 -> 0x01

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 12486 Comm: syz-executor.1 Not tainted 6.3.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/14/2023
==================================================================

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/04/24 00:11 upstream 457391b03803 2b32bd34 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __lru_add_drain_all / folio_activate
* Struck through repros no longer work on HEAD.