syzbot


KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq (5)

Status: moderation: reported on 2024/12/03 07:27
Subsystems: rtc
[Documentation on labels]
Reported-by: syzbot+7623b588d2f48190bb96@syzkaller.appspotmail.com
First crash: 18d, last: 9d16h
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq (2) rtc 1 1074d 1074d 0/28 auto-closed as invalid on 2022/02/16 06:16
upstream KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq (4) rtc 1 169d 169d 0/28 auto-obsoleted due to no activity on 2024/08/09 01:42
upstream KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq rtc 1 1197d 1197d 0/28 auto-closed as invalid on 2021/10/16 01:04
upstream KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq (3) rtc 1 237d 237d 0/28 auto-obsoleted due to no activity on 2024/06/01 19:35

Sample crash report:
==================================================================
BUG: KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq

read-write to 0xffff888103500380 of 8 bytes by interrupt on cpu 0:
 rtc_handle_legacy_irq drivers/rtc/interface.c:624 [inline]
 rtc_pie_update_irq+0x95/0xf0 drivers/rtc/interface.c:672
 __run_hrtimer kernel/time/hrtimer.c:1739 [inline]
 __hrtimer_run_queues+0x20d/0x5e0 kernel/time/hrtimer.c:1803
 hrtimer_interrupt+0x235/0x4a0 kernel/time/hrtimer.c:1865
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1038 [inline]
 __sysvec_apic_timer_interrupt+0x5c/0x1d0 arch/x86/kernel/apic/apic.c:1055
 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1049 [inline]
 sysvec_apic_timer_interrupt+0x32/0x80 arch/x86/kernel/apic/apic.c:1049
 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:702

read to 0xffff888103500380 of 8 bytes by task 10088 on cpu 1:
 rtc_dev_poll+0x76/0xb0 drivers/rtc/dev.c:198
 vfs_poll include/linux/poll.h:84 [inline]
 __io_arm_poll_handler+0x1e5/0xd50 io_uring/poll.c:578
 io_arm_poll_handler+0x3f6/0x5b0 io_uring/poll.c:706
 io_queue_async+0x89/0x320 io_uring/io_uring.c:1924
 io_queue_sqe io_uring/io_uring.c:1953 [inline]
 io_req_task_submit+0xb9/0xc0 io_uring/io_uring.c:1370
 io_poll_task_func+0x5fa/0x7c0
 io_handle_tw_list+0xe3/0x200 io_uring/io_uring.c:1053
 tctx_task_work_run+0x6e/0x1c0 io_uring/io_uring.c:1117
 tctx_task_work+0x40/0x80 io_uring/io_uring.c:1135
 task_work_run+0x13a/0x1a0 kernel/task_work.c:239
 get_signal+0xe78/0x1000 kernel/signal.c:2790
 arch_do_signal_or_restart+0x95/0x4b0 arch/x86/kernel/signal.c:337
 exit_to_user_mode_loop kernel/entry/common.c:111 [inline]
 exit_to_user_mode_prepare include/linux/entry-common.h:329 [inline]
 __syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline]
 syscall_exit_to_user_mode+0x62/0x120 kernel/entry/common.c:218
 do_syscall_64+0xd6/0x1c0 arch/x86/entry/common.c:89
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

value changed: 0x0000000000000000 -> 0x00000000000001c0

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 UID: 0 PID: 10088 Comm: syz.2.1502 Not tainted 6.13.0-rc2-syzkaller-00031-gf92f4749861b #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
==================================================================

Crashes (4):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/12/11 21:34 upstream f92f4749861b ff949d25 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq
2024/12/09 01:52 upstream 62b5a46999c7 9ac0fdc6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq
2024/12/07 19:08 upstream b5f217084ab3 9ac0fdc6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq
2024/12/03 07:26 upstream cdd30ebb1b9f 578925bc .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in rtc_dev_poll / rtc_pie_update_irq
* Struck through repros no longer work on HEAD.