syzbot


KCSAN: data-race in n_tty_write / tty_set_termios (5)

Status: auto-closed as invalid on 2021/06/22 15:42
Subsystems: serial
[Documentation on labels]
First crash: 1069d, last: 1067d
Similar bugs (9)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in n_tty_write / tty_set_termios (3) serial 1 1269d 1269d 0/26 auto-closed as invalid on 2020/12/02 18:50
upstream KCSAN: data-race in n_tty_write / tty_set_termios (10) serial 1 366d 366d 0/26 auto-obsoleted due to no activity on 2023/05/24 17:53
upstream KCSAN: data-race in n_tty_write / tty_set_termios (8) serial 9 610d 736d 0/26 auto-closed as invalid on 2022/09/22 18:33
upstream KCSAN: data-race in n_tty_write / tty_set_termios (4) serial 3 1177d 1228d 0/26 auto-closed as invalid on 2021/03/04 08:49
upstream KCSAN: data-race in n_tty_write / tty_set_termios (2) serial 1 1333d 1333d 0/26 auto-closed as invalid on 2020/09/29 07:57
upstream KCSAN: data-race in n_tty_write / tty_set_termios (6) serial 8 896d 1014d 0/26 auto-closed as invalid on 2021/12/10 21:01
upstream KCSAN: data-race in n_tty_write / tty_set_termios serial 1 1395d 1395d 0/26 auto-closed as invalid on 2020/07/29 04:13
upstream KCSAN: data-race in n_tty_write / tty_set_termios (7) serial 4 778d 815d 0/26 auto-closed as invalid on 2022/04/07 21:37
upstream KCSAN: data-race in n_tty_write / tty_set_termios (9) serial 7 457d 538d 0/26 auto-obsoleted due to no activity on 2023/02/26 21:46

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

write to 0xffff8881029aed1c of 4 bytes by task 31666 on cpu 0:
 unset_locked_termios drivers/tty/tty_ioctl.c:254 [inline]
 tty_set_termios+0x1c2/0x8a0 drivers/tty/tty_ioctl.c:331
 set_termios+0x375/0x3b0 drivers/tty/tty_ioctl.c:414
 tty_mode_ioctl+0x573/0x670 drivers/tty/tty_ioctl.c:725
 n_tty_ioctl_helper+0x8b/0x4c0 drivers/tty/tty_ioctl.c:883
 n_tty_ioctl+0x102/0x200 drivers/tty/n_tty.c:2487
 tty_ioctl+0xa8f/0x1120 drivers/tty/tty_io.c:2814
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:1069 [inline]
 __se_sys_ioctl+0xcb/0x140 fs/ioctl.c:1055
 __x64_sys_ioctl+0x3f/0x50 fs/ioctl.c:1055
 do_syscall_64+0x4a/0x90 arch/x86/entry/common.c:47
 entry_SYSCALL_64_after_hwframe+0x44/0xae

read to 0xffff8881029aed1c of 4 bytes by task 11311 on cpu 1:
 n_tty_write+0x86/0xaf0 drivers/tty/n_tty.c:2331
 do_tty_write drivers/tty/tty_io.c:1043 [inline]
 file_tty_write+0x409/0x660 drivers/tty/tty_io.c:1133
 tty_write+0x24/0x30 drivers/tty/tty_io.c:1140
 call_write_iter include/linux/fs.h:2114 [inline]
 do_iter_readv_writev+0x2cb/0x360 fs/read_write.c:740
 do_iter_write+0x112/0x4c0 fs/read_write.c:866
 vfs_writev fs/read_write.c:939 [inline]
 do_writev+0x1e0/0x400 fs/read_write.c:982
 __do_sys_writev fs/read_write.c:1055 [inline]
 __se_sys_writev fs/read_write.c:1052 [inline]
 __x64_sys_writev+0x41/0x50 fs/read_write.c:1052
 do_syscall_64+0x4a/0x90 arch/x86/entry/common.c:47
 entry_SYSCALL_64_after_hwframe+0x44/0xae

Reported by Kernel Concurrency Sanitizer on:
CPU: 1 PID: 11311 Comm: syz-executor.2 Not tainted 5.13.0-rc2-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2021/05/18 15:37 upstream 8ac91e6c6033 a343ba6b .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in n_tty_write / tty_set_termios
2021/05/16 18:05 upstream 63d1cb53e26a f54a5c09 .config console log report info ci2-upstream-kcsan-gce KCSAN: data-race in n_tty_write / tty_set_termios
* Struck through repros no longer work on HEAD.