pts pts537: tty_release: tty->count(2) != (#fd's(1) + #kopen's(0)) pts pts538: tty_release: tty->count(2) != (#fd's(1) + #kopen's(0)) pts pts539: tty_release: tty->count(2) != (#fd's(1) + #kopen's(0)) pts pts542: tty_release: tty->count(2) != (#fd's(1) + #kopen's(0)) ================================================================== BUG: KASAN: user-memory-access in memset include/linux/string.h:329 [inline] BUG: KASAN: user-memory-access in bitmap_zero include/linux/bitmap.h:197 [inline] BUG: KASAN: user-memory-access in n_tty_set_termios+0xee/0xcb0 drivers/tty/n_tty.c:1786 Write of size 512 at addr 0000000000001060 by task syz-executor0/6677 CPU: 0 PID: 6677 Comm: syz-executor0 Not tainted 4.14.67+ #1 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0xb9/0x11b lib/dump_stack.c:53 kasan_report_error mm/kasan/report.c:349 [inline] kasan_report.cold.6+0x6d/0x2dd mm/kasan/report.c:409 memset+0x1f/0x40 mm/kasan/kasan.c:285 memset include/linux/string.h:329 [inline] bitmap_zero include/linux/bitmap.h:197 [inline] n_tty_set_termios+0xee/0xcb0 drivers/tty/n_tty.c:1786 tty_set_termios+0x5fd/0x860 drivers/tty/tty_ioctl.c:340 set_termios+0x2bf/0x440 drivers/tty/tty_ioctl.c:413 tty_mode_ioctl+0x870/0x920 drivers/tty/tty_ioctl.c:748 n_tty_ioctl_helper+0x3f/0x350 drivers/tty/tty_ioctl.c:939 n_tty_ioctl+0x43/0x2e0 drivers/tty/n_tty.c:2452 tty_ioctl+0x551/0x13e0 drivers/tty/tty_io.c:2654 vfs_ioctl fs/ioctl.c:46 [inline] file_ioctl fs/ioctl.c:500 [inline] do_vfs_ioctl+0x1a0/0x1030 fs/ioctl.c:684 SYSC_ioctl fs/ioctl.c:701 [inline] SyS_ioctl+0x7e/0xb0 fs/ioctl.c:692 do_syscall_64+0x19b/0x4b0 arch/x86/entry/common.c:289 entry_SYSCALL_64_after_hwframe+0x42/0xb7 RIP: 0033:0x457099 RSP: 002b:00007f9411bd8c78 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007f9411bd96d4 RCX: 0000000000457099 RDX: 00000000200000c0 RSI: 0000000000005402 RDI: 0000000000000005 RBP: 00000000009300a0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff R13: 00000000004d0b10 R14: 00000000004c64f6 R15: 0000000000000000 ================================================================== pts pts536: tty_release: tty->count(2) != (#fd's(1) + #kopen's(0)) pts pts541: tty_release: tty->count(2) != (#fd's(1) + #kopen's(0))