================================================================== BUG: KCSAN: data-race in n_tty_flush_buffer / n_tty_lookahead_flow_ctrl write to 0xffffc90000ebf270 of 8 bytes by task 8404 on cpu 1: reset_buffer_flags drivers/tty/n_tty.c:328 [inline] n_tty_flush_buffer+0x9f/0x190 drivers/tty/n_tty.c:359 tty_ldisc_hangup+0x72/0x370 drivers/tty/tty_ldisc.c:699 __tty_hangup+0x3c6/0x540 drivers/tty/tty_io.c:630 tty_vhangup+0x17/0x20 drivers/tty/tty_io.c:700 pty_close+0x262/0x280 drivers/tty/pty.c:79 tty_release+0x20c/0x940 drivers/tty/tty_io.c:1760 __fput+0x192/0x6f0 fs/file_table.c:422 ____fput+0x15/0x20 fs/file_table.c:450 task_work_run+0x13a/0x1a0 kernel/task_work.c:222 get_signal+0xeee/0x1080 kernel/signal.c:2689 arch_do_signal_or_restart+0x95/0x4b0 arch/x86/kernel/signal.c:310 exit_to_user_mode_loop kernel/entry/common.c:111 [inline] exit_to_user_mode_prepare include/linux/entry-common.h:328 [inline] __syscall_exit_to_user_mode_work kernel/entry/common.c:207 [inline] syscall_exit_to_user_mode+0x59/0x130 kernel/entry/common.c:218 do_syscall_64+0xd6/0x1c0 arch/x86/entry/common.c:89 entry_SYSCALL_64_after_hwframe+0x77/0x7f read-write to 0xffffc90000ebf270 of 8 bytes by task 11 on cpu 0: n_tty_lookahead_flow_ctrl+0x48/0x130 drivers/tty/n_tty.c:1507 tty_port_default_lookahead_buf+0x8a/0xc0 drivers/tty/tty_port.c:59 lookahead_bufs drivers/tty/tty_buffer.c:428 [inline] flush_to_ldisc+0x31c/0x410 drivers/tty/tty_buffer.c:498 process_one_work kernel/workqueue.c:3231 [inline] process_scheduled_works+0x483/0x9a0 kernel/workqueue.c:3312 worker_thread+0x526/0x700 kernel/workqueue.c:3390 kthread+0x1d1/0x210 kernel/kthread.c:389 ret_from_fork+0x4b/0x60 arch/x86/kernel/process.c:147 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244 value changed: 0x0000000000000006 -> 0x0000000000000000 Reported by Kernel Concurrency Sanitizer on: CPU: 0 PID: 11 Comm: kworker/u8:0 Not tainted 6.10.0-syzkaller-10729-g3c3ff7be9729 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/27/2024 Workqueue: events_unbound flush_to_ldisc ==================================================================