syzbot


KCSAN: data-race in n_tty_receive_buf_common / n_tty_write (3)

Status: auto-obsoleted due to no activity on 2022/12/07 10:52
Subsystems: serial
[Documentation on labels]
First crash: 555d, last: 513d
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in n_tty_receive_buf_common / n_tty_write (2) serial 36 599d 937d 0/26 auto-closed as invalid on 2022/09/11 21:39
upstream KCSAN: data-race in n_tty_receive_buf_common / n_tty_write (4) serial 5 359d 450d 0/26 auto-obsoleted due to no activity on 2023/05/10 10:49
upstream KCSAN: data-race in n_tty_receive_buf_common / n_tty_write serial 1 1348d 1348d 0/26 auto-closed as invalid on 2020/08/23 22:27
upstream KCSAN: data-race in n_tty_receive_buf_common / n_tty_write (5) serial 38 2d09h 111d 0/26 moderation: reported on 2023/12/09 00:07

Sample crash report:
==================================================================
BUG: KCSAN: data-race in n_tty_receive_buf_common / n_tty_write

write to 0xffffc9000dc01020 of 8 bytes by task 17379 on cpu 1:
 process_echoes drivers/tty/n_tty.c:798 [inline]
 n_tty_write+0x198/0xb10 drivers/tty/n_tty.c:2336
 do_tty_write drivers/tty/tty_io.c:1018 [inline]
 file_tty_write+0x3b8/0x620 drivers/tty/tty_io.c:1089
 tty_write+0x24/0x30 drivers/tty/tty_io.c:1110
 do_iter_write+0x494/0x750 fs/read_write.c:861
 vfs_writev fs/read_write.c:934 [inline]
 do_writev+0x256/0x4b0 fs/read_write.c:977
 __do_sys_writev fs/read_write.c:1050 [inline]
 __se_sys_writev fs/read_write.c:1047 [inline]
 __x64_sys_writev+0x41/0x50 fs/read_write.c:1047
 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

read to 0xffffc9000dc01020 of 8 bytes by task 17387 on cpu 0:
 flush_echoes drivers/tty/n_tty.c:812 [inline]
 __receive_buf drivers/tty/n_tty.c:1615 [inline]
 n_tty_receive_buf_common+0x7dc/0xbf0 drivers/tty/n_tty.c:1711
 n_tty_receive_buf2+0x2e/0x40 drivers/tty/n_tty.c:1746
 tty_ldisc_receive_buf+0x5b/0xf0 drivers/tty/tty_buffer.c:457
 paste_selection+0x1d9/0x2d0 drivers/tty/vt/selection.c:409
 tioclinux+0xee/0x3e0 drivers/tty/vt/vt.c:3204
 vt_ioctl+0x263/0x13c0 drivers/tty/vt/vt_ioctl.c:762
 tty_ioctl+0x689/0x940 drivers/tty/tty_io.c:2771
 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: 0x0000000000005036 -> 0x0000000000005038

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 17387 Comm: syz-executor.0 Tainted: G        W          6.1.0-rc3-syzkaller-00035-gf526d6a82242-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/11/2022
==================================================================

Crashes (5):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/11/02 10:41 upstream f526d6a82242 08977f5d .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in n_tty_receive_buf_common / n_tty_write
2022/10/15 05:19 upstream 9c9155a3509a 67cb024c .config console log report info [disk image] [vmlinux] ci2-upstream-kcsan-gce KCSAN: data-race in n_tty_receive_buf_common / n_tty_write
2022/10/09 12:57 upstream a6afa4199d3d aea5da89 .config console log report info [disk image] [vmlinux] ci2-upstream-kcsan-gce KCSAN: data-race in n_tty_receive_buf_common / n_tty_write
2022/09/26 04:42 upstream 5e049663f678 0042f2b4 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in n_tty_receive_buf_common / n_tty_write
2022/09/20 18:17 upstream 521a547ced64 c4b8ccfd .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in n_tty_receive_buf_common / n_tty_write
* Struck through repros no longer work on HEAD.