tty 83 arch/alpha/kernel/srmcons.c if (port->tty) tty 133 arch/alpha/kernel/srmcons.c srmcons_write(struct tty_struct *tty, tty 139 arch/alpha/kernel/srmcons.c srmcons_do_write(tty->port, (const char *) buf, count); tty 146 arch/alpha/kernel/srmcons.c srmcons_write_room(struct tty_struct *tty) tty 152 arch/alpha/kernel/srmcons.c srmcons_chars_in_buffer(struct tty_struct *tty) tty 158 arch/alpha/kernel/srmcons.c srmcons_open(struct tty_struct *tty, struct file *filp) tty 166 arch/alpha/kernel/srmcons.c if (!port->tty) { tty 167 arch/alpha/kernel/srmcons.c tty->driver_data = srmconsp; tty 168 arch/alpha/kernel/srmcons.c tty->port = port; tty 169 arch/alpha/kernel/srmcons.c port->tty = tty; /* XXX proper refcounting */ tty 179 arch/alpha/kernel/srmcons.c srmcons_close(struct tty_struct *tty, struct file *filp) tty 181 arch/alpha/kernel/srmcons.c struct srmcons_private *srmconsp = tty->driver_data; tty 187 arch/alpha/kernel/srmcons.c if (tty->count == 1) { tty 188 arch/alpha/kernel/srmcons.c port->tty = NULL; tty 1342 arch/ia64/kernel/unaligned.c struct tty_struct *tty = get_current_tty(); tty 1343 arch/ia64/kernel/unaligned.c tty_write_message(tty, buf); tty 1344 arch/ia64/kernel/unaligned.c tty_kref_put(tty); tty 64 arch/m68k/emu/nfcon.c static int nfcon_tty_open(struct tty_struct *tty, struct file *filp) tty 69 arch/m68k/emu/nfcon.c static void nfcon_tty_close(struct tty_struct *tty, struct file *filp) tty 73 arch/m68k/emu/nfcon.c static int nfcon_tty_write(struct tty_struct *tty, const unsigned char *buf, tty 80 arch/m68k/emu/nfcon.c static int nfcon_tty_put_char(struct tty_struct *tty, unsigned char ch) tty 88 arch/m68k/emu/nfcon.c static int nfcon_tty_write_room(struct tty_struct *tty) tty 84 arch/parisc/kernel/pdc_cons.c static int pdc_console_tty_open(struct tty_struct *tty, struct file *filp) tty 86 arch/parisc/kernel/pdc_cons.c tty_port_tty_set(&tty_port, tty); tty 92 arch/parisc/kernel/pdc_cons.c static void pdc_console_tty_close(struct tty_struct *tty, struct file *filp) tty 94 arch/parisc/kernel/pdc_cons.c if (tty->count == 1) { tty 100 arch/parisc/kernel/pdc_cons.c static int pdc_console_tty_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 106 arch/parisc/kernel/pdc_cons.c static int pdc_console_tty_write_room(struct tty_struct *tty) tty 111 arch/parisc/kernel/pdc_cons.c static int pdc_console_tty_chars_in_buffer(struct tty_struct *tty) tty 74 arch/powerpc/include/asm/hvsi.h struct tty_struct *tty; /* tty structure */ tty 50 arch/um/drivers/line.c int line_write_room(struct tty_struct *tty) tty 52 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 63 arch/um/drivers/line.c int line_chars_in_buffer(struct tty_struct *tty) tty 65 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 168 arch/um/drivers/line.c void line_flush_buffer(struct tty_struct *tty) tty 170 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 182 arch/um/drivers/line.c void line_flush_chars(struct tty_struct *tty) tty 184 arch/um/drivers/line.c line_flush_buffer(tty); tty 187 arch/um/drivers/line.c int line_put_char(struct tty_struct *tty, unsigned char ch) tty 189 arch/um/drivers/line.c return line_write(tty, &ch, sizeof(ch)); tty 192 arch/um/drivers/line.c int line_write(struct tty_struct *tty, const unsigned char *buf, int len) tty 194 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 219 arch/um/drivers/line.c void line_set_termios(struct tty_struct *tty, struct ktermios * old) tty 224 arch/um/drivers/line.c void line_throttle(struct tty_struct *tty) tty 226 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 232 arch/um/drivers/line.c void line_unthrottle(struct tty_struct *tty) tty 234 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 285 arch/um/drivers/line.c static int line_activate(struct tty_port *port, struct tty_struct *tty) tty 288 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 299 arch/um/drivers/line.c chan_window_size(line, &tty->winsize.ws_row, tty 300 arch/um/drivers/line.c &tty->winsize.ws_col); tty 305 arch/um/drivers/line.c static void unregister_winch(struct tty_struct *tty); tty 309 arch/um/drivers/line.c struct tty_struct *tty = tty_port_tty_get(port); tty 310 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 313 arch/um/drivers/line.c unregister_winch(tty); tty 323 arch/um/drivers/line.c int line_open(struct tty_struct *tty, struct file *filp) tty 325 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 327 arch/um/drivers/line.c return tty_port_open(&line->port, tty, filp); tty 330 arch/um/drivers/line.c int line_install(struct tty_driver *driver, struct tty_struct *tty, tty 335 arch/um/drivers/line.c ret = tty_standard_install(driver, tty); tty 339 arch/um/drivers/line.c tty->driver_data = line; tty 344 arch/um/drivers/line.c void line_close(struct tty_struct *tty, struct file * filp) tty 346 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 348 arch/um/drivers/line.c tty_port_close(&line->port, tty, filp); tty 351 arch/um/drivers/line.c void line_hangup(struct tty_struct *tty) tty 353 arch/um/drivers/line.c struct line *line = tty->driver_data; tty 505 arch/um/drivers/line.c struct tty_struct *tty = tty_port_tty_get(&line->port); tty 506 arch/um/drivers/line.c if (tty == NULL) { tty 510 arch/um/drivers/line.c tty_kref_put(tty); tty 623 arch/um/drivers/line.c struct tty_struct *tty; tty 648 arch/um/drivers/line.c tty = tty_port_tty_get(winch->port); tty 649 arch/um/drivers/line.c if (tty != NULL) { tty 650 arch/um/drivers/line.c line = tty->driver_data; tty 652 arch/um/drivers/line.c chan_window_size(line, &tty->winsize.ws_row, tty 653 arch/um/drivers/line.c &tty->winsize.ws_col); tty 654 arch/um/drivers/line.c pgrp = tty_get_pgrp(tty); tty 659 arch/um/drivers/line.c tty_kref_put(tty); tty 705 arch/um/drivers/line.c static void unregister_winch(struct tty_struct *tty) tty 716 arch/um/drivers/line.c if (wtty == tty) { tty 59 arch/um/drivers/line.h extern void line_close(struct tty_struct *tty, struct file * filp); tty 60 arch/um/drivers/line.h extern int line_open(struct tty_struct *tty, struct file *filp); tty 61 arch/um/drivers/line.h extern int line_install(struct tty_driver *driver, struct tty_struct *tty, tty 63 arch/um/drivers/line.h extern void line_cleanup(struct tty_struct *tty); tty 64 arch/um/drivers/line.h extern void line_hangup(struct tty_struct *tty); tty 67 arch/um/drivers/line.h extern int line_write(struct tty_struct *tty, const unsigned char *buf, tty 69 arch/um/drivers/line.h extern int line_put_char(struct tty_struct *tty, unsigned char ch); tty 70 arch/um/drivers/line.h extern void line_set_termios(struct tty_struct *tty, struct ktermios * old); tty 71 arch/um/drivers/line.h extern int line_chars_in_buffer(struct tty_struct *tty); tty 72 arch/um/drivers/line.h extern void line_flush_buffer(struct tty_struct *tty); tty 73 arch/um/drivers/line.h extern void line_flush_chars(struct tty_struct *tty); tty 74 arch/um/drivers/line.h extern int line_write_room(struct tty_struct *tty); tty 75 arch/um/drivers/line.h extern void line_throttle(struct tty_struct *tty); tty 76 arch/um/drivers/line.h extern void line_unthrottle(struct tty_struct *tty); tty 89 arch/um/drivers/ssl.c static int ssl_install(struct tty_driver *driver, struct tty_struct *tty) tty 91 arch/um/drivers/ssl.c return line_install(driver, tty, &serial_lines[tty->index]); tty 95 arch/um/drivers/stdio_console.c static int con_install(struct tty_driver *driver, struct tty_struct *tty) tty 97 arch/um/drivers/stdio_console.c return line_install(driver, tty, &vts[tty->index]); tty 52 arch/xtensa/platforms/iss/console.c static int rs_open(struct tty_struct *tty, struct file * filp) tty 54 arch/xtensa/platforms/iss/console.c tty->port = &serial_port; tty 56 arch/xtensa/platforms/iss/console.c if (tty->count == 1) { tty 76 arch/xtensa/platforms/iss/console.c static void rs_close(struct tty_struct *tty, struct file * filp) tty 79 arch/xtensa/platforms/iss/console.c if (tty->count == 1) tty 85 arch/xtensa/platforms/iss/console.c static int rs_write(struct tty_struct * tty, tty 119 arch/xtensa/platforms/iss/console.c static int rs_put_char(struct tty_struct *tty, unsigned char ch) tty 121 arch/xtensa/platforms/iss/console.c return rs_write(tty, &ch, 1); tty 124 arch/xtensa/platforms/iss/console.c static void rs_flush_chars(struct tty_struct *tty) tty 128 arch/xtensa/platforms/iss/console.c static int rs_write_room(struct tty_struct *tty) tty 134 arch/xtensa/platforms/iss/console.c static int rs_chars_in_buffer(struct tty_struct *tty) tty 140 arch/xtensa/platforms/iss/console.c static void rs_hangup(struct tty_struct *tty) tty 145 arch/xtensa/platforms/iss/console.c static void rs_wait_until_sent(struct tty_struct *tty, int timeout) tty 50 drivers/bluetooth/hci_ath.c static int ath_wakeup_ar3k(struct tty_struct *tty) tty 52 drivers/bluetooth/hci_ath.c int status = tty->driver->ops->tiocmget(tty); tty 58 drivers/bluetooth/hci_ath.c tty->driver->ops->tiocmget(tty); tty 59 drivers/bluetooth/hci_ath.c tty->driver->ops->tiocmset(tty, 0x00, TIOCM_RTS); tty 63 drivers/bluetooth/hci_ath.c tty->driver->ops->tiocmget(tty); tty 64 drivers/bluetooth/hci_ath.c tty->driver->ops->tiocmset(tty, TIOCM_RTS, 0x00); tty 67 drivers/bluetooth/hci_ath.c status = tty->driver->ops->tiocmget(tty); tty 76 drivers/bluetooth/hci_ath.c struct tty_struct *tty; tty 81 drivers/bluetooth/hci_ath.c tty = hu->tty; tty 85 drivers/bluetooth/hci_ath.c status = ath_wakeup_ar3k(tty); tty 427 drivers/bluetooth/hci_bcm.c if (!hu->tty->dev) tty 437 drivers/bluetooth/hci_bcm.c if (hu->tty->dev->parent == dev->dev->parent) { tty 294 drivers/bluetooth/hci_intel.c if (!hu->tty->dev) tty 306 drivers/bluetooth/hci_intel.c if (hu->tty->dev->parent != idev->pdev->dev.parent) tty 369 drivers/bluetooth/hci_intel.c if (!intel->hu->tty->dev) tty 378 drivers/bluetooth/hci_intel.c if (intel->hu->tty->dev->parent == idev->pdev->dev.parent) { tty 845 drivers/bluetooth/hci_intel.c if (!hu->tty->dev) tty 847 drivers/bluetooth/hci_intel.c if (hu->tty->dev->parent == dev->pdev->dev.parent) { tty 1006 drivers/bluetooth/hci_intel.c if (!hu->tty->dev) tty 1017 drivers/bluetooth/hci_intel.c if (hu->tty->dev->parent == idev->pdev->dev.parent) { tty 149 drivers/bluetooth/hci_ldisc.c struct tty_struct *tty = hu->tty; tty 163 drivers/bluetooth/hci_ldisc.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 164 drivers/bluetooth/hci_ldisc.c len = tty->ops->write(tty, skb->data, skb->len); tty 229 drivers/bluetooth/hci_ldisc.c struct tty_struct *tty = hu->tty; tty 231 drivers/bluetooth/hci_ldisc.c BT_DBG("hdev %p tty %p", hdev, tty); tty 238 drivers/bluetooth/hci_ldisc.c tty_ldisc_flush(tty); tty 239 drivers/bluetooth/hci_ldisc.c tty_driver_flush_buffer(tty); tty 302 drivers/bluetooth/hci_ldisc.c if (hu->tty->driver->ops->tiocmget && hu->tty->driver->ops->tiocmset) tty 311 drivers/bluetooth/hci_ldisc.c struct tty_struct *tty = hu->tty; tty 325 drivers/bluetooth/hci_ldisc.c ktermios = tty->termios; tty 327 drivers/bluetooth/hci_ldisc.c status = tty_set_termios(tty, &ktermios); tty 333 drivers/bluetooth/hci_ldisc.c status = tty->driver->ops->tiocmget(tty); tty 342 drivers/bluetooth/hci_ldisc.c status = tty->driver->ops->tiocmset(tty, set, clear); tty 346 drivers/bluetooth/hci_ldisc.c status = tty->driver->ops->tiocmget(tty); tty 355 drivers/bluetooth/hci_ldisc.c status = tty->driver->ops->tiocmset(tty, set, clear); tty 359 drivers/bluetooth/hci_ldisc.c ktermios = tty->termios; tty 361 drivers/bluetooth/hci_ldisc.c status = tty_set_termios(tty, &ktermios); tty 376 drivers/bluetooth/hci_ldisc.c struct tty_struct *tty = hu->tty; tty 379 drivers/bluetooth/hci_ldisc.c ktermios = tty->termios; tty 384 drivers/bluetooth/hci_ldisc.c tty_set_termios(tty, &ktermios); tty 387 drivers/bluetooth/hci_ldisc.c tty->termios.c_ispeed, tty->termios.c_ospeed); tty 477 drivers/bluetooth/hci_ldisc.c static int hci_uart_tty_open(struct tty_struct *tty) tty 481 drivers/bluetooth/hci_ldisc.c BT_DBG("tty %p", tty); tty 486 drivers/bluetooth/hci_ldisc.c if (tty->ops->write == NULL) tty 495 drivers/bluetooth/hci_ldisc.c tty->disc_data = hu; tty 496 drivers/bluetooth/hci_ldisc.c hu->tty = tty; tty 497 drivers/bluetooth/hci_ldisc.c tty->receive_room = 65536; tty 509 drivers/bluetooth/hci_ldisc.c tty_driver_flush_buffer(tty); tty 519 drivers/bluetooth/hci_ldisc.c static void hci_uart_tty_close(struct tty_struct *tty) tty 521 drivers/bluetooth/hci_ldisc.c struct hci_uart *hu = tty->disc_data; tty 524 drivers/bluetooth/hci_ldisc.c BT_DBG("tty %p", tty); tty 527 drivers/bluetooth/hci_ldisc.c tty->disc_data = NULL; tty 565 drivers/bluetooth/hci_ldisc.c static void hci_uart_tty_wakeup(struct tty_struct *tty) tty 567 drivers/bluetooth/hci_ldisc.c struct hci_uart *hu = tty->disc_data; tty 574 drivers/bluetooth/hci_ldisc.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 576 drivers/bluetooth/hci_ldisc.c if (tty != hu->tty) tty 595 drivers/bluetooth/hci_ldisc.c static void hci_uart_tty_receive(struct tty_struct *tty, const u8 *data, tty 598 drivers/bluetooth/hci_ldisc.c struct hci_uart *hu = tty->disc_data; tty 600 drivers/bluetooth/hci_ldisc.c if (!hu || tty != hu->tty) tty 619 drivers/bluetooth/hci_ldisc.c tty_unthrottle(tty); tty 653 drivers/bluetooth/hci_ldisc.c SET_HCIDEV_DEV(hdev, hu->tty->dev); tty 745 drivers/bluetooth/hci_ldisc.c static int hci_uart_tty_ioctl(struct tty_struct *tty, struct file *file, tty 748 drivers/bluetooth/hci_ldisc.c struct hci_uart *hu = tty->disc_data; tty 793 drivers/bluetooth/hci_ldisc.c err = n_tty_ioctl_helper(tty, file, cmd, arg); tty 803 drivers/bluetooth/hci_ldisc.c static ssize_t hci_uart_tty_read(struct tty_struct *tty, struct file *file, tty 809 drivers/bluetooth/hci_ldisc.c static ssize_t hci_uart_tty_write(struct tty_struct *tty, struct file *file, tty 815 drivers/bluetooth/hci_ldisc.c static __poll_t hci_uart_tty_poll(struct tty_struct *tty, tty 195 drivers/bluetooth/hci_qca.c static void __serial_clock_on(struct tty_struct *tty) tty 203 drivers/bluetooth/hci_qca.c static void __serial_clock_off(struct tty_struct *tty) tty 261 drivers/bluetooth/hci_qca.c __serial_clock_on(hu->tty); tty 263 drivers/bluetooth/hci_qca.c __serial_clock_off(hu->tty); tty 65 drivers/bluetooth/hci_uart.h struct tty_struct *tty; tty 366 drivers/char/pcmcia/synclink_cs.c static void tx_start(MGSLPC_INFO *info, struct tty_struct *tty); tty 402 drivers/char/pcmcia/synclink_cs.c static bool rx_get_frame(MGSLPC_INFO *info, struct tty_struct *tty); tty 413 drivers/char/pcmcia/synclink_cs.c static void bh_transmit(MGSLPC_INFO *info, struct tty_struct *tty); tty 419 drivers/char/pcmcia/synclink_cs.c static int tiocmget(struct tty_struct *tty); tty 420 drivers/char/pcmcia/synclink_cs.c static int tiocmset(struct tty_struct *tty, tty 424 drivers/char/pcmcia/synclink_cs.c static int set_params(MGSLPC_INFO *info, MGSL_PARAMS __user *new_params, struct tty_struct *tty); tty 427 drivers/char/pcmcia/synclink_cs.c static int set_txenable(MGSLPC_INFO *info, int enable, struct tty_struct *tty); tty 466 drivers/char/pcmcia/synclink_cs.c static void mgslpc_change_params(MGSLPC_INFO *info, struct tty_struct *tty); tty 467 drivers/char/pcmcia/synclink_cs.c static void mgslpc_wait_until_sent(struct tty_struct *tty, int timeout); tty 495 drivers/char/pcmcia/synclink_cs.c static void ldisc_receive_buf(struct tty_struct *tty, tty 499 drivers/char/pcmcia/synclink_cs.c if (!tty) tty 501 drivers/char/pcmcia/synclink_cs.c ld = tty_ldisc_ref(tty); tty 504 drivers/char/pcmcia/synclink_cs.c ld->ops->receive_buf(tty, data, flags, count); tty 704 drivers/char/pcmcia/synclink_cs.c static void tx_pause(struct tty_struct *tty) tty 706 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 709 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "tx_pause")) tty 720 drivers/char/pcmcia/synclink_cs.c static void tx_release(struct tty_struct *tty) tty 722 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 725 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "tx_release")) tty 732 drivers/char/pcmcia/synclink_cs.c tx_start(info, tty); tty 771 drivers/char/pcmcia/synclink_cs.c struct tty_struct *tty; tty 779 drivers/char/pcmcia/synclink_cs.c tty = tty_port_tty_get(&info->port); tty 791 drivers/char/pcmcia/synclink_cs.c while(rx_get_frame(info, tty)); tty 794 drivers/char/pcmcia/synclink_cs.c bh_transmit(info, tty); tty 806 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 812 drivers/char/pcmcia/synclink_cs.c static void bh_transmit(MGSLPC_INFO *info, struct tty_struct *tty) tty 817 drivers/char/pcmcia/synclink_cs.c if (tty) tty 818 drivers/char/pcmcia/synclink_cs.c tty_wakeup(tty); tty 961 drivers/char/pcmcia/synclink_cs.c static void tx_done(MGSLPC_INFO *info, struct tty_struct *tty) tty 990 drivers/char/pcmcia/synclink_cs.c if (tty && (tty->stopped || tty->hw_stopped)) { tty 998 drivers/char/pcmcia/synclink_cs.c static void tx_ready(MGSLPC_INFO *info, struct tty_struct *tty) tty 1010 drivers/char/pcmcia/synclink_cs.c if (tty && (tty->stopped || tty->hw_stopped)) { tty 1047 drivers/char/pcmcia/synclink_cs.c static void cts_change(MGSLPC_INFO *info, struct tty_struct *tty) tty 1060 drivers/char/pcmcia/synclink_cs.c if (tty && tty_port_cts_enabled(&info->port)) { tty 1061 drivers/char/pcmcia/synclink_cs.c if (tty->hw_stopped) { tty 1065 drivers/char/pcmcia/synclink_cs.c tty->hw_stopped = 0; tty 1066 drivers/char/pcmcia/synclink_cs.c tx_start(info, tty); tty 1074 drivers/char/pcmcia/synclink_cs.c tty->hw_stopped = 1; tty 1082 drivers/char/pcmcia/synclink_cs.c static void dcd_change(MGSLPC_INFO *info, struct tty_struct *tty) tty 1113 drivers/char/pcmcia/synclink_cs.c if (tty) tty 1114 drivers/char/pcmcia/synclink_cs.c tty_hangup(tty); tty 1160 drivers/char/pcmcia/synclink_cs.c struct tty_struct *tty; tty 1171 drivers/char/pcmcia/synclink_cs.c tty = tty_port_tty_get(&info->port); tty 1188 drivers/char/pcmcia/synclink_cs.c dcd_change(info, tty); tty 1190 drivers/char/pcmcia/synclink_cs.c cts_change(info, tty); tty 1208 drivers/char/pcmcia/synclink_cs.c do_SAK(tty); tty 1226 drivers/char/pcmcia/synclink_cs.c tx_done(info, tty); tty 1230 drivers/char/pcmcia/synclink_cs.c tx_done(info, tty); tty 1233 drivers/char/pcmcia/synclink_cs.c tx_ready(info, tty); tty 1257 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 1268 drivers/char/pcmcia/synclink_cs.c static int startup(MGSLPC_INFO * info, struct tty_struct *tty) tty 1302 drivers/char/pcmcia/synclink_cs.c if (capable(CAP_SYS_ADMIN) && tty) tty 1303 drivers/char/pcmcia/synclink_cs.c set_bit(TTY_IO_ERROR, &tty->flags); tty 1309 drivers/char/pcmcia/synclink_cs.c mgslpc_change_params(info, tty); tty 1311 drivers/char/pcmcia/synclink_cs.c if (tty) tty 1312 drivers/char/pcmcia/synclink_cs.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 1321 drivers/char/pcmcia/synclink_cs.c static void shutdown(MGSLPC_INFO * info, struct tty_struct *tty) tty 1352 drivers/char/pcmcia/synclink_cs.c if (!tty || C_HUPCL(tty)) { tty 1361 drivers/char/pcmcia/synclink_cs.c if (tty) tty 1362 drivers/char/pcmcia/synclink_cs.c set_bit(TTY_IO_ERROR, &tty->flags); tty 1367 drivers/char/pcmcia/synclink_cs.c static void mgslpc_program_hw(MGSLPC_INFO *info, struct tty_struct *tty) tty 1393 drivers/char/pcmcia/synclink_cs.c if (info->netcount || (tty && C_CREAD(tty))) tty 1401 drivers/char/pcmcia/synclink_cs.c static void mgslpc_change_params(MGSLPC_INFO *info, struct tty_struct *tty) tty 1406 drivers/char/pcmcia/synclink_cs.c if (!tty) tty 1413 drivers/char/pcmcia/synclink_cs.c cflag = tty->termios.c_cflag; tty 1460 drivers/char/pcmcia/synclink_cs.c info->params.data_rate = tty_get_baud_rate(tty); tty 1475 drivers/char/pcmcia/synclink_cs.c if (I_INPCK(tty)) tty 1477 drivers/char/pcmcia/synclink_cs.c if (I_IGNPAR(tty)) tty 1480 drivers/char/pcmcia/synclink_cs.c mgslpc_program_hw(info, tty); tty 1485 drivers/char/pcmcia/synclink_cs.c static int mgslpc_put_char(struct tty_struct *tty, unsigned char ch) tty 1487 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1495 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_put_char")) tty 1518 drivers/char/pcmcia/synclink_cs.c static void mgslpc_flush_chars(struct tty_struct *tty) tty 1520 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1527 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_flush_chars")) tty 1530 drivers/char/pcmcia/synclink_cs.c if (info->tx_count <= 0 || tty->stopped || tty 1531 drivers/char/pcmcia/synclink_cs.c tty->hw_stopped || !info->tx_buf) tty 1540 drivers/char/pcmcia/synclink_cs.c tx_start(info, tty); tty 1554 drivers/char/pcmcia/synclink_cs.c static int mgslpc_write(struct tty_struct * tty, tty 1558 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1565 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_write") || tty 1599 drivers/char/pcmcia/synclink_cs.c if (info->tx_count && !tty->stopped && !tty->hw_stopped) { tty 1602 drivers/char/pcmcia/synclink_cs.c tx_start(info, tty); tty 1614 drivers/char/pcmcia/synclink_cs.c static int mgslpc_write_room(struct tty_struct *tty) tty 1616 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1619 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_write_room")) tty 1642 drivers/char/pcmcia/synclink_cs.c static int mgslpc_chars_in_buffer(struct tty_struct *tty) tty 1644 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1651 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_chars_in_buffer")) tty 1668 drivers/char/pcmcia/synclink_cs.c static void mgslpc_flush_buffer(struct tty_struct *tty) tty 1670 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1677 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_flush_buffer")) tty 1685 drivers/char/pcmcia/synclink_cs.c wake_up_interruptible(&tty->write_wait); tty 1686 drivers/char/pcmcia/synclink_cs.c tty_wakeup(tty); tty 1691 drivers/char/pcmcia/synclink_cs.c static void mgslpc_send_xchar(struct tty_struct *tty, char ch) tty 1693 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1700 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_send_xchar")) tty 1707 drivers/char/pcmcia/synclink_cs.c tx_start(info, tty); tty 1714 drivers/char/pcmcia/synclink_cs.c static void mgslpc_throttle(struct tty_struct * tty) tty 1716 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1723 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_throttle")) tty 1726 drivers/char/pcmcia/synclink_cs.c if (I_IXOFF(tty)) tty 1727 drivers/char/pcmcia/synclink_cs.c mgslpc_send_xchar(tty, STOP_CHAR(tty)); tty 1729 drivers/char/pcmcia/synclink_cs.c if (C_CRTSCTS(tty)) { tty 1739 drivers/char/pcmcia/synclink_cs.c static void mgslpc_unthrottle(struct tty_struct * tty) tty 1741 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 1748 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_unthrottle")) tty 1751 drivers/char/pcmcia/synclink_cs.c if (I_IXOFF(tty)) { tty 1755 drivers/char/pcmcia/synclink_cs.c mgslpc_send_xchar(tty, START_CHAR(tty)); tty 1758 drivers/char/pcmcia/synclink_cs.c if (C_CRTSCTS(tty)) { tty 1805 drivers/char/pcmcia/synclink_cs.c static int set_params(MGSLPC_INFO * info, MGSL_PARAMS __user *new_params, struct tty_struct *tty) tty 1826 drivers/char/pcmcia/synclink_cs.c mgslpc_change_params(info, tty); tty 1887 drivers/char/pcmcia/synclink_cs.c static int set_txenable(MGSLPC_INFO * info, int enable, struct tty_struct *tty) tty 1897 drivers/char/pcmcia/synclink_cs.c tx_start(info, tty); tty 2114 drivers/char/pcmcia/synclink_cs.c static int tiocmget(struct tty_struct *tty) tty 2116 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 2139 drivers/char/pcmcia/synclink_cs.c static int tiocmset(struct tty_struct *tty, tty 2142 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 2170 drivers/char/pcmcia/synclink_cs.c static int mgslpc_break(struct tty_struct *tty, int break_state) tty 2172 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO * info = (MGSLPC_INFO *)tty->driver_data; tty 2179 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_break")) tty 2191 drivers/char/pcmcia/synclink_cs.c static int mgslpc_get_icount(struct tty_struct *tty, tty 2194 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO * info = (MGSLPC_INFO *)tty->driver_data; tty 2227 drivers/char/pcmcia/synclink_cs.c static int mgslpc_ioctl(struct tty_struct *tty, tty 2230 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO * info = (MGSLPC_INFO *)tty->driver_data; tty 2237 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_ioctl")) tty 2241 drivers/char/pcmcia/synclink_cs.c if (tty_io_error(tty)) tty 2249 drivers/char/pcmcia/synclink_cs.c return set_params(info, argp, tty); tty 2259 drivers/char/pcmcia/synclink_cs.c return set_txenable(info,(int)arg, tty); tty 2283 drivers/char/pcmcia/synclink_cs.c static void mgslpc_set_termios(struct tty_struct *tty, struct ktermios *old_termios) tty 2285 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO *info = (MGSLPC_INFO *)tty->driver_data; tty 2290 drivers/char/pcmcia/synclink_cs.c tty->driver->name); tty 2293 drivers/char/pcmcia/synclink_cs.c if ((tty->termios.c_cflag == old_termios->c_cflag) tty 2294 drivers/char/pcmcia/synclink_cs.c && (RELEVANT_IFLAG(tty->termios.c_iflag) tty 2298 drivers/char/pcmcia/synclink_cs.c mgslpc_change_params(info, tty); tty 2301 drivers/char/pcmcia/synclink_cs.c if ((old_termios->c_cflag & CBAUD) && !C_BAUD(tty)) { tty 2309 drivers/char/pcmcia/synclink_cs.c if (!(old_termios->c_cflag & CBAUD) && C_BAUD(tty)) { tty 2311 drivers/char/pcmcia/synclink_cs.c if (!C_CRTSCTS(tty) || !tty_throttled(tty)) tty 2319 drivers/char/pcmcia/synclink_cs.c if (old_termios->c_cflag & CRTSCTS && !C_CRTSCTS(tty)) { tty 2320 drivers/char/pcmcia/synclink_cs.c tty->hw_stopped = 0; tty 2321 drivers/char/pcmcia/synclink_cs.c tx_release(tty); tty 2325 drivers/char/pcmcia/synclink_cs.c static void mgslpc_close(struct tty_struct *tty, struct file * filp) tty 2327 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO * info = (MGSLPC_INFO *)tty->driver_data; tty 2330 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_close")) tty 2337 drivers/char/pcmcia/synclink_cs.c if (tty_port_close_start(port, tty, filp) == 0) tty 2341 drivers/char/pcmcia/synclink_cs.c mgslpc_wait_until_sent(tty, info->timeout); tty 2343 drivers/char/pcmcia/synclink_cs.c mgslpc_flush_buffer(tty); tty 2345 drivers/char/pcmcia/synclink_cs.c tty_ldisc_flush(tty); tty 2346 drivers/char/pcmcia/synclink_cs.c shutdown(info, tty); tty 2348 drivers/char/pcmcia/synclink_cs.c tty_port_close_end(port, tty); tty 2353 drivers/char/pcmcia/synclink_cs.c tty->driver->name, port->count); tty 2358 drivers/char/pcmcia/synclink_cs.c static void mgslpc_wait_until_sent(struct tty_struct *tty, int timeout) tty 2360 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO * info = (MGSLPC_INFO *)tty->driver_data; tty 2370 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_wait_until_sent")) tty 2422 drivers/char/pcmcia/synclink_cs.c static void mgslpc_hangup(struct tty_struct *tty) tty 2424 drivers/char/pcmcia/synclink_cs.c MGSLPC_INFO * info = (MGSLPC_INFO *)tty->driver_data; tty 2430 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_hangup")) tty 2433 drivers/char/pcmcia/synclink_cs.c mgslpc_flush_buffer(tty); tty 2434 drivers/char/pcmcia/synclink_cs.c shutdown(info, tty); tty 2467 drivers/char/pcmcia/synclink_cs.c static int mgslpc_open(struct tty_struct *tty, struct file * filp) tty 2475 drivers/char/pcmcia/synclink_cs.c line = tty->index; tty 2486 drivers/char/pcmcia/synclink_cs.c if (mgslpc_paranoia_check(info, tty->name, "mgslpc_open")) tty 2490 drivers/char/pcmcia/synclink_cs.c tty->driver_data = info; tty 2491 drivers/char/pcmcia/synclink_cs.c tty_port_tty_set(port, tty); tty 2495 drivers/char/pcmcia/synclink_cs.c __FILE__, __LINE__, tty->driver->name, port->count); tty 2512 drivers/char/pcmcia/synclink_cs.c retval = startup(info, tty); tty 2517 drivers/char/pcmcia/synclink_cs.c retval = tty_port_block_til_ready(&info->port, tty, filp); tty 3284 drivers/char/pcmcia/synclink_cs.c static void tx_start(MGSLPC_INFO *info, struct tty_struct *tty) tty 3308 drivers/char/pcmcia/synclink_cs.c tx_ready(info, tty); tty 3312 drivers/char/pcmcia/synclink_cs.c tx_ready(info, tty); tty 3633 drivers/char/pcmcia/synclink_cs.c static bool rx_get_frame(MGSLPC_INFO *info, struct tty_struct *tty) tty 3702 drivers/char/pcmcia/synclink_cs.c ldisc_receive_buf(tty, buf->data, info->flag_buf, framesize); tty 3859 drivers/char/pcmcia/synclink_cs.c struct tty_struct *tty = tty_port_tty_get(&info->port); tty 3860 drivers/char/pcmcia/synclink_cs.c bh_transmit(info, tty); tty 3861 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 3881 drivers/char/pcmcia/synclink_cs.c struct tty_struct *tty; tty 3912 drivers/char/pcmcia/synclink_cs.c tty = tty_port_tty_get(&info->port); tty 3913 drivers/char/pcmcia/synclink_cs.c mgslpc_program_hw(info, tty); tty 3914 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 3956 drivers/char/pcmcia/synclink_cs.c struct tty_struct *tty = tty_port_tty_get(&info->port); tty 3957 drivers/char/pcmcia/synclink_cs.c tx_start(info, tty); tty 3958 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 3976 drivers/char/pcmcia/synclink_cs.c struct tty_struct *tty; tty 3998 drivers/char/pcmcia/synclink_cs.c tty = tty_port_tty_get(&info->port); tty 4000 drivers/char/pcmcia/synclink_cs.c rc = startup(info, tty); tty 4002 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 4010 drivers/char/pcmcia/synclink_cs.c mgslpc_program_hw(info, tty); tty 4011 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 4039 drivers/char/pcmcia/synclink_cs.c struct tty_struct *tty = tty_port_tty_get(&info->port); tty 4048 drivers/char/pcmcia/synclink_cs.c shutdown(info, tty); tty 4049 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 4156 drivers/char/pcmcia/synclink_cs.c struct tty_struct *tty = tty_port_tty_get(&info->port); tty 4157 drivers/char/pcmcia/synclink_cs.c mgslpc_program_hw(info, tty); tty 4158 drivers/char/pcmcia/synclink_cs.c tty_kref_put(tty); tty 90 drivers/char/ttyprintk.c static int tpk_open(struct tty_struct *tty, struct file *filp) tty 92 drivers/char/ttyprintk.c tty->driver_data = &tpk_port; tty 94 drivers/char/ttyprintk.c return tty_port_open(&tpk_port.port, tty, filp); tty 100 drivers/char/ttyprintk.c static void tpk_close(struct tty_struct *tty, struct file *filp) tty 102 drivers/char/ttyprintk.c struct ttyprintk_port *tpkp = tty->driver_data; tty 110 drivers/char/ttyprintk.c tty_port_close(&tpkp->port, tty, filp); tty 116 drivers/char/ttyprintk.c static int tpk_write(struct tty_struct *tty, tty 119 drivers/char/ttyprintk.c struct ttyprintk_port *tpkp = tty->driver_data; tty 135 drivers/char/ttyprintk.c static int tpk_write_room(struct tty_struct *tty) tty 143 drivers/char/ttyprintk.c static int tpk_ioctl(struct tty_struct *tty, tty 146 drivers/char/ttyprintk.c struct ttyprintk_port *tpkp = tty->driver_data; tty 32 drivers/input/serio/serport.c struct tty_struct *tty; tty 47 drivers/input/serio/serport.c return -(serport->tty->ops->write(serport->tty, &data, 1) != 1); tty 78 drivers/input/serio/serport.c static int serport_ldisc_open(struct tty_struct *tty) tty 89 drivers/input/serio/serport.c serport->tty = tty; tty 93 drivers/input/serio/serport.c tty->disc_data = serport; tty 94 drivers/input/serio/serport.c tty->receive_room = 256; tty 95 drivers/input/serio/serport.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 104 drivers/input/serio/serport.c static void serport_ldisc_close(struct tty_struct *tty) tty 106 drivers/input/serio/serport.c struct serport *serport = (struct serport *) tty->disc_data; tty 117 drivers/input/serio/serport.c static void serport_ldisc_receive(struct tty_struct *tty, const unsigned char *cp, char *fp, int count) tty 119 drivers/input/serio/serport.c struct serport *serport = (struct serport*) tty->disc_data; tty 159 drivers/input/serio/serport.c static ssize_t serport_ldisc_read(struct tty_struct * tty, struct file * file, unsigned char __user * buf, size_t nr) tty 161 drivers/input/serio/serport.c struct serport *serport = (struct serport*) tty->disc_data; tty 172 drivers/input/serio/serport.c snprintf(serio->phys, sizeof(serio->phys), "%s/serio0", tty_name(tty)); tty 179 drivers/input/serio/serport.c serio->dev.parent = tty->dev; tty 182 drivers/input/serio/serport.c printk(KERN_INFO "serio: Serial port %s\n", tty_name(tty)); tty 194 drivers/input/serio/serport.c static void serport_set_type(struct tty_struct *tty, unsigned long type) tty 196 drivers/input/serio/serport.c struct serport *serport = tty->disc_data; tty 207 drivers/input/serio/serport.c static int serport_ldisc_ioctl(struct tty_struct *tty, struct file *file, tty 216 drivers/input/serio/serport.c serport_set_type(tty, type); tty 225 drivers/input/serio/serport.c static int serport_ldisc_compat_ioctl(struct tty_struct *tty, tty 236 drivers/input/serio/serport.c serport_set_type(tty, compat_type); tty 244 drivers/input/serio/serport.c static int serport_ldisc_hangup(struct tty_struct *tty) tty 246 drivers/input/serio/serport.c struct serport *serport = (struct serport *) tty->disc_data; tty 257 drivers/input/serio/serport.c static void serport_ldisc_write_wakeup(struct tty_struct * tty) tty 259 drivers/input/serio/serport.c struct serport *serport = (struct serport *) tty->disc_data; tty 71 drivers/ipack/devices/ipoctal.c static int ipoctal_port_activate(struct tty_port *port, struct tty_struct *tty) tty 75 drivers/ipack/devices/ipoctal.c channel = dev_get_drvdata(tty->dev); tty 86 drivers/ipack/devices/ipoctal.c static int ipoctal_open(struct tty_struct *tty, struct file *file) tty 88 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = dev_get_drvdata(tty->dev); tty 89 drivers/ipack/devices/ipoctal.c struct ipoctal *ipoctal = chan_to_ipoctal(channel, tty->index); tty 92 drivers/ipack/devices/ipoctal.c tty->driver_data = channel; tty 97 drivers/ipack/devices/ipoctal.c err = tty_port_open(&channel->tty_port, tty, file); tty 122 drivers/ipack/devices/ipoctal.c static void ipoctal_close(struct tty_struct *tty, struct file *filp) tty 124 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 126 drivers/ipack/devices/ipoctal.c tty_port_close(&channel->tty_port, tty, filp); tty 130 drivers/ipack/devices/ipoctal.c static int ipoctal_get_icount(struct tty_struct *tty, tty 133 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 268 drivers/ipack/devices/ipoctal.c struct tty_driver *tty; tty 352 drivers/ipack/devices/ipoctal.c tty = alloc_tty_driver(NR_CHANNELS); tty 354 drivers/ipack/devices/ipoctal.c if (!tty) tty 358 drivers/ipack/devices/ipoctal.c tty->owner = THIS_MODULE; tty 359 drivers/ipack/devices/ipoctal.c tty->driver_name = KBUILD_MODNAME; tty 361 drivers/ipack/devices/ipoctal.c tty->name = name; tty 362 drivers/ipack/devices/ipoctal.c tty->major = 0; tty 364 drivers/ipack/devices/ipoctal.c tty->minor_start = 0; tty 365 drivers/ipack/devices/ipoctal.c tty->type = TTY_DRIVER_TYPE_SERIAL; tty 366 drivers/ipack/devices/ipoctal.c tty->subtype = SERIAL_TYPE_NORMAL; tty 367 drivers/ipack/devices/ipoctal.c tty->flags = TTY_DRIVER_REAL_RAW | TTY_DRIVER_DYNAMIC_DEV; tty 368 drivers/ipack/devices/ipoctal.c tty->init_termios = tty_std_termios; tty 369 drivers/ipack/devices/ipoctal.c tty->init_termios.c_cflag = B9600 | CS8 | CREAD | HUPCL | CLOCAL; tty 370 drivers/ipack/devices/ipoctal.c tty->init_termios.c_ispeed = 9600; tty 371 drivers/ipack/devices/ipoctal.c tty->init_termios.c_ospeed = 9600; tty 373 drivers/ipack/devices/ipoctal.c tty_set_operations(tty, &ipoctal_fops); tty 374 drivers/ipack/devices/ipoctal.c res = tty_register_driver(tty); tty 377 drivers/ipack/devices/ipoctal.c put_tty_driver(tty); tty 382 drivers/ipack/devices/ipoctal.c ipoctal->tty_drv = tty; tty 397 drivers/ipack/devices/ipoctal.c tty_dev = tty_port_register_device(&channel->tty_port, tty, i, NULL); tty 440 drivers/ipack/devices/ipoctal.c static int ipoctal_write_tty(struct tty_struct *tty, tty 443 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 463 drivers/ipack/devices/ipoctal.c static int ipoctal_write_room(struct tty_struct *tty) tty 465 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 470 drivers/ipack/devices/ipoctal.c static int ipoctal_chars_in_buffer(struct tty_struct *tty) tty 472 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 477 drivers/ipack/devices/ipoctal.c static void ipoctal_set_termios(struct tty_struct *tty, tty 484 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 487 drivers/ipack/devices/ipoctal.c cflag = tty->termios.c_cflag; tty 504 drivers/ipack/devices/ipoctal.c tty->termios.c_cflag = (cflag & ~CSIZE) | CS8; tty 518 drivers/ipack/devices/ipoctal.c tty->termios.c_cflag &= ~CMSPAR; tty 550 drivers/ipack/devices/ipoctal.c baud = tty_get_baud_rate(tty); tty 551 drivers/ipack/devices/ipoctal.c tty_termios_encode_baud_rate(&tty->termios, baud, baud); tty 595 drivers/ipack/devices/ipoctal.c tty_termios_encode_baud_rate(&tty->termios, 38400, 38400); tty 612 drivers/ipack/devices/ipoctal.c static void ipoctal_hangup(struct tty_struct *tty) tty 615 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 633 drivers/ipack/devices/ipoctal.c static void ipoctal_shutdown(struct tty_struct *tty) tty 635 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 644 drivers/ipack/devices/ipoctal.c static void ipoctal_cleanup(struct tty_struct *tty) tty 646 drivers/ipack/devices/ipoctal.c struct ipoctal_channel *channel = tty->driver_data; tty 647 drivers/ipack/devices/ipoctal.c struct ipoctal *ipoctal = chan_to_ipoctal(channel, tty->index); tty 304 drivers/isdn/capi/capi.c struct tty_struct *tty; tty 307 drivers/isdn/capi/capi.c tty = tty_port_tty_get(&mp->port); tty 308 drivers/isdn/capi/capi.c if (tty) { tty 309 drivers/isdn/capi/capi.c tty_vhangup(tty); tty 310 drivers/isdn/capi/capi.c tty_kref_put(tty); tty 321 drivers/isdn/capi/capi.c struct tty_struct *tty; tty 324 drivers/isdn/capi/capi.c tty = tty_port_tty_get(&mp->port); tty 325 drivers/isdn/capi/capi.c if (tty) { tty 326 drivers/isdn/capi/capi.c count = tty->count; tty 327 drivers/isdn/capi/capi.c tty_kref_put(tty); tty 405 drivers/isdn/capi/capi.c struct tty_struct *tty; tty 411 drivers/isdn/capi/capi.c tty = tty_port_tty_get(&mp->port); tty 412 drivers/isdn/capi/capi.c if (!tty) { tty 417 drivers/isdn/capi/capi.c ld = tty_ldisc_ref(tty); tty 435 drivers/isdn/capi/capi.c if (tty->receive_room < datalen) { tty 454 drivers/isdn/capi/capi.c ld->ops->receive_buf(tty, skb->data, NULL, skb->len); tty 472 drivers/isdn/capi/capi.c tty_kref_put(tty); tty 489 drivers/isdn/capi/capi.c struct tty_struct *tty; tty 495 drivers/isdn/capi/capi.c tty = tty_port_tty_get(&mp->port); tty 496 drivers/isdn/capi/capi.c if (!tty) tty 501 drivers/isdn/capi/capi.c tty_kref_put(tty); tty 563 drivers/isdn/capi/capi.c tty_kref_put(tty); tty 1007 drivers/isdn/capi/capi.c capinc_tty_install(struct tty_driver *driver, struct tty_struct *tty) tty 1009 drivers/isdn/capi/capi.c struct capiminor *mp = capiminor_get(tty->index); tty 1010 drivers/isdn/capi/capi.c int ret = tty_standard_install(driver, tty); tty 1013 drivers/isdn/capi/capi.c tty->driver_data = mp; tty 1019 drivers/isdn/capi/capi.c static void capinc_tty_cleanup(struct tty_struct *tty) tty 1021 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1022 drivers/isdn/capi/capi.c tty->driver_data = NULL; tty 1026 drivers/isdn/capi/capi.c static int capinc_tty_open(struct tty_struct *tty, struct file *filp) tty 1028 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1031 drivers/isdn/capi/capi.c err = tty_port_open(&mp->port, tty, filp); tty 1039 drivers/isdn/capi/capi.c static void capinc_tty_close(struct tty_struct *tty, struct file *filp) tty 1041 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1043 drivers/isdn/capi/capi.c tty_port_close(&mp->port, tty, filp); tty 1046 drivers/isdn/capi/capi.c static int capinc_tty_write(struct tty_struct *tty, tty 1049 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1081 drivers/isdn/capi/capi.c static int capinc_tty_put_char(struct tty_struct *tty, unsigned char ch) tty 1083 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1122 drivers/isdn/capi/capi.c static void capinc_tty_flush_chars(struct tty_struct *tty) tty 1124 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1144 drivers/isdn/capi/capi.c static int capinc_tty_write_room(struct tty_struct *tty) tty 1146 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1155 drivers/isdn/capi/capi.c static int capinc_tty_chars_in_buffer(struct tty_struct *tty) tty 1157 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1166 drivers/isdn/capi/capi.c static void capinc_tty_set_termios(struct tty_struct *tty, struct ktermios *old) tty 1171 drivers/isdn/capi/capi.c static void capinc_tty_throttle(struct tty_struct *tty) tty 1173 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1178 drivers/isdn/capi/capi.c static void capinc_tty_unthrottle(struct tty_struct *tty) tty 1180 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1187 drivers/isdn/capi/capi.c static void capinc_tty_stop(struct tty_struct *tty) tty 1189 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1195 drivers/isdn/capi/capi.c static void capinc_tty_start(struct tty_struct *tty) tty 1197 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1204 drivers/isdn/capi/capi.c static void capinc_tty_hangup(struct tty_struct *tty) tty 1206 drivers/isdn/capi/capi.c struct capiminor *mp = tty->driver_data; tty 1212 drivers/isdn/capi/capi.c static int capinc_tty_break_ctl(struct tty_struct *tty, int state) tty 1218 drivers/isdn/capi/capi.c static void capinc_tty_flush_buffer(struct tty_struct *tty) tty 1223 drivers/isdn/capi/capi.c static void capinc_tty_set_ldisc(struct tty_struct *tty) tty 1228 drivers/isdn/capi/capi.c static void capinc_tty_send_xchar(struct tty_struct *tty, char ch) tty 342 drivers/media/platform/sti/bdisp/bdisp-debug.c bdisp_dbg_dump_tty(s, node->tty); tty 830 drivers/media/platform/sti/bdisp/bdisp-hw.c node->tty = dst->bytesperline; tty 831 drivers/media/platform/sti/bdisp/bdisp-hw.c node->tty |= bdisp_hw_color_format(dst_fmt); tty 832 drivers/media/platform/sti/bdisp/bdisp-hw.c node->tty |= BLT_TTY_DITHER; tty 833 drivers/media/platform/sti/bdisp/bdisp-hw.c node->tty |= (t_plan == BDISP_CBCR) ? BLT_TTY_CHROMA : 0; tty 834 drivers/media/platform/sti/bdisp/bdisp-hw.c node->tty |= cfg->hflip ? BLT_TTY_HSO : 0; tty 835 drivers/media/platform/sti/bdisp/bdisp-hw.c node->tty |= cfg->vflip ? BLT_TTY_VSO : 0; tty 15 drivers/media/platform/sti/bdisp/bdisp-reg.h u32 tty; tty 413 drivers/misc/pti.c static int pti_tty_driver_open(struct tty_struct *tty, struct file *filp) tty 422 drivers/misc/pti.c return tty_port_open(tty->port, tty, filp); tty 436 drivers/misc/pti.c static void pti_tty_driver_close(struct tty_struct *tty, struct file *filp) tty 438 drivers/misc/pti.c tty_port_close(tty->port, tty, filp); tty 453 drivers/misc/pti.c static int pti_tty_install(struct tty_driver *driver, struct tty_struct *tty) tty 455 drivers/misc/pti.c int idx = tty->index; tty 457 drivers/misc/pti.c int ret = tty_standard_install(driver, tty); tty 473 drivers/misc/pti.c tty->driver_data = pti_tty_data; tty 485 drivers/misc/pti.c static void pti_tty_cleanup(struct tty_struct *tty) tty 487 drivers/misc/pti.c struct pti_tty *pti_tty_data = tty->driver_data; tty 492 drivers/misc/pti.c tty->driver_data = NULL; tty 508 drivers/misc/pti.c static int pti_tty_driver_write(struct tty_struct *tty, tty 511 drivers/misc/pti.c struct pti_tty *pti_tty_data = tty->driver_data; tty 529 drivers/misc/pti.c static int pti_tty_write_room(struct tty_struct *tty) tty 747 drivers/misc/pti.c static int pti_port_activate(struct tty_port *port, struct tty_struct *tty) tty 749 drivers/misc/pti.c if (port->tty->index == PTITTY_MINOR_START) tty 766 drivers/misc/pti.c if (port->tty->index == PTITTY_MINOR_START) tty 54 drivers/misc/ti-st/st_core.c struct tty_struct *tty; tty 55 drivers/misc/ti-st/st_core.c if (unlikely(st_gdata == NULL || st_gdata->tty == NULL)) { tty 59 drivers/misc/ti-st/st_core.c tty = st_gdata->tty; tty 60 drivers/misc/ti-st/st_core.c return tty->ops->write_room(tty); tty 73 drivers/misc/ti-st/st_core.c struct tty_struct *tty; tty 74 drivers/misc/ti-st/st_core.c if (unlikely(st_gdata == NULL || st_gdata->tty == NULL)) { tty 78 drivers/misc/ti-st/st_core.c tty = st_gdata->tty; tty 83 drivers/misc/ti-st/st_core.c return tty->ops->write(tty, data, count); tty 479 drivers/misc/ti-st/st_core.c set_bit(TTY_DO_WRITE_WAKEUP, &st_data->tty->flags); tty 661 drivers/misc/ti-st/st_core.c if (st_gdata->tty) { tty 662 drivers/misc/ti-st/st_core.c tty_ldisc_flush(st_gdata->tty); tty 663 drivers/misc/ti-st/st_core.c stop_tty(st_gdata->tty); tty 685 drivers/misc/ti-st/st_core.c || st_gdata->tty == NULL)) { tty 709 drivers/misc/ti-st/st_core.c static int st_tty_open(struct tty_struct *tty) tty 716 drivers/misc/ti-st/st_core.c st_gdata->tty = tty; tty 717 drivers/misc/ti-st/st_core.c tty->disc_data = st_gdata; tty 720 drivers/misc/ti-st/st_core.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 724 drivers/misc/ti-st/st_core.c tty->receive_room = 65536; tty 726 drivers/misc/ti-st/st_core.c tty_ldisc_flush(tty); tty 727 drivers/misc/ti-st/st_core.c tty_driver_flush_buffer(tty); tty 737 drivers/misc/ti-st/st_core.c static void st_tty_close(struct tty_struct *tty) tty 741 drivers/misc/ti-st/st_core.c struct st_data_s *st_gdata = tty->disc_data; tty 763 drivers/misc/ti-st/st_core.c st_gdata->tty = NULL; tty 765 drivers/misc/ti-st/st_core.c tty_ldisc_flush(tty); tty 766 drivers/misc/ti-st/st_core.c tty_driver_flush_buffer(tty); tty 782 drivers/misc/ti-st/st_core.c static void st_tty_receive(struct tty_struct *tty, const unsigned char *data, tty 794 drivers/misc/ti-st/st_core.c st_recv(tty->disc_data, data, count); tty 801 drivers/misc/ti-st/st_core.c static void st_tty_wakeup(struct tty_struct *tty) tty 803 drivers/misc/ti-st/st_core.c struct st_data_s *st_gdata = tty->disc_data; tty 806 drivers/misc/ti-st/st_core.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 816 drivers/misc/ti-st/st_core.c static void st_tty_flush_buffer(struct tty_struct *tty) tty 818 drivers/misc/ti-st/st_core.c struct st_data_s *st_gdata = tty->disc_data; tty 824 drivers/misc/ti-st/st_core.c tty_driver_flush_buffer(tty); tty 514 drivers/misc/ti-st/st_kim.c struct tty_struct *tty = kim_gdata->core_data->tty; tty 518 drivers/misc/ti-st/st_kim.c if (tty) { /* can be called before ldisc is installed */ tty 520 drivers/misc/ti-st/st_kim.c tty_ldisc_flush(tty); tty 521 drivers/misc/ti-st/st_kim.c tty_driver_flush_buffer(tty); tty 428 drivers/mmc/core/sdio_uart.c struct tty_struct *tty; tty 439 drivers/mmc/core/sdio_uart.c tty = tty_port_tty_get(&port->port); tty 441 drivers/mmc/core/sdio_uart.c if (tty == NULL || !kfifo_len(xmit) || tty 442 drivers/mmc/core/sdio_uart.c tty->stopped || tty->hw_stopped) { tty 444 drivers/mmc/core/sdio_uart.c tty_kref_put(tty); tty 456 drivers/mmc/core/sdio_uart.c tty_wakeup(tty); tty 460 drivers/mmc/core/sdio_uart.c tty_kref_put(tty); tty 466 drivers/mmc/core/sdio_uart.c struct tty_struct *tty; tty 489 drivers/mmc/core/sdio_uart.c tty = tty_port_tty_get(&port->port); tty 490 drivers/mmc/core/sdio_uart.c if (tty && C_CRTSCTS(tty)) { tty 492 drivers/mmc/core/sdio_uart.c if (tty->hw_stopped) { tty 494 drivers/mmc/core/sdio_uart.c tty->hw_stopped = 0; tty 496 drivers/mmc/core/sdio_uart.c tty_wakeup(tty); tty 500 drivers/mmc/core/sdio_uart.c tty->hw_stopped = 1; tty 505 drivers/mmc/core/sdio_uart.c tty_kref_put(tty); tty 594 drivers/mmc/core/sdio_uart.c static int sdio_uart_activate(struct tty_port *tport, struct tty_struct *tty) tty 604 drivers/mmc/core/sdio_uart.c set_bit(TTY_IO_ERROR, &tty->flags); tty 643 drivers/mmc/core/sdio_uart.c sdio_uart_change_speed(port, &tty->termios, NULL); tty 645 drivers/mmc/core/sdio_uart.c if (C_BAUD(tty)) tty 648 drivers/mmc/core/sdio_uart.c if (C_CRTSCTS(tty)) tty 650 drivers/mmc/core/sdio_uart.c tty->hw_stopped = 1; tty 652 drivers/mmc/core/sdio_uart.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 726 drivers/mmc/core/sdio_uart.c static int sdio_uart_install(struct tty_driver *driver, struct tty_struct *tty) tty 728 drivers/mmc/core/sdio_uart.c int idx = tty->index; tty 730 drivers/mmc/core/sdio_uart.c int ret = tty_standard_install(driver, tty); tty 734 drivers/mmc/core/sdio_uart.c tty->driver_data = port; tty 748 drivers/mmc/core/sdio_uart.c static void sdio_uart_cleanup(struct tty_struct *tty) tty 750 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 751 drivers/mmc/core/sdio_uart.c tty->driver_data = NULL; /* Bug trap */ tty 759 drivers/mmc/core/sdio_uart.c static int sdio_uart_open(struct tty_struct *tty, struct file *filp) tty 761 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 762 drivers/mmc/core/sdio_uart.c return tty_port_open(&port->port, tty, filp); tty 765 drivers/mmc/core/sdio_uart.c static void sdio_uart_close(struct tty_struct *tty, struct file * filp) tty 767 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 768 drivers/mmc/core/sdio_uart.c tty_port_close(&port->port, tty, filp); tty 771 drivers/mmc/core/sdio_uart.c static void sdio_uart_hangup(struct tty_struct *tty) tty 773 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 777 drivers/mmc/core/sdio_uart.c static int sdio_uart_write(struct tty_struct *tty, const unsigned char *buf, tty 780 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 800 drivers/mmc/core/sdio_uart.c static int sdio_uart_write_room(struct tty_struct *tty) tty 802 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 806 drivers/mmc/core/sdio_uart.c static int sdio_uart_chars_in_buffer(struct tty_struct *tty) tty 808 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 812 drivers/mmc/core/sdio_uart.c static void sdio_uart_send_xchar(struct tty_struct *tty, char ch) tty 814 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 826 drivers/mmc/core/sdio_uart.c static void sdio_uart_throttle(struct tty_struct *tty) tty 828 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 830 drivers/mmc/core/sdio_uart.c if (!I_IXOFF(tty) && !C_CRTSCTS(tty)) tty 836 drivers/mmc/core/sdio_uart.c if (I_IXOFF(tty)) { tty 837 drivers/mmc/core/sdio_uart.c port->x_char = STOP_CHAR(tty); tty 841 drivers/mmc/core/sdio_uart.c if (C_CRTSCTS(tty)) tty 848 drivers/mmc/core/sdio_uart.c static void sdio_uart_unthrottle(struct tty_struct *tty) tty 850 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 852 drivers/mmc/core/sdio_uart.c if (!I_IXOFF(tty) && !C_CRTSCTS(tty)) tty 858 drivers/mmc/core/sdio_uart.c if (I_IXOFF(tty)) { tty 862 drivers/mmc/core/sdio_uart.c port->x_char = START_CHAR(tty); tty 867 drivers/mmc/core/sdio_uart.c if (C_CRTSCTS(tty)) tty 874 drivers/mmc/core/sdio_uart.c static void sdio_uart_set_termios(struct tty_struct *tty, tty 877 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 878 drivers/mmc/core/sdio_uart.c unsigned int cflag = tty->termios.c_cflag; tty 883 drivers/mmc/core/sdio_uart.c sdio_uart_change_speed(port, &tty->termios, old_termios); tty 892 drivers/mmc/core/sdio_uart.c if (!(cflag & CRTSCTS) || !tty_throttled(tty)) tty 899 drivers/mmc/core/sdio_uart.c tty->hw_stopped = 0; tty 906 drivers/mmc/core/sdio_uart.c tty->hw_stopped = 1; tty 914 drivers/mmc/core/sdio_uart.c static int sdio_uart_break_ctl(struct tty_struct *tty, int break_state) tty 916 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 933 drivers/mmc/core/sdio_uart.c static int sdio_uart_tiocmget(struct tty_struct *tty) tty 935 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 947 drivers/mmc/core/sdio_uart.c static int sdio_uart_tiocmset(struct tty_struct *tty, tty 950 drivers/mmc/core/sdio_uart.c struct sdio_uart_port *port = tty->driver_data; tty 70 drivers/net/caif/caif_serial.c struct tty_struct *tty; tty 85 drivers/net/caif/caif_serial.c static void ldisc_tx_wakeup(struct tty_struct *tty); tty 90 drivers/net/caif/caif_serial.c ser->tty->stopped << 5 | tty 91 drivers/net/caif/caif_serial.c ser->tty->flow_stopped << 3 | tty 92 drivers/net/caif/caif_serial.c ser->tty->packet << 2 | tty 93 drivers/net/caif/caif_serial.c ser->tty->port->low_latency << 1; tty 95 drivers/net/caif/caif_serial.c static inline void debugfs_init(struct ser_device *ser, struct tty_struct *tty) tty 97 drivers/net/caif/caif_serial.c ser->debugfs_tty_dir = debugfs_create_dir(tty->name, debugfsdir); tty 140 drivers/net/caif/caif_serial.c static inline void debugfs_init(struct ser_device *ser, struct tty_struct *tty) tty 162 drivers/net/caif/caif_serial.c static void ldisc_receive(struct tty_struct *tty, const u8 *data, tty 169 drivers/net/caif/caif_serial.c ser = tty->disc_data; tty 211 drivers/net/caif/caif_serial.c struct tty_struct *tty; tty 215 drivers/net/caif/caif_serial.c tty = ser->tty; tty 227 drivers/net/caif/caif_serial.c room = tty_write_room(tty); tty 237 drivers/net/caif/caif_serial.c tty_wr = tty->ops->write(tty, skb->data, len); tty 241 drivers/net/caif/caif_serial.c ldisc_receive(tty, skb->data, NULL, len); tty 288 drivers/net/caif/caif_serial.c static void ldisc_tx_wakeup(struct tty_struct *tty) tty 292 drivers/net/caif/caif_serial.c ser = tty->disc_data; tty 294 drivers/net/caif/caif_serial.c WARN_ON(ser->tty != tty); tty 321 drivers/net/caif/caif_serial.c static int ldisc_open(struct tty_struct *tty) tty 329 drivers/net/caif/caif_serial.c if (tty->ops->write == NULL) tty 337 drivers/net/caif/caif_serial.c result = snprintf(name, sizeof(name), "cf%s", tty->name); tty 346 drivers/net/caif/caif_serial.c ser->tty = tty_kref_get(tty); tty 348 drivers/net/caif/caif_serial.c debugfs_init(ser, tty); tty 349 drivers/net/caif/caif_serial.c tty->receive_room = N_TTY_BUF_SIZE; tty 350 drivers/net/caif/caif_serial.c tty->disc_data = ser; tty 351 drivers/net/caif/caif_serial.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 369 drivers/net/caif/caif_serial.c static void ldisc_close(struct tty_struct *tty) tty 371 drivers/net/caif/caif_serial.c struct ser_device *ser = tty->disc_data; tty 373 drivers/net/caif/caif_serial.c tty_kref_put(ser->tty); tty 84 drivers/net/can/slcan.c struct tty_struct *tty; /* ptr to TTY structure */ tty 303 drivers/net/can/slcan.c set_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 304 drivers/net/can/slcan.c actual = sl->tty->ops->write(sl->tty, sl->xbuff, pos - sl->xbuff); tty 318 drivers/net/can/slcan.c if (!sl->tty || sl->magic != SLCAN_MAGIC || !netif_running(sl->dev)) { tty 327 drivers/net/can/slcan.c clear_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 333 drivers/net/can/slcan.c actual = sl->tty->ops->write(sl->tty, sl->xhead, sl->xleft); tty 343 drivers/net/can/slcan.c static void slcan_write_wakeup(struct tty_struct *tty) tty 348 drivers/net/can/slcan.c sl = rcu_dereference(tty->disc_data); tty 371 drivers/net/can/slcan.c if (sl->tty == NULL) { tty 396 drivers/net/can/slcan.c if (sl->tty) { tty 398 drivers/net/can/slcan.c clear_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 413 drivers/net/can/slcan.c if (sl->tty == NULL) tty 472 drivers/net/can/slcan.c static void slcan_receive_buf(struct tty_struct *tty, tty 475 drivers/net/can/slcan.c struct slcan *sl = (struct slcan *) tty->disc_data; tty 509 drivers/net/can/slcan.c if (sl->tty) tty 566 drivers/net/can/slcan.c static int slcan_open(struct tty_struct *tty) tty 574 drivers/net/can/slcan.c if (tty->ops->write == NULL) tty 586 drivers/net/can/slcan.c sl = tty->disc_data; tty 599 drivers/net/can/slcan.c sl->tty = tty; tty 600 drivers/net/can/slcan.c tty->disc_data = sl; tty 616 drivers/net/can/slcan.c tty->receive_room = 65536; /* We don't flow control */ tty 622 drivers/net/can/slcan.c sl->tty = NULL; tty 623 drivers/net/can/slcan.c tty->disc_data = NULL; tty 646 drivers/net/can/slcan.c static void slcan_close(struct tty_struct *tty) tty 648 drivers/net/can/slcan.c struct slcan *sl = (struct slcan *) tty->disc_data; tty 651 drivers/net/can/slcan.c if (!sl || sl->magic != SLCAN_MAGIC || sl->tty != tty) tty 655 drivers/net/can/slcan.c rcu_assign_pointer(tty->disc_data, NULL); tty 656 drivers/net/can/slcan.c sl->tty = NULL; tty 667 drivers/net/can/slcan.c static int slcan_hangup(struct tty_struct *tty) tty 669 drivers/net/can/slcan.c slcan_close(tty); tty 674 drivers/net/can/slcan.c static int slcan_ioctl(struct tty_struct *tty, struct file *file, tty 677 drivers/net/can/slcan.c struct slcan *sl = (struct slcan *) tty->disc_data; tty 695 drivers/net/can/slcan.c return tty_mode_ioctl(tty, file, cmd, arg); tty 758 drivers/net/can/slcan.c if (sl->tty) { tty 760 drivers/net/can/slcan.c tty_hangup(sl->tty); tty 776 drivers/net/can/slcan.c if (sl->tty) { tty 87 drivers/net/hamradio/6pack.c struct tty_struct *tty; /* ptr to TTY structure */ tty 149 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 151 drivers/net/hamradio/6pack.c actual = sp->tty->ops->write(sp->tty, sp->xbuff, sp->status2); tty 155 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 195 drivers/net/hamradio/6pack.c set_bit(TTY_DO_WRITE_WAKEUP, &sp->tty->flags); tty 221 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 223 drivers/net/hamradio/6pack.c actual = sp->tty->ops->write(sp->tty, sp->xbuff, count); tty 227 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 269 drivers/net/hamradio/6pack.c if (sp->tty == NULL) tty 280 drivers/net/hamradio/6pack.c if (sp->tty) { tty 282 drivers/net/hamradio/6pack.c clear_bit(TTY_DO_WRITE_WAKEUP, &sp->tty->flags); tty 377 drivers/net/hamradio/6pack.c static struct sixpack *sp_get(struct tty_struct *tty) tty 382 drivers/net/hamradio/6pack.c sp = tty->disc_data; tty 400 drivers/net/hamradio/6pack.c static void sixpack_write_wakeup(struct tty_struct *tty) tty 402 drivers/net/hamradio/6pack.c struct sixpack *sp = sp_get(tty); tty 411 drivers/net/hamradio/6pack.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 418 drivers/net/hamradio/6pack.c actual = tty->ops->write(tty, sp->xhead, sp->xleft); tty 435 drivers/net/hamradio/6pack.c static void sixpack_receive_buf(struct tty_struct *tty, tty 444 drivers/net/hamradio/6pack.c sp = sp_get(tty); tty 461 drivers/net/hamradio/6pack.c tty_unthrottle(tty); tty 522 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 523 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &resync_cmd, 1); tty 536 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &inbyte, 1); tty 550 drivers/net/hamradio/6pack.c static int sixpack_open(struct tty_struct *tty) tty 560 drivers/net/hamradio/6pack.c if (tty->ops->write == NULL) tty 591 drivers/net/hamradio/6pack.c sp->tty = tty; tty 624 drivers/net/hamradio/6pack.c tty->disc_data = sp; tty 625 drivers/net/hamradio/6pack.c tty->receive_room = 65536; tty 653 drivers/net/hamradio/6pack.c static void sixpack_close(struct tty_struct *tty) tty 658 drivers/net/hamradio/6pack.c sp = tty->disc_data; tty 659 drivers/net/hamradio/6pack.c tty->disc_data = NULL; tty 688 drivers/net/hamradio/6pack.c static int sixpack_ioctl(struct tty_struct *tty, struct file *file, tty 691 drivers/net/hamradio/6pack.c struct sixpack *sp = sp_get(tty); tty 742 drivers/net/hamradio/6pack.c err = tty_mode_ioctl(tty, file, cmd, arg); tty 879 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 881 drivers/net/hamradio/6pack.c actual = sp->tty->ops->write(sp->tty, sp->xbuff, sp->status2); tty 891 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 915 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 920 drivers/net/hamradio/6pack.c sp->tty->ops->write(sp->tty, &sp->led_state, 1); tty 41 drivers/net/hamradio/mkiss.c struct tty_struct *tty; /* ptr to TTY structure */ tty 507 drivers/net/hamradio/mkiss.c set_bit(TTY_DO_WRITE_WAKEUP, &ax->tty->flags); tty 508 drivers/net/hamradio/mkiss.c actual = ax->tty->ops->write(ax->tty, ax->xbuff, count); tty 541 drivers/net/hamradio/mkiss.c (tty_chars_in_buffer(ax->tty) || ax->xleft) ? tty 545 drivers/net/hamradio/mkiss.c clear_bit(TTY_DO_WRITE_WAKEUP, &ax->tty->flags); tty 561 drivers/net/hamradio/mkiss.c if (ax->tty == NULL) tty 573 drivers/net/hamradio/mkiss.c if (ax->tty == NULL) tty 622 drivers/net/hamradio/mkiss.c if (ax->tty) tty 623 drivers/net/hamradio/mkiss.c clear_bit(TTY_DO_WRITE_WAKEUP, &ax->tty->flags); tty 665 drivers/net/hamradio/mkiss.c static struct mkiss *mkiss_get(struct tty_struct *tty) tty 670 drivers/net/hamradio/mkiss.c ax = tty->disc_data; tty 686 drivers/net/hamradio/mkiss.c static int mkiss_open(struct tty_struct *tty) tty 694 drivers/net/hamradio/mkiss.c if (tty->ops->write == NULL) tty 711 drivers/net/hamradio/mkiss.c ax->tty = tty; tty 712 drivers/net/hamradio/mkiss.c tty->disc_data = ax; tty 713 drivers/net/hamradio/mkiss.c tty->receive_room = 65535; tty 715 drivers/net/hamradio/mkiss.c tty_driver_flush_buffer(tty); tty 772 drivers/net/hamradio/mkiss.c static void mkiss_close(struct tty_struct *tty) tty 777 drivers/net/hamradio/mkiss.c ax = tty->disc_data; tty 778 drivers/net/hamradio/mkiss.c tty->disc_data = NULL; tty 800 drivers/net/hamradio/mkiss.c ax->tty = NULL; tty 806 drivers/net/hamradio/mkiss.c static int mkiss_ioctl(struct tty_struct *tty, struct file *file, tty 809 drivers/net/hamradio/mkiss.c struct mkiss *ax = mkiss_get(tty); tty 874 drivers/net/hamradio/mkiss.c static void mkiss_receive_buf(struct tty_struct *tty, const unsigned char *cp, tty 877 drivers/net/hamradio/mkiss.c struct mkiss *ax = mkiss_get(tty); tty 902 drivers/net/hamradio/mkiss.c tty_unthrottle(tty); tty 909 drivers/net/hamradio/mkiss.c static void mkiss_write_wakeup(struct tty_struct *tty) tty 911 drivers/net/hamradio/mkiss.c struct mkiss *ax = mkiss_get(tty); tty 921 drivers/net/hamradio/mkiss.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 927 drivers/net/hamradio/mkiss.c actual = tty->ops->write(tty, ax->xhead, ax->xleft); tty 42 drivers/net/ppp/ppp_async.c struct tty_struct *tty; tty 132 drivers/net/ppp/ppp_async.c static struct asyncppp *ap_get(struct tty_struct *tty) tty 137 drivers/net/ppp/ppp_async.c ap = tty->disc_data; tty 155 drivers/net/ppp/ppp_async.c ppp_asynctty_open(struct tty_struct *tty) tty 161 drivers/net/ppp/ppp_async.c if (tty->ops->write == NULL) tty 170 drivers/net/ppp/ppp_async.c ap->tty = tty; tty 190 drivers/net/ppp/ppp_async.c speed = tty_get_baud_rate(tty); tty 196 drivers/net/ppp/ppp_async.c tty->disc_data = ap; tty 197 drivers/net/ppp/ppp_async.c tty->receive_room = 65536; tty 215 drivers/net/ppp/ppp_async.c ppp_asynctty_close(struct tty_struct *tty) tty 220 drivers/net/ppp/ppp_async.c ap = tty->disc_data; tty 221 drivers/net/ppp/ppp_async.c tty->disc_data = NULL; tty 250 drivers/net/ppp/ppp_async.c static int ppp_asynctty_hangup(struct tty_struct *tty) tty 252 drivers/net/ppp/ppp_async.c ppp_asynctty_close(tty); tty 261 drivers/net/ppp/ppp_async.c ppp_asynctty_read(struct tty_struct *tty, struct file *file, tty 272 drivers/net/ppp/ppp_async.c ppp_asynctty_write(struct tty_struct *tty, struct file *file, tty 284 drivers/net/ppp/ppp_async.c ppp_asynctty_ioctl(struct tty_struct *tty, struct file *file, tty 287 drivers/net/ppp/ppp_async.c struct asyncppp *ap = ap_get(tty); tty 313 drivers/net/ppp/ppp_async.c err = n_tty_ioctl_helper(tty, file, cmd, arg); tty 325 drivers/net/ppp/ppp_async.c err = tty_mode_ioctl(tty, file, cmd, arg); tty 334 drivers/net/ppp/ppp_async.c ppp_asynctty_poll(struct tty_struct *tty, struct file *file, poll_table *wait) tty 341 drivers/net/ppp/ppp_async.c ppp_asynctty_receive(struct tty_struct *tty, const unsigned char *buf, tty 344 drivers/net/ppp/ppp_async.c struct asyncppp *ap = ap_get(tty); tty 355 drivers/net/ppp/ppp_async.c tty_unthrottle(tty); tty 359 drivers/net/ppp/ppp_async.c ppp_asynctty_wakeup(struct tty_struct *tty) tty 361 drivers/net/ppp/ppp_async.c struct asyncppp *ap = ap_get(tty); tty 363 drivers/net/ppp/ppp_async.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 650 drivers/net/ppp/ppp_async.c struct tty_struct *tty = ap->tty; tty 670 drivers/net/ppp/ppp_async.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 671 drivers/net/ppp/ppp_async.c sent = tty->ops->write(tty, ap->optr, avail); tty 911 drivers/net/ppp/ppp_async.c } else if (I_IXON(ap->tty)) { tty 912 drivers/net/ppp/ppp_async.c if (c == START_CHAR(ap->tty)) tty 913 drivers/net/ppp/ppp_async.c start_tty(ap->tty); tty 914 drivers/net/ppp/ppp_async.c else if (c == STOP_CHAR(ap->tty)) tty 915 drivers/net/ppp/ppp_async.c stop_tty(ap->tty); tty 53 drivers/net/ppp/ppp_synctty.c struct tty_struct *tty; tty 134 drivers/net/ppp/ppp_synctty.c static struct syncppp *sp_get(struct tty_struct *tty) tty 139 drivers/net/ppp/ppp_synctty.c ap = tty->disc_data; tty 156 drivers/net/ppp/ppp_synctty.c ppp_sync_open(struct tty_struct *tty) tty 162 drivers/net/ppp/ppp_synctty.c if (tty->ops->write == NULL) tty 171 drivers/net/ppp/ppp_synctty.c ap->tty = tty; tty 189 drivers/net/ppp/ppp_synctty.c speed = tty_get_baud_rate(tty); tty 195 drivers/net/ppp/ppp_synctty.c tty->disc_data = ap; tty 196 drivers/net/ppp/ppp_synctty.c tty->receive_room = 65536; tty 214 drivers/net/ppp/ppp_synctty.c ppp_sync_close(struct tty_struct *tty) tty 219 drivers/net/ppp/ppp_synctty.c ap = tty->disc_data; tty 220 drivers/net/ppp/ppp_synctty.c tty->disc_data = NULL; tty 248 drivers/net/ppp/ppp_synctty.c static int ppp_sync_hangup(struct tty_struct *tty) tty 250 drivers/net/ppp/ppp_synctty.c ppp_sync_close(tty); tty 259 drivers/net/ppp/ppp_synctty.c ppp_sync_read(struct tty_struct *tty, struct file *file, tty 270 drivers/net/ppp/ppp_synctty.c ppp_sync_write(struct tty_struct *tty, struct file *file, tty 277 drivers/net/ppp/ppp_synctty.c ppp_synctty_ioctl(struct tty_struct *tty, struct file *file, tty 280 drivers/net/ppp/ppp_synctty.c struct syncppp *ap = sp_get(tty); tty 306 drivers/net/ppp/ppp_synctty.c err = n_tty_ioctl_helper(tty, file, cmd, arg); tty 317 drivers/net/ppp/ppp_synctty.c err = tty_mode_ioctl(tty, file, cmd, arg); tty 327 drivers/net/ppp/ppp_synctty.c ppp_sync_poll(struct tty_struct *tty, struct file *file, poll_table *wait) tty 334 drivers/net/ppp/ppp_synctty.c ppp_sync_receive(struct tty_struct *tty, const unsigned char *buf, tty 337 drivers/net/ppp/ppp_synctty.c struct syncppp *ap = sp_get(tty); tty 348 drivers/net/ppp/ppp_synctty.c tty_unthrottle(tty); tty 352 drivers/net/ppp/ppp_synctty.c ppp_sync_wakeup(struct tty_struct *tty) tty 354 drivers/net/ppp/ppp_synctty.c struct syncppp *ap = sp_get(tty); tty 356 drivers/net/ppp/ppp_synctty.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 591 drivers/net/ppp/ppp_synctty.c struct tty_struct *tty = ap->tty; tty 600 drivers/net/ppp/ppp_synctty.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 601 drivers/net/ppp/ppp_synctty.c sent = tty->ops->write(tty, ap->tpkt->data, ap->tpkt->len); tty 171 drivers/net/slip/slip.c if (sl->tty == NULL) { tty 260 drivers/net/slip/slip.c if (sl->tty == NULL) tty 407 drivers/net/slip/slip.c set_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 408 drivers/net/slip/slip.c actual = sl->tty->ops->write(sl->tty, sl->xbuff, count); tty 428 drivers/net/slip/slip.c if (!sl->tty || sl->magic != SLIP_MAGIC || !netif_running(sl->dev)) { tty 437 drivers/net/slip/slip.c clear_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 443 drivers/net/slip/slip.c actual = sl->tty->ops->write(sl->tty, sl->xhead, sl->xleft); tty 453 drivers/net/slip/slip.c static void slip_write_wakeup(struct tty_struct *tty) tty 458 drivers/net/slip/slip.c sl = rcu_dereference(tty->disc_data); tty 487 drivers/net/slip/slip.c (tty_chars_in_buffer(sl->tty) || sl->xleft) ? tty 490 drivers/net/slip/slip.c clear_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 512 drivers/net/slip/slip.c if (sl->tty == NULL) { tty 540 drivers/net/slip/slip.c if (sl->tty) tty 542 drivers/net/slip/slip.c clear_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 557 drivers/net/slip/slip.c if (sl->tty == NULL) tty 690 drivers/net/slip/slip.c static void slip_receive_buf(struct tty_struct *tty, const unsigned char *cp, tty 693 drivers/net/slip/slip.c struct slip *sl = tty->disc_data; tty 732 drivers/net/slip/slip.c if (sl->tty || sl->leased) tty 790 drivers/net/slip/slip.c static int slip_open(struct tty_struct *tty) tty 798 drivers/net/slip/slip.c if (tty->ops->write == NULL) tty 810 drivers/net/slip/slip.c sl = tty->disc_data; tty 823 drivers/net/slip/slip.c sl->tty = tty; tty 824 drivers/net/slip/slip.c tty->disc_data = sl; tty 853 drivers/net/slip/slip.c tty->receive_room = 65536; /* We don't flow control */ tty 862 drivers/net/slip/slip.c sl->tty = NULL; tty 863 drivers/net/slip/slip.c tty->disc_data = NULL; tty 886 drivers/net/slip/slip.c static void slip_close(struct tty_struct *tty) tty 888 drivers/net/slip/slip.c struct slip *sl = tty->disc_data; tty 891 drivers/net/slip/slip.c if (!sl || sl->magic != SLIP_MAGIC || sl->tty != tty) tty 895 drivers/net/slip/slip.c rcu_assign_pointer(tty->disc_data, NULL); tty 896 drivers/net/slip/slip.c sl->tty = NULL; tty 912 drivers/net/slip/slip.c static int slip_hangup(struct tty_struct *tty) tty 914 drivers/net/slip/slip.c slip_close(tty); tty 1078 drivers/net/slip/slip.c static int slip_ioctl(struct tty_struct *tty, struct file *file, tty 1081 drivers/net/slip/slip.c struct slip *sl = tty->disc_data; tty 1133 drivers/net/slip/slip.c if (!sl->tty) { tty 1158 drivers/net/slip/slip.c if (!sl->tty) { tty 1179 drivers/net/slip/slip.c return tty_mode_ioctl(tty, file, cmd, arg); tty 1199 drivers/net/slip/slip.c if (!sl->tty) { tty 1248 drivers/net/slip/slip.c if (sl->tty != current->signal->tty && tty 1337 drivers/net/slip/slip.c if (sl->tty) { tty 1339 drivers/net/slip/slip.c tty_hangup(sl->tty); tty 1355 drivers/net/slip/slip.c if (sl->tty) { tty 1386 drivers/net/slip/slip.c if (sl->tty == NULL) tty 1400 drivers/net/slip/slip.c sl->tty->ops->write(sl->tty, &s, 1); tty 1417 drivers/net/slip/slip.c if (sl->tty == NULL) tty 1428 drivers/net/slip/slip.c tty_hangup(sl->tty); tty 54 drivers/net/slip/slip.h struct tty_struct *tty; /* ptr to TTY structure */ tty 291 drivers/net/usb/hso.c static int hso_serial_tiocmset(struct tty_struct *tty, tty 1085 drivers/net/usb/hso.c static void _hso_serial_set_termios(struct tty_struct *tty, tty 1088 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1100 drivers/net/usb/hso.c tty->termios.c_iflag &= ~IXON; /* disable enable XON/XOFF flow control */ tty 1102 drivers/net/usb/hso.c tty->termios.c_cflag &= tty 1108 drivers/net/usb/hso.c tty->termios.c_cflag |= CS8; /* character size 8 bits */ tty 1111 drivers/net/usb/hso.c tty_encode_baud_rate(tty, 115200, 115200); tty 1229 drivers/net/usb/hso.c static void hso_unthrottle(struct tty_struct *tty) tty 1231 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1237 drivers/net/usb/hso.c static int hso_serial_open(struct tty_struct *tty, struct file *filp) tty 1239 drivers/net/usb/hso.c struct hso_serial *serial = get_serial_by_index(tty->index); tty 1245 drivers/net/usb/hso.c tty->driver_data = NULL; tty 1258 drivers/net/usb/hso.c tty->driver_data = serial; tty 1259 drivers/net/usb/hso.c tty_port_tty_set(&serial->port, tty); tty 1266 drivers/net/usb/hso.c _hso_serial_set_termios(tty, NULL); tty 1285 drivers/net/usb/hso.c hso_serial_tiocmset(tty, TIOCM_RTS | TIOCM_DTR, 0); tty 1292 drivers/net/usb/hso.c static void hso_serial_close(struct tty_struct *tty, struct file *filp) tty 1294 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1328 drivers/net/usb/hso.c static int hso_serial_write(struct tty_struct *tty, const unsigned char *buf, tty 1331 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1361 drivers/net/usb/hso.c static int hso_serial_write_room(struct tty_struct *tty) tty 1363 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1375 drivers/net/usb/hso.c static void hso_serial_cleanup(struct tty_struct *tty) tty 1377 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1386 drivers/net/usb/hso.c static void hso_serial_set_termios(struct tty_struct *tty, struct ktermios *old) tty 1388 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1393 drivers/net/usb/hso.c tty->termios.c_cflag, old->c_cflag); tty 1398 drivers/net/usb/hso.c _hso_serial_set_termios(tty, old); tty 1400 drivers/net/usb/hso.c tty->termios = *old; tty 1407 drivers/net/usb/hso.c static int hso_serial_chars_in_buffer(struct tty_struct *tty) tty 1409 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1590 drivers/net/usb/hso.c static int hso_get_count(struct tty_struct *tty, tty 1594 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1621 drivers/net/usb/hso.c static int hso_serial_tiocmget(struct tty_struct *tty) tty 1624 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1652 drivers/net/usb/hso.c static int hso_serial_tiocmset(struct tty_struct *tty, tty 1658 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 1697 drivers/net/usb/hso.c static int hso_serial_ioctl(struct tty_struct *tty, tty 1700 drivers/net/usb/hso.c struct hso_serial *serial = tty->driver_data; tty 2001 drivers/net/usb/hso.c struct tty_struct *tty; tty 2010 drivers/net/usb/hso.c tty = tty_port_tty_get(&serial->port); tty 2012 drivers/net/usb/hso.c if (tty && tty_throttled(tty)) { tty 2013 drivers/net/usb/hso.c tty_kref_put(tty); tty 2029 drivers/net/usb/hso.c tty_kref_put(tty); tty 244 drivers/net/wan/x25_asy.c set_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 245 drivers/net/wan/x25_asy.c actual = sl->tty->ops->write(sl->tty, sl->xbuff, count); tty 256 drivers/net/wan/x25_asy.c static void x25_asy_write_wakeup(struct tty_struct *tty) tty 259 drivers/net/wan/x25_asy.c struct x25_asy *sl = tty->disc_data; tty 269 drivers/net/wan/x25_asy.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 274 drivers/net/wan/x25_asy.c actual = tty->ops->write(tty, sl->xhead, sl->xleft); tty 289 drivers/net/wan/x25_asy.c (tty_chars_in_buffer(sl->tty) || sl->xleft) ? tty 292 drivers/net/wan/x25_asy.c clear_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 379 drivers/net/wan/x25_asy.c if (netif_queue_stopped(sl->dev) || sl->tty == NULL) { tty 454 drivers/net/wan/x25_asy.c if (sl->tty == NULL) tty 504 drivers/net/wan/x25_asy.c if (sl->tty) tty 505 drivers/net/wan/x25_asy.c clear_bit(TTY_DO_WRITE_WAKEUP, &sl->tty->flags); tty 521 drivers/net/wan/x25_asy.c static void x25_asy_receive_buf(struct tty_struct *tty, tty 524 drivers/net/wan/x25_asy.c struct x25_asy *sl = tty->disc_data; tty 550 drivers/net/wan/x25_asy.c static int x25_asy_open_tty(struct tty_struct *tty) tty 555 drivers/net/wan/x25_asy.c if (tty->ops->write == NULL) tty 563 drivers/net/wan/x25_asy.c sl->tty = tty; tty 564 drivers/net/wan/x25_asy.c tty->disc_data = sl; tty 565 drivers/net/wan/x25_asy.c tty->receive_room = 65536; tty 566 drivers/net/wan/x25_asy.c tty_driver_flush_buffer(tty); tty 567 drivers/net/wan/x25_asy.c tty_ldisc_flush(tty); tty 589 drivers/net/wan/x25_asy.c static void x25_asy_close_tty(struct tty_struct *tty) tty 591 drivers/net/wan/x25_asy.c struct x25_asy *sl = tty->disc_data; tty 608 drivers/net/wan/x25_asy.c tty->disc_data = NULL; tty 609 drivers/net/wan/x25_asy.c sl->tty = NULL; tty 686 drivers/net/wan/x25_asy.c static int x25_asy_ioctl(struct tty_struct *tty, struct file *file, tty 689 drivers/net/wan/x25_asy.c struct x25_asy *sl = tty->disc_data; tty 704 drivers/net/wan/x25_asy.c return tty_mode_ioctl(tty, file, cmd, arg); tty 711 drivers/net/wan/x25_asy.c if (sl->tty == NULL) tty 791 drivers/net/wan/x25_asy.c if (sl->tty) tty 792 drivers/net/wan/x25_asy.c tty_hangup(sl->tty); tty 23 drivers/net/wan/x25_asy.h struct tty_struct *tty; /* ptr to TTY structure */ tty 334 drivers/net/wan/z85230.h struct tty_struct *tty; /* Attached terminal */ tty 114 drivers/nfc/nfcmrvl/uart.c struct device *dev = nu->tty->dev; tty 167 drivers/nfc/nfcmrvl/uart.c if (priv->config.break_control && nu->tty->ops->break_ctl) { tty 168 drivers/nfc/nfcmrvl/uart.c nu->tty->ops->break_ctl(nu->tty, 0); tty 185 drivers/nfc/nfcmrvl/uart.c if (priv->config.break_control && nu->tty->ops->break_ctl) { tty 186 drivers/nfc/nfcmrvl/uart.c nu->tty->ops->break_ctl(nu->tty, -1); tty 18 drivers/pps/clients/pps-ldisc.c static void pps_tty_dcd_change(struct tty_struct *tty, unsigned int status) tty 25 drivers/pps/clients/pps-ldisc.c pps = pps_lookup_dev(tty); tty 41 drivers/pps/clients/pps-ldisc.c static int (*alias_n_tty_open)(struct tty_struct *tty); tty 43 drivers/pps/clients/pps-ldisc.c static int pps_tty_open(struct tty_struct *tty) tty 46 drivers/pps/clients/pps-ldisc.c struct tty_driver *drv = tty->driver; tty 47 drivers/pps/clients/pps-ldisc.c int index = tty->index + drv->name_base; tty 65 drivers/pps/clients/pps-ldisc.c pps->lookup_cookie = tty; tty 68 drivers/pps/clients/pps-ldisc.c ret = alias_n_tty_open(tty); tty 83 drivers/pps/clients/pps-ldisc.c static void (*alias_n_tty_close)(struct tty_struct *tty); tty 85 drivers/pps/clients/pps-ldisc.c static void pps_tty_close(struct tty_struct *tty) tty 87 drivers/pps/clients/pps-ldisc.c struct pps_device *pps = pps_lookup_dev(tty); tty 89 drivers/pps/clients/pps-ldisc.c alias_n_tty_close(tty); tty 340 drivers/s390/char/con3215.c struct tty_struct *tty; tty 342 drivers/s390/char/con3215.c tty = tty_port_tty_get(&raw->port); tty 343 drivers/s390/char/con3215.c if (tty) { tty 344 drivers/s390/char/con3215.c tty_wakeup(tty); tty 345 drivers/s390/char/con3215.c tty_kref_put(tty); tty 352 drivers/s390/char/con3215.c static void raw3215_next_io(struct raw3215_info *raw, struct tty_struct *tty) tty 356 drivers/s390/char/con3215.c if (tty && RAW3215_BUFFER_SIZE - raw->count >= RAW3215_MIN_SPACE) tty 368 drivers/s390/char/con3215.c struct tty_struct *tty; tty 374 drivers/s390/char/con3215.c tty = tty_port_tty_get(&raw->port); tty 378 drivers/s390/char/con3215.c raw3215_next_io(raw, tty); tty 388 drivers/s390/char/con3215.c raw3215_next_io(raw, tty); tty 406 drivers/s390/char/con3215.c if (req->type == RAW3215_READ && tty != NULL) { tty 411 drivers/s390/char/con3215.c cchar = ctrlchar_handle(raw->inbuf, count, tty); tty 448 drivers/s390/char/con3215.c raw3215_next_io(raw, tty); tty 460 drivers/s390/char/con3215.c raw3215_next_io(raw, tty); tty 463 drivers/s390/char/con3215.c tty_kref_put(tty); tty 960 drivers/s390/char/con3215.c static int tty3215_install(struct tty_driver *driver, struct tty_struct *tty) tty 964 drivers/s390/char/con3215.c raw = raw3215[tty->index]; tty 968 drivers/s390/char/con3215.c tty->driver_data = raw; tty 970 drivers/s390/char/con3215.c return tty_port_install(&raw->port, driver, tty); tty 978 drivers/s390/char/con3215.c static int tty3215_open(struct tty_struct *tty, struct file * filp) tty 980 drivers/s390/char/con3215.c struct raw3215_info *raw = tty->driver_data; tty 983 drivers/s390/char/con3215.c tty_port_tty_set(&raw->port, tty); tty 1002 drivers/s390/char/con3215.c static void tty3215_close(struct tty_struct *tty, struct file * filp) tty 1006 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1007 drivers/s390/char/con3215.c if (raw == NULL || tty->count > 1) tty 1009 drivers/s390/char/con3215.c tty->closing = 1; tty 1013 drivers/s390/char/con3215.c tty->closing = 0; tty 1020 drivers/s390/char/con3215.c static int tty3215_write_room(struct tty_struct *tty) tty 1024 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1036 drivers/s390/char/con3215.c static int tty3215_write(struct tty_struct * tty, tty 1042 drivers/s390/char/con3215.c if (!tty) tty 1044 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1065 drivers/s390/char/con3215.c static int tty3215_put_char(struct tty_struct *tty, unsigned char ch) tty 1069 drivers/s390/char/con3215.c if (!tty) tty 1071 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1076 drivers/s390/char/con3215.c static void tty3215_flush_chars(struct tty_struct *tty) tty 1083 drivers/s390/char/con3215.c static int tty3215_chars_in_buffer(struct tty_struct *tty) tty 1087 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1091 drivers/s390/char/con3215.c static void tty3215_flush_buffer(struct tty_struct *tty) tty 1095 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1097 drivers/s390/char/con3215.c tty_wakeup(tty); tty 1103 drivers/s390/char/con3215.c static void tty3215_throttle(struct tty_struct * tty) tty 1107 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1114 drivers/s390/char/con3215.c static void tty3215_unthrottle(struct tty_struct * tty) tty 1119 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1131 drivers/s390/char/con3215.c static void tty3215_stop(struct tty_struct *tty) tty 1135 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 1142 drivers/s390/char/con3215.c static void tty3215_start(struct tty_struct *tty) tty 1147 drivers/s390/char/con3215.c raw = (struct raw3215_info *) tty->driver_data; tty 48 drivers/s390/char/ctrlchar.c ctrlchar_handle(const unsigned char *buf, int len, struct tty_struct *tty) tty 72 drivers/s390/char/ctrlchar.c return INTR_CHAR(tty) | CTRLCHAR_CTRL; tty 74 drivers/s390/char/ctrlchar.c return EOF_CHAR(tty) | CTRLCHAR_CTRL; tty 76 drivers/s390/char/ctrlchar.c return SUSP_CHAR(tty) | CTRLCHAR_CTRL; tty 15 drivers/s390/char/ctrlchar.h ctrlchar_handle(const unsigned char *buf, int len, struct tty_struct *tty); tty 441 drivers/s390/char/fs3270.c struct tty_struct *tty = get_current_tty(); tty 442 drivers/s390/char/fs3270.c if (!tty || tty->driver->major != IBM_TTY3270_MAJOR) { tty 443 drivers/s390/char/fs3270.c tty_kref_put(tty); tty 446 drivers/s390/char/fs3270.c minor = tty->index; tty 447 drivers/s390/char/fs3270.c tty_kref_put(tty); tty 479 drivers/s390/char/keyboard.c struct tty_struct *tty; tty 490 drivers/s390/char/keyboard.c tty = tty_port_tty_get(kbd->port); tty 492 drivers/s390/char/keyboard.c perm = current->signal->tty == tty || capable(CAP_SYS_TTY_CONFIG); tty 493 drivers/s390/char/keyboard.c tty_kref_put(tty); tty 64 drivers/s390/char/sclp_tty.c sclp_tty_open(struct tty_struct *tty, struct file *filp) tty 66 drivers/s390/char/sclp_tty.c tty_port_tty_set(&sclp_port, tty); tty 67 drivers/s390/char/sclp_tty.c tty->driver_data = NULL; tty 74 drivers/s390/char/sclp_tty.c sclp_tty_close(struct tty_struct *tty, struct file *filp) tty 76 drivers/s390/char/sclp_tty.c if (tty->count > 1) tty 91 drivers/s390/char/sclp_tty.c sclp_tty_write_room (struct tty_struct *tty) tty 234 drivers/s390/char/sclp_tty.c sclp_tty_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 254 drivers/s390/char/sclp_tty.c sclp_tty_put_char(struct tty_struct *tty, unsigned char ch) tty 269 drivers/s390/char/sclp_tty.c sclp_tty_flush_chars(struct tty_struct *tty) tty 285 drivers/s390/char/sclp_tty.c sclp_tty_chars_in_buffer(struct tty_struct *tty) tty 308 drivers/s390/char/sclp_tty.c sclp_tty_flush_buffer(struct tty_struct *tty) tty 322 drivers/s390/char/sclp_tty.c struct tty_struct *tty = tty_port_tty_get(&sclp_port); tty 329 drivers/s390/char/sclp_tty.c if (tty == NULL) tty 331 drivers/s390/char/sclp_tty.c cchar = ctrlchar_handle(buf, count, tty); tty 352 drivers/s390/char/sclp_tty.c tty_kref_put(tty); tty 472 drivers/s390/char/sclp_vt220.c sclp_vt220_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 559 drivers/s390/char/sclp_vt220.c sclp_vt220_open(struct tty_struct *tty, struct file *filp) tty 561 drivers/s390/char/sclp_vt220.c if (tty->count == 1) { tty 562 drivers/s390/char/sclp_vt220.c tty_port_tty_set(&sclp_vt220_port, tty); tty 564 drivers/s390/char/sclp_vt220.c if (!tty->winsize.ws_row && !tty->winsize.ws_col) { tty 565 drivers/s390/char/sclp_vt220.c tty->winsize.ws_row = 24; tty 566 drivers/s390/char/sclp_vt220.c tty->winsize.ws_col = 80; tty 576 drivers/s390/char/sclp_vt220.c sclp_vt220_close(struct tty_struct *tty, struct file *filp) tty 578 drivers/s390/char/sclp_vt220.c if (tty->count == 1) tty 589 drivers/s390/char/sclp_vt220.c sclp_vt220_put_char(struct tty_struct *tty, unsigned char ch) tty 599 drivers/s390/char/sclp_vt220.c sclp_vt220_flush_chars(struct tty_struct *tty) tty 614 drivers/s390/char/sclp_vt220.c sclp_vt220_write_room(struct tty_struct *tty) tty 634 drivers/s390/char/sclp_vt220.c sclp_vt220_chars_in_buffer(struct tty_struct *tty) tty 658 drivers/s390/char/sclp_vt220.c sclp_vt220_flush_buffer(struct tty_struct *tty) tty 850 drivers/s390/char/tty3270.c struct tty_struct *tty; tty 877 drivers/s390/char/tty3270.c tty = tty_port_tty_get(&tp->port); tty 878 drivers/s390/char/tty3270.c if (!tty) tty 882 drivers/s390/char/tty3270.c tty_do_resize(tty, &ws); tty 883 drivers/s390/char/tty3270.c tty_kref_put(tty); tty 906 drivers/s390/char/tty3270.c struct tty_struct *tty = tty_port_tty_get(&tp->port); tty 908 drivers/s390/char/tty3270.c if (tty) { tty 909 drivers/s390/char/tty3270.c tty->driver_data = NULL; tty 911 drivers/s390/char/tty3270.c tty_hangup(tty); tty 913 drivers/s390/char/tty3270.c tty_kref_put(tty); tty 957 drivers/s390/char/tty3270.c static int tty3270_install(struct tty_driver *driver, struct tty_struct *tty) tty 964 drivers/s390/char/tty3270.c view = raw3270_find_view(&tty3270_fn, tty->index + RAW3270_FIRSTMINOR); tty 967 drivers/s390/char/tty3270.c tty->driver_data = tp; tty 968 drivers/s390/char/tty3270.c tty->winsize.ws_row = tp->view.rows - 2; tty 969 drivers/s390/char/tty3270.c tty->winsize.ws_col = tp->view.cols; tty 974 drivers/s390/char/tty3270.c if (tty3270_max_index < tty->index + 1) tty 975 drivers/s390/char/tty3270.c tty3270_max_index = tty->index + 1; tty 983 drivers/s390/char/tty3270.c tty->index + RAW3270_FIRSTMINOR, tty 1000 drivers/s390/char/tty3270.c tty->winsize.ws_row = tp->view.rows - 2; tty 1001 drivers/s390/char/tty3270.c tty->winsize.ws_col = tp->view.cols; tty 1021 drivers/s390/char/tty3270.c rc = tty_port_install(&tp->port, driver, tty); tty 1027 drivers/s390/char/tty3270.c tty->driver_data = tp; tty 1036 drivers/s390/char/tty3270.c tty3270_open(struct tty_struct *tty, struct file *filp) tty 1038 drivers/s390/char/tty3270.c struct tty3270 *tp = tty->driver_data; tty 1042 drivers/s390/char/tty3270.c tty_port_tty_set(port, tty); tty 1051 drivers/s390/char/tty3270.c tty3270_close(struct tty_struct *tty, struct file * filp) tty 1053 drivers/s390/char/tty3270.c struct tty3270 *tp = tty->driver_data; tty 1055 drivers/s390/char/tty3270.c if (tty->count > 1) tty 1061 drivers/s390/char/tty3270.c static void tty3270_cleanup(struct tty_struct *tty) tty 1063 drivers/s390/char/tty3270.c struct tty3270 *tp = tty->driver_data; tty 1066 drivers/s390/char/tty3270.c tty->driver_data = NULL; tty 1075 drivers/s390/char/tty3270.c tty3270_write_room(struct tty_struct *tty) tty 1637 drivers/s390/char/tty3270.c tty3270_do_write(struct tty3270 *tp, struct tty_struct *tty, tty 1643 drivers/s390/char/tty3270.c for (i_msg = 0; !tty->stopped && i_msg < count; i_msg++) { tty 1711 drivers/s390/char/tty3270.c tty3270_write(struct tty_struct * tty, tty 1716 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1720 drivers/s390/char/tty3270.c tty3270_do_write(tp, tty, tp->char_buf, tp->char_count); tty 1723 drivers/s390/char/tty3270.c tty3270_do_write(tp, tty, buf, count); tty 1730 drivers/s390/char/tty3270.c static int tty3270_put_char(struct tty_struct *tty, unsigned char ch) tty 1734 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1746 drivers/s390/char/tty3270.c tty3270_flush_chars(struct tty_struct *tty) tty 1750 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1754 drivers/s390/char/tty3270.c tty3270_do_write(tp, tty, tp->char_buf, tp->char_count); tty 1765 drivers/s390/char/tty3270.c tty3270_chars_in_buffer(struct tty_struct *tty) tty 1771 drivers/s390/char/tty3270.c tty3270_flush_buffer(struct tty_struct *tty) tty 1779 drivers/s390/char/tty3270.c tty3270_set_termios(struct tty_struct *tty, struct ktermios *old) tty 1784 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1788 drivers/s390/char/tty3270.c if (L_ICANON(tty)) { tty 1789 drivers/s390/char/tty3270.c new = L_ECHO(tty) ? TF_INPUT: TF_INPUTN; tty 1803 drivers/s390/char/tty3270.c tty3270_throttle(struct tty_struct * tty) tty 1807 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1817 drivers/s390/char/tty3270.c tty3270_unthrottle(struct tty_struct * tty) tty 1821 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1833 drivers/s390/char/tty3270.c tty3270_hangup(struct tty_struct *tty) tty 1837 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1854 drivers/s390/char/tty3270.c tty3270_wait_until_sent(struct tty_struct *tty, int timeout) tty 1858 drivers/s390/char/tty3270.c static int tty3270_ioctl(struct tty_struct *tty, unsigned int cmd, tty 1863 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1866 drivers/s390/char/tty3270.c if (tty_io_error(tty)) tty 1872 drivers/s390/char/tty3270.c static long tty3270_compat_ioctl(struct tty_struct *tty, tty 1877 drivers/s390/char/tty3270.c tp = tty->driver_data; tty 1880 drivers/s390/char/tty3270.c if (tty_io_error(tty)) tty 297 drivers/staging/fwserial/fwserial.c struct tty_struct *tty; tty 317 drivers/staging/fwserial/fwserial.c tty = tty_port_tty_get(&port->port); tty 318 drivers/staging/fwserial/fwserial.c if (tty && !C_CLOCAL(tty)) { tty 324 drivers/staging/fwserial/fwserial.c tty_kref_put(tty); tty 328 drivers/staging/fwserial/fwserial.c tty = tty_port_tty_get(&port->port); tty 329 drivers/staging/fwserial/fwserial.c if (tty && C_CRTSCTS(tty)) { tty 330 drivers/staging/fwserial/fwserial.c if (tty->hw_stopped) { tty 332 drivers/staging/fwserial/fwserial.c tty->hw_stopped = 0; tty 340 drivers/staging/fwserial/fwserial.c tty->hw_stopped = 1; tty 343 drivers/staging/fwserial/fwserial.c tty_kref_put(tty); tty 346 drivers/staging/fwserial/fwserial.c tty = tty_port_tty_get(&port->port); tty 347 drivers/staging/fwserial/fwserial.c if (tty) { tty 348 drivers/staging/fwserial/fwserial.c if (tty->hw_stopped) { tty 350 drivers/staging/fwserial/fwserial.c tty->hw_stopped = 0; tty 358 drivers/staging/fwserial/fwserial.c tty->hw_stopped = 1; tty 361 drivers/staging/fwserial/fwserial.c tty_kref_put(tty); tty 444 drivers/staging/fwserial/fwserial.c struct tty_struct *tty; tty 447 drivers/staging/fwserial/fwserial.c tty = tty_port_tty_get(&port->port); tty 448 drivers/staging/fwserial/fwserial.c if (!tty) tty 455 drivers/staging/fwserial/fwserial.c if (C_CRTSCTS(tty)) tty 462 drivers/staging/fwserial/fwserial.c tty_kref_put(tty); tty 488 drivers/staging/fwserial/fwserial.c struct tty_struct *tty; tty 492 drivers/staging/fwserial/fwserial.c tty = tty_port_tty_get(&port->port); tty 493 drivers/staging/fwserial/fwserial.c if (tty) tty 494 drivers/staging/fwserial/fwserial.c tty_vhangup(tty); tty 495 drivers/staging/fwserial/fwserial.c tty_kref_put(tty); tty 704 drivers/staging/fwserial/fwserial.c struct tty_struct *tty; tty 707 drivers/staging/fwserial/fwserial.c tty = tty_port_tty_get(&port->port); tty 708 drivers/staging/fwserial/fwserial.c if (!tty) tty 725 drivers/staging/fwserial/fwserial.c while (!tty->stopped && !tty->hw_stopped && tty 782 drivers/staging/fwserial/fwserial.c tty_wakeup(tty); tty 790 drivers/staging/fwserial/fwserial.c tty_kref_put(tty); tty 925 drivers/staging/fwserial/fwserial.c static unsigned int set_termios(struct fwtty_port *port, struct tty_struct *tty) tty 929 drivers/staging/fwserial/fwserial.c baud = tty_termios_baud_rate(&tty->termios); tty 930 drivers/staging/fwserial/fwserial.c tty_termios_encode_baud_rate(&tty->termios, baud, baud); tty 933 drivers/staging/fwserial/fwserial.c frame = 12 + ((C_CSTOPB(tty)) ? 4 : 2) + ((C_PARENB(tty)) ? 2 : 0); tty 935 drivers/staging/fwserial/fwserial.c switch (C_CSIZE(tty)) { tty 937 drivers/staging/fwserial/fwserial.c frame -= (C_CSTOPB(tty)) ? 1 : 0; tty 953 drivers/staging/fwserial/fwserial.c if (_I_FLAG(tty, BRKINT | PARMRK)) tty 957 drivers/staging/fwserial/fwserial.c if (I_IGNBRK(tty)) { tty 959 drivers/staging/fwserial/fwserial.c if (I_IGNPAR(tty)) tty 963 drivers/staging/fwserial/fwserial.c port->write_only = !C_CREAD(tty); tty 967 drivers/staging/fwserial/fwserial.c tty->termios.c_lflag &= ~(ECHO | ECHOE | ECHOK | ECHOKE | tty 969 drivers/staging/fwserial/fwserial.c tty->termios.c_oflag &= ~ONLCR; tty 976 drivers/staging/fwserial/fwserial.c struct tty_struct *tty) tty 982 drivers/staging/fwserial/fwserial.c set_bit(TTY_IO_ERROR, &tty->flags); tty 994 drivers/staging/fwserial/fwserial.c baud = set_termios(port, tty); tty 1003 drivers/staging/fwserial/fwserial.c if (C_CRTSCTS(tty) && ~port->mstatus & TIOCM_CTS) tty 1004 drivers/staging/fwserial/fwserial.c tty->hw_stopped = 1; tty 1009 drivers/staging/fwserial/fwserial.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 1038 drivers/staging/fwserial/fwserial.c static int fwtty_open(struct tty_struct *tty, struct file *fp) tty 1040 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1042 drivers/staging/fwserial/fwserial.c return tty_port_open(&port->port, tty, fp); tty 1045 drivers/staging/fwserial/fwserial.c static void fwtty_close(struct tty_struct *tty, struct file *fp) tty 1047 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1049 drivers/staging/fwserial/fwserial.c tty_port_close(&port->port, tty, fp); tty 1052 drivers/staging/fwserial/fwserial.c static void fwtty_hangup(struct tty_struct *tty) tty 1054 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1059 drivers/staging/fwserial/fwserial.c static void fwtty_cleanup(struct tty_struct *tty) tty 1061 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1063 drivers/staging/fwserial/fwserial.c tty->driver_data = NULL; tty 1067 drivers/staging/fwserial/fwserial.c static int fwtty_install(struct tty_driver *driver, struct tty_struct *tty) tty 1069 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = fwtty_port_get(tty->index); tty 1072 drivers/staging/fwserial/fwserial.c err = tty_standard_install(driver, tty); tty 1074 drivers/staging/fwserial/fwserial.c tty->driver_data = port; tty 1080 drivers/staging/fwserial/fwserial.c static int fwloop_install(struct tty_driver *driver, struct tty_struct *tty) tty 1082 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = fwtty_port_get(table_idx(tty->index)); tty 1085 drivers/staging/fwserial/fwserial.c err = tty_standard_install(driver, tty); tty 1087 drivers/staging/fwserial/fwserial.c tty->driver_data = port; tty 1093 drivers/staging/fwserial/fwserial.c static int fwtty_write(struct tty_struct *tty, const unsigned char *buf, int c) tty 1095 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1116 drivers/staging/fwserial/fwserial.c static int fwtty_write_room(struct tty_struct *tty) tty 1118 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1130 drivers/staging/fwserial/fwserial.c static int fwtty_chars_in_buffer(struct tty_struct *tty) tty 1132 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1144 drivers/staging/fwserial/fwserial.c static void fwtty_send_xchar(struct tty_struct *tty, char ch) tty 1146 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1153 drivers/staging/fwserial/fwserial.c static void fwtty_throttle(struct tty_struct *tty) tty 1155 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1171 drivers/staging/fwserial/fwserial.c static void fwtty_unthrottle(struct tty_struct *tty) tty 1173 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1175 drivers/staging/fwserial/fwserial.c fwtty_dbg(port, "CRTSCTS: %d\n", C_CRTSCTS(tty) != 0); tty 1181 drivers/staging/fwserial/fwserial.c if (C_CRTSCTS(tty)) tty 1215 drivers/staging/fwserial/fwserial.c static int get_serial_info(struct tty_struct *tty, tty 1218 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1222 drivers/staging/fwserial/fwserial.c ss->line = port->port.tty->index; tty 1231 drivers/staging/fwserial/fwserial.c static int set_serial_info(struct tty_struct *tty, tty 1234 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1254 drivers/staging/fwserial/fwserial.c static int fwtty_ioctl(struct tty_struct *tty, unsigned int cmd, tty 1257 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1272 drivers/staging/fwserial/fwserial.c static void fwtty_set_termios(struct tty_struct *tty, struct ktermios *old) tty 1274 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1278 drivers/staging/fwserial/fwserial.c baud = set_termios(port, tty); tty 1283 drivers/staging/fwserial/fwserial.c if (C_CRTSCTS(tty) || !tty_throttled(tty)) tty 1292 drivers/staging/fwserial/fwserial.c if (!C_CRTSCTS(tty)) { tty 1293 drivers/staging/fwserial/fwserial.c tty->hw_stopped = 0; tty 1296 drivers/staging/fwserial/fwserial.c } else if (C_CRTSCTS(tty) && ~port->mstatus & TIOCM_CTS) { tty 1297 drivers/staging/fwserial/fwserial.c tty->hw_stopped = 1; tty 1311 drivers/staging/fwserial/fwserial.c static int fwtty_break_ctl(struct tty_struct *tty, int state) tty 1313 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1344 drivers/staging/fwserial/fwserial.c static int fwtty_tiocmget(struct tty_struct *tty) tty 1346 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1358 drivers/staging/fwserial/fwserial.c static int fwtty_tiocmset(struct tty_struct *tty, tty 1361 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1375 drivers/staging/fwserial/fwserial.c static int fwtty_get_icount(struct tty_struct *tty, tty 1378 drivers/staging/fwserial/fwserial.c struct fwtty_port *port = tty->driver_data; tty 1845 drivers/staging/fwserial/fwserial.c struct tty_struct *tty; tty 1848 drivers/staging/fwserial/fwserial.c tty = tty_port_tty_get(&port->port); tty 1849 drivers/staging/fwserial/fwserial.c if (tty) { tty 1850 drivers/staging/fwserial/fwserial.c tty_vhangup(tty); tty 1851 drivers/staging/fwserial/fwserial.c tty_kref_put(tty); tty 54 drivers/staging/gdm724x/gdm_tty.c static int gdm_tty_install(struct tty_driver *driver, struct tty_struct *tty) tty 60 drivers/staging/gdm724x/gdm_tty.c tty->driver->driver_name); tty 65 drivers/staging/gdm724x/gdm_tty.c gdm = gdm_table[ret][tty->index]; tty 73 drivers/staging/gdm724x/gdm_tty.c ret = tty_standard_install(driver, tty); tty 80 drivers/staging/gdm724x/gdm_tty.c tty->driver_data = gdm; tty 86 drivers/staging/gdm724x/gdm_tty.c static int gdm_tty_open(struct tty_struct *tty, struct file *filp) tty 88 drivers/staging/gdm724x/gdm_tty.c struct gdm *gdm = tty->driver_data; tty 90 drivers/staging/gdm724x/gdm_tty.c return tty_port_open(&gdm->port, tty, filp); tty 93 drivers/staging/gdm724x/gdm_tty.c static void gdm_tty_cleanup(struct tty_struct *tty) tty 95 drivers/staging/gdm724x/gdm_tty.c struct gdm *gdm = tty->driver_data; tty 100 drivers/staging/gdm724x/gdm_tty.c static void gdm_tty_hangup(struct tty_struct *tty) tty 102 drivers/staging/gdm724x/gdm_tty.c struct gdm *gdm = tty->driver_data; tty 107 drivers/staging/gdm724x/gdm_tty.c static void gdm_tty_close(struct tty_struct *tty, struct file *filp) tty 109 drivers/staging/gdm724x/gdm_tty.c struct gdm *gdm = tty->driver_data; tty 111 drivers/staging/gdm724x/gdm_tty.c tty_port_close(&gdm->port, tty, filp); tty 155 drivers/staging/gdm724x/gdm_tty.c static int gdm_tty_write(struct tty_struct *tty, const unsigned char *buf, tty 158 drivers/staging/gdm724x/gdm_tty.c struct gdm *gdm = tty->driver_data; tty 186 drivers/staging/gdm724x/gdm_tty.c static int gdm_tty_write_room(struct tty_struct *tty) tty 188 drivers/staging/gdm724x/gdm_tty.c struct gdm *gdm = tty->driver_data; tty 244 drivers/staging/gdm724x/gdm_tty.c struct tty_struct *tty; tty 256 drivers/staging/gdm724x/gdm_tty.c tty = tty_port_tty_get(&gdm->port); tty 257 drivers/staging/gdm724x/gdm_tty.c if (tty) { tty 258 drivers/staging/gdm724x/gdm_tty.c tty_vhangup(tty); tty 259 drivers/staging/gdm724x/gdm_tty.c tty_kref_put(tty); tty 289 drivers/staging/greybus/uart.c static int send_line_coding(struct gb_tty *tty) tty 293 drivers/staging/greybus/uart.c memcpy(&request, &tty->line_coding, tty 294 drivers/staging/greybus/uart.c sizeof(tty->line_coding)); tty 295 drivers/staging/greybus/uart.c return gb_operation_sync(tty->connection, GB_UART_TYPE_SET_LINE_CODING, tty 393 drivers/staging/greybus/uart.c static int gb_tty_install(struct tty_driver *driver, struct tty_struct *tty) tty 398 drivers/staging/greybus/uart.c gb_tty = get_gb_by_minor(tty->index); tty 402 drivers/staging/greybus/uart.c retval = tty_standard_install(driver, tty); tty 406 drivers/staging/greybus/uart.c tty->driver_data = gb_tty; tty 413 drivers/staging/greybus/uart.c static int gb_tty_open(struct tty_struct *tty, struct file *file) tty 415 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 417 drivers/staging/greybus/uart.c return tty_port_open(&gb_tty->port, tty, file); tty 420 drivers/staging/greybus/uart.c static void gb_tty_close(struct tty_struct *tty, struct file *file) tty 422 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 424 drivers/staging/greybus/uart.c tty_port_close(&gb_tty->port, tty, file); tty 427 drivers/staging/greybus/uart.c static void gb_tty_cleanup(struct tty_struct *tty) tty 429 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 434 drivers/staging/greybus/uart.c static void gb_tty_hangup(struct tty_struct *tty) tty 436 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 441 drivers/staging/greybus/uart.c static int gb_tty_write(struct tty_struct *tty, const unsigned char *buf, tty 444 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 454 drivers/staging/greybus/uart.c static int gb_tty_write_room(struct tty_struct *tty) tty 456 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 471 drivers/staging/greybus/uart.c static int gb_tty_chars_in_buffer(struct tty_struct *tty) tty 473 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 486 drivers/staging/greybus/uart.c static int gb_tty_break_ctl(struct tty_struct *tty, int state) tty 488 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 493 drivers/staging/greybus/uart.c static void gb_tty_set_termios(struct tty_struct *tty, tty 496 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 497 drivers/staging/greybus/uart.c struct ktermios *termios = &tty->termios; tty 501 drivers/staging/greybus/uart.c newline.rate = cpu_to_le32(tty_get_baud_rate(tty)); tty 527 drivers/staging/greybus/uart.c if (C_BAUD(tty) == B0) { tty 539 drivers/staging/greybus/uart.c if (C_CRTSCTS(tty) && C_BAUD(tty) != B0) tty 550 drivers/staging/greybus/uart.c static int gb_tty_tiocmget(struct tty_struct *tty) tty 552 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 562 drivers/staging/greybus/uart.c static int gb_tty_tiocmset(struct tty_struct *tty, unsigned int set, tty 565 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 581 drivers/staging/greybus/uart.c static void gb_tty_throttle(struct tty_struct *tty) tty 583 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 587 drivers/staging/greybus/uart.c if (I_IXOFF(tty)) { tty 588 drivers/staging/greybus/uart.c stop_char = STOP_CHAR(tty); tty 589 drivers/staging/greybus/uart.c retval = gb_tty_write(tty, &stop_char, 1); tty 594 drivers/staging/greybus/uart.c if (tty->termios.c_cflag & CRTSCTS) { tty 600 drivers/staging/greybus/uart.c static void gb_tty_unthrottle(struct tty_struct *tty) tty 602 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 606 drivers/staging/greybus/uart.c if (I_IXOFF(tty)) { tty 607 drivers/staging/greybus/uart.c start_char = START_CHAR(tty); tty 608 drivers/staging/greybus/uart.c retval = gb_tty_write(tty, &start_char, 1); tty 613 drivers/staging/greybus/uart.c if (tty->termios.c_cflag & CRTSCTS) { tty 619 drivers/staging/greybus/uart.c static int get_serial_info(struct tty_struct *tty, tty 622 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 635 drivers/staging/greybus/uart.c static int set_serial_info(struct tty_struct *tty, tty 638 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 702 drivers/staging/greybus/uart.c static int gb_tty_get_icount(struct tty_struct *tty, tty 705 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 718 drivers/staging/greybus/uart.c static int gb_tty_ioctl(struct tty_struct *tty, unsigned int cmd, tty 721 drivers/staging/greybus/uart.c struct gb_tty *gb_tty = tty->driver_data; tty 749 drivers/staging/greybus/uart.c struct tty_struct *tty) tty 938 drivers/staging/greybus/uart.c struct tty_struct *tty; tty 951 drivers/staging/greybus/uart.c tty = tty_port_tty_get(&gb_tty->port); tty 952 drivers/staging/greybus/uart.c if (tty) { tty 953 drivers/staging/greybus/uart.c tty_vhangup(tty); tty 954 drivers/staging/greybus/uart.c tty_kref_put(tty); tty 1026 drivers/staging/isdn/gigaset/common.c struct cardstate *gigaset_get_cs_by_tty(struct tty_struct *tty) tty 1028 drivers/staging/isdn/gigaset/common.c return gigaset_get_cs_by_minor(tty->index + tty->driver->minor_start); tty 507 drivers/staging/isdn/gigaset/gigaset.h struct tty_driver *tty; tty 729 drivers/staging/isdn/gigaset/gigaset.h struct cardstate *gigaset_get_cs_by_tty(struct tty_struct *tty); tty 113 drivers/staging/isdn/gigaset/interface.c static int if_open(struct tty_struct *tty, struct file *filp) tty 118 drivers/staging/isdn/gigaset/interface.c tty->driver->minor_start, tty->index, __func__); tty 120 drivers/staging/isdn/gigaset/interface.c cs = gigaset_get_cs_by_tty(tty); tty 128 drivers/staging/isdn/gigaset/interface.c tty->driver_data = cs; tty 133 drivers/staging/isdn/gigaset/interface.c tty_port_tty_set(&cs->port, tty); tty 141 drivers/staging/isdn/gigaset/interface.c static void if_close(struct tty_struct *tty, struct file *filp) tty 143 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 166 drivers/staging/isdn/gigaset/interface.c static int if_ioctl(struct tty_struct *tty, tty 169 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 234 drivers/staging/isdn/gigaset/interface.c static long if_compat_ioctl(struct tty_struct *tty, tty 237 drivers/staging/isdn/gigaset/interface.c return if_ioctl(tty, cmd, (unsigned long)compat_ptr(arg)); tty 241 drivers/staging/isdn/gigaset/interface.c static int if_tiocmget(struct tty_struct *tty) tty 243 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 258 drivers/staging/isdn/gigaset/interface.c static int if_tiocmset(struct tty_struct *tty, tty 261 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 285 drivers/staging/isdn/gigaset/interface.c static int if_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 287 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 330 drivers/staging/isdn/gigaset/interface.c static int if_write_room(struct tty_struct *tty) tty 332 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 354 drivers/staging/isdn/gigaset/interface.c static int if_chars_in_buffer(struct tty_struct *tty) tty 356 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 375 drivers/staging/isdn/gigaset/interface.c static void if_throttle(struct tty_struct *tty) tty 377 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 391 drivers/staging/isdn/gigaset/interface.c static void if_unthrottle(struct tty_struct *tty) tty 393 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 407 drivers/staging/isdn/gigaset/interface.c static void if_set_termios(struct tty_struct *tty, struct ktermios *old) tty 409 drivers/staging/isdn/gigaset/interface.c struct cardstate *cs = tty->driver_data; tty 424 drivers/staging/isdn/gigaset/interface.c iflag = tty->termios.c_iflag; tty 425 drivers/staging/isdn/gigaset/interface.c cflag = tty->termios.c_cflag; tty 515 drivers/staging/isdn/gigaset/interface.c cs->tty_dev = tty_port_register_device(&cs->port, drv->tty, tty 538 drivers/staging/isdn/gigaset/interface.c tty_unregister_device(drv->tty, cs->minor_index); tty 569 drivers/staging/isdn/gigaset/interface.c struct tty_driver *tty; tty 573 drivers/staging/isdn/gigaset/interface.c drv->tty = tty = alloc_tty_driver(drv->minors); tty 574 drivers/staging/isdn/gigaset/interface.c if (tty == NULL) tty 577 drivers/staging/isdn/gigaset/interface.c tty->type = TTY_DRIVER_TYPE_SERIAL; tty 578 drivers/staging/isdn/gigaset/interface.c tty->subtype = SERIAL_TYPE_NORMAL; tty 579 drivers/staging/isdn/gigaset/interface.c tty->flags = TTY_DRIVER_REAL_RAW | TTY_DRIVER_DYNAMIC_DEV; tty 581 drivers/staging/isdn/gigaset/interface.c tty->driver_name = procname; tty 582 drivers/staging/isdn/gigaset/interface.c tty->name = devname; tty 583 drivers/staging/isdn/gigaset/interface.c tty->minor_start = drv->minor; tty 585 drivers/staging/isdn/gigaset/interface.c tty->init_termios = tty_std_termios; tty 586 drivers/staging/isdn/gigaset/interface.c tty->init_termios.c_cflag = B9600 | CS8 | CREAD | HUPCL | CLOCAL; tty 587 drivers/staging/isdn/gigaset/interface.c tty_set_operations(tty, &if_ops); tty 589 drivers/staging/isdn/gigaset/interface.c ret = tty_register_driver(tty); tty 601 drivers/staging/isdn/gigaset/interface.c if (drv->tty) tty 602 drivers/staging/isdn/gigaset/interface.c put_tty_driver(drv->tty); tty 611 drivers/staging/isdn/gigaset/interface.c tty_unregister_driver(drv->tty); tty 612 drivers/staging/isdn/gigaset/interface.c put_tty_driver(drv->tty); tty 44 drivers/staging/isdn/gigaset/ser-gigaset.c struct tty_struct *tty; tty 62 drivers/staging/isdn/gigaset/ser-gigaset.c struct tty_struct *tty = cs->hw.ser->tty; tty 67 drivers/staging/isdn/gigaset/ser-gigaset.c WARN_ON(!tty || !tty->ops || !skb); tty 75 drivers/staging/isdn/gigaset/ser-gigaset.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 76 drivers/staging/isdn/gigaset/ser-gigaset.c if (tty->ops->write) tty 77 drivers/staging/isdn/gigaset/ser-gigaset.c sent = tty->ops->write(tty, skb->data, skb->len); tty 103 drivers/staging/isdn/gigaset/ser-gigaset.c struct tty_struct *tty = cs->hw.ser->tty; tty 108 drivers/staging/isdn/gigaset/ser-gigaset.c WARN_ON(!tty || !tty->ops); tty 115 drivers/staging/isdn/gigaset/ser-gigaset.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 116 drivers/staging/isdn/gigaset/ser-gigaset.c sent = tty->ops->write(tty, cb->buf + cb->offset, cb->len); tty 419 drivers/staging/isdn/gigaset/ser-gigaset.c struct tty_struct *tty = cs->hw.ser->tty; tty 422 drivers/staging/isdn/gigaset/ser-gigaset.c WARN_ON(!tty || !tty->ops); tty 424 drivers/staging/isdn/gigaset/ser-gigaset.c if (!tty->ops->tiocmset) tty 431 drivers/staging/isdn/gigaset/ser-gigaset.c return tty->ops->tiocmset(tty, set, clear); tty 468 drivers/staging/isdn/gigaset/ser-gigaset.c static struct cardstate *cs_get(struct tty_struct *tty) tty 470 drivers/staging/isdn/gigaset/ser-gigaset.c struct cardstate *cs = tty->disc_data; tty 491 drivers/staging/isdn/gigaset/ser-gigaset.c gigaset_tty_open(struct tty_struct *tty) tty 513 drivers/staging/isdn/gigaset/ser-gigaset.c cs->hw.ser->tty = tty; tty 516 drivers/staging/isdn/gigaset/ser-gigaset.c tty->disc_data = cs; tty 526 drivers/staging/isdn/gigaset/ser-gigaset.c tty->receive_room = RBUFSIZE/2; tty 544 drivers/staging/isdn/gigaset/ser-gigaset.c tty->disc_data = NULL; tty 554 drivers/staging/isdn/gigaset/ser-gigaset.c gigaset_tty_close(struct tty_struct *tty) tty 556 drivers/staging/isdn/gigaset/ser-gigaset.c struct cardstate *cs = tty->disc_data; tty 566 drivers/staging/isdn/gigaset/ser-gigaset.c tty->disc_data = NULL; tty 592 drivers/staging/isdn/gigaset/ser-gigaset.c static int gigaset_tty_hangup(struct tty_struct *tty) tty 594 drivers/staging/isdn/gigaset/ser-gigaset.c gigaset_tty_close(tty); tty 604 drivers/staging/isdn/gigaset/ser-gigaset.c gigaset_tty_ioctl(struct tty_struct *tty, struct file *file, tty 607 drivers/staging/isdn/gigaset/ser-gigaset.c struct cardstate *cs = cs_get(tty); tty 637 drivers/staging/isdn/gigaset/ser-gigaset.c rc = n_tty_ioctl_helper(tty, file, cmd, arg); tty 657 drivers/staging/isdn/gigaset/ser-gigaset.c gigaset_tty_receive(struct tty_struct *tty, const unsigned char *buf, tty 660 drivers/staging/isdn/gigaset/ser-gigaset.c struct cardstate *cs = cs_get(tty); tty 713 drivers/staging/isdn/gigaset/ser-gigaset.c gigaset_tty_wakeup(struct tty_struct *tty) tty 715 drivers/staging/isdn/gigaset/ser-gigaset.c struct cardstate *cs = cs_get(tty); tty 717 drivers/staging/isdn/gigaset/ser-gigaset.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 31 drivers/staging/speakup/buffers.c if (vc_cons[i].d && vc_cons[i].d->port.tty) tty 32 drivers/staging/speakup/buffers.c start_tty(vc_cons[i].d->port.tty); tty 42 drivers/staging/speakup/buffers.c if (vc_cons[i].d && vc_cons[i].d->port.tty) tty 43 drivers/staging/speakup/buffers.c stop_tty(vc_cons[i].d->port.tty); tty 107 drivers/staging/speakup/main.c static struct tty_struct *tty; tty 361 drivers/staging/speakup/main.c ret = speakup_set_selection(tty); tty 385 drivers/staging/speakup/main.c speakup_paste_selection(tty); tty 2111 drivers/staging/speakup/main.c tty = vc->port.tty; tty 22 drivers/staging/speakup/selection.c struct tty_struct *tty; tty 37 drivers/staging/speakup/selection.c struct tty_struct *tty; tty 46 drivers/staging/speakup/selection.c tty = xchg(&ssw->tty, NULL); tty 54 drivers/staging/speakup/selection.c set_selection_kernel(&sel, tty); tty 57 drivers/staging/speakup/selection.c tty_kref_put(tty); tty 65 drivers/staging/speakup/selection.c int speakup_set_selection(struct tty_struct *tty) tty 73 drivers/staging/speakup/selection.c tty_kref_get(tty); tty 74 drivers/staging/speakup/selection.c if (cmpxchg(&speakup_sel_work.tty, NULL, tty)) { tty 75 drivers/staging/speakup/selection.c tty_kref_put(tty); tty 97 drivers/staging/speakup/selection.c struct tty_struct *tty; tty 104 drivers/staging/speakup/selection.c tty = xchg(&speakup_sel_work.tty, NULL); tty 105 drivers/staging/speakup/selection.c if (tty) tty 106 drivers/staging/speakup/selection.c tty_kref_put(tty); tty 113 drivers/staging/speakup/selection.c struct tty_struct *tty = xchg(&ssw->tty, NULL); tty 115 drivers/staging/speakup/selection.c paste_selection(tty); tty 116 drivers/staging/speakup/selection.c tty_kref_put(tty); tty 124 drivers/staging/speakup/selection.c int speakup_paste_selection(struct tty_struct *tty) tty 126 drivers/staging/speakup/selection.c tty_kref_get(tty); tty 127 drivers/staging/speakup/selection.c if (cmpxchg(&speakup_paste_work.tty, NULL, tty)) { tty 128 drivers/staging/speakup/selection.c tty_kref_put(tty); tty 138 drivers/staging/speakup/selection.c struct tty_struct *tty; tty 141 drivers/staging/speakup/selection.c tty = xchg(&speakup_paste_work.tty, NULL); tty 142 drivers/staging/speakup/selection.c if (tty) tty 143 drivers/staging/speakup/selection.c tty_kref_put(tty); tty 74 drivers/staging/speakup/speakup.h int speakup_set_selection(struct tty_struct *tty); tty 76 drivers/staging/speakup/speakup.h int speakup_paste_selection(struct tty_struct *tty); tty 46 drivers/staging/speakup/spk_ttyio.c static int spk_ttyio_ldisc_open(struct tty_struct *tty) tty 50 drivers/staging/speakup/spk_ttyio.c if (!tty->ops->write) tty 52 drivers/staging/speakup/spk_ttyio.c speakup_tty = tty; tty 65 drivers/staging/speakup/spk_ttyio.c static void spk_ttyio_ldisc_close(struct tty_struct *tty) tty 73 drivers/staging/speakup/spk_ttyio.c static int spk_ttyio_receive_buf2(struct tty_struct *tty, tty 76 drivers/staging/speakup/spk_ttyio.c struct spk_ldisc_data *ldisc_data = tty->disc_data; tty 131 drivers/staging/speakup/spk_ttyio.c static inline void get_termios(struct tty_struct *tty, tty 134 drivers/staging/speakup/spk_ttyio.c down_read(&tty->termios_rwsem); tty 135 drivers/staging/speakup/spk_ttyio.c *out_termios = tty->termios; tty 136 drivers/staging/speakup/spk_ttyio.c up_read(&tty->termios_rwsem); tty 142 drivers/staging/speakup/spk_ttyio.c struct tty_struct *tty; tty 150 drivers/staging/speakup/spk_ttyio.c tty = tty_kopen(dev); tty 151 drivers/staging/speakup/spk_ttyio.c if (IS_ERR(tty)) tty 152 drivers/staging/speakup/spk_ttyio.c return PTR_ERR(tty); tty 154 drivers/staging/speakup/spk_ttyio.c if (tty->ops->open) tty 155 drivers/staging/speakup/spk_ttyio.c ret = tty->ops->open(tty, NULL); tty 160 drivers/staging/speakup/spk_ttyio.c tty_unlock(tty); tty 164 drivers/staging/speakup/spk_ttyio.c clear_bit(TTY_HUPPED, &tty->flags); tty 166 drivers/staging/speakup/spk_ttyio.c get_termios(tty, &tmp_termios); tty 169 drivers/staging/speakup/spk_ttyio.c tty_set_termios(tty, &tmp_termios); tty 175 drivers/staging/speakup/spk_ttyio.c get_termios(tty, &tmp_termios); tty 180 drivers/staging/speakup/spk_ttyio.c tty_unlock(tty); tty 182 drivers/staging/speakup/spk_ttyio.c ret = tty_set_ldisc(tty, N_SPEAKUP); tty 246 drivers/staging/speakup/spk_ttyio.c static int check_tty(struct tty_struct *tty) tty 248 drivers/staging/speakup/spk_ttyio.c if (!tty) { tty 48 drivers/tty/amiserial.c tty->name, (info->tport.flags), serial_driver->refcount,info->count,tty->count,s) tty 122 drivers/tty/amiserial.c static void change_speed(struct tty_struct *tty, struct serial_state *info, tty 124 drivers/tty/amiserial.c static void rs_wait_until_sent(struct tty_struct *tty, int timeout); tty 187 drivers/tty/amiserial.c static void rs_stop(struct tty_struct *tty) tty 189 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 192 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_stop")) tty 207 drivers/tty/amiserial.c static void rs_start(struct tty_struct *tty) tty 209 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 212 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_start")) tty 316 drivers/tty/amiserial.c do_SAK(info->tport.tty); tty 350 drivers/tty/amiserial.c || info->tport.tty->stopped tty 351 drivers/tty/amiserial.c || info->tport.tty->hw_stopped) { tty 366 drivers/tty/amiserial.c tty_wakeup(info->tport.tty); tty 413 drivers/tty/amiserial.c if (port->tty) tty 414 drivers/tty/amiserial.c tty_hangup(port->tty); tty 418 drivers/tty/amiserial.c if (port->tty->hw_stopped) { tty 423 drivers/tty/amiserial.c port->tty->hw_stopped = 0; tty 430 drivers/tty/amiserial.c tty_wakeup(port->tty); tty 438 drivers/tty/amiserial.c port->tty->hw_stopped = 1; tty 471 drivers/tty/amiserial.c if (!info->tport.tty) tty 490 drivers/tty/amiserial.c if (!info->tport.tty) tty 516 drivers/tty/amiserial.c static int startup(struct tty_struct *tty, struct serial_state *info) tty 551 drivers/tty/amiserial.c set_bit(TTY_IO_ERROR, &tty->flags); tty 566 drivers/tty/amiserial.c if (C_BAUD(tty)) tty 570 drivers/tty/amiserial.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 576 drivers/tty/amiserial.c change_speed(tty, info, NULL); tty 591 drivers/tty/amiserial.c static void shutdown(struct tty_struct *tty, struct serial_state *info) tty 631 drivers/tty/amiserial.c if (C_HUPCL(tty)) tty 635 drivers/tty/amiserial.c set_bit(TTY_IO_ERROR, &tty->flags); tty 646 drivers/tty/amiserial.c static void change_speed(struct tty_struct *tty, struct serial_state *info, tty 655 drivers/tty/amiserial.c cflag = tty->termios.c_cflag; tty 676 drivers/tty/amiserial.c baud = tty_get_baud_rate(tty); tty 692 drivers/tty/amiserial.c tty->termios.c_cflag &= ~CBAUD; tty 693 drivers/tty/amiserial.c tty->termios.c_cflag |= (old_termios->c_cflag & CBAUD); tty 694 drivers/tty/amiserial.c baud = tty_get_baud_rate(tty); tty 734 drivers/tty/amiserial.c if (I_INPCK(tty)) tty 736 drivers/tty/amiserial.c if (I_BRKINT(tty) || I_PARMRK(tty)) tty 743 drivers/tty/amiserial.c if (I_IGNPAR(tty)) tty 745 drivers/tty/amiserial.c if (I_IGNBRK(tty)) { tty 751 drivers/tty/amiserial.c if (I_IGNPAR(tty)) tty 779 drivers/tty/amiserial.c static int rs_put_char(struct tty_struct *tty, unsigned char ch) tty 784 drivers/tty/amiserial.c info = tty->driver_data; tty 786 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_put_char")) tty 806 drivers/tty/amiserial.c static void rs_flush_chars(struct tty_struct *tty) tty 808 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 811 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_flush_chars")) tty 815 drivers/tty/amiserial.c || tty->stopped tty 816 drivers/tty/amiserial.c || tty->hw_stopped tty 830 drivers/tty/amiserial.c static int rs_write(struct tty_struct * tty, const unsigned char *buf, int count) tty 833 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 836 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_write")) tty 862 drivers/tty/amiserial.c && !tty->stopped tty 863 drivers/tty/amiserial.c && !tty->hw_stopped tty 877 drivers/tty/amiserial.c static int rs_write_room(struct tty_struct *tty) tty 879 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 881 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_write_room")) tty 886 drivers/tty/amiserial.c static int rs_chars_in_buffer(struct tty_struct *tty) tty 888 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 890 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_chars_in_buffer")) tty 895 drivers/tty/amiserial.c static void rs_flush_buffer(struct tty_struct *tty) tty 897 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 900 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_flush_buffer")) tty 905 drivers/tty/amiserial.c tty_wakeup(tty); tty 912 drivers/tty/amiserial.c static void rs_send_xchar(struct tty_struct *tty, char ch) tty 914 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 917 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_send_xchar")) tty 947 drivers/tty/amiserial.c static void rs_throttle(struct tty_struct * tty) tty 949 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 952 drivers/tty/amiserial.c printk("throttle %s ....\n", tty_name(tty)); tty 955 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_throttle")) tty 958 drivers/tty/amiserial.c if (I_IXOFF(tty)) tty 959 drivers/tty/amiserial.c rs_send_xchar(tty, STOP_CHAR(tty)); tty 961 drivers/tty/amiserial.c if (C_CRTSCTS(tty)) tty 969 drivers/tty/amiserial.c static void rs_unthrottle(struct tty_struct * tty) tty 971 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 974 drivers/tty/amiserial.c printk("unthrottle %s ....\n", tty_name(tty)); tty 977 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_unthrottle")) tty 980 drivers/tty/amiserial.c if (I_IXOFF(tty)) { tty 984 drivers/tty/amiserial.c rs_send_xchar(tty, START_CHAR(tty)); tty 986 drivers/tty/amiserial.c if (C_CRTSCTS(tty)) tty 999 drivers/tty/amiserial.c static int get_serial_info(struct tty_struct *tty, struct serial_struct *ss) tty 1001 drivers/tty/amiserial.c struct serial_state *state = tty->driver_data; tty 1003 drivers/tty/amiserial.c tty_lock(tty); tty 1004 drivers/tty/amiserial.c ss->line = tty->index; tty 1012 drivers/tty/amiserial.c tty_unlock(tty); tty 1016 drivers/tty/amiserial.c static int set_serial_info(struct tty_struct *tty, struct serial_struct *ss) tty 1018 drivers/tty/amiserial.c struct serial_state *state = tty->driver_data; tty 1023 drivers/tty/amiserial.c tty_lock(tty); tty 1028 drivers/tty/amiserial.c tty_unlock(tty); tty 1038 drivers/tty/amiserial.c tty_unlock(tty); tty 1048 drivers/tty/amiserial.c tty_unlock(tty); tty 1070 drivers/tty/amiserial.c dev_warn_ratelimited(tty->dev, "use of SPD flags is deprecated\n"); tty 1071 drivers/tty/amiserial.c change_speed(tty, state, NULL); tty 1074 drivers/tty/amiserial.c retval = startup(tty, state); tty 1075 drivers/tty/amiserial.c tty_unlock(tty); tty 1106 drivers/tty/amiserial.c static int rs_tiocmget(struct tty_struct *tty) tty 1108 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 1112 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_ioctl")) tty 1114 drivers/tty/amiserial.c if (tty_io_error(tty)) tty 1128 drivers/tty/amiserial.c static int rs_tiocmset(struct tty_struct *tty, unsigned int set, tty 1131 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 1134 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_ioctl")) tty 1136 drivers/tty/amiserial.c if (tty_io_error(tty)) tty 1156 drivers/tty/amiserial.c static int rs_break(struct tty_struct *tty, int break_state) tty 1158 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 1161 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_break")) tty 1180 drivers/tty/amiserial.c static int rs_get_icount(struct tty_struct *tty, tty 1183 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 1205 drivers/tty/amiserial.c static int rs_ioctl(struct tty_struct *tty, tty 1208 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 1215 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_ioctl")) tty 1220 drivers/tty/amiserial.c if (tty_io_error(tty)) tty 1277 drivers/tty/amiserial.c static void rs_set_termios(struct tty_struct *tty, struct ktermios *old_termios) tty 1279 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 1281 drivers/tty/amiserial.c unsigned int cflag = tty->termios.c_cflag; tty 1283 drivers/tty/amiserial.c change_speed(tty, info, old_termios); tty 1296 drivers/tty/amiserial.c if (!C_CRTSCTS(tty) || !tty_throttled(tty)) tty 1304 drivers/tty/amiserial.c if ((old_termios->c_cflag & CRTSCTS) && !C_CRTSCTS(tty)) { tty 1305 drivers/tty/amiserial.c tty->hw_stopped = 0; tty 1306 drivers/tty/amiserial.c rs_start(tty); tty 1316 drivers/tty/amiserial.c if (!(old_termios->c_cflag & CLOCAL) && C_CLOCAL(tty)) tty 1331 drivers/tty/amiserial.c static void rs_close(struct tty_struct *tty, struct file * filp) tty 1333 drivers/tty/amiserial.c struct serial_state *state = tty->driver_data; tty 1336 drivers/tty/amiserial.c if (serial_paranoia_check(state, tty->name, "rs_close")) tty 1339 drivers/tty/amiserial.c if (tty_port_close_start(port, tty, filp) == 0) tty 1362 drivers/tty/amiserial.c rs_wait_until_sent(tty, state->timeout); tty 1364 drivers/tty/amiserial.c shutdown(tty, state); tty 1365 drivers/tty/amiserial.c rs_flush_buffer(tty); tty 1367 drivers/tty/amiserial.c tty_ldisc_flush(tty); tty 1368 drivers/tty/amiserial.c port->tty = NULL; tty 1370 drivers/tty/amiserial.c tty_port_close_end(port, tty); tty 1376 drivers/tty/amiserial.c static void rs_wait_until_sent(struct tty_struct *tty, int timeout) tty 1378 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 1382 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_wait_until_sent")) tty 1439 drivers/tty/amiserial.c static void rs_hangup(struct tty_struct *tty) tty 1441 drivers/tty/amiserial.c struct serial_state *info = tty->driver_data; tty 1443 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_hangup")) tty 1446 drivers/tty/amiserial.c rs_flush_buffer(tty); tty 1447 drivers/tty/amiserial.c shutdown(tty, info); tty 1450 drivers/tty/amiserial.c info->tport.tty = NULL; tty 1460 drivers/tty/amiserial.c static int rs_open(struct tty_struct *tty, struct file * filp) tty 1462 drivers/tty/amiserial.c struct serial_state *info = rs_table + tty->index; tty 1467 drivers/tty/amiserial.c port->tty = tty; tty 1468 drivers/tty/amiserial.c tty->driver_data = info; tty 1469 drivers/tty/amiserial.c tty->port = port; tty 1470 drivers/tty/amiserial.c if (serial_paranoia_check(info, tty->name, "rs_open")) tty 1475 drivers/tty/amiserial.c retval = startup(tty, info); tty 1480 drivers/tty/amiserial.c return tty_port_block_til_ready(port, tty, filp); tty 91 drivers/tty/cyclades.c static void cy_send_xchar(struct tty_struct *tty, char ch); tty 484 drivers/tty/cyclades.c struct tty_struct *tty = tty 486 drivers/tty/cyclades.c if (tty) { tty 487 drivers/tty/cyclades.c do_SAK(tty); tty 488 drivers/tty/cyclades.c tty_kref_put(tty); tty 570 drivers/tty/cyclades.c struct tty_struct *tty; tty 588 drivers/tty/cyclades.c tty = tty_port_tty_get(&info->port); tty 589 drivers/tty/cyclades.c if (tty == NULL) { tty 636 drivers/tty/cyclades.c if (tty->stopped || tty->hw_stopped) { tty 671 drivers/tty/cyclades.c tty_wakeup(tty); tty 672 drivers/tty/cyclades.c tty_kref_put(tty); tty 683 drivers/tty/cyclades.c struct tty_struct *tty; tty 697 drivers/tty/cyclades.c tty = tty_port_tty_get(&info->port); tty 698 drivers/tty/cyclades.c if (!tty) tty 719 drivers/tty/cyclades.c tty_hangup(tty); tty 722 drivers/tty/cyclades.c if (tty->hw_stopped) { tty 726 drivers/tty/cyclades.c tty->hw_stopped = 0; tty 729 drivers/tty/cyclades.c tty_wakeup(tty); tty 735 drivers/tty/cyclades.c tty->hw_stopped = 1; tty 745 drivers/tty/cyclades.c tty_kref_put(tty); tty 1009 drivers/tty/cyclades.c struct tty_struct *tty; tty 1032 drivers/tty/cyclades.c tty = tty_port_tty_get(&info->port); tty 1033 drivers/tty/cyclades.c if (tty == NULL) tty 1076 drivers/tty/cyclades.c tty_wakeup(tty); tty 1077 drivers/tty/cyclades.c tty_kref_put(tty); tty 1261 drivers/tty/cyclades.c static int cy_startup(struct cyclades_port *info, struct tty_struct *tty) tty 1282 drivers/tty/cyclades.c set_bit(TTY_IO_ERROR, &tty->flags); tty 1293 drivers/tty/cyclades.c cy_set_line_char(info, tty); tty 1365 drivers/tty/cyclades.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 1418 drivers/tty/cyclades.c static void cy_shutdown(struct cyclades_port *info, struct tty_struct *tty) tty 1439 drivers/tty/cyclades.c if (C_HUPCL(tty)) tty 1446 drivers/tty/cyclades.c set_bit(TTY_IO_ERROR, &tty->flags); tty 1468 drivers/tty/cyclades.c if (C_HUPCL(tty)) tty 1471 drivers/tty/cyclades.c set_bit(TTY_IO_ERROR, &tty->flags); tty 1492 drivers/tty/cyclades.c static int cy_open(struct tty_struct *tty, struct file *filp) tty 1495 drivers/tty/cyclades.c unsigned int i, line = tty->index; tty 1561 drivers/tty/cyclades.c tty->driver_data = info; tty 1562 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_open")) tty 1578 drivers/tty/cyclades.c retval = cy_startup(info, tty); tty 1582 drivers/tty/cyclades.c retval = tty_port_block_til_ready(&info->port, tty, filp); tty 1592 drivers/tty/cyclades.c tty_port_tty_set(&info->port, tty); tty 1603 drivers/tty/cyclades.c static void cy_wait_until_sent(struct tty_struct *tty, int timeout) tty 1606 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 1610 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_wait_until_sent")) tty 1659 drivers/tty/cyclades.c static void cy_flush_buffer(struct tty_struct *tty) tty 1661 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 1670 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_flush_buffer")) tty 1690 drivers/tty/cyclades.c tty_wakeup(tty); tty 1714 drivers/tty/cyclades.c cy_wait_until_sent(port->tty, info->timeout); tty 1737 drivers/tty/cyclades.c cy_shutdown(info, port->tty); tty 1743 drivers/tty/cyclades.c static void cy_close(struct tty_struct *tty, struct file *filp) tty 1745 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 1746 drivers/tty/cyclades.c if (!info || serial_paranoia_check(info, tty->name, "cy_close")) tty 1748 drivers/tty/cyclades.c tty_port_close(&info->port, tty, filp); tty 1764 drivers/tty/cyclades.c static int cy_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 1766 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 1774 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_write")) tty 1801 drivers/tty/cyclades.c if (info->xmit_cnt && !tty->stopped && !tty->hw_stopped) tty 1814 drivers/tty/cyclades.c static int cy_put_char(struct tty_struct *tty, unsigned char ch) tty 1816 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 1823 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_put_char")) tty 1848 drivers/tty/cyclades.c static void cy_flush_chars(struct tty_struct *tty) tty 1850 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 1856 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_flush_chars")) tty 1859 drivers/tty/cyclades.c if (info->xmit_cnt <= 0 || tty->stopped || tty->hw_stopped || tty 1872 drivers/tty/cyclades.c static int cy_write_room(struct tty_struct *tty) tty 1874 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 1881 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_write_room")) tty 1889 drivers/tty/cyclades.c static int cy_chars_in_buffer(struct tty_struct *tty) tty 1891 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 1893 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_chars_in_buffer")) tty 1961 drivers/tty/cyclades.c static void cy_set_line_char(struct cyclades_port *info, struct tty_struct *tty) tty 1973 drivers/tty/cyclades.c cflag = tty->termios.c_cflag; tty 1974 drivers/tty/cyclades.c iflag = tty->termios.c_iflag; tty 1983 drivers/tty/cyclades.c baud = tty_get_baud_rate(tty); tty 2101 drivers/tty/cyclades.c cyy_writeb(info, CySCHR1, START_CHAR(tty)); tty 2102 drivers/tty/cyclades.c cyy_writeb(info, CySCHR2, STOP_CHAR(tty)); tty 2119 drivers/tty/cyclades.c if (!C_CLOCAL(tty)) tty 2136 drivers/tty/cyclades.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 2148 drivers/tty/cyclades.c baud = tty_get_baud_rate(tty); tty 2256 drivers/tty/cyclades.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 2260 drivers/tty/cyclades.c static int cy_get_serial_info(struct tty_struct *tty, tty 2263 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2266 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_ioctl")) tty 2281 drivers/tty/cyclades.c static int cy_set_serial_info(struct tty_struct *tty, tty 2284 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2288 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_ioctl")) tty 2329 drivers/tty/cyclades.c dev_warn_ratelimited(tty->dev, "use of SPD flags is deprecated\n"); tty 2331 drivers/tty/cyclades.c cy_set_line_char(info, tty); tty 2334 drivers/tty/cyclades.c ret = cy_startup(info, tty); tty 2369 drivers/tty/cyclades.c static int cy_tiocmget(struct tty_struct *tty) tty 2371 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2375 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, __func__)) tty 2423 drivers/tty/cyclades.c cy_tiocmset(struct tty_struct *tty, tty 2426 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2430 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, __func__)) tty 2479 drivers/tty/cyclades.c static int cy_break(struct tty_struct *tty, int break_state) tty 2481 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2486 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_break")) tty 2620 drivers/tty/cyclades.c cy_ioctl(struct tty_struct *tty, tty 2623 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2629 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_ioctl")) tty 2736 drivers/tty/cyclades.c static int cy_get_icount(struct tty_struct *tty, tty 2739 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2767 drivers/tty/cyclades.c static void cy_set_termios(struct tty_struct *tty, struct ktermios *old_termios) tty 2769 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2775 drivers/tty/cyclades.c cy_set_line_char(info, tty); tty 2777 drivers/tty/cyclades.c if ((old_termios->c_cflag & CRTSCTS) && !C_CRTSCTS(tty)) { tty 2778 drivers/tty/cyclades.c tty->hw_stopped = 0; tty 2779 drivers/tty/cyclades.c cy_start(tty); tty 2788 drivers/tty/cyclades.c if (!(old_termios->c_cflag & CLOCAL) && C_CLOCAL(tty)) tty 2796 drivers/tty/cyclades.c static void cy_send_xchar(struct tty_struct *tty, char ch) tty 2798 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2802 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_send_xchar")) tty 2808 drivers/tty/cyclades.c cy_start(tty); tty 2814 drivers/tty/cyclades.c if (ch == STOP_CHAR(tty)) tty 2816 drivers/tty/cyclades.c else if (ch == START_CHAR(tty)) tty 2825 drivers/tty/cyclades.c static void cy_throttle(struct tty_struct *tty) tty 2827 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2832 drivers/tty/cyclades.c printk(KERN_DEBUG "cyc:throttle %s ...ttyC%d\n", tty_name(tty), tty 2836 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_throttle")) tty 2841 drivers/tty/cyclades.c if (I_IXOFF(tty)) { tty 2843 drivers/tty/cyclades.c cy_send_xchar(tty, STOP_CHAR(tty)); tty 2848 drivers/tty/cyclades.c if (C_CRTSCTS(tty)) { tty 2864 drivers/tty/cyclades.c static void cy_unthrottle(struct tty_struct *tty) tty 2866 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2872 drivers/tty/cyclades.c tty_name(tty), info->line); tty 2875 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_unthrottle")) tty 2878 drivers/tty/cyclades.c if (I_IXOFF(tty)) { tty 2882 drivers/tty/cyclades.c cy_send_xchar(tty, START_CHAR(tty)); tty 2885 drivers/tty/cyclades.c if (C_CRTSCTS(tty)) { tty 2900 drivers/tty/cyclades.c static void cy_stop(struct tty_struct *tty) tty 2903 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2911 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_stop")) tty 2924 drivers/tty/cyclades.c static void cy_start(struct tty_struct *tty) tty 2927 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2935 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_start")) tty 2951 drivers/tty/cyclades.c static void cy_hangup(struct tty_struct *tty) tty 2953 drivers/tty/cyclades.c struct cyclades_port *info = tty->driver_data; tty 2959 drivers/tty/cyclades.c if (serial_paranoia_check(info, tty->name, "cy_hangup")) tty 2962 drivers/tty/cyclades.c cy_flush_buffer(tty); tty 2963 drivers/tty/cyclades.c cy_shutdown(info, tty); tty 3941 drivers/tty/cyclades.c struct tty_struct *tty; tty 3944 drivers/tty/cyclades.c tty = tty_port_tty_get(&info->port); tty 3945 drivers/tty/cyclades.c if (tty) { tty 3946 drivers/tty/cyclades.c ld = tty_ldisc_ref(tty); tty 3951 drivers/tty/cyclades.c tty_kref_put(tty); tty 158 drivers/tty/goldfish.c static int goldfish_tty_activate(struct tty_port *port, struct tty_struct *tty) tty 173 drivers/tty/goldfish.c static int goldfish_tty_open(struct tty_struct *tty, struct file *filp) tty 175 drivers/tty/goldfish.c struct goldfish_tty *qtty = &goldfish_ttys[tty->index]; tty 176 drivers/tty/goldfish.c return tty_port_open(&qtty->port, tty, filp); tty 179 drivers/tty/goldfish.c static void goldfish_tty_close(struct tty_struct *tty, struct file *filp) tty 181 drivers/tty/goldfish.c tty_port_close(tty->port, tty, filp); tty 184 drivers/tty/goldfish.c static void goldfish_tty_hangup(struct tty_struct *tty) tty 186 drivers/tty/goldfish.c tty_port_hangup(tty->port); tty 189 drivers/tty/goldfish.c static int goldfish_tty_write(struct tty_struct *tty, const unsigned char *buf, tty 192 drivers/tty/goldfish.c goldfish_tty_do_write(tty->index, buf, count); tty 196 drivers/tty/goldfish.c static int goldfish_tty_write_room(struct tty_struct *tty) tty 201 drivers/tty/goldfish.c static int goldfish_tty_chars_in_buffer(struct tty_struct *tty) tty 203 drivers/tty/goldfish.c struct goldfish_tty *qtty = &goldfish_ttys[tty->index]; tty 247 drivers/tty/goldfish.c struct tty_driver *tty; tty 256 drivers/tty/goldfish.c tty = alloc_tty_driver(goldfish_tty_line_count); tty 257 drivers/tty/goldfish.c if (tty == NULL) { tty 261 drivers/tty/goldfish.c tty->driver_name = "goldfish"; tty 262 drivers/tty/goldfish.c tty->name = "ttyGF"; tty 263 drivers/tty/goldfish.c tty->type = TTY_DRIVER_TYPE_SERIAL; tty 264 drivers/tty/goldfish.c tty->subtype = SERIAL_TYPE_NORMAL; tty 265 drivers/tty/goldfish.c tty->init_termios = tty_std_termios; tty 266 drivers/tty/goldfish.c tty->flags = TTY_DRIVER_RESET_TERMIOS | TTY_DRIVER_REAL_RAW | tty 268 drivers/tty/goldfish.c tty_set_operations(tty, &goldfish_tty_ops); tty 269 drivers/tty/goldfish.c ret = tty_register_driver(tty); tty 273 drivers/tty/goldfish.c goldfish_tty_driver = tty; tty 277 drivers/tty/goldfish.c put_tty_driver(tty); tty 320 drivers/tty/hvc/hvc_console.c static void hvc_unthrottle(struct tty_struct *tty) tty 325 drivers/tty/hvc/hvc_console.c static int hvc_install(struct tty_driver *driver, struct tty_struct *tty) tty 331 drivers/tty/hvc/hvc_console.c hp = hvc_get_by_index(tty->index); tty 335 drivers/tty/hvc/hvc_console.c tty->driver_data = hp; tty 337 drivers/tty/hvc/hvc_console.c rc = tty_port_install(&hp->port, driver, tty); tty 347 drivers/tty/hvc/hvc_console.c static int hvc_open(struct tty_struct *tty, struct file * filp) tty 349 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 362 drivers/tty/hvc/hvc_console.c tty_port_tty_set(&hp->port, tty); tty 377 drivers/tty/hvc/hvc_console.c if (C_BAUD(tty)) tty 389 drivers/tty/hvc/hvc_console.c static void hvc_close(struct tty_struct *tty, struct file * filp) tty 391 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 407 drivers/tty/hvc/hvc_console.c if (C_HUPCL(tty)) tty 422 drivers/tty/hvc/hvc_console.c tty_wait_until_sent(tty, HVC_CLOSE_WAIT); tty 432 drivers/tty/hvc/hvc_console.c static void hvc_cleanup(struct tty_struct *tty) tty 434 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 439 drivers/tty/hvc/hvc_console.c static void hvc_hangup(struct tty_struct *tty) tty 441 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 499 drivers/tty/hvc/hvc_console.c static int hvc_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 501 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 567 drivers/tty/hvc/hvc_console.c struct tty_struct *tty; tty 572 drivers/tty/hvc/hvc_console.c tty = tty_port_tty_get(&hp->port); tty 573 drivers/tty/hvc/hvc_console.c if (!tty) tty 580 drivers/tty/hvc/hvc_console.c tty_do_resize(tty, &ws); tty 581 drivers/tty/hvc/hvc_console.c tty_kref_put(tty); tty 589 drivers/tty/hvc/hvc_console.c static int hvc_write_room(struct tty_struct *tty) tty 591 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 599 drivers/tty/hvc/hvc_console.c static int hvc_chars_in_buffer(struct tty_struct *tty) tty 601 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 634 drivers/tty/hvc/hvc_console.c struct tty_struct *tty; tty 661 drivers/tty/hvc/hvc_console.c tty = tty_port_tty_get(&hp->port); tty 662 drivers/tty/hvc/hvc_console.c if (tty == NULL) tty 666 drivers/tty/hvc/hvc_console.c if (tty_throttled(tty)) tty 690 drivers/tty/hvc/hvc_console.c tty_hangup(tty); tty 745 drivers/tty/hvc/hvc_console.c tty_wakeup(tty); tty 757 drivers/tty/hvc/hvc_console.c tty_kref_put(tty); tty 836 drivers/tty/hvc/hvc_console.c static int hvc_tiocmget(struct tty_struct *tty) tty 838 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 845 drivers/tty/hvc/hvc_console.c static int hvc_tiocmset(struct tty_struct *tty, tty 848 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 863 drivers/tty/hvc/hvc_console.c struct tty_struct *tty = driver->ttys[0]; tty 864 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 878 drivers/tty/hvc/hvc_console.c struct tty_struct *tty = driver->ttys[0]; tty 879 drivers/tty/hvc/hvc_console.c struct hvc_struct *hp = tty->driver_data; tty 982 drivers/tty/hvc/hvc_console.c struct tty_struct *tty; tty 984 drivers/tty/hvc/hvc_console.c tty = tty_port_tty_get(&hp->port); tty 1009 drivers/tty/hvc/hvc_console.c if (tty) { tty 1010 drivers/tty/hvc/hvc_console.c tty_vhangup(tty); tty 1011 drivers/tty/hvc/hvc_console.c tty_kref_put(tty); tty 295 drivers/tty/hvc/hvcs.c static void hvcs_unthrottle(struct tty_struct *tty); tty 296 drivers/tty/hvc/hvcs.c static void hvcs_throttle(struct tty_struct *tty); tty 299 drivers/tty/hvc/hvcs.c static int hvcs_write(struct tty_struct *tty, tty 301 drivers/tty/hvc/hvcs.c static int hvcs_write_room(struct tty_struct *tty); tty 302 drivers/tty/hvc/hvcs.c static int hvcs_chars_in_buffer(struct tty_struct *tty); tty 316 drivers/tty/hvc/hvcs.c static int hvcs_open(struct tty_struct *tty, struct file *filp); tty 317 drivers/tty/hvc/hvcs.c static void hvcs_close(struct tty_struct *tty, struct file *filp); tty 318 drivers/tty/hvc/hvcs.c static void hvcs_hangup(struct tty_struct * tty); tty 504 drivers/tty/hvc/hvcs.c static void hvcs_unthrottle(struct tty_struct *tty) tty 506 drivers/tty/hvc/hvcs.c struct hvcs_struct *hvcsd = tty->driver_data; tty 515 drivers/tty/hvc/hvcs.c static void hvcs_throttle(struct tty_struct *tty) tty 517 drivers/tty/hvc/hvcs.c struct hvcs_struct *hvcsd = tty->driver_data; tty 547 drivers/tty/hvc/hvcs.c struct tty_struct *tty = hvcsd->port.tty; tty 567 drivers/tty/hvc/hvcs.c if (tty) { tty 568 drivers/tty/hvc/hvcs.c tty_wakeup(tty); tty 577 drivers/tty/hvc/hvcs.c struct tty_struct *tty; tty 585 drivers/tty/hvc/hvcs.c tty = hvcsd->port.tty; tty 589 drivers/tty/hvc/hvcs.c if (!tty || tty_throttled(tty)) { tty 828 drivers/tty/hvc/hvcs.c struct tty_struct *tty; tty 837 drivers/tty/hvc/hvcs.c tty = hvcsd->port.tty; tty 852 drivers/tty/hvc/hvcs.c if (tty) tty 853 drivers/tty/hvc/hvcs.c tty_hangup(tty); tty 1086 drivers/tty/hvc/hvcs.c static int hvcs_install(struct tty_driver *driver, struct tty_struct *tty) tty 1098 drivers/tty/hvc/hvcs.c hvcsd = hvcs_get_by_index(tty->index); tty 1101 drivers/tty/hvc/hvcs.c " with tty->index %d.\n", tty->index); tty 1117 drivers/tty/hvc/hvcs.c hvcsd->port.tty = tty; tty 1118 drivers/tty/hvc/hvcs.c tty->driver_data = hvcsd; tty 1143 drivers/tty/hvc/hvcs.c retval = tty_port_install(&hvcsd->port, driver, tty); tty 1163 drivers/tty/hvc/hvcs.c static int hvcs_open(struct tty_struct *tty, struct file *filp) tty 1165 drivers/tty/hvc/hvcs.c struct hvcs_struct *hvcsd = tty->driver_data; tty 1181 drivers/tty/hvc/hvcs.c static void hvcs_close(struct tty_struct *tty, struct file *filp) tty 1199 drivers/tty/hvc/hvcs.c if (!tty->driver_data) tty 1202 drivers/tty/hvc/hvcs.c hvcsd = tty->driver_data; tty 1214 drivers/tty/hvc/hvcs.c hvcsd->port.tty = NULL; tty 1219 drivers/tty/hvc/hvcs.c tty_wait_until_sent(tty, HVCS_CLOSE_WAIT); tty 1226 drivers/tty/hvc/hvcs.c tty->driver_data = NULL; tty 1238 drivers/tty/hvc/hvcs.c static void hvcs_cleanup(struct tty_struct * tty) tty 1240 drivers/tty/hvc/hvcs.c struct hvcs_struct *hvcsd = tty->driver_data; tty 1245 drivers/tty/hvc/hvcs.c static void hvcs_hangup(struct tty_struct * tty) tty 1247 drivers/tty/hvc/hvcs.c struct hvcs_struct *hvcsd = tty->driver_data; tty 1266 drivers/tty/hvc/hvcs.c tty->driver_data = NULL; tty 1267 drivers/tty/hvc/hvcs.c hvcsd->port.tty = NULL; tty 1305 drivers/tty/hvc/hvcs.c static int hvcs_write(struct tty_struct *tty, tty 1308 drivers/tty/hvc/hvcs.c struct hvcs_struct *hvcsd = tty->driver_data; tty 1410 drivers/tty/hvc/hvcs.c static int hvcs_write_room(struct tty_struct *tty) tty 1412 drivers/tty/hvc/hvcs.c struct hvcs_struct *hvcsd = tty->driver_data; tty 1420 drivers/tty/hvc/hvcs.c static int hvcs_chars_in_buffer(struct tty_struct *tty) tty 1422 drivers/tty/hvc/hvcs.c struct hvcs_struct *hvcsd = tty->driver_data; tty 226 drivers/tty/hvc/hvsi.c struct tty_struct *tty, struct hvsi_struct **to_handshake) tty 236 drivers/tty/hvc/hvsi.c if (tty && !C_CLOCAL(tty)) tty 237 drivers/tty/hvc/hvsi.c tty_hangup(tty); tty 388 drivers/tty/hvc/hvsi.c static int hvsi_load_chunk(struct hvsi_struct *hp, struct tty_struct *tty, tty 431 drivers/tty/hvc/hvsi.c hvsi_recv_control(hp, packet, tty, handshake); tty 479 drivers/tty/hvc/hvsi.c struct tty_struct *tty; tty 485 drivers/tty/hvc/hvsi.c tty = tty_port_tty_get(&hp->port); tty 489 drivers/tty/hvc/hvsi.c again = hvsi_load_chunk(hp, tty, &handshake); tty 499 drivers/tty/hvc/hvsi.c if (tty && hp->n_throttle && !tty_throttled(tty)) { tty 507 drivers/tty/hvc/hvsi.c tty_kref_put(tty); tty 699 drivers/tty/hvc/hvsi.c static int hvsi_open(struct tty_struct *tty, struct file *filp) tty 707 drivers/tty/hvc/hvsi.c hp = &hvsi_ports[tty->index]; tty 709 drivers/tty/hvc/hvsi.c tty->driver_data = hp; tty 715 drivers/tty/hvc/hvsi.c tty_port_tty_set(&hp->port, tty); tty 727 drivers/tty/hvc/hvsi.c printk(KERN_ERR "%s: HVSI handshaking failed\n", tty->name); tty 733 drivers/tty/hvc/hvsi.c printk(KERN_ERR "%s: couldn't get initial modem flags\n", tty->name); tty 739 drivers/tty/hvc/hvsi.c printk(KERN_ERR "%s: couldn't set DTR\n", tty->name); tty 762 drivers/tty/hvc/hvsi.c static void hvsi_close(struct tty_struct *tty, struct file *filp) tty 764 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 786 drivers/tty/hvc/hvsi.c tty->closing = 1; tty 814 drivers/tty/hvc/hvsi.c static void hvsi_hangup(struct tty_struct *tty) tty 816 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 893 drivers/tty/hvc/hvsi.c static int hvsi_write_room(struct tty_struct *tty) tty 895 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 900 drivers/tty/hvc/hvsi.c static int hvsi_chars_in_buffer(struct tty_struct *tty) tty 902 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 907 drivers/tty/hvc/hvsi.c static int hvsi_write(struct tty_struct *tty, tty 910 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 931 drivers/tty/hvc/hvsi.c while ((count > 0) && (hvsi_write_room(tty) > 0)) { tty 932 drivers/tty/hvc/hvsi.c int chunksize = min(count, hvsi_write_room(tty)); tty 966 drivers/tty/hvc/hvsi.c static void hvsi_throttle(struct tty_struct *tty) tty 968 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 975 drivers/tty/hvc/hvsi.c static void hvsi_unthrottle(struct tty_struct *tty) tty 977 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 993 drivers/tty/hvc/hvsi.c static int hvsi_tiocmget(struct tty_struct *tty) tty 995 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 1001 drivers/tty/hvc/hvsi.c static int hvsi_tiocmset(struct tty_struct *tty, tty 1004 drivers/tty/hvc/hvsi.c struct hvsi_struct *hp = tty->driver_data; tty 379 drivers/tty/hvc/hvsi_lib.c pv->tty = tty_port_tty_get(&hp->port); tty 402 drivers/tty/hvc/hvsi_lib.c if (!pv->tty || (pv->tty->termios.c_cflag & HUPCL)) tty 409 drivers/tty/hvc/hvsi_lib.c tty_kref_put(pv->tty); tty 410 drivers/tty/hvc/hvsi_lib.c pv->tty = NULL; tty 208 drivers/tty/ipwireless/main.c ipw->tty = ipwireless_tty_create(ipw->hardware, ipw->network); tty 209 drivers/tty/ipwireless/main.c if (!ipw->tty) tty 306 drivers/tty/ipwireless/main.c if (ipw->tty != NULL) tty 307 drivers/tty/ipwireless/main.c ipwireless_tty_free(ipw->tty); tty 60 drivers/tty/ipwireless/main.h struct ipw_tty *tty; tty 323 drivers/tty/ipwireless/network.c struct ipw_tty *tty = tty 332 drivers/tty/ipwireless/network.c if (tty) tty 333 drivers/tty/ipwireless/network.c ipwireless_tty_notify_control_line_change(tty, tty 373 drivers/tty/ipwireless/network.c struct ipw_tty *tty = network->associated_ttys[channel_idx][i]; tty 375 drivers/tty/ipwireless/network.c if (!tty) tty 387 drivers/tty/ipwireless/network.c && ipwireless_tty_is_modem(tty)) { tty 412 drivers/tty/ipwireless/network.c ipwireless_tty_received(tty, data, length); tty 453 drivers/tty/ipwireless/network.c struct ipw_tty *tty) tty 459 drivers/tty/ipwireless/network.c network->associated_ttys[channel_idx][i] = tty; tty 43 drivers/tty/ipwireless/network.h unsigned int channel_idx, struct ipw_tty *tty); tty 91 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = get_tty(linux_tty->index); tty 93 drivers/tty/ipwireless/tty.c if (!tty) tty 96 drivers/tty/ipwireless/tty.c mutex_lock(&tty->ipw_tty_mutex); tty 97 drivers/tty/ipwireless/tty.c if (tty->port.count == 0) tty 98 drivers/tty/ipwireless/tty.c tty->tx_bytes_queued = 0; tty 100 drivers/tty/ipwireless/tty.c tty->port.count++; tty 102 drivers/tty/ipwireless/tty.c tty->port.tty = linux_tty; tty 103 drivers/tty/ipwireless/tty.c linux_tty->driver_data = tty; tty 104 drivers/tty/ipwireless/tty.c tty->port.low_latency = 1; tty 106 drivers/tty/ipwireless/tty.c if (tty->tty_type == TTYTYPE_MODEM) tty 107 drivers/tty/ipwireless/tty.c ipwireless_ppp_open(tty->network); tty 109 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 114 drivers/tty/ipwireless/tty.c static void do_ipw_close(struct ipw_tty *tty) tty 116 drivers/tty/ipwireless/tty.c tty->port.count--; tty 118 drivers/tty/ipwireless/tty.c if (tty->port.count == 0) { tty 119 drivers/tty/ipwireless/tty.c struct tty_struct *linux_tty = tty->port.tty; tty 122 drivers/tty/ipwireless/tty.c tty->port.tty = NULL; tty 125 drivers/tty/ipwireless/tty.c if (tty->tty_type == TTYTYPE_MODEM) tty 126 drivers/tty/ipwireless/tty.c ipwireless_ppp_close(tty->network); tty 133 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = linux_tty->driver_data; tty 135 drivers/tty/ipwireless/tty.c if (!tty) tty 138 drivers/tty/ipwireless/tty.c mutex_lock(&tty->ipw_tty_mutex); tty 139 drivers/tty/ipwireless/tty.c if (tty->port.count == 0) { tty 140 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 144 drivers/tty/ipwireless/tty.c do_ipw_close(tty); tty 146 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 155 drivers/tty/ipwireless/tty.c void ipwireless_tty_received(struct ipw_tty *tty, unsigned char *data, tty 160 drivers/tty/ipwireless/tty.c mutex_lock(&tty->ipw_tty_mutex); tty 162 drivers/tty/ipwireless/tty.c if (!tty->port.count) { tty 163 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 166 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 168 drivers/tty/ipwireless/tty.c work = tty_insert_flip_string(&tty->port, data, length); tty 176 drivers/tty/ipwireless/tty.c tty_flip_buffer_push(&tty->port); tty 182 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = callback_data; tty 188 drivers/tty/ipwireless/tty.c tty->tx_bytes_queued -= packet_length; tty 194 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = linux_tty->driver_data; tty 197 drivers/tty/ipwireless/tty.c if (!tty) tty 200 drivers/tty/ipwireless/tty.c mutex_lock(&tty->ipw_tty_mutex); tty 201 drivers/tty/ipwireless/tty.c if (!tty->port.count) { tty 202 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 206 drivers/tty/ipwireless/tty.c room = IPWIRELESS_TX_QUEUE_SIZE - tty->tx_bytes_queued; tty 214 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 218 drivers/tty/ipwireless/tty.c ret = ipwireless_send_packet(tty->hardware, IPW_CHANNEL_RAS, tty 220 drivers/tty/ipwireless/tty.c ipw_write_packet_sent_callback, tty); tty 222 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 226 drivers/tty/ipwireless/tty.c tty->tx_bytes_queued += count; tty 227 drivers/tty/ipwireless/tty.c mutex_unlock(&tty->ipw_tty_mutex); tty 234 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = linux_tty->driver_data; tty 238 drivers/tty/ipwireless/tty.c if (!tty) tty 241 drivers/tty/ipwireless/tty.c if (!tty->port.count) tty 244 drivers/tty/ipwireless/tty.c room = IPWIRELESS_TX_QUEUE_SIZE - tty->tx_bytes_queued; tty 254 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = linux_tty->driver_data; tty 256 drivers/tty/ipwireless/tty.c if (!tty) tty 259 drivers/tty/ipwireless/tty.c if (!tty->port.count) tty 263 drivers/tty/ipwireless/tty.c ss->line = tty->index; tty 276 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = linux_tty->driver_data; tty 278 drivers/tty/ipwireless/tty.c if (!tty) tty 281 drivers/tty/ipwireless/tty.c if (!tty->port.count) tty 284 drivers/tty/ipwireless/tty.c return tty->tx_bytes_queued; tty 287 drivers/tty/ipwireless/tty.c static int get_control_lines(struct ipw_tty *tty) tty 289 drivers/tty/ipwireless/tty.c unsigned int my = tty->control_lines; tty 306 drivers/tty/ipwireless/tty.c static int set_control_lines(struct ipw_tty *tty, unsigned int set, tty 312 drivers/tty/ipwireless/tty.c ret = ipwireless_set_RTS(tty->hardware, tty->channel_idx, 1); tty 315 drivers/tty/ipwireless/tty.c if (tty->secondary_channel_idx != -1) { tty 316 drivers/tty/ipwireless/tty.c ret = ipwireless_set_RTS(tty->hardware, tty 317 drivers/tty/ipwireless/tty.c tty->secondary_channel_idx, 1); tty 323 drivers/tty/ipwireless/tty.c ret = ipwireless_set_DTR(tty->hardware, tty->channel_idx, 1); tty 326 drivers/tty/ipwireless/tty.c if (tty->secondary_channel_idx != -1) { tty 327 drivers/tty/ipwireless/tty.c ret = ipwireless_set_DTR(tty->hardware, tty 328 drivers/tty/ipwireless/tty.c tty->secondary_channel_idx, 1); tty 334 drivers/tty/ipwireless/tty.c ret = ipwireless_set_RTS(tty->hardware, tty->channel_idx, 0); tty 335 drivers/tty/ipwireless/tty.c if (tty->secondary_channel_idx != -1) { tty 336 drivers/tty/ipwireless/tty.c ret = ipwireless_set_RTS(tty->hardware, tty 337 drivers/tty/ipwireless/tty.c tty->secondary_channel_idx, 0); tty 343 drivers/tty/ipwireless/tty.c ret = ipwireless_set_DTR(tty->hardware, tty->channel_idx, 0); tty 344 drivers/tty/ipwireless/tty.c if (tty->secondary_channel_idx != -1) { tty 345 drivers/tty/ipwireless/tty.c ret = ipwireless_set_DTR(tty->hardware, tty 346 drivers/tty/ipwireless/tty.c tty->secondary_channel_idx, 0); tty 356 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = linux_tty->driver_data; tty 359 drivers/tty/ipwireless/tty.c if (!tty) tty 362 drivers/tty/ipwireless/tty.c if (!tty->port.count) tty 365 drivers/tty/ipwireless/tty.c return get_control_lines(tty); tty 372 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = linux_tty->driver_data; tty 375 drivers/tty/ipwireless/tty.c if (!tty) tty 378 drivers/tty/ipwireless/tty.c if (!tty->port.count) tty 381 drivers/tty/ipwireless/tty.c return set_control_lines(tty, set, clear); tty 387 drivers/tty/ipwireless/tty.c struct ipw_tty *tty = linux_tty->driver_data; tty 389 drivers/tty/ipwireless/tty.c if (!tty) tty 392 drivers/tty/ipwireless/tty.c if (!tty->port.count) tty 396 drivers/tty/ipwireless/tty.c if (tty->tty_type == TTYTYPE_MODEM) { tty 401 drivers/tty/ipwireless/tty.c tty->network); tty 413 drivers/tty/ipwireless/tty.c tty->network); tty 514 drivers/tty/ipwireless/tty.c void ipwireless_tty_free(struct ipw_tty *tty) tty 517 drivers/tty/ipwireless/tty.c struct ipw_network *network = ttys[tty->index]->network; tty 519 drivers/tty/ipwireless/tty.c for (j = tty->index; j < IPWIRELESS_PCMCIA_MINORS; tty 530 drivers/tty/ipwireless/tty.c if (ttyj->port.tty != NULL) { tty 532 drivers/tty/ipwireless/tty.c tty_vhangup(ttyj->port.tty); tty 609 drivers/tty/ipwireless/tty.c int ipwireless_tty_is_modem(struct ipw_tty *tty) tty 611 drivers/tty/ipwireless/tty.c return tty->tty_type == TTYTYPE_MODEM; tty 615 drivers/tty/ipwireless/tty.c ipwireless_tty_notify_control_line_change(struct ipw_tty *tty, tty 620 drivers/tty/ipwireless/tty.c unsigned int old_control_lines = tty->control_lines; tty 622 drivers/tty/ipwireless/tty.c tty->control_lines = (tty->control_lines & ~changed_mask) tty 630 drivers/tty/ipwireless/tty.c && !(tty->control_lines & IPW_CONTROL_LINE_DCD) tty 631 drivers/tty/ipwireless/tty.c && tty->port.tty) { tty 632 drivers/tty/ipwireless/tty.c tty_hangup(tty->port.tty); tty 37 drivers/tty/ipwireless/tty.h void ipwireless_tty_free(struct ipw_tty *tty); tty 38 drivers/tty/ipwireless/tty.h void ipwireless_tty_received(struct ipw_tty *tty, unsigned char *data, tty 40 drivers/tty/ipwireless/tty.h int ipwireless_tty_is_modem(struct ipw_tty *tty); tty 41 drivers/tty/ipwireless/tty.h void ipwireless_tty_notify_control_line_change(struct ipw_tty *tty, tty 174 drivers/tty/isicom.c static void isicom_start(struct tty_struct *tty); tty 400 drivers/tty/isicom.c struct tty_struct *tty; tty 427 drivers/tty/isicom.c tty = tty_port_tty_get(&port->port); tty 428 drivers/tty/isicom.c if (tty == NULL) tty 438 drivers/tty/isicom.c if (txcount <= 0 || tty->stopped || tty->hw_stopped) tty 491 drivers/tty/isicom.c tty_wakeup(tty); tty 495 drivers/tty/isicom.c tty_kref_put(tty); tty 511 drivers/tty/isicom.c struct tty_struct *tty; tty 554 drivers/tty/isicom.c tty = tty_port_tty_get(&port->port); tty 555 drivers/tty/isicom.c if (tty == NULL) { tty 578 drivers/tty/isicom.c tty_hangup(tty); tty 595 drivers/tty/isicom.c if (tty->hw_stopped) { tty 597 drivers/tty/isicom.c tty->hw_stopped = 0; tty 601 drivers/tty/isicom.c tty_wakeup(tty); tty 604 drivers/tty/isicom.c tty->hw_stopped = 1; tty 630 drivers/tty/isicom.c do_SAK(tty); tty 669 drivers/tty/isicom.c tty_kref_put(tty); tty 674 drivers/tty/isicom.c static void isicom_config_port(struct tty_struct *tty) tty 676 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 685 drivers/tty/isicom.c baud = C_BAUD(tty); tty 696 drivers/tty/isicom.c tty->termios.c_cflag &= ~CBAUDEX; tty 727 drivers/tty/isicom.c switch (C_CSIZE(tty)) { tty 742 drivers/tty/isicom.c if (C_CSTOPB(tty)) tty 744 drivers/tty/isicom.c if (C_PARENB(tty)) { tty 746 drivers/tty/isicom.c if (C_PARODD(tty)) tty 752 drivers/tty/isicom.c tty_port_set_check_carrier(&port->port, !C_CLOCAL(tty)); tty 756 drivers/tty/isicom.c tty_port_set_cts_flow(&port->port, C_CRTSCTS(tty)); tty 757 drivers/tty/isicom.c if (C_CRTSCTS(tty)) tty 759 drivers/tty/isicom.c if (I_IXON(tty)) tty 761 drivers/tty/isicom.c if (I_IXOFF(tty)) tty 767 drivers/tty/isicom.c outw((STOP_CHAR(tty)) << 8 | (START_CHAR(tty)), base); tty 772 drivers/tty/isicom.c if (C_CREAD(tty)) { tty 797 drivers/tty/isicom.c static int isicom_activate(struct tty_port *tport, struct tty_struct *tty) tty 818 drivers/tty/isicom.c isicom_config_port(tty); tty 830 drivers/tty/isicom.c static struct tty_port *isicom_find_port(struct tty_struct *tty) tty 835 drivers/tty/isicom.c int line = tty->index; tty 848 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_open")) tty 854 drivers/tty/isicom.c static int isicom_open(struct tty_struct *tty, struct file *filp) tty 859 drivers/tty/isicom.c tport = isicom_find_port(tty); tty 864 drivers/tty/isicom.c tty->driver_data = port; tty 865 drivers/tty/isicom.c return tty_port_open(tport, tty, filp); tty 885 drivers/tty/isicom.c static void isicom_flush_buffer(struct tty_struct *tty) tty 887 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 891 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_flush_buffer")) tty 898 drivers/tty/isicom.c tty_wakeup(tty); tty 917 drivers/tty/isicom.c static void isicom_close(struct tty_struct *tty, struct file *filp) tty 919 drivers/tty/isicom.c struct isi_port *ip = tty->driver_data; tty 926 drivers/tty/isicom.c if (isicom_paranoia_check(ip, tty->name, "isicom_close")) tty 928 drivers/tty/isicom.c tty_port_close(port, tty, filp); tty 932 drivers/tty/isicom.c static int isicom_write(struct tty_struct *tty, const unsigned char *buf, tty 935 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 940 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_write")) tty 959 drivers/tty/isicom.c if (port->xmit_cnt && !tty->stopped && !tty->hw_stopped) tty 966 drivers/tty/isicom.c static int isicom_put_char(struct tty_struct *tty, unsigned char ch) tty 968 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 972 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_put_char")) tty 989 drivers/tty/isicom.c static void isicom_flush_chars(struct tty_struct *tty) tty 991 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 993 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_flush_chars")) tty 996 drivers/tty/isicom.c if (port->xmit_cnt <= 0 || tty->stopped || tty->hw_stopped || tty 1006 drivers/tty/isicom.c static int isicom_write_room(struct tty_struct *tty) tty 1008 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1011 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_write_room")) tty 1021 drivers/tty/isicom.c static int isicom_chars_in_buffer(struct tty_struct *tty) tty 1023 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1024 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_chars_in_buffer")) tty 1030 drivers/tty/isicom.c static int isicom_send_break(struct tty_struct *tty, int length) tty 1032 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1051 drivers/tty/isicom.c static int isicom_tiocmget(struct tty_struct *tty) tty 1053 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1057 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_ioctl")) tty 1068 drivers/tty/isicom.c static int isicom_tiocmset(struct tty_struct *tty, tty 1071 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1074 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_ioctl")) tty 1092 drivers/tty/isicom.c static int isicom_set_serial_info(struct tty_struct *tty, tty 1095 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1098 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_ioctl")) tty 1124 drivers/tty/isicom.c isicom_config_port(tty); tty 1131 drivers/tty/isicom.c static int isicom_get_serial_info(struct tty_struct *tty, tty 1134 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1136 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_ioctl")) tty 1153 drivers/tty/isicom.c static void isicom_set_termios(struct tty_struct *tty, tty 1156 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1159 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_set_termios")) tty 1162 drivers/tty/isicom.c if (tty->termios.c_cflag == old_termios->c_cflag && tty 1163 drivers/tty/isicom.c tty->termios.c_iflag == old_termios->c_iflag) tty 1167 drivers/tty/isicom.c isicom_config_port(tty); tty 1170 drivers/tty/isicom.c if ((old_termios->c_cflag & CRTSCTS) && !C_CRTSCTS(tty)) { tty 1171 drivers/tty/isicom.c tty->hw_stopped = 0; tty 1172 drivers/tty/isicom.c isicom_start(tty); tty 1177 drivers/tty/isicom.c static void isicom_throttle(struct tty_struct *tty) tty 1179 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1182 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_throttle")) tty 1191 drivers/tty/isicom.c static void isicom_unthrottle(struct tty_struct *tty) tty 1193 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1196 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_unthrottle")) tty 1205 drivers/tty/isicom.c static void isicom_stop(struct tty_struct *tty) tty 1207 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1209 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_stop")) tty 1218 drivers/tty/isicom.c static void isicom_start(struct tty_struct *tty) tty 1220 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1222 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_start")) tty 1230 drivers/tty/isicom.c static void isicom_hangup(struct tty_struct *tty) tty 1232 drivers/tty/isicom.c struct isi_port *port = tty->driver_data; tty 1234 drivers/tty/isicom.c if (isicom_paranoia_check(port, tty->name, "isicom_hangup")) tty 418 drivers/tty/mips_ejtag_fdc.c struct tty_struct *tty; tty 465 drivers/tty/mips_ejtag_fdc.c tty = tty_port_tty_get(&dport->port); tty 466 drivers/tty/mips_ejtag_fdc.c if (tty) { tty 467 drivers/tty/mips_ejtag_fdc.c tty_wakeup(tty); tty 468 drivers/tty/mips_ejtag_fdc.c tty_kref_put(tty); tty 695 drivers/tty/mips_ejtag_fdc.c struct tty_struct *tty) tty 761 drivers/tty/mips_ejtag_fdc.c struct tty_struct *tty) tty 765 drivers/tty/mips_ejtag_fdc.c tty->driver_data = &priv->ports[tty->index]; tty 766 drivers/tty/mips_ejtag_fdc.c return tty_port_install(&priv->ports[tty->index].port, driver, tty); tty 769 drivers/tty/mips_ejtag_fdc.c static int mips_ejtag_fdc_tty_open(struct tty_struct *tty, struct file *filp) tty 771 drivers/tty/mips_ejtag_fdc.c return tty_port_open(tty->port, tty, filp); tty 774 drivers/tty/mips_ejtag_fdc.c static void mips_ejtag_fdc_tty_close(struct tty_struct *tty, struct file *filp) tty 776 drivers/tty/mips_ejtag_fdc.c return tty_port_close(tty->port, tty, filp); tty 779 drivers/tty/mips_ejtag_fdc.c static void mips_ejtag_fdc_tty_hangup(struct tty_struct *tty) tty 781 drivers/tty/mips_ejtag_fdc.c struct mips_ejtag_fdc_tty_port *dport = tty->driver_data; tty 795 drivers/tty/mips_ejtag_fdc.c tty_port_hangup(tty->port); tty 798 drivers/tty/mips_ejtag_fdc.c static int mips_ejtag_fdc_tty_write(struct tty_struct *tty, tty 802 drivers/tty/mips_ejtag_fdc.c struct mips_ejtag_fdc_tty_port *dport = tty->driver_data; tty 842 drivers/tty/mips_ejtag_fdc.c static int mips_ejtag_fdc_tty_write_room(struct tty_struct *tty) tty 844 drivers/tty/mips_ejtag_fdc.c struct mips_ejtag_fdc_tty_port *dport = tty->driver_data; tty 856 drivers/tty/mips_ejtag_fdc.c static int mips_ejtag_fdc_tty_chars_in_buffer(struct tty_struct *tty) tty 858 drivers/tty/mips_ejtag_fdc.c struct mips_ejtag_fdc_tty_port *dport = tty->driver_data; tty 198 drivers/tty/moxa.c static int moxa_tiocmget(struct tty_struct *tty); tty 199 drivers/tty/moxa.c static int moxa_tiocmset(struct tty_struct *tty, tty 286 drivers/tty/moxa.c static int moxa_ioctl(struct tty_struct *tty, tty 289 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 293 drivers/tty/moxa.c if (tty->index == MAX_PORTS) { tty 384 drivers/tty/moxa.c static int moxa_break_ctl(struct tty_struct *tty, int state) tty 386 drivers/tty/moxa.c struct moxa_port *port = tty->driver_data; tty 1155 drivers/tty/moxa.c static int moxa_open(struct tty_struct *tty, struct file *filp) tty 1161 drivers/tty/moxa.c port = tty->index; tty 1180 drivers/tty/moxa.c tty->driver_data = ch; tty 1181 drivers/tty/moxa.c tty_port_tty_set(&ch->port, tty); tty 1185 drivers/tty/moxa.c moxa_set_tty_param(tty, &tty->termios); tty 1194 drivers/tty/moxa.c return tty_port_block_til_ready(&ch->port, tty, filp); tty 1197 drivers/tty/moxa.c static void moxa_close(struct tty_struct *tty, struct file *filp) tty 1199 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1200 drivers/tty/moxa.c ch->cflag = tty->termios.c_cflag; tty 1201 drivers/tty/moxa.c tty_port_close(&ch->port, tty, filp); tty 1204 drivers/tty/moxa.c static int moxa_write(struct tty_struct *tty, tty 1207 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1215 drivers/tty/moxa.c len = MoxaPortWriteData(tty, buf, count); tty 1222 drivers/tty/moxa.c static int moxa_write_room(struct tty_struct *tty) tty 1226 drivers/tty/moxa.c if (tty->stopped) tty 1228 drivers/tty/moxa.c ch = tty->driver_data; tty 1234 drivers/tty/moxa.c static void moxa_flush_buffer(struct tty_struct *tty) tty 1236 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1241 drivers/tty/moxa.c tty_wakeup(tty); tty 1244 drivers/tty/moxa.c static int moxa_chars_in_buffer(struct tty_struct *tty) tty 1246 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1259 drivers/tty/moxa.c static int moxa_tiocmget(struct tty_struct *tty) tty 1261 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1279 drivers/tty/moxa.c static int moxa_tiocmset(struct tty_struct *tty, tty 1286 drivers/tty/moxa.c ch = tty->driver_data; tty 1306 drivers/tty/moxa.c static void moxa_set_termios(struct tty_struct *tty, tty 1309 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1313 drivers/tty/moxa.c moxa_set_tty_param(tty, old_termios); tty 1314 drivers/tty/moxa.c if (!(old_termios->c_cflag & CLOCAL) && C_CLOCAL(tty)) tty 1318 drivers/tty/moxa.c static void moxa_stop(struct tty_struct *tty) tty 1320 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1329 drivers/tty/moxa.c static void moxa_start(struct tty_struct *tty) tty 1331 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1343 drivers/tty/moxa.c static void moxa_hangup(struct tty_struct *tty) tty 1345 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1368 drivers/tty/moxa.c struct tty_struct *tty = tty_port_tty_get(&p->port); tty 1373 drivers/tty/moxa.c if (tty) { tty 1377 drivers/tty/moxa.c tty_wakeup(tty); tty 1379 drivers/tty/moxa.c if (test_bit(LOWWAIT, &p->statusflags) && !tty->stopped && tty 1382 drivers/tty/moxa.c tty_wakeup(tty); tty 1385 drivers/tty/moxa.c if (inited && !tty_throttled(tty) && tty 1411 drivers/tty/moxa.c if (tty && (intr & IntrBreak) && !I_IGNBRK(tty)) { /* BREAK */ tty 1419 drivers/tty/moxa.c tty_kref_put(tty); tty 1466 drivers/tty/moxa.c static void moxa_set_tty_param(struct tty_struct *tty, struct ktermios *old_termios) tty 1468 drivers/tty/moxa.c register struct ktermios *ts = &tty->termios; tty 1469 drivers/tty/moxa.c struct moxa_port *ch = tty->driver_data; tty 1483 drivers/tty/moxa.c baud = MoxaPortSetTermio(ch, ts, tty_get_baud_rate(tty)); tty 1487 drivers/tty/moxa.c tty_encode_baud_rate(tty, baud, baud); tty 1866 drivers/tty/moxa.c static int MoxaPortWriteData(struct tty_struct *tty, tty 1869 drivers/tty/moxa.c struct moxa_port *port = tty->driver_data; tty 1885 drivers/tty/moxa.c moxaLog.txcnt[port->port.tty->index] += c; tty 1927 drivers/tty/moxa.c struct tty_struct *tty = port->port.tty; tty 1946 drivers/tty/moxa.c moxaLog.rxcnt[tty->index] += total; tty 2029 drivers/tty/moxa.c static int moxa_get_serial_info(struct tty_struct *tty, tty 2032 drivers/tty/moxa.c struct moxa_port *info = tty->driver_data; tty 2034 drivers/tty/moxa.c if (tty->index == MAX_PORTS) tty 2040 drivers/tty/moxa.c ss->line = info->port.tty->index, tty 2049 drivers/tty/moxa.c static int moxa_set_serial_info(struct tty_struct *tty, tty 2052 drivers/tty/moxa.c struct moxa_port *info = tty->driver_data; tty 2054 drivers/tty/moxa.c if (tty->index == MAX_PORTS) tty 568 drivers/tty/mxser.c static int mxser_set_baud(struct tty_struct *tty, long newspd) tty 570 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 583 drivers/tty/mxser.c tty_encode_baud_rate(tty, 134, 134); tty 589 drivers/tty/mxser.c tty_encode_baud_rate(tty, baud, baud); tty 620 drivers/tty/mxser.c if (C_BAUD(tty) == BOTHER) { tty 641 drivers/tty/mxser.c static int mxser_change_speed(struct tty_struct *tty) tty 643 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 648 drivers/tty/mxser.c cflag = tty->termios.c_cflag; tty 652 drivers/tty/mxser.c if (mxser_set_baud_method[tty->index] == 0) tty 653 drivers/tty/mxser.c mxser_set_baud(tty, tty_get_baud_rate(tty)); tty 722 drivers/tty/mxser.c if (tty->hw_stopped) { tty 724 drivers/tty/mxser.c tty->hw_stopped = 0; tty 734 drivers/tty/mxser.c tty_wakeup(tty); tty 738 drivers/tty/mxser.c tty->hw_stopped = 1; tty 759 drivers/tty/mxser.c if (I_INPCK(tty)) tty 761 drivers/tty/mxser.c if (I_BRKINT(tty) || I_PARMRK(tty)) tty 766 drivers/tty/mxser.c if (I_IGNBRK(tty)) { tty 773 drivers/tty/mxser.c if (I_IGNPAR(tty)) { tty 785 drivers/tty/mxser.c mxser_set_must_xon1_value(info->ioaddr, START_CHAR(tty)); tty 786 drivers/tty/mxser.c mxser_set_must_xoff1_value(info->ioaddr, STOP_CHAR(tty)); tty 787 drivers/tty/mxser.c if (I_IXON(tty)) { tty 794 drivers/tty/mxser.c if (I_IXOFF(tty)) { tty 810 drivers/tty/mxser.c static void mxser_check_modem_status(struct tty_struct *tty, tty 831 drivers/tty/mxser.c if (tty->hw_stopped) { tty 833 drivers/tty/mxser.c tty->hw_stopped = 0; tty 843 drivers/tty/mxser.c tty_wakeup(tty); tty 847 drivers/tty/mxser.c tty->hw_stopped = 1; tty 859 drivers/tty/mxser.c static int mxser_activate(struct tty_port *port, struct tty_struct *tty) tty 872 drivers/tty/mxser.c set_bit(TTY_IO_ERROR, &tty->flags); tty 899 drivers/tty/mxser.c set_bit(TTY_IO_ERROR, &tty->flags); tty 937 drivers/tty/mxser.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 943 drivers/tty/mxser.c mxser_change_speed(tty); tty 1001 drivers/tty/mxser.c static int mxser_open(struct tty_struct *tty, struct file *filp) tty 1006 drivers/tty/mxser.c line = tty->index; tty 1013 drivers/tty/mxser.c tty->driver_data = info; tty 1014 drivers/tty/mxser.c return tty_port_open(&info->port, tty, filp); tty 1017 drivers/tty/mxser.c static void mxser_flush_buffer(struct tty_struct *tty) tty 1019 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1034 drivers/tty/mxser.c tty_wakeup(tty); tty 1072 drivers/tty/mxser.c static void mxser_close(struct tty_struct *tty, struct file *filp) tty 1074 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1077 drivers/tty/mxser.c if (tty->index == MXSER_PORTS || info == NULL) tty 1079 drivers/tty/mxser.c if (tty_port_close_start(port, tty, filp) == 0) tty 1084 drivers/tty/mxser.c mxser_flush_buffer(tty); tty 1085 drivers/tty/mxser.c if (tty_port_initialized(port) && C_HUPCL(tty)) tty 1093 drivers/tty/mxser.c tty_port_close_end(port, tty); tty 1097 drivers/tty/mxser.c static int mxser_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 1100 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1124 drivers/tty/mxser.c if (info->xmit_cnt && !tty->stopped) { tty 1125 drivers/tty/mxser.c if (!tty->hw_stopped || tty 1139 drivers/tty/mxser.c static int mxser_put_char(struct tty_struct *tty, unsigned char ch) tty 1141 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1155 drivers/tty/mxser.c if (!tty->stopped) { tty 1156 drivers/tty/mxser.c if (!tty->hw_stopped || tty 1170 drivers/tty/mxser.c static void mxser_flush_chars(struct tty_struct *tty) tty 1172 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1175 drivers/tty/mxser.c if (info->xmit_cnt <= 0 || tty->stopped || !info->port.xmit_buf || tty 1176 drivers/tty/mxser.c (tty->hw_stopped && info->type != PORT_16550A && tty 1189 drivers/tty/mxser.c static int mxser_write_room(struct tty_struct *tty) tty 1191 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1198 drivers/tty/mxser.c static int mxser_chars_in_buffer(struct tty_struct *tty) tty 1200 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1209 drivers/tty/mxser.c static int mxser_get_serial_info(struct tty_struct *tty, tty 1212 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1215 drivers/tty/mxser.c if (tty->index == MXSER_PORTS) tty 1220 drivers/tty/mxser.c ss->line = tty->index, tty 1232 drivers/tty/mxser.c static int mxser_set_serial_info(struct tty_struct *tty, tty 1235 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1242 drivers/tty/mxser.c if (tty->index == MXSER_PORTS) tty 1244 drivers/tty/mxser.c if (tty_io_error(tty)) tty 1289 drivers/tty/mxser.c tty_encode_baud_rate(tty, baud, baud); tty 1300 drivers/tty/mxser.c mxser_change_speed(tty); tty 1304 drivers/tty/mxser.c retval = mxser_activate(port, tty); tty 1336 drivers/tty/mxser.c static int mxser_tiocmget(struct tty_struct *tty) tty 1338 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1343 drivers/tty/mxser.c if (tty->index == MXSER_PORTS) tty 1345 drivers/tty/mxser.c if (tty_io_error(tty)) tty 1353 drivers/tty/mxser.c mxser_check_modem_status(tty, info, status); tty 1363 drivers/tty/mxser.c static int mxser_tiocmset(struct tty_struct *tty, tty 1366 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1370 drivers/tty/mxser.c if (tty->index == MXSER_PORTS) tty 1372 drivers/tty/mxser.c if (tty_io_error(tty)) tty 1499 drivers/tty/mxser.c struct tty_struct *tty; tty 1536 drivers/tty/mxser.c tty = tty_port_tty_get(port); tty 1538 drivers/tty/mxser.c if (!tty) tty 1541 drivers/tty/mxser.c ms.cflag = tty->termios.c_cflag; tty 1542 drivers/tty/mxser.c tty_kref_put(tty); tty 1605 drivers/tty/mxser.c tty = tty_port_tty_get(&ip->port); tty 1607 drivers/tty/mxser.c if (!tty) { tty 1612 drivers/tty/mxser.c cflag = tty->termios.c_cflag; tty 1613 drivers/tty/mxser.c iflag = tty->termios.c_iflag; tty 1614 drivers/tty/mxser.c me->baudrate[p] = tty_get_baud_rate(tty); tty 1616 drivers/tty/mxser.c tty_kref_put(tty); tty 1674 drivers/tty/mxser.c static int mxser_ioctl(struct tty_struct *tty, tty 1677 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1682 drivers/tty/mxser.c if (tty->index == MXSER_PORTS) tty 1695 drivers/tty/mxser.c p = tty->index % 4; tty 1724 drivers/tty/mxser.c if (cmd != TIOCMIWAIT && tty_io_error(tty)) tty 1755 drivers/tty/mxser.c len = mxser_chars_in_buffer(tty); tty 1767 drivers/tty/mxser.c status = mxser_get_msr(info->ioaddr, 1, tty->index); tty 1768 drivers/tty/mxser.c mxser_check_modem_status(tty, info, status); tty 1783 drivers/tty/mxser.c if (tty->hw_stopped) tty 1806 drivers/tty/mxser.c mxser_set_baud_method[tty->index] = method; tty 1822 drivers/tty/mxser.c static int mxser_get_icount(struct tty_struct *tty, tty 1826 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1848 drivers/tty/mxser.c static void mxser_stoprx(struct tty_struct *tty) tty 1850 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1853 drivers/tty/mxser.c if (I_IXOFF(tty)) { tty 1858 drivers/tty/mxser.c info->x_char = STOP_CHAR(tty); tty 1865 drivers/tty/mxser.c if (C_CRTSCTS(tty)) { tty 1875 drivers/tty/mxser.c static void mxser_throttle(struct tty_struct *tty) tty 1877 drivers/tty/mxser.c mxser_stoprx(tty); tty 1880 drivers/tty/mxser.c static void mxser_unthrottle(struct tty_struct *tty) tty 1882 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1886 drivers/tty/mxser.c if (I_IXOFF(tty)) { tty 1894 drivers/tty/mxser.c info->x_char = START_CHAR(tty); tty 1902 drivers/tty/mxser.c if (C_CRTSCTS(tty)) { tty 1914 drivers/tty/mxser.c static void mxser_stop(struct tty_struct *tty) tty 1916 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1927 drivers/tty/mxser.c static void mxser_start(struct tty_struct *tty) tty 1929 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1941 drivers/tty/mxser.c static void mxser_set_termios(struct tty_struct *tty, struct ktermios *old_termios) tty 1943 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 1947 drivers/tty/mxser.c mxser_change_speed(tty); tty 1950 drivers/tty/mxser.c if ((old_termios->c_cflag & CRTSCTS) && !C_CRTSCTS(tty)) { tty 1951 drivers/tty/mxser.c tty->hw_stopped = 0; tty 1952 drivers/tty/mxser.c mxser_start(tty); tty 1956 drivers/tty/mxser.c if ((old_termios->c_iflag & IXON) && !I_IXON(tty)) { tty 1957 drivers/tty/mxser.c tty->stopped = 0; tty 1966 drivers/tty/mxser.c mxser_start(tty); tty 1973 drivers/tty/mxser.c static void mxser_wait_until_sent(struct tty_struct *tty, int timeout) tty 1975 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 2030 drivers/tty/mxser.c static void mxser_hangup(struct tty_struct *tty) tty 2032 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 2034 drivers/tty/mxser.c mxser_flush_buffer(tty); tty 2041 drivers/tty/mxser.c static int mxser_rs_break(struct tty_struct *tty, int break_state) tty 2043 drivers/tty/mxser.c struct mxser_port *info = tty->driver_data; tty 2057 drivers/tty/mxser.c static void mxser_receive_chars(struct tty_struct *tty, tty 2066 drivers/tty/mxser.c recv_room = tty->receive_room; tty 2068 drivers/tty/mxser.c mxser_stoprx(tty); tty 2085 drivers/tty/mxser.c mxser_stoprx(tty); tty 2115 drivers/tty/mxser.c do_SAK(tty); tty 2132 drivers/tty/mxser.c mxser_stoprx(tty); tty 2145 drivers/tty/mxser.c mxvar_log.rxcnt[tty->index] += cnt; tty 2159 drivers/tty/mxser.c static void mxser_transmit_chars(struct tty_struct *tty, struct mxser_port *port) tty 2166 drivers/tty/mxser.c mxvar_log.txcnt[tty->index]++; tty 2176 drivers/tty/mxser.c if (port->xmit_cnt <= 0 || tty->stopped || tty 2177 drivers/tty/mxser.c (tty->hw_stopped && tty 2194 drivers/tty/mxser.c mxvar_log.txcnt[tty->index] += (cnt - port->xmit_cnt); tty 2201 drivers/tty/mxser.c tty_wakeup(tty); tty 2220 drivers/tty/mxser.c struct tty_struct *tty; tty 2253 drivers/tty/mxser.c tty = tty_port_tty_get(&port->port); tty 2254 drivers/tty/mxser.c if (!tty || port->closing || tty 2259 drivers/tty/mxser.c tty_kref_put(tty); tty 2280 drivers/tty/mxser.c mxser_receive_chars(tty, port, tty 2286 drivers/tty/mxser.c mxser_receive_chars(tty, port, tty 2291 drivers/tty/mxser.c mxser_check_modem_status(tty, port, msr); tty 2296 drivers/tty/mxser.c mxser_transmit_chars(tty, port); tty 2299 drivers/tty/mxser.c mxser_transmit_chars(tty, port); tty 2301 drivers/tty/mxser.c tty_kref_put(tty); tty 182 drivers/tty/n_gsm.c struct tty_struct *tty; /* The tty our ldisc is bound to */ tty 1014 drivers/tty/n_gsm.c static void gsm_process_modem(struct tty_struct *tty, struct gsm_dlci *dlci, tty 1054 drivers/tty/n_gsm.c if (tty) { tty 1056 drivers/tty/n_gsm.c if (!C_CLOCAL(tty)) tty 1057 drivers/tty/n_gsm.c tty_hangup(tty); tty 1084 drivers/tty/n_gsm.c struct tty_struct *tty; tty 1117 drivers/tty/n_gsm.c tty = tty_port_tty_get(&dlci->port); tty 1118 drivers/tty/n_gsm.c gsm_process_modem(tty, dlci, modem, clen); tty 1119 drivers/tty/n_gsm.c if (tty) { tty 1120 drivers/tty/n_gsm.c tty_wakeup(tty); tty 1121 drivers/tty/n_gsm.c tty_kref_put(tty); tty 1560 drivers/tty/n_gsm.c struct tty_struct *tty; tty 1578 drivers/tty/n_gsm.c tty = tty_port_tty_get(port); tty 1579 drivers/tty/n_gsm.c if (tty) { tty 1580 drivers/tty/n_gsm.c gsm_process_modem(tty, dlci, modem, clen); tty 1581 drivers/tty/n_gsm.c tty_kref_put(tty); tty 1713 drivers/tty/n_gsm.c struct tty_struct *tty = tty_port_tty_get(&dlci->port); tty 1714 drivers/tty/n_gsm.c if (tty) { tty 1719 drivers/tty/n_gsm.c tty_hangup(tty); tty 1722 drivers/tty/n_gsm.c tty_kref_put(tty); tty 2341 drivers/tty/n_gsm.c if (tty_write_room(gsm->tty) < len) { tty 2342 drivers/tty/n_gsm.c set_bit(TTY_DO_WRITE_WAKEUP, &gsm->tty->flags); tty 2348 drivers/tty/n_gsm.c gsm->tty->ops->write(gsm->tty, data, len); tty 2362 drivers/tty/n_gsm.c static int gsmld_attach_gsm(struct tty_struct *tty, struct gsm_mux *gsm) tty 2367 drivers/tty/n_gsm.c gsm->tty = tty_kref_get(tty); tty 2371 drivers/tty/n_gsm.c tty_kref_put(gsm->tty); tty 2391 drivers/tty/n_gsm.c static void gsmld_detach_gsm(struct tty_struct *tty, struct gsm_mux *gsm) tty 2396 drivers/tty/n_gsm.c WARN_ON(tty != gsm->tty); tty 2400 drivers/tty/n_gsm.c tty_kref_put(gsm->tty); tty 2401 drivers/tty/n_gsm.c gsm->tty = NULL; tty 2404 drivers/tty/n_gsm.c static void gsmld_receive_buf(struct tty_struct *tty, const unsigned char *cp, tty 2407 drivers/tty/n_gsm.c struct gsm_mux *gsm = tty->disc_data; tty 2432 drivers/tty/n_gsm.c tty_name(tty), flags); tty 2449 drivers/tty/n_gsm.c static void gsmld_flush_buffer(struct tty_struct *tty) tty 2463 drivers/tty/n_gsm.c static void gsmld_close(struct tty_struct *tty) tty 2465 drivers/tty/n_gsm.c struct gsm_mux *gsm = tty->disc_data; tty 2467 drivers/tty/n_gsm.c gsmld_detach_gsm(tty, gsm); tty 2469 drivers/tty/n_gsm.c gsmld_flush_buffer(tty); tty 2484 drivers/tty/n_gsm.c static int gsmld_open(struct tty_struct *tty) tty 2489 drivers/tty/n_gsm.c if (tty->ops->write == NULL) tty 2497 drivers/tty/n_gsm.c tty->disc_data = gsm; tty 2498 drivers/tty/n_gsm.c tty->receive_room = 65536; tty 2503 drivers/tty/n_gsm.c ret = gsmld_attach_gsm(tty, gsm); tty 2520 drivers/tty/n_gsm.c static void gsmld_write_wakeup(struct tty_struct *tty) tty 2522 drivers/tty/n_gsm.c struct gsm_mux *gsm = tty->disc_data; tty 2526 drivers/tty/n_gsm.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 2550 drivers/tty/n_gsm.c static ssize_t gsmld_read(struct tty_struct *tty, struct file *file, tty 2570 drivers/tty/n_gsm.c static ssize_t gsmld_write(struct tty_struct *tty, struct file *file, tty 2573 drivers/tty/n_gsm.c int space = tty_write_room(tty); tty 2575 drivers/tty/n_gsm.c return tty->ops->write(tty, buf, nr); tty 2576 drivers/tty/n_gsm.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 2594 drivers/tty/n_gsm.c static __poll_t gsmld_poll(struct tty_struct *tty, struct file *file, tty 2598 drivers/tty/n_gsm.c struct gsm_mux *gsm = tty->disc_data; tty 2600 drivers/tty/n_gsm.c poll_wait(file, &tty->read_wait, wait); tty 2601 drivers/tty/n_gsm.c poll_wait(file, &tty->write_wait, wait); tty 2604 drivers/tty/n_gsm.c if (!tty_is_writelocked(tty) && tty_write_room(tty) > 0) tty 2611 drivers/tty/n_gsm.c static int gsmld_ioctl(struct tty_struct *tty, struct file *file, tty 2615 drivers/tty/n_gsm.c struct gsm_mux *gsm = tty->disc_data; tty 2632 drivers/tty/n_gsm.c return n_tty_ioctl_helper(tty, file, cmd, arg); tty 2921 drivers/tty/n_gsm.c static int gsmtty_install(struct tty_driver *driver, struct tty_struct *tty) tty 2925 drivers/tty/n_gsm.c unsigned int line = tty->index; tty 2960 drivers/tty/n_gsm.c ret = tty_port_install(&dlci->port, driver, tty); tty 2971 drivers/tty/n_gsm.c tty->driver_data = dlci; tty 2977 drivers/tty/n_gsm.c static int gsmtty_open(struct tty_struct *tty, struct file *filp) tty 2979 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 2983 drivers/tty/n_gsm.c tty_port_tty_set(port, tty); tty 2992 drivers/tty/n_gsm.c return tty_port_block_til_ready(port, tty, filp); tty 2995 drivers/tty/n_gsm.c static void gsmtty_close(struct tty_struct *tty, struct file *filp) tty 2997 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3006 drivers/tty/n_gsm.c if (tty_port_close_start(&dlci->port, tty, filp) == 0) tty 3009 drivers/tty/n_gsm.c if (tty_port_initialized(&dlci->port) && C_HUPCL(tty)) tty 3011 drivers/tty/n_gsm.c tty_port_close_end(&dlci->port, tty); tty 3016 drivers/tty/n_gsm.c static void gsmtty_hangup(struct tty_struct *tty) tty 3018 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3025 drivers/tty/n_gsm.c static int gsmtty_write(struct tty_struct *tty, const unsigned char *buf, tty 3029 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3039 drivers/tty/n_gsm.c static int gsmtty_write_room(struct tty_struct *tty) tty 3041 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3047 drivers/tty/n_gsm.c static int gsmtty_chars_in_buffer(struct tty_struct *tty) tty 3049 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3055 drivers/tty/n_gsm.c static void gsmtty_flush_buffer(struct tty_struct *tty) tty 3057 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3068 drivers/tty/n_gsm.c static void gsmtty_wait_until_sent(struct tty_struct *tty, int timeout) tty 3075 drivers/tty/n_gsm.c static int gsmtty_tiocmget(struct tty_struct *tty) tty 3077 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3083 drivers/tty/n_gsm.c static int gsmtty_tiocmset(struct tty_struct *tty, tty 3086 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3102 drivers/tty/n_gsm.c static int gsmtty_ioctl(struct tty_struct *tty, tty 3105 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3135 drivers/tty/n_gsm.c static void gsmtty_set_termios(struct tty_struct *tty, struct ktermios *old) tty 3137 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3145 drivers/tty/n_gsm.c tty_termios_copy_hw(&tty->termios, old); tty 3148 drivers/tty/n_gsm.c static void gsmtty_throttle(struct tty_struct *tty) tty 3150 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3153 drivers/tty/n_gsm.c if (C_CRTSCTS(tty)) tty 3160 drivers/tty/n_gsm.c static void gsmtty_unthrottle(struct tty_struct *tty) tty 3162 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3165 drivers/tty/n_gsm.c if (C_CRTSCTS(tty)) tty 3172 drivers/tty/n_gsm.c static int gsmtty_break_ctl(struct tty_struct *tty, int state) tty 3174 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 3190 drivers/tty/n_gsm.c static void gsmtty_cleanup(struct tty_struct *tty) tty 3192 drivers/tty/n_gsm.c struct gsm_dlci *dlci = tty->driver_data; tty 145 drivers/tty/n_hdlc.c struct tty_struct *tty; tty 177 drivers/tty/n_hdlc.c static ssize_t n_hdlc_tty_read(struct tty_struct *tty, struct file *file, tty 179 drivers/tty/n_hdlc.c static ssize_t n_hdlc_tty_write(struct tty_struct *tty, struct file *file, tty 181 drivers/tty/n_hdlc.c static int n_hdlc_tty_ioctl(struct tty_struct *tty, struct file *file, tty 183 drivers/tty/n_hdlc.c static __poll_t n_hdlc_tty_poll(struct tty_struct *tty, struct file *filp, tty 185 drivers/tty/n_hdlc.c static int n_hdlc_tty_open(struct tty_struct *tty); tty 186 drivers/tty/n_hdlc.c static void n_hdlc_tty_close(struct tty_struct *tty); tty 187 drivers/tty/n_hdlc.c static void n_hdlc_tty_receive(struct tty_struct *tty, const __u8 *cp, tty 189 drivers/tty/n_hdlc.c static void n_hdlc_tty_wakeup(struct tty_struct *tty); tty 193 drivers/tty/n_hdlc.c #define tty2n_hdlc(tty) ((struct n_hdlc *) ((tty)->disc_data)) tty 194 drivers/tty/n_hdlc.c #define n_hdlc2tty(n_hdlc) ((n_hdlc)->tty) tty 196 drivers/tty/n_hdlc.c static void flush_rx_queue(struct tty_struct *tty) tty 198 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc(tty); tty 205 drivers/tty/n_hdlc.c static void flush_tx_queue(struct tty_struct *tty) tty 207 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc(tty); tty 235 drivers/tty/n_hdlc.c struct tty_struct *tty = n_hdlc2tty (n_hdlc); tty 242 drivers/tty/n_hdlc.c wake_up_interruptible (&tty->read_wait); tty 243 drivers/tty/n_hdlc.c wake_up_interruptible (&tty->write_wait); tty 245 drivers/tty/n_hdlc.c if (tty->disc_data == n_hdlc) tty 246 drivers/tty/n_hdlc.c tty->disc_data = NULL; /* Break the tty->n_hdlc link */ tty 288 drivers/tty/n_hdlc.c static void n_hdlc_tty_close(struct tty_struct *tty) tty 290 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc (tty); tty 301 drivers/tty/n_hdlc.c clear_bit(TTY_NO_WRITE_SPLIT,&tty->flags); tty 303 drivers/tty/n_hdlc.c tty->disc_data = NULL; tty 304 drivers/tty/n_hdlc.c if (tty == n_hdlc->backup_tty) tty 306 drivers/tty/n_hdlc.c if (tty != n_hdlc->tty) tty 309 drivers/tty/n_hdlc.c n_hdlc->tty = n_hdlc->backup_tty; tty 326 drivers/tty/n_hdlc.c static int n_hdlc_tty_open (struct tty_struct *tty) tty 328 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc (tty); tty 333 drivers/tty/n_hdlc.c tty->name); tty 347 drivers/tty/n_hdlc.c tty->disc_data = n_hdlc; tty 348 drivers/tty/n_hdlc.c n_hdlc->tty = tty; tty 349 drivers/tty/n_hdlc.c tty->receive_room = 65536; tty 353 drivers/tty/n_hdlc.c set_bit(TTY_NO_WRITE_SPLIT,&tty->flags); tty 357 drivers/tty/n_hdlc.c tty_driver_flush_buffer(tty); tty 375 drivers/tty/n_hdlc.c static void n_hdlc_send_frames(struct n_hdlc *n_hdlc, struct tty_struct *tty) tty 402 drivers/tty/n_hdlc.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 403 drivers/tty/n_hdlc.c actual = tty->ops->write(tty, tbuf->buf, tbuf->count); tty 424 drivers/tty/n_hdlc.c wake_up_interruptible(&tty->write_wait); tty 443 drivers/tty/n_hdlc.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 464 drivers/tty/n_hdlc.c static void n_hdlc_tty_wakeup(struct tty_struct *tty) tty 466 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc(tty); tty 474 drivers/tty/n_hdlc.c if (tty != n_hdlc->tty) { tty 475 drivers/tty/n_hdlc.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 479 drivers/tty/n_hdlc.c n_hdlc_send_frames (n_hdlc, tty); tty 493 drivers/tty/n_hdlc.c static void n_hdlc_tty_receive(struct tty_struct *tty, const __u8 *data, tty 496 drivers/tty/n_hdlc.c register struct n_hdlc *n_hdlc = tty2n_hdlc (tty); tty 504 drivers/tty/n_hdlc.c if (!n_hdlc || tty != n_hdlc->tty) tty 545 drivers/tty/n_hdlc.c wake_up_interruptible (&tty->read_wait); tty 546 drivers/tty/n_hdlc.c if (n_hdlc->tty->fasync != NULL) tty 547 drivers/tty/n_hdlc.c kill_fasync (&n_hdlc->tty->fasync, SIGIO, POLL_IN); tty 560 drivers/tty/n_hdlc.c static ssize_t n_hdlc_tty_read(struct tty_struct *tty, struct file *file, tty 563 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc(tty); tty 582 drivers/tty/n_hdlc.c add_wait_queue(&tty->read_wait, &wait); tty 585 drivers/tty/n_hdlc.c if (test_bit(TTY_OTHER_CLOSED, &tty->flags)) { tty 616 drivers/tty/n_hdlc.c if (tty_io_nonblock(tty, file)) { tty 629 drivers/tty/n_hdlc.c remove_wait_queue(&tty->read_wait, &wait); tty 645 drivers/tty/n_hdlc.c static ssize_t n_hdlc_tty_write(struct tty_struct *tty, struct file *file, tty 648 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc (tty); tty 674 drivers/tty/n_hdlc.c add_wait_queue(&tty->write_wait, &wait); tty 683 drivers/tty/n_hdlc.c if (tty_io_nonblock(tty, file)) { tty 689 drivers/tty/n_hdlc.c n_hdlc = tty2n_hdlc (tty); tty 691 drivers/tty/n_hdlc.c tty != n_hdlc->tty) { tty 704 drivers/tty/n_hdlc.c remove_wait_queue(&tty->write_wait, &wait); tty 713 drivers/tty/n_hdlc.c n_hdlc_send_frames(n_hdlc,tty); tty 729 drivers/tty/n_hdlc.c static int n_hdlc_tty_ioctl(struct tty_struct *tty, struct file *file, tty 732 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc (tty); tty 763 drivers/tty/n_hdlc.c count = tty_chars_in_buffer(tty); tty 778 drivers/tty/n_hdlc.c flush_tx_queue(tty); tty 783 drivers/tty/n_hdlc.c error = n_tty_ioctl_helper(tty, file, cmd, arg); tty 800 drivers/tty/n_hdlc.c static __poll_t n_hdlc_tty_poll(struct tty_struct *tty, struct file *filp, tty 803 drivers/tty/n_hdlc.c struct n_hdlc *n_hdlc = tty2n_hdlc (tty); tty 809 drivers/tty/n_hdlc.c if (n_hdlc && n_hdlc->magic == HDLC_MAGIC && tty == n_hdlc->tty) { tty 813 drivers/tty/n_hdlc.c poll_wait(filp, &tty->read_wait, wait); tty 814 drivers/tty/n_hdlc.c poll_wait(filp, &tty->write_wait, wait); tty 819 drivers/tty/n_hdlc.c if (test_bit(TTY_OTHER_CLOSED, &tty->flags)) tty 823 drivers/tty/n_hdlc.c if (!tty_is_writelocked(tty) && tty 13 drivers/tty/n_null.c static int n_null_open(struct tty_struct *tty) tty 18 drivers/tty/n_null.c static void n_null_close(struct tty_struct *tty) tty 22 drivers/tty/n_null.c static ssize_t n_null_read(struct tty_struct *tty, struct file *file, tty 28 drivers/tty/n_null.c static ssize_t n_null_write(struct tty_struct *tty, struct file *file, tty 34 drivers/tty/n_null.c static void n_null_receivebuf(struct tty_struct *tty, tty 129 drivers/tty/n_r3964.c static int r3964_open(struct tty_struct *tty); tty 130 drivers/tty/n_r3964.c static void r3964_close(struct tty_struct *tty); tty 131 drivers/tty/n_r3964.c static ssize_t r3964_read(struct tty_struct *tty, struct file *file, tty 133 drivers/tty/n_r3964.c static ssize_t r3964_write(struct tty_struct *tty, struct file *file, tty 135 drivers/tty/n_r3964.c static int r3964_ioctl(struct tty_struct *tty, struct file *file, tty 138 drivers/tty/n_r3964.c static int r3964_compat_ioctl(struct tty_struct *tty, struct file *file, tty 141 drivers/tty/n_r3964.c static void r3964_set_termios(struct tty_struct *tty, struct ktermios *old); tty 142 drivers/tty/n_r3964.c static __poll_t r3964_poll(struct tty_struct *tty, struct file *file, tty 144 drivers/tty/n_r3964.c static void r3964_receive_buf(struct tty_struct *tty, const unsigned char *cp, tty 284 drivers/tty/n_r3964.c wake_up_interruptible(&pInfo->tty->read_wait); tty 378 drivers/tty/n_r3964.c struct tty_struct *tty = pInfo->tty; tty 380 drivers/tty/n_r3964.c tty_put_char(tty, ch); tty 386 drivers/tty/n_r3964.c struct tty_struct *tty = pInfo->tty; tty 388 drivers/tty/n_r3964.c if (tty == NULL || tty->ops->flush_chars == NULL) tty 390 drivers/tty/n_r3964.c tty->ops->flush_chars(tty); tty 444 drivers/tty/n_r3964.c struct tty_struct *tty = pInfo->tty; tty 448 drivers/tty/n_r3964.c if (tty == NULL || pBlock == NULL) { tty 452 drivers/tty/n_r3964.c room = tty_write_room(tty); tty 550 drivers/tty/n_r3964.c wake_up_interruptible(&pInfo->tty->read_wait); tty 947 drivers/tty/n_r3964.c static int r3964_open(struct tty_struct *tty) tty 953 drivers/tty/n_r3964.c tty, current->pid, tty->disc_data); tty 987 drivers/tty/n_r3964.c pInfo->tty = tty; tty 1000 drivers/tty/n_r3964.c tty->disc_data = pInfo; tty 1001 drivers/tty/n_r3964.c tty->receive_room = 65536; tty 1008 drivers/tty/n_r3964.c static void r3964_close(struct tty_struct *tty) tty 1010 drivers/tty/n_r3964.c struct r3964_info *pInfo = tty->disc_data; tty 1061 drivers/tty/n_r3964.c static ssize_t r3964_read(struct tty_struct *tty, struct file *file, tty 1064 drivers/tty/n_r3964.c struct r3964_info *pInfo = tty->disc_data; tty 1088 drivers/tty/n_r3964.c if (tty_io_nonblock(tty, file)) { tty 1093 drivers/tty/n_r3964.c wait_event_interruptible(tty->read_wait, tty 1127 drivers/tty/n_r3964.c static ssize_t r3964_write(struct tty_struct *tty, struct file *file, tty 1130 drivers/tty/n_r3964.c struct r3964_info *pInfo = tty->disc_data; tty 1192 drivers/tty/n_r3964.c static int r3964_ioctl(struct tty_struct *tty, struct file *file, tty 1195 drivers/tty/n_r3964.c struct r3964_info *pInfo = tty->disc_data; tty 1221 drivers/tty/n_r3964.c static int r3964_compat_ioctl(struct tty_struct *tty, struct file *file, tty 1228 drivers/tty/n_r3964.c return r3964_ioctl(tty, file, cmd, arg); tty 1235 drivers/tty/n_r3964.c static void r3964_set_termios(struct tty_struct *tty, struct ktermios *old) tty 1241 drivers/tty/n_r3964.c static __poll_t r3964_poll(struct tty_struct *tty, struct file *file, tty 1244 drivers/tty/n_r3964.c struct r3964_info *pInfo = tty->disc_data; tty 1254 drivers/tty/n_r3964.c poll_wait(file, &tty->read_wait, wait); tty 1266 drivers/tty/n_r3964.c static void r3964_receive_buf(struct tty_struct *tty, const unsigned char *cp, tty 1269 drivers/tty/n_r3964.c struct r3964_info *pInfo = tty->disc_data; tty 61 drivers/tty/n_tracerouter.c static int n_tracerouter_open(struct tty_struct *tty) tty 68 drivers/tty/n_tracerouter.c tr_data->kref_tty = tty_kref_get(tty); tty 73 drivers/tty/n_tracerouter.c tty->disc_data = tr_data; tty 74 drivers/tty/n_tracerouter.c tty->receive_room = RECEIVE_ROOM; tty 75 drivers/tty/n_tracerouter.c tty_driver_flush_buffer(tty); tty 89 drivers/tty/n_tracerouter.c static void n_tracerouter_close(struct tty_struct *tty) tty 91 drivers/tty/n_tracerouter.c struct tracerouter_data *tptr = tty->disc_data; tty 95 drivers/tty/n_tracerouter.c tty_driver_flush_buffer(tty); tty 99 drivers/tty/n_tracerouter.c tty->disc_data = NULL; tty 120 drivers/tty/n_tracerouter.c static ssize_t n_tracerouter_read(struct tty_struct *tty, struct file *file, tty 144 drivers/tty/n_tracerouter.c static ssize_t n_tracerouter_write(struct tty_struct *tty, struct file *file, tty 161 drivers/tty/n_tracerouter.c static void n_tracerouter_receivebuf(struct tty_struct *tty, tty 64 drivers/tty/n_tracesink.c static int n_tracesink_open(struct tty_struct *tty) tty 70 drivers/tty/n_tracesink.c this_tty = tty_kref_get(tty); tty 74 drivers/tty/n_tracesink.c tty->disc_data = this_tty; tty 75 drivers/tty/n_tracesink.c tty_driver_flush_buffer(tty); tty 90 drivers/tty/n_tracesink.c static void n_tracesink_close(struct tty_struct *tty) tty 93 drivers/tty/n_tracesink.c tty_driver_flush_buffer(tty); tty 96 drivers/tty/n_tracesink.c tty->disc_data = NULL; tty 117 drivers/tty/n_tracesink.c static ssize_t n_tracesink_read(struct tty_struct *tty, struct file *file, tty 141 drivers/tty/n_tracesink.c static ssize_t n_tracesink_write(struct tty_struct *tty, struct file *file, tty 158 drivers/tty/n_tty.c static void zero_buffer(struct tty_struct *tty, u8 *buffer, int size) tty 160 drivers/tty/n_tty.c bool icanon = !!L_ICANON(tty); tty 161 drivers/tty/n_tty.c bool no_echo = !L_ECHO(tty); tty 167 drivers/tty/n_tty.c static int tty_copy_to_user(struct tty_struct *tty, void __user *to, tty 170 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 176 drivers/tty/n_tty.c tty_audit_add_data(tty, from, size); tty 178 drivers/tty/n_tty.c zero_buffer(tty, from, size - uncopied); tty 186 drivers/tty/n_tty.c tty_audit_add_data(tty, from, n); tty 188 drivers/tty/n_tty.c zero_buffer(tty, from, n - uncopied); tty 204 drivers/tty/n_tty.c static void n_tty_kick_worker(struct tty_struct *tty) tty 206 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 212 drivers/tty/n_tty.c WARN_RATELIMIT(tty->port->itty == NULL, tty 218 drivers/tty/n_tty.c WARN_RATELIMIT(test_bit(TTY_LDISC_HALTED, &tty->flags), tty 220 drivers/tty/n_tty.c tty_buffer_restart_work(tty->port); tty 224 drivers/tty/n_tty.c static ssize_t chars_in_buffer(struct tty_struct *tty) tty 226 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 245 drivers/tty/n_tty.c static void n_tty_write_wakeup(struct tty_struct *tty) tty 247 drivers/tty/n_tty.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 248 drivers/tty/n_tty.c kill_fasync(&tty->fasync, SIGIO, POLL_OUT); tty 251 drivers/tty/n_tty.c static void n_tty_check_throttle(struct tty_struct *tty) tty 253 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 265 drivers/tty/n_tty.c tty_set_flow_change(tty, TTY_THROTTLE_SAFE); tty 268 drivers/tty/n_tty.c throttled = tty_throttle_safe(tty); tty 272 drivers/tty/n_tty.c __tty_set_flow_change(tty, 0); tty 275 drivers/tty/n_tty.c static void n_tty_check_unthrottle(struct tty_struct *tty) tty 277 drivers/tty/n_tty.c if (tty->driver->type == TTY_DRIVER_TYPE_PTY) { tty 278 drivers/tty/n_tty.c if (chars_in_buffer(tty) > TTY_THRESHOLD_UNTHROTTLE) tty 280 drivers/tty/n_tty.c n_tty_kick_worker(tty); tty 281 drivers/tty/n_tty.c tty_wakeup(tty->link); tty 295 drivers/tty/n_tty.c tty_set_flow_change(tty, TTY_UNTHROTTLE_SAFE); tty 296 drivers/tty/n_tty.c if (chars_in_buffer(tty) > TTY_THRESHOLD_UNTHROTTLE) tty 298 drivers/tty/n_tty.c n_tty_kick_worker(tty); tty 299 drivers/tty/n_tty.c unthrottled = tty_unthrottle_safe(tty); tty 303 drivers/tty/n_tty.c __tty_set_flow_change(tty, 0); tty 345 drivers/tty/n_tty.c static void n_tty_packet_mode_flush(struct tty_struct *tty) tty 349 drivers/tty/n_tty.c if (tty->link->packet) { tty 350 drivers/tty/n_tty.c spin_lock_irqsave(&tty->ctrl_lock, flags); tty 351 drivers/tty/n_tty.c tty->ctrl_status |= TIOCPKT_FLUSHREAD; tty 352 drivers/tty/n_tty.c spin_unlock_irqrestore(&tty->ctrl_lock, flags); tty 353 drivers/tty/n_tty.c wake_up_interruptible(&tty->link->read_wait); tty 371 drivers/tty/n_tty.c static void n_tty_flush_buffer(struct tty_struct *tty) tty 373 drivers/tty/n_tty.c down_write(&tty->termios_rwsem); tty 374 drivers/tty/n_tty.c reset_buffer_flags(tty->disc_data); tty 375 drivers/tty/n_tty.c n_tty_kick_worker(tty); tty 377 drivers/tty/n_tty.c if (tty->link) tty 378 drivers/tty/n_tty.c n_tty_packet_mode_flush(tty); tty 379 drivers/tty/n_tty.c up_write(&tty->termios_rwsem); tty 404 drivers/tty/n_tty.c static inline int is_continuation(unsigned char c, struct tty_struct *tty) tty 406 drivers/tty/n_tty.c return I_IUTF8(tty) && is_utf8_continuation(c); tty 431 drivers/tty/n_tty.c static int do_output_char(unsigned char c, struct tty_struct *tty, int space) tty 433 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 441 drivers/tty/n_tty.c if (O_ONLRET(tty)) tty 443 drivers/tty/n_tty.c if (O_ONLCR(tty)) { tty 447 drivers/tty/n_tty.c tty->ops->write(tty, "\r\n", 2); tty 453 drivers/tty/n_tty.c if (O_ONOCR(tty) && ldata->column == 0) tty 455 drivers/tty/n_tty.c if (O_OCRNL(tty)) { tty 457 drivers/tty/n_tty.c if (O_ONLRET(tty)) tty 465 drivers/tty/n_tty.c if (O_TABDLY(tty) == XTABS) { tty 469 drivers/tty/n_tty.c tty->ops->write(tty, " ", spaces); tty 480 drivers/tty/n_tty.c if (O_OLCUC(tty)) tty 482 drivers/tty/n_tty.c if (!is_continuation(c, tty)) tty 488 drivers/tty/n_tty.c tty_put_char(tty, c); tty 506 drivers/tty/n_tty.c static int process_output(unsigned char c, struct tty_struct *tty) tty 508 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 513 drivers/tty/n_tty.c space = tty_write_room(tty); tty 514 drivers/tty/n_tty.c retval = do_output_char(c, tty, space); tty 542 drivers/tty/n_tty.c static ssize_t process_output_block(struct tty_struct *tty, tty 545 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 552 drivers/tty/n_tty.c space = tty_write_room(tty); tty 565 drivers/tty/n_tty.c if (O_ONLRET(tty)) tty 567 drivers/tty/n_tty.c if (O_ONLCR(tty)) tty 572 drivers/tty/n_tty.c if (O_ONOCR(tty) && ldata->column == 0) tty 574 drivers/tty/n_tty.c if (O_OCRNL(tty)) tty 586 drivers/tty/n_tty.c if (O_OLCUC(tty)) tty 588 drivers/tty/n_tty.c if (!is_continuation(c, tty)) tty 595 drivers/tty/n_tty.c i = tty->ops->write(tty, buf, i); tty 626 drivers/tty/n_tty.c static size_t __process_echoes(struct tty_struct *tty) tty 628 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 633 drivers/tty/n_tty.c old_space = space = tty_write_room(tty); tty 684 drivers/tty/n_tty.c tty_put_char(tty, '\b'); tty 708 drivers/tty/n_tty.c tty_put_char(tty, ECHO_OP_START); tty 728 drivers/tty/n_tty.c tty_put_char(tty, '^'); tty 729 drivers/tty/n_tty.c tty_put_char(tty, op ^ 0100); tty 738 drivers/tty/n_tty.c if (O_OPOST(tty)) { tty 739 drivers/tty/n_tty.c int retval = do_output_char(c, tty, space); tty 746 drivers/tty/n_tty.c tty_put_char(tty, c); tty 772 drivers/tty/n_tty.c static void commit_echoes(struct tty_struct *tty) tty 774 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 794 drivers/tty/n_tty.c echoed = __process_echoes(tty); tty 797 drivers/tty/n_tty.c if (echoed && tty->ops->flush_chars) tty 798 drivers/tty/n_tty.c tty->ops->flush_chars(tty); tty 801 drivers/tty/n_tty.c static void process_echoes(struct tty_struct *tty) tty 803 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 811 drivers/tty/n_tty.c echoed = __process_echoes(tty); tty 814 drivers/tty/n_tty.c if (echoed && tty->ops->flush_chars) tty 815 drivers/tty/n_tty.c tty->ops->flush_chars(tty); tty 819 drivers/tty/n_tty.c static void flush_echoes(struct tty_struct *tty) tty 821 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 823 drivers/tty/n_tty.c if ((!L_ECHO(tty) && !L_ECHONL(tty)) || tty 829 drivers/tty/n_tty.c __process_echoes(tty); tty 939 drivers/tty/n_tty.c static void echo_char(unsigned char c, struct tty_struct *tty) tty 941 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 947 drivers/tty/n_tty.c if (L_ECHOCTL(tty) && iscntrl(c) && c != '\t') tty 979 drivers/tty/n_tty.c static void eraser(unsigned char c, struct tty_struct *tty) tty 981 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 991 drivers/tty/n_tty.c if (c == ERASE_CHAR(tty)) tty 993 drivers/tty/n_tty.c else if (c == WERASE_CHAR(tty)) tty 996 drivers/tty/n_tty.c if (!L_ECHO(tty)) { tty 1000 drivers/tty/n_tty.c if (!L_ECHOK(tty) || !L_ECHOKE(tty) || !L_ECHOE(tty)) { tty 1003 drivers/tty/n_tty.c echo_char(KILL_CHAR(tty), tty); tty 1005 drivers/tty/n_tty.c if (L_ECHOK(tty)) tty 1020 drivers/tty/n_tty.c } while (is_continuation(c, tty) && tty 1024 drivers/tty/n_tty.c if (is_continuation(c, tty)) tty 1036 drivers/tty/n_tty.c if (L_ECHO(tty)) { tty 1037 drivers/tty/n_tty.c if (L_ECHOPRT(tty)) { tty 1043 drivers/tty/n_tty.c echo_char(c, tty); tty 1049 drivers/tty/n_tty.c } else if (kill_type == ERASE && !L_ECHOE(tty)) { tty 1050 drivers/tty/n_tty.c echo_char(ERASE_CHAR(tty), tty); tty 1070 drivers/tty/n_tty.c if (L_ECHOCTL(tty)) tty 1072 drivers/tty/n_tty.c } else if (!is_continuation(c, tty)) { tty 1078 drivers/tty/n_tty.c if (iscntrl(c) && L_ECHOCTL(tty)) { tty 1083 drivers/tty/n_tty.c if (!iscntrl(c) || L_ECHOCTL(tty)) { tty 1093 drivers/tty/n_tty.c if (ldata->read_head == ldata->canon_head && L_ECHO(tty)) tty 1112 drivers/tty/n_tty.c static void __isig(int sig, struct tty_struct *tty) tty 1114 drivers/tty/n_tty.c struct pid *tty_pgrp = tty_get_pgrp(tty); tty 1121 drivers/tty/n_tty.c static void isig(int sig, struct tty_struct *tty) tty 1123 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1125 drivers/tty/n_tty.c if (L_NOFLSH(tty)) { tty 1127 drivers/tty/n_tty.c __isig(sig, tty); tty 1130 drivers/tty/n_tty.c up_read(&tty->termios_rwsem); tty 1131 drivers/tty/n_tty.c down_write(&tty->termios_rwsem); tty 1133 drivers/tty/n_tty.c __isig(sig, tty); tty 1142 drivers/tty/n_tty.c tty_driver_flush_buffer(tty); tty 1145 drivers/tty/n_tty.c reset_buffer_flags(tty->disc_data); tty 1148 drivers/tty/n_tty.c if (tty->link) tty 1149 drivers/tty/n_tty.c n_tty_packet_mode_flush(tty); tty 1151 drivers/tty/n_tty.c up_write(&tty->termios_rwsem); tty 1152 drivers/tty/n_tty.c down_read(&tty->termios_rwsem); tty 1169 drivers/tty/n_tty.c static void n_tty_receive_break(struct tty_struct *tty) tty 1171 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1173 drivers/tty/n_tty.c if (I_IGNBRK(tty)) tty 1175 drivers/tty/n_tty.c if (I_BRKINT(tty)) { tty 1176 drivers/tty/n_tty.c isig(SIGINT, tty); tty 1179 drivers/tty/n_tty.c if (I_PARMRK(tty)) { tty 1199 drivers/tty/n_tty.c static void n_tty_receive_overrun(struct tty_struct *tty) tty 1201 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1206 drivers/tty/n_tty.c tty_warn(tty, "%d input overrun(s)\n", ldata->num_overrun); tty 1223 drivers/tty/n_tty.c static void n_tty_receive_parity_error(struct tty_struct *tty, unsigned char c) tty 1225 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1227 drivers/tty/n_tty.c if (I_INPCK(tty)) { tty 1228 drivers/tty/n_tty.c if (I_IGNPAR(tty)) tty 1230 drivers/tty/n_tty.c if (I_PARMRK(tty)) { tty 1241 drivers/tty/n_tty.c n_tty_receive_signal_char(struct tty_struct *tty, int signal, unsigned char c) tty 1243 drivers/tty/n_tty.c isig(signal, tty); tty 1244 drivers/tty/n_tty.c if (I_IXON(tty)) tty 1245 drivers/tty/n_tty.c start_tty(tty); tty 1246 drivers/tty/n_tty.c if (L_ECHO(tty)) { tty 1247 drivers/tty/n_tty.c echo_char(c, tty); tty 1248 drivers/tty/n_tty.c commit_echoes(tty); tty 1250 drivers/tty/n_tty.c process_echoes(tty); tty 1271 drivers/tty/n_tty.c n_tty_receive_char_special(struct tty_struct *tty, unsigned char c) tty 1273 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1275 drivers/tty/n_tty.c if (I_IXON(tty)) { tty 1276 drivers/tty/n_tty.c if (c == START_CHAR(tty)) { tty 1277 drivers/tty/n_tty.c start_tty(tty); tty 1278 drivers/tty/n_tty.c process_echoes(tty); tty 1281 drivers/tty/n_tty.c if (c == STOP_CHAR(tty)) { tty 1282 drivers/tty/n_tty.c stop_tty(tty); tty 1287 drivers/tty/n_tty.c if (L_ISIG(tty)) { tty 1288 drivers/tty/n_tty.c if (c == INTR_CHAR(tty)) { tty 1289 drivers/tty/n_tty.c n_tty_receive_signal_char(tty, SIGINT, c); tty 1291 drivers/tty/n_tty.c } else if (c == QUIT_CHAR(tty)) { tty 1292 drivers/tty/n_tty.c n_tty_receive_signal_char(tty, SIGQUIT, c); tty 1294 drivers/tty/n_tty.c } else if (c == SUSP_CHAR(tty)) { tty 1295 drivers/tty/n_tty.c n_tty_receive_signal_char(tty, SIGTSTP, c); tty 1300 drivers/tty/n_tty.c if (tty->stopped && !tty->flow_stopped && I_IXON(tty) && I_IXANY(tty)) { tty 1301 drivers/tty/n_tty.c start_tty(tty); tty 1302 drivers/tty/n_tty.c process_echoes(tty); tty 1306 drivers/tty/n_tty.c if (I_IGNCR(tty)) tty 1308 drivers/tty/n_tty.c if (I_ICRNL(tty)) tty 1310 drivers/tty/n_tty.c } else if (c == '\n' && I_INLCR(tty)) tty 1314 drivers/tty/n_tty.c if (c == ERASE_CHAR(tty) || c == KILL_CHAR(tty) || tty 1315 drivers/tty/n_tty.c (c == WERASE_CHAR(tty) && L_IEXTEN(tty))) { tty 1316 drivers/tty/n_tty.c eraser(c, tty); tty 1317 drivers/tty/n_tty.c commit_echoes(tty); tty 1320 drivers/tty/n_tty.c if (c == LNEXT_CHAR(tty) && L_IEXTEN(tty)) { tty 1322 drivers/tty/n_tty.c if (L_ECHO(tty)) { tty 1324 drivers/tty/n_tty.c if (L_ECHOCTL(tty)) { tty 1327 drivers/tty/n_tty.c commit_echoes(tty); tty 1332 drivers/tty/n_tty.c if (c == REPRINT_CHAR(tty) && L_ECHO(tty) && L_IEXTEN(tty)) { tty 1336 drivers/tty/n_tty.c echo_char(c, tty); tty 1339 drivers/tty/n_tty.c echo_char(read_buf(ldata, tail), tty); tty 1342 drivers/tty/n_tty.c commit_echoes(tty); tty 1346 drivers/tty/n_tty.c if (L_ECHO(tty) || L_ECHONL(tty)) { tty 1348 drivers/tty/n_tty.c commit_echoes(tty); tty 1352 drivers/tty/n_tty.c if (c == EOF_CHAR(tty)) { tty 1356 drivers/tty/n_tty.c if ((c == EOL_CHAR(tty)) || tty 1357 drivers/tty/n_tty.c (c == EOL2_CHAR(tty) && L_IEXTEN(tty))) { tty 1361 drivers/tty/n_tty.c if (L_ECHO(tty)) { tty 1365 drivers/tty/n_tty.c echo_char(c, tty); tty 1366 drivers/tty/n_tty.c commit_echoes(tty); tty 1372 drivers/tty/n_tty.c if (c == (unsigned char) '\377' && I_PARMRK(tty)) tty 1379 drivers/tty/n_tty.c kill_fasync(&tty->fasync, SIGIO, POLL_IN); tty 1380 drivers/tty/n_tty.c wake_up_interruptible_poll(&tty->read_wait, EPOLLIN); tty 1385 drivers/tty/n_tty.c if (L_ECHO(tty)) { tty 1393 drivers/tty/n_tty.c echo_char(c, tty); tty 1395 drivers/tty/n_tty.c commit_echoes(tty); tty 1399 drivers/tty/n_tty.c if (c == (unsigned char) '\377' && I_PARMRK(tty)) tty 1407 drivers/tty/n_tty.c n_tty_receive_char_inline(struct tty_struct *tty, unsigned char c) tty 1409 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1411 drivers/tty/n_tty.c if (tty->stopped && !tty->flow_stopped && I_IXON(tty) && I_IXANY(tty)) { tty 1412 drivers/tty/n_tty.c start_tty(tty); tty 1413 drivers/tty/n_tty.c process_echoes(tty); tty 1415 drivers/tty/n_tty.c if (L_ECHO(tty)) { tty 1420 drivers/tty/n_tty.c echo_char(c, tty); tty 1421 drivers/tty/n_tty.c commit_echoes(tty); tty 1424 drivers/tty/n_tty.c if (c == (unsigned char) '\377' && I_PARMRK(tty)) tty 1429 drivers/tty/n_tty.c static void n_tty_receive_char(struct tty_struct *tty, unsigned char c) tty 1431 drivers/tty/n_tty.c n_tty_receive_char_inline(tty, c); tty 1435 drivers/tty/n_tty.c n_tty_receive_char_fast(struct tty_struct *tty, unsigned char c) tty 1437 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1439 drivers/tty/n_tty.c if (tty->stopped && !tty->flow_stopped && I_IXON(tty) && I_IXANY(tty)) { tty 1440 drivers/tty/n_tty.c start_tty(tty); tty 1441 drivers/tty/n_tty.c process_echoes(tty); tty 1443 drivers/tty/n_tty.c if (L_ECHO(tty)) { tty 1448 drivers/tty/n_tty.c echo_char(c, tty); tty 1449 drivers/tty/n_tty.c commit_echoes(tty); tty 1454 drivers/tty/n_tty.c static void n_tty_receive_char_closing(struct tty_struct *tty, unsigned char c) tty 1456 drivers/tty/n_tty.c if (I_ISTRIP(tty)) tty 1458 drivers/tty/n_tty.c if (I_IUCLC(tty) && L_IEXTEN(tty)) tty 1461 drivers/tty/n_tty.c if (I_IXON(tty)) { tty 1462 drivers/tty/n_tty.c if (c == STOP_CHAR(tty)) tty 1463 drivers/tty/n_tty.c stop_tty(tty); tty 1464 drivers/tty/n_tty.c else if (c == START_CHAR(tty) || tty 1465 drivers/tty/n_tty.c (tty->stopped && !tty->flow_stopped && I_IXANY(tty) && tty 1466 drivers/tty/n_tty.c c != INTR_CHAR(tty) && c != QUIT_CHAR(tty) && tty 1467 drivers/tty/n_tty.c c != SUSP_CHAR(tty))) { tty 1468 drivers/tty/n_tty.c start_tty(tty); tty 1469 drivers/tty/n_tty.c process_echoes(tty); tty 1475 drivers/tty/n_tty.c n_tty_receive_char_flagged(struct tty_struct *tty, unsigned char c, char flag) tty 1479 drivers/tty/n_tty.c n_tty_receive_break(tty); tty 1483 drivers/tty/n_tty.c n_tty_receive_parity_error(tty, c); tty 1486 drivers/tty/n_tty.c n_tty_receive_overrun(tty); tty 1489 drivers/tty/n_tty.c tty_err(tty, "unknown flag %d\n", flag); tty 1495 drivers/tty/n_tty.c n_tty_receive_char_lnext(struct tty_struct *tty, unsigned char c, char flag) tty 1497 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1501 drivers/tty/n_tty.c if (I_ISTRIP(tty)) tty 1503 drivers/tty/n_tty.c if (I_IUCLC(tty) && L_IEXTEN(tty)) tty 1505 drivers/tty/n_tty.c n_tty_receive_char(tty, c); tty 1507 drivers/tty/n_tty.c n_tty_receive_char_flagged(tty, c, flag); tty 1511 drivers/tty/n_tty.c n_tty_receive_buf_real_raw(struct tty_struct *tty, const unsigned char *cp, tty 1514 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1531 drivers/tty/n_tty.c n_tty_receive_buf_raw(struct tty_struct *tty, const unsigned char *cp, tty 1534 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1543 drivers/tty/n_tty.c n_tty_receive_char_flagged(tty, *cp++, flag); tty 1548 drivers/tty/n_tty.c n_tty_receive_buf_closing(struct tty_struct *tty, const unsigned char *cp, tty 1557 drivers/tty/n_tty.c n_tty_receive_char_closing(tty, *cp++); tty 1562 drivers/tty/n_tty.c n_tty_receive_buf_standard(struct tty_struct *tty, const unsigned char *cp, tty 1565 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1574 drivers/tty/n_tty.c if (I_ISTRIP(tty)) tty 1576 drivers/tty/n_tty.c if (I_IUCLC(tty) && L_IEXTEN(tty)) tty 1578 drivers/tty/n_tty.c if (L_EXTPROC(tty)) { tty 1583 drivers/tty/n_tty.c n_tty_receive_char_inline(tty, c); tty 1584 drivers/tty/n_tty.c else if (n_tty_receive_char_special(tty, c) && count) { tty 1587 drivers/tty/n_tty.c n_tty_receive_char_lnext(tty, *cp++, flag); tty 1591 drivers/tty/n_tty.c n_tty_receive_char_flagged(tty, *cp++, flag); tty 1596 drivers/tty/n_tty.c n_tty_receive_buf_fast(struct tty_struct *tty, const unsigned char *cp, tty 1599 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1609 drivers/tty/n_tty.c n_tty_receive_char_fast(tty, c); tty 1610 drivers/tty/n_tty.c else if (n_tty_receive_char_special(tty, c) && count) { tty 1613 drivers/tty/n_tty.c n_tty_receive_char_lnext(tty, *cp++, flag); tty 1617 drivers/tty/n_tty.c n_tty_receive_char_flagged(tty, *cp++, flag); tty 1621 drivers/tty/n_tty.c static void __receive_buf(struct tty_struct *tty, const unsigned char *cp, tty 1624 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1625 drivers/tty/n_tty.c bool preops = I_ISTRIP(tty) || (I_IUCLC(tty) && L_IEXTEN(tty)); tty 1628 drivers/tty/n_tty.c n_tty_receive_buf_real_raw(tty, cp, fp, count); tty 1629 drivers/tty/n_tty.c else if (ldata->raw || (L_EXTPROC(tty) && !preops)) tty 1630 drivers/tty/n_tty.c n_tty_receive_buf_raw(tty, cp, fp, count); tty 1631 drivers/tty/n_tty.c else if (tty->closing && !L_EXTPROC(tty)) tty 1632 drivers/tty/n_tty.c n_tty_receive_buf_closing(tty, cp, fp, count); tty 1639 drivers/tty/n_tty.c n_tty_receive_char_lnext(tty, *cp++, flag); tty 1643 drivers/tty/n_tty.c if (!preops && !I_PARMRK(tty)) tty 1644 drivers/tty/n_tty.c n_tty_receive_buf_fast(tty, cp, fp, count); tty 1646 drivers/tty/n_tty.c n_tty_receive_buf_standard(tty, cp, fp, count); tty 1648 drivers/tty/n_tty.c flush_echoes(tty); tty 1649 drivers/tty/n_tty.c if (tty->ops->flush_chars) tty 1650 drivers/tty/n_tty.c tty->ops->flush_chars(tty); tty 1653 drivers/tty/n_tty.c if (ldata->icanon && !L_EXTPROC(tty)) tty 1660 drivers/tty/n_tty.c kill_fasync(&tty->fasync, SIGIO, POLL_IN); tty 1661 drivers/tty/n_tty.c wake_up_interruptible_poll(&tty->read_wait, EPOLLIN); tty 1699 drivers/tty/n_tty.c n_tty_receive_buf_common(struct tty_struct *tty, const unsigned char *cp, tty 1702 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1705 drivers/tty/n_tty.c down_read(&tty->termios_rwsem); tty 1724 drivers/tty/n_tty.c if (I_PARMRK(tty)) tty 1742 drivers/tty/n_tty.c __receive_buf(tty, cp, fp, n); tty 1749 drivers/tty/n_tty.c } while (!test_bit(TTY_LDISC_CHANGING, &tty->flags)); tty 1751 drivers/tty/n_tty.c tty->receive_room = room; tty 1754 drivers/tty/n_tty.c if (tty->driver->type == TTY_DRIVER_TYPE_PTY) { tty 1756 drivers/tty/n_tty.c tty_set_flow_change(tty, TTY_UNTHROTTLE_SAFE); tty 1757 drivers/tty/n_tty.c tty_unthrottle_safe(tty); tty 1758 drivers/tty/n_tty.c __tty_set_flow_change(tty, 0); tty 1761 drivers/tty/n_tty.c n_tty_check_throttle(tty); tty 1763 drivers/tty/n_tty.c up_read(&tty->termios_rwsem); tty 1768 drivers/tty/n_tty.c static void n_tty_receive_buf(struct tty_struct *tty, const unsigned char *cp, tty 1771 drivers/tty/n_tty.c n_tty_receive_buf_common(tty, cp, fp, count, 0); tty 1774 drivers/tty/n_tty.c static int n_tty_receive_buf2(struct tty_struct *tty, const unsigned char *cp, tty 1777 drivers/tty/n_tty.c return n_tty_receive_buf_common(tty, cp, fp, count, 1); tty 1794 drivers/tty/n_tty.c static void n_tty_set_termios(struct tty_struct *tty, struct ktermios *old) tty 1796 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1798 drivers/tty/n_tty.c if (!old || (old->c_lflag ^ tty->termios.c_lflag) & (ICANON | EXTPROC)) { tty 1801 drivers/tty/n_tty.c if (!L_ICANON(tty) || !read_cnt(ldata)) { tty 1815 drivers/tty/n_tty.c ldata->icanon = (L_ICANON(tty) != 0); tty 1817 drivers/tty/n_tty.c if (I_ISTRIP(tty) || I_IUCLC(tty) || I_IGNCR(tty) || tty 1818 drivers/tty/n_tty.c I_ICRNL(tty) || I_INLCR(tty) || L_ICANON(tty) || tty 1819 drivers/tty/n_tty.c I_IXON(tty) || L_ISIG(tty) || L_ECHO(tty) || tty 1820 drivers/tty/n_tty.c I_PARMRK(tty)) { tty 1823 drivers/tty/n_tty.c if (I_IGNCR(tty) || I_ICRNL(tty)) tty 1825 drivers/tty/n_tty.c if (I_INLCR(tty)) tty 1828 drivers/tty/n_tty.c if (L_ICANON(tty)) { tty 1829 drivers/tty/n_tty.c set_bit(ERASE_CHAR(tty), ldata->char_map); tty 1830 drivers/tty/n_tty.c set_bit(KILL_CHAR(tty), ldata->char_map); tty 1831 drivers/tty/n_tty.c set_bit(EOF_CHAR(tty), ldata->char_map); tty 1833 drivers/tty/n_tty.c set_bit(EOL_CHAR(tty), ldata->char_map); tty 1834 drivers/tty/n_tty.c if (L_IEXTEN(tty)) { tty 1835 drivers/tty/n_tty.c set_bit(WERASE_CHAR(tty), ldata->char_map); tty 1836 drivers/tty/n_tty.c set_bit(LNEXT_CHAR(tty), ldata->char_map); tty 1837 drivers/tty/n_tty.c set_bit(EOL2_CHAR(tty), ldata->char_map); tty 1838 drivers/tty/n_tty.c if (L_ECHO(tty)) tty 1839 drivers/tty/n_tty.c set_bit(REPRINT_CHAR(tty), tty 1843 drivers/tty/n_tty.c if (I_IXON(tty)) { tty 1844 drivers/tty/n_tty.c set_bit(START_CHAR(tty), ldata->char_map); tty 1845 drivers/tty/n_tty.c set_bit(STOP_CHAR(tty), ldata->char_map); tty 1847 drivers/tty/n_tty.c if (L_ISIG(tty)) { tty 1848 drivers/tty/n_tty.c set_bit(INTR_CHAR(tty), ldata->char_map); tty 1849 drivers/tty/n_tty.c set_bit(QUIT_CHAR(tty), ldata->char_map); tty 1850 drivers/tty/n_tty.c set_bit(SUSP_CHAR(tty), ldata->char_map); tty 1857 drivers/tty/n_tty.c if ((I_IGNBRK(tty) || (!I_BRKINT(tty) && !I_PARMRK(tty))) && tty 1858 drivers/tty/n_tty.c (I_IGNPAR(tty) || !I_INPCK(tty)) && tty 1859 drivers/tty/n_tty.c (tty->driver->flags & TTY_DRIVER_REAL_RAW)) tty 1868 drivers/tty/n_tty.c if (!I_IXON(tty) && old && (old->c_iflag & IXON) && !tty->flow_stopped) { tty 1869 drivers/tty/n_tty.c start_tty(tty); tty 1870 drivers/tty/n_tty.c process_echoes(tty); tty 1874 drivers/tty/n_tty.c wake_up_interruptible(&tty->write_wait); tty 1875 drivers/tty/n_tty.c wake_up_interruptible(&tty->read_wait); tty 1888 drivers/tty/n_tty.c static void n_tty_close(struct tty_struct *tty) tty 1890 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1892 drivers/tty/n_tty.c if (tty->link) tty 1893 drivers/tty/n_tty.c n_tty_packet_mode_flush(tty); tty 1896 drivers/tty/n_tty.c tty->disc_data = NULL; tty 1909 drivers/tty/n_tty.c static int n_tty_open(struct tty_struct *tty) tty 1922 drivers/tty/n_tty.c tty->disc_data = ldata; tty 1923 drivers/tty/n_tty.c tty->closing = 0; tty 1925 drivers/tty/n_tty.c clear_bit(TTY_LDISC_HALTED, &tty->flags); tty 1926 drivers/tty/n_tty.c n_tty_set_termios(tty, NULL); tty 1927 drivers/tty/n_tty.c tty_unthrottle(tty); tty 1931 drivers/tty/n_tty.c static inline int input_available_p(struct tty_struct *tty, int poll) tty 1933 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1934 drivers/tty/n_tty.c int amt = poll && !TIME_CHAR(tty) && MIN_CHAR(tty) ? MIN_CHAR(tty) : 1; tty 1936 drivers/tty/n_tty.c if (ldata->icanon && !L_EXTPROC(tty)) tty 1962 drivers/tty/n_tty.c static int copy_from_read_buf(struct tty_struct *tty, tty 1967 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 1981 drivers/tty/n_tty.c is_eof = n == 1 && *from == EOF_CHAR(tty); tty 1982 drivers/tty/n_tty.c tty_audit_add_data(tty, from, n); tty 1983 drivers/tty/n_tty.c zero_buffer(tty, from, n); tty 1986 drivers/tty/n_tty.c if (L_EXTPROC(tty) && ldata->icanon && is_eof && tty 2018 drivers/tty/n_tty.c static int canon_copy_from_read_buf(struct tty_struct *tty, tty 2022 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 2062 drivers/tty/n_tty.c ret = tty_copy_to_user(tty, *b, tail, n); tty 2099 drivers/tty/n_tty.c static int job_control(struct tty_struct *tty, struct file *file) tty 2109 drivers/tty/n_tty.c return __tty_check_change(tty, SIGTTIN); tty 2132 drivers/tty/n_tty.c static ssize_t n_tty_read(struct tty_struct *tty, struct file *file, tty 2135 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 2145 drivers/tty/n_tty.c c = job_control(tty, file); tty 2160 drivers/tty/n_tty.c down_read(&tty->termios_rwsem); tty 2165 drivers/tty/n_tty.c minimum = MIN_CHAR(tty); tty 2167 drivers/tty/n_tty.c time = (HZ / 10) * TIME_CHAR(tty); tty 2169 drivers/tty/n_tty.c timeout = (HZ / 10) * TIME_CHAR(tty); tty 2174 drivers/tty/n_tty.c packet = tty->packet; tty 2177 drivers/tty/n_tty.c add_wait_queue(&tty->read_wait, &wait); tty 2180 drivers/tty/n_tty.c if (packet && tty->link->ctrl_status) { tty 2184 drivers/tty/n_tty.c spin_lock_irq(&tty->link->ctrl_lock); tty 2185 drivers/tty/n_tty.c cs = tty->link->ctrl_status; tty 2186 drivers/tty/n_tty.c tty->link->ctrl_status = 0; tty 2187 drivers/tty/n_tty.c spin_unlock_irq(&tty->link->ctrl_lock); tty 2197 drivers/tty/n_tty.c if (!input_available_p(tty, 0)) { tty 2198 drivers/tty/n_tty.c up_read(&tty->termios_rwsem); tty 2199 drivers/tty/n_tty.c tty_buffer_flush_work(tty->port); tty 2200 drivers/tty/n_tty.c down_read(&tty->termios_rwsem); tty 2201 drivers/tty/n_tty.c if (!input_available_p(tty, 0)) { tty 2202 drivers/tty/n_tty.c if (test_bit(TTY_OTHER_CLOSED, &tty->flags)) { tty 2212 drivers/tty/n_tty.c if (test_bit(TTY_HUPPING, &tty->flags)) tty 2216 drivers/tty/n_tty.c if (tty_io_nonblock(tty, file)) { tty 2224 drivers/tty/n_tty.c up_read(&tty->termios_rwsem); tty 2229 drivers/tty/n_tty.c down_read(&tty->termios_rwsem); tty 2234 drivers/tty/n_tty.c if (ldata->icanon && !L_EXTPROC(tty)) { tty 2235 drivers/tty/n_tty.c retval = canon_copy_from_read_buf(tty, &b, &nr); tty 2251 drivers/tty/n_tty.c uncopied = copy_from_read_buf(tty, &b, &nr); tty 2252 drivers/tty/n_tty.c uncopied += copy_from_read_buf(tty, &b, &nr); tty 2259 drivers/tty/n_tty.c n_tty_check_unthrottle(tty); tty 2267 drivers/tty/n_tty.c n_tty_kick_worker(tty); tty 2268 drivers/tty/n_tty.c up_read(&tty->termios_rwsem); tty 2270 drivers/tty/n_tty.c remove_wait_queue(&tty->read_wait, &wait); tty 2301 drivers/tty/n_tty.c static ssize_t n_tty_write(struct tty_struct *tty, struct file *file, tty 2310 drivers/tty/n_tty.c if (L_TOSTOP(tty) && file->f_op->write != redirected_tty_write) { tty 2311 drivers/tty/n_tty.c retval = tty_check_change(tty); tty 2316 drivers/tty/n_tty.c down_read(&tty->termios_rwsem); tty 2319 drivers/tty/n_tty.c process_echoes(tty); tty 2321 drivers/tty/n_tty.c add_wait_queue(&tty->write_wait, &wait); tty 2327 drivers/tty/n_tty.c if (tty_hung_up_p(file) || (tty->link && !tty->link->count)) { tty 2331 drivers/tty/n_tty.c if (O_OPOST(tty)) { tty 2333 drivers/tty/n_tty.c ssize_t num = process_output_block(tty, b, nr); tty 2345 drivers/tty/n_tty.c if (process_output(c, tty) < 0) tty 2349 drivers/tty/n_tty.c if (tty->ops->flush_chars) tty 2350 drivers/tty/n_tty.c tty->ops->flush_chars(tty); tty 2352 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 2356 drivers/tty/n_tty.c c = tty->ops->write(tty, b, nr); tty 2370 drivers/tty/n_tty.c if (tty_io_nonblock(tty, file)) { tty 2374 drivers/tty/n_tty.c up_read(&tty->termios_rwsem); tty 2378 drivers/tty/n_tty.c down_read(&tty->termios_rwsem); tty 2381 drivers/tty/n_tty.c remove_wait_queue(&tty->write_wait, &wait); tty 2382 drivers/tty/n_tty.c if (nr && tty->fasync) tty 2383 drivers/tty/n_tty.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 2384 drivers/tty/n_tty.c up_read(&tty->termios_rwsem); tty 2402 drivers/tty/n_tty.c static __poll_t n_tty_poll(struct tty_struct *tty, struct file *file, tty 2407 drivers/tty/n_tty.c poll_wait(file, &tty->read_wait, wait); tty 2408 drivers/tty/n_tty.c poll_wait(file, &tty->write_wait, wait); tty 2409 drivers/tty/n_tty.c if (input_available_p(tty, 1)) tty 2412 drivers/tty/n_tty.c tty_buffer_flush_work(tty->port); tty 2413 drivers/tty/n_tty.c if (input_available_p(tty, 1)) tty 2416 drivers/tty/n_tty.c if (tty->packet && tty->link->ctrl_status) tty 2418 drivers/tty/n_tty.c if (test_bit(TTY_OTHER_CLOSED, &tty->flags)) tty 2422 drivers/tty/n_tty.c if (tty->ops->write && !tty_is_writelocked(tty) && tty 2423 drivers/tty/n_tty.c tty_chars_in_buffer(tty) < WAKEUP_CHARS && tty 2424 drivers/tty/n_tty.c tty_write_room(tty) > 0) tty 2448 drivers/tty/n_tty.c static int n_tty_ioctl(struct tty_struct *tty, struct file *file, tty 2451 drivers/tty/n_tty.c struct n_tty_data *ldata = tty->disc_data; tty 2456 drivers/tty/n_tty.c return put_user(tty_chars_in_buffer(tty), (int __user *) arg); tty 2458 drivers/tty/n_tty.c down_write(&tty->termios_rwsem); tty 2459 drivers/tty/n_tty.c if (L_ICANON(tty) && !L_EXTPROC(tty)) tty 2463 drivers/tty/n_tty.c up_write(&tty->termios_rwsem); tty 2466 drivers/tty/n_tty.c return n_tty_ioctl_helper(tty, file, cmd, arg); tty 384 drivers/tty/nozomi.c static inline struct nozomi *get_dc_by_tty(const struct tty_struct *tty) tty 386 drivers/tty/nozomi.c return tty ? ndevs[tty->index / MAX_PORT] : NULL; tty 389 drivers/tty/nozomi.c static inline struct port *get_port_by_tty(const struct tty_struct *tty) tty 391 drivers/tty/nozomi.c struct nozomi *ndev = get_dc_by_tty(tty); tty 392 drivers/tty/nozomi.c return ndev ? &ndev->port[tty->index % MAX_PORT] : NULL; tty 789 drivers/tty/nozomi.c struct tty_struct *tty = tty_port_tty_get(&port->port); tty 795 drivers/tty/nozomi.c if (tty && tty_throttled(tty)) { tty 831 drivers/tty/nozomi.c tty_kref_put(tty); tty 1520 drivers/tty/nozomi.c static void set_rts(const struct tty_struct *tty, int rts) tty 1522 drivers/tty/nozomi.c struct port *port = get_port_by_tty(tty); tty 1526 drivers/tty/nozomi.c enable_transmit_ul(PORT_CTRL, get_dc_by_tty(tty)); tty 1529 drivers/tty/nozomi.c static void set_dtr(const struct tty_struct *tty, int dtr) tty 1531 drivers/tty/nozomi.c struct port *port = get_port_by_tty(tty); tty 1533 drivers/tty/nozomi.c DBG1("SETTING DTR index: %d, dtr: %d", tty->index, dtr); tty 1537 drivers/tty/nozomi.c enable_transmit_ul(PORT_CTRL, get_dc_by_tty(tty)); tty 1546 drivers/tty/nozomi.c static int ntty_install(struct tty_driver *driver, struct tty_struct *tty) tty 1548 drivers/tty/nozomi.c struct port *port = get_port_by_tty(tty); tty 1549 drivers/tty/nozomi.c struct nozomi *dc = get_dc_by_tty(tty); tty 1553 drivers/tty/nozomi.c ret = tty_standard_install(driver, tty); tty 1555 drivers/tty/nozomi.c tty->driver_data = port; tty 1559 drivers/tty/nozomi.c static void ntty_cleanup(struct tty_struct *tty) tty 1561 drivers/tty/nozomi.c tty->driver_data = NULL; tty 1564 drivers/tty/nozomi.c static int ntty_activate(struct tty_port *tport, struct tty_struct *tty) tty 1576 drivers/tty/nozomi.c printk("noz: activated %d: %p\n", tty->index, tport); tty 1580 drivers/tty/nozomi.c static int ntty_open(struct tty_struct *tty, struct file *filp) tty 1582 drivers/tty/nozomi.c struct port *port = tty->driver_data; tty 1583 drivers/tty/nozomi.c return tty_port_open(&port->port, tty, filp); tty 1601 drivers/tty/nozomi.c static void ntty_close(struct tty_struct *tty, struct file *filp) tty 1603 drivers/tty/nozomi.c struct port *port = tty->driver_data; tty 1605 drivers/tty/nozomi.c tty_port_close(&port->port, tty, filp); tty 1608 drivers/tty/nozomi.c static void ntty_hangup(struct tty_struct *tty) tty 1610 drivers/tty/nozomi.c struct port *port = tty->driver_data; tty 1618 drivers/tty/nozomi.c static int ntty_write(struct tty_struct *tty, const unsigned char *buffer, tty 1622 drivers/tty/nozomi.c struct nozomi *dc = get_dc_by_tty(tty); tty 1623 drivers/tty/nozomi.c struct port *port = tty->driver_data; tty 1638 drivers/tty/nozomi.c enable_transmit_ul(tty->index % MAX_PORT, dc); tty 1644 drivers/tty/nozomi.c enable_transmit_ul(tty->index % MAX_PORT, dc); tty 1660 drivers/tty/nozomi.c static int ntty_write_room(struct tty_struct *tty) tty 1662 drivers/tty/nozomi.c struct port *port = tty->driver_data; tty 1664 drivers/tty/nozomi.c const struct nozomi *dc = get_dc_by_tty(tty); tty 1673 drivers/tty/nozomi.c static int ntty_tiocmget(struct tty_struct *tty) tty 1675 drivers/tty/nozomi.c const struct port *port = tty->driver_data; tty 1690 drivers/tty/nozomi.c static int ntty_tiocmset(struct tty_struct *tty, tty 1693 drivers/tty/nozomi.c struct nozomi *dc = get_dc_by_tty(tty); tty 1698 drivers/tty/nozomi.c set_rts(tty, 1); tty 1700 drivers/tty/nozomi.c set_rts(tty, 0); tty 1703 drivers/tty/nozomi.c set_dtr(tty, 1); tty 1705 drivers/tty/nozomi.c set_dtr(tty, 0); tty 1727 drivers/tty/nozomi.c static int ntty_tiocgicount(struct tty_struct *tty, tty 1730 drivers/tty/nozomi.c struct port *port = tty->driver_data; tty 1747 drivers/tty/nozomi.c static int ntty_ioctl(struct tty_struct *tty, tty 1750 drivers/tty/nozomi.c struct port *port = tty->driver_data; tty 1775 drivers/tty/nozomi.c static void ntty_unthrottle(struct tty_struct *tty) tty 1777 drivers/tty/nozomi.c struct nozomi *dc = get_dc_by_tty(tty); tty 1782 drivers/tty/nozomi.c enable_transmit_dl(tty->index % MAX_PORT, dc); tty 1783 drivers/tty/nozomi.c set_rts(tty, 1); tty 1792 drivers/tty/nozomi.c static void ntty_throttle(struct tty_struct *tty) tty 1794 drivers/tty/nozomi.c struct nozomi *dc = get_dc_by_tty(tty); tty 1799 drivers/tty/nozomi.c set_rts(tty, 0); tty 1804 drivers/tty/nozomi.c static s32 ntty_chars_in_buffer(struct tty_struct *tty) tty 1806 drivers/tty/nozomi.c struct port *port = tty->driver_data; tty 1807 drivers/tty/nozomi.c struct nozomi *dc = get_dc_by_tty(tty); tty 35 drivers/tty/pty.c # define tty_debug_hangup(tty, f, args...) tty_debug(tty, f, ##args) tty 37 drivers/tty/pty.c # define tty_debug_hangup(tty, f, args...) do {} while (0) tty 46 drivers/tty/pty.c static void pty_close(struct tty_struct *tty, struct file *filp) tty 48 drivers/tty/pty.c BUG_ON(!tty); tty 49 drivers/tty/pty.c if (tty->driver->subtype == PTY_TYPE_MASTER) tty 50 drivers/tty/pty.c WARN_ON(tty->count > 1); tty 52 drivers/tty/pty.c if (tty_io_error(tty)) tty 54 drivers/tty/pty.c if (tty->count > 2) tty 57 drivers/tty/pty.c set_bit(TTY_IO_ERROR, &tty->flags); tty 58 drivers/tty/pty.c wake_up_interruptible(&tty->read_wait); tty 59 drivers/tty/pty.c wake_up_interruptible(&tty->write_wait); tty 60 drivers/tty/pty.c spin_lock_irq(&tty->ctrl_lock); tty 61 drivers/tty/pty.c tty->packet = 0; tty 62 drivers/tty/pty.c spin_unlock_irq(&tty->ctrl_lock); tty 64 drivers/tty/pty.c if (!tty->link) tty 66 drivers/tty/pty.c set_bit(TTY_OTHER_CLOSED, &tty->link->flags); tty 67 drivers/tty/pty.c wake_up_interruptible(&tty->link->read_wait); tty 68 drivers/tty/pty.c wake_up_interruptible(&tty->link->write_wait); tty 69 drivers/tty/pty.c if (tty->driver->subtype == PTY_TYPE_MASTER) { tty 70 drivers/tty/pty.c set_bit(TTY_OTHER_CLOSED, &tty->flags); tty 72 drivers/tty/pty.c if (tty->driver == ptm_driver) { tty 74 drivers/tty/pty.c if (tty->link->driver_data) tty 75 drivers/tty/pty.c devpts_pty_kill(tty->link->driver_data); tty 79 drivers/tty/pty.c tty_vhangup(tty->link); tty 93 drivers/tty/pty.c static void pty_unthrottle(struct tty_struct *tty) tty 95 drivers/tty/pty.c tty_wakeup(tty->link); tty 96 drivers/tty/pty.c set_bit(TTY_THROTTLED, &tty->flags); tty 111 drivers/tty/pty.c static int pty_write(struct tty_struct *tty, const unsigned char *buf, int c) tty 113 drivers/tty/pty.c struct tty_struct *to = tty->link; tty 116 drivers/tty/pty.c if (tty->stopped) tty 139 drivers/tty/pty.c static int pty_write_room(struct tty_struct *tty) tty 141 drivers/tty/pty.c if (tty->stopped) tty 143 drivers/tty/pty.c return tty_buffer_space_avail(tty->link->port); tty 154 drivers/tty/pty.c static int pty_chars_in_buffer(struct tty_struct *tty) tty 160 drivers/tty/pty.c static int pty_set_lock(struct tty_struct *tty, int __user *arg) tty 166 drivers/tty/pty.c set_bit(TTY_PTY_LOCK, &tty->flags); tty 168 drivers/tty/pty.c clear_bit(TTY_PTY_LOCK, &tty->flags); tty 172 drivers/tty/pty.c static int pty_get_lock(struct tty_struct *tty, int __user *arg) tty 174 drivers/tty/pty.c int locked = test_bit(TTY_PTY_LOCK, &tty->flags); tty 179 drivers/tty/pty.c static int pty_set_pktmode(struct tty_struct *tty, int __user *arg) tty 186 drivers/tty/pty.c spin_lock_irq(&tty->ctrl_lock); tty 188 drivers/tty/pty.c if (!tty->packet) { tty 189 drivers/tty/pty.c tty->link->ctrl_status = 0; tty 191 drivers/tty/pty.c tty->packet = 1; tty 194 drivers/tty/pty.c tty->packet = 0; tty 195 drivers/tty/pty.c spin_unlock_irq(&tty->ctrl_lock); tty 201 drivers/tty/pty.c static int pty_get_pktmode(struct tty_struct *tty, int __user *arg) tty 203 drivers/tty/pty.c int pktmode = tty->packet; tty 208 drivers/tty/pty.c static int pty_signal(struct tty_struct *tty, int sig) tty 215 drivers/tty/pty.c if (tty->link) { tty 216 drivers/tty/pty.c pgrp = tty_get_pgrp(tty->link); tty 224 drivers/tty/pty.c static void pty_flush_buffer(struct tty_struct *tty) tty 226 drivers/tty/pty.c struct tty_struct *to = tty->link; tty 233 drivers/tty/pty.c spin_lock_irq(&tty->ctrl_lock); tty 234 drivers/tty/pty.c tty->ctrl_status |= TIOCPKT_FLUSHWRITE; tty 236 drivers/tty/pty.c spin_unlock_irq(&tty->ctrl_lock); tty 240 drivers/tty/pty.c static int pty_open(struct tty_struct *tty, struct file *filp) tty 242 drivers/tty/pty.c if (!tty || !tty->link) tty 245 drivers/tty/pty.c if (test_bit(TTY_OTHER_CLOSED, &tty->flags)) tty 247 drivers/tty/pty.c if (test_bit(TTY_PTY_LOCK, &tty->link->flags)) tty 249 drivers/tty/pty.c if (tty->driver->subtype == PTY_TYPE_SLAVE && tty->link->count != 1) tty 252 drivers/tty/pty.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 253 drivers/tty/pty.c clear_bit(TTY_OTHER_CLOSED, &tty->link->flags); tty 254 drivers/tty/pty.c set_bit(TTY_THROTTLED, &tty->flags); tty 258 drivers/tty/pty.c set_bit(TTY_IO_ERROR, &tty->flags); tty 262 drivers/tty/pty.c static void pty_set_termios(struct tty_struct *tty, tty 266 drivers/tty/pty.c if (tty->link && tty->link->packet) { tty 267 drivers/tty/pty.c int extproc = (old_termios->c_lflag & EXTPROC) | L_EXTPROC(tty); tty 271 drivers/tty/pty.c int new_flow = (I_IXON(tty) && tty 272 drivers/tty/pty.c STOP_CHAR(tty) == '\023' && tty 273 drivers/tty/pty.c START_CHAR(tty) == '\021'); tty 275 drivers/tty/pty.c spin_lock_irq(&tty->ctrl_lock); tty 277 drivers/tty/pty.c tty->ctrl_status &= ~(TIOCPKT_DOSTOP | TIOCPKT_NOSTOP); tty 279 drivers/tty/pty.c tty->ctrl_status |= TIOCPKT_DOSTOP; tty 281 drivers/tty/pty.c tty->ctrl_status |= TIOCPKT_NOSTOP; tty 284 drivers/tty/pty.c tty->ctrl_status |= TIOCPKT_IOCTL; tty 285 drivers/tty/pty.c spin_unlock_irq(&tty->ctrl_lock); tty 286 drivers/tty/pty.c wake_up_interruptible(&tty->link->read_wait); tty 290 drivers/tty/pty.c tty->termios.c_cflag &= ~(CSIZE | PARENB); tty 291 drivers/tty/pty.c tty->termios.c_cflag |= (CS8 | CREAD); tty 303 drivers/tty/pty.c static int pty_resize(struct tty_struct *tty, struct winsize *ws) tty 306 drivers/tty/pty.c struct tty_struct *pty = tty->link; tty 309 drivers/tty/pty.c mutex_lock(&tty->winsize_mutex); tty 310 drivers/tty/pty.c if (!memcmp(ws, &tty->winsize, sizeof(*ws))) tty 314 drivers/tty/pty.c pgrp = tty_get_pgrp(tty); tty 325 drivers/tty/pty.c tty->winsize = *ws; tty 328 drivers/tty/pty.c mutex_unlock(&tty->winsize_mutex); tty 342 drivers/tty/pty.c static void pty_start(struct tty_struct *tty) tty 346 drivers/tty/pty.c if (tty->link && tty->link->packet) { tty 347 drivers/tty/pty.c spin_lock_irqsave(&tty->ctrl_lock, flags); tty 348 drivers/tty/pty.c tty->ctrl_status &= ~TIOCPKT_STOP; tty 349 drivers/tty/pty.c tty->ctrl_status |= TIOCPKT_START; tty 350 drivers/tty/pty.c spin_unlock_irqrestore(&tty->ctrl_lock, flags); tty 351 drivers/tty/pty.c wake_up_interruptible_poll(&tty->link->read_wait, EPOLLIN); tty 355 drivers/tty/pty.c static void pty_stop(struct tty_struct *tty) tty 359 drivers/tty/pty.c if (tty->link && tty->link->packet) { tty 360 drivers/tty/pty.c spin_lock_irqsave(&tty->ctrl_lock, flags); tty 361 drivers/tty/pty.c tty->ctrl_status &= ~TIOCPKT_START; tty 362 drivers/tty/pty.c tty->ctrl_status |= TIOCPKT_STOP; tty 363 drivers/tty/pty.c spin_unlock_irqrestore(&tty->ctrl_lock, flags); tty 364 drivers/tty/pty.c wake_up_interruptible_poll(&tty->link->read_wait, EPOLLIN); tty 379 drivers/tty/pty.c static int pty_common_install(struct tty_driver *driver, struct tty_struct *tty, tty 384 drivers/tty/pty.c int idx = tty->index; tty 409 drivers/tty/pty.c tty_init_termios(tty); tty 413 drivers/tty/pty.c driver->ttys[idx] = tty; tty 415 drivers/tty/pty.c memset(&tty->termios_locked, 0, sizeof(tty->termios_locked)); tty 416 drivers/tty/pty.c tty->termios = driver->init_termios; tty 417 drivers/tty/pty.c memset(&o_tty->termios_locked, 0, sizeof(tty->termios_locked)); tty 426 drivers/tty/pty.c tty->link = o_tty; tty 427 drivers/tty/pty.c o_tty->link = tty; tty 433 drivers/tty/pty.c tty->port = ports[1]; tty 439 drivers/tty/pty.c tty->count++; tty 451 drivers/tty/pty.c static void pty_cleanup(struct tty_struct *tty) tty 453 drivers/tty/pty.c tty_port_put(tty->port); tty 459 drivers/tty/pty.c static int pty_install(struct tty_driver *driver, struct tty_struct *tty) tty 461 drivers/tty/pty.c return pty_common_install(driver, tty, true); tty 464 drivers/tty/pty.c static void pty_remove(struct tty_driver *driver, struct tty_struct *tty) tty 466 drivers/tty/pty.c struct tty_struct *pair = tty->link; tty 467 drivers/tty/pty.c driver->ttys[tty->index] = NULL; tty 472 drivers/tty/pty.c static int pty_bsd_ioctl(struct tty_struct *tty, tty 477 drivers/tty/pty.c return pty_set_lock(tty, (int __user *) arg); tty 479 drivers/tty/pty.c return pty_get_lock(tty, (int __user *)arg); tty 481 drivers/tty/pty.c return pty_set_pktmode(tty, (int __user *)arg); tty 483 drivers/tty/pty.c return pty_get_pktmode(tty, (int __user *)arg); tty 485 drivers/tty/pty.c return pty_signal(tty, (int) arg); tty 493 drivers/tty/pty.c static long pty_bsd_compat_ioctl(struct tty_struct *tty, tty 500 drivers/tty/pty.c return pty_bsd_ioctl(tty, cmd, (unsigned long)compat_ptr(arg)); tty 623 drivers/tty/pty.c int ptm_open_peer(struct file *master, struct tty_struct *tty, int flags) tty 630 drivers/tty/pty.c if (tty->driver != ptm_driver) tty 640 drivers/tty/pty.c path.mnt = devpts_mntget(master, tty->driver_data); tty 645 drivers/tty/pty.c path.dentry = tty->link->driver_data; tty 663 drivers/tty/pty.c static int pty_unix98_ioctl(struct tty_struct *tty, tty 668 drivers/tty/pty.c return pty_set_lock(tty, (int __user *)arg); tty 670 drivers/tty/pty.c return pty_get_lock(tty, (int __user *)arg); tty 672 drivers/tty/pty.c return pty_set_pktmode(tty, (int __user *)arg); tty 674 drivers/tty/pty.c return pty_get_pktmode(tty, (int __user *)arg); tty 676 drivers/tty/pty.c return put_user(tty->index, (unsigned int __user *)arg); tty 678 drivers/tty/pty.c return pty_signal(tty, (int) arg); tty 685 drivers/tty/pty.c static long pty_unix98_compat_ioctl(struct tty_struct *tty, tty 692 drivers/tty/pty.c return pty_unix98_ioctl(tty, cmd, tty 727 drivers/tty/pty.c struct tty_struct *tty; tty 730 drivers/tty/pty.c tty = devpts_get_priv(file->f_path.dentry); tty 733 drivers/tty/pty.c if (!tty) tty 735 drivers/tty/pty.c return tty; tty 738 drivers/tty/pty.c static int pty_unix98_install(struct tty_driver *driver, struct tty_struct *tty) tty 740 drivers/tty/pty.c return pty_common_install(driver, tty, false); tty 744 drivers/tty/pty.c static void pty_unix98_remove(struct tty_driver *driver, struct tty_struct *tty) tty 748 drivers/tty/pty.c if (tty->driver->subtype == PTY_TYPE_MASTER) tty 749 drivers/tty/pty.c fsi = tty->driver_data; tty 751 drivers/tty/pty.c fsi = tty->link->driver_data; tty 754 drivers/tty/pty.c devpts_kill_index(fsi, tty->index); tty 759 drivers/tty/pty.c static void pty_show_fdinfo(struct tty_struct *tty, struct seq_file *m) tty 761 drivers/tty/pty.c seq_printf(m, "tty-index:\t%d\n", tty->index); tty 814 drivers/tty/pty.c struct tty_struct *tty; tty 845 drivers/tty/pty.c tty = tty_init_dev(ptm_driver, index); tty 850 drivers/tty/pty.c retval = PTR_ERR(tty); tty 851 drivers/tty/pty.c if (IS_ERR(tty)) tty 858 drivers/tty/pty.c set_bit(TTY_PTY_LOCK, &tty->flags); /* LOCK THE SLAVE */ tty 859 drivers/tty/pty.c tty->driver_data = fsi; tty 861 drivers/tty/pty.c tty_add_file(tty, filp); tty 863 drivers/tty/pty.c dentry = devpts_pty_new(fsi, index, tty->link); tty 868 drivers/tty/pty.c tty->link->driver_data = dentry; tty 870 drivers/tty/pty.c retval = ptm_driver->ops->open(tty, filp); tty 874 drivers/tty/pty.c tty_debug_hangup(tty, "opening (count=%d)\n", tty->count); tty 876 drivers/tty/pty.c tty_unlock(tty); tty 879 drivers/tty/pty.c tty_unlock(tty); tty 217 drivers/tty/rocket.c static void rp_wait_until_sent(struct tty_struct *tty, int timeout); tty 218 drivers/tty/rocket.c static void rp_flush_buffer(struct tty_struct *tty); tty 221 drivers/tty/rocket.c static void rp_start(struct tty_struct *tty); tty 414 drivers/tty/rocket.c struct tty_struct *tty; tty 422 drivers/tty/rocket.c tty = tty_port_tty_get(&info->port); tty 424 drivers/tty/rocket.c if (tty == NULL) { tty 435 drivers/tty/rocket.c if (tty->stopped) tty 457 drivers/tty/rocket.c tty_wakeup(tty); tty 459 drivers/tty/rocket.c wake_up_interruptible(&tty->poll_wait); tty 464 drivers/tty/rocket.c tty_kref_put(tty); tty 695 drivers/tty/rocket.c static void configure_r_port(struct tty_struct *tty, struct r_port *info, tty 703 drivers/tty/rocket.c struct ktermios *t = &tty->termios; tty 736 drivers/tty/rocket.c baud = tty_get_baud_rate(tty); tty 754 drivers/tty/rocket.c tty_encode_baud_rate(tty, baud, baud); tty 779 drivers/tty/rocket.c if (I_IXON(tty)) { tty 781 drivers/tty/rocket.c if (I_IXANY(tty)) { tty 786 drivers/tty/rocket.c sSetTxXONChar(cp, START_CHAR(tty)); tty 787 drivers/tty/rocket.c sSetTxXOFFChar(cp, STOP_CHAR(tty)); tty 799 drivers/tty/rocket.c if (I_INPCK(tty)) tty 801 drivers/tty/rocket.c if (I_BRKINT(tty) || I_PARMRK(tty)) tty 808 drivers/tty/rocket.c if (I_IGNPAR(tty)) tty 810 drivers/tty/rocket.c if (I_IGNBRK(tty)) { tty 816 drivers/tty/rocket.c if (I_IGNPAR(tty)) tty 871 drivers/tty/rocket.c static int rp_open(struct tty_struct *tty, struct file *filp) tty 879 drivers/tty/rocket.c info = rp_table[tty->index]; tty 896 drivers/tty/rocket.c tty->driver_data = info; tty 897 drivers/tty/rocket.c tty_port_tty_set(port, tty); tty 940 drivers/tty/rocket.c configure_r_port(tty, info, NULL); tty 941 drivers/tty/rocket.c if (C_BAUD(tty)) { tty 949 drivers/tty/rocket.c retval = tty_port_block_til_ready(port, tty, filp); tty 962 drivers/tty/rocket.c static void rp_close(struct tty_struct *tty, struct file *filp) tty 964 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 976 drivers/tty/rocket.c if (tty_port_close_start(port, tty, filp) == 0) tty 989 drivers/tty/rocket.c rp_wait_until_sent(tty, timeout); tty 1000 drivers/tty/rocket.c if (C_HUPCL(tty)) tty 1003 drivers/tty/rocket.c rp_flush_buffer(tty); tty 1005 drivers/tty/rocket.c tty_ldisc_flush(tty); tty 1024 drivers/tty/rocket.c tty->closing = 0; tty 1041 drivers/tty/rocket.c static void rp_set_termios(struct tty_struct *tty, tty 1044 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1051 drivers/tty/rocket.c cflag = tty->termios.c_cflag; tty 1057 drivers/tty/rocket.c tty->termios.c_cflag = tty 1060 drivers/tty/rocket.c tty->termios.c_cflag &= ~CMSPAR; tty 1062 drivers/tty/rocket.c configure_r_port(tty, info, old_termios); tty 1067 drivers/tty/rocket.c if ((old_termios->c_cflag & CBAUD) && !C_BAUD(tty)) { tty 1073 drivers/tty/rocket.c if (!(old_termios->c_cflag & CBAUD) && C_BAUD(tty)) { tty 1078 drivers/tty/rocket.c if ((old_termios->c_cflag & CRTSCTS) && !C_CRTSCTS(tty)) tty 1079 drivers/tty/rocket.c rp_start(tty); tty 1082 drivers/tty/rocket.c static int rp_break(struct tty_struct *tty, int break_state) tty 1084 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1128 drivers/tty/rocket.c static int rp_tiocmget(struct tty_struct *tty) tty 1130 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1148 drivers/tty/rocket.c static int rp_tiocmset(struct tty_struct *tty, tty 1151 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1184 drivers/tty/rocket.c static int set_config(struct tty_struct *tty, struct r_port *info, tty 1207 drivers/tty/rocket.c dev_warn_ratelimited(tty->dev, "use of SPD flags is deprecated\n"); tty 1216 drivers/tty/rocket.c configure_r_port(tty, info, NULL); tty 1278 drivers/tty/rocket.c static int rp_ioctl(struct tty_struct *tty, tty 1281 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1290 drivers/tty/rocket.c dev_warn_ratelimited(tty->dev, tty 1295 drivers/tty/rocket.c dev_warn_ratelimited(tty->dev, tty 1297 drivers/tty/rocket.c ret = set_config(tty, info, argp); tty 1300 drivers/tty/rocket.c dev_warn_ratelimited(tty->dev, tty 1305 drivers/tty/rocket.c dev_warn_ratelimited(tty->dev, tty 1310 drivers/tty/rocket.c dev_warn_ratelimited(tty->dev, tty 1320 drivers/tty/rocket.c static void rp_send_xchar(struct tty_struct *tty, char ch) tty 1322 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1335 drivers/tty/rocket.c static void rp_throttle(struct tty_struct *tty) tty 1337 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1340 drivers/tty/rocket.c printk(KERN_INFO "throttle %s ....\n", tty->name); tty 1346 drivers/tty/rocket.c if (I_IXOFF(tty)) tty 1347 drivers/tty/rocket.c rp_send_xchar(tty, STOP_CHAR(tty)); tty 1352 drivers/tty/rocket.c static void rp_unthrottle(struct tty_struct *tty) tty 1354 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1356 drivers/tty/rocket.c printk(KERN_INFO "unthrottle %s ....\n", tty->name); tty 1362 drivers/tty/rocket.c if (I_IXOFF(tty)) tty 1363 drivers/tty/rocket.c rp_send_xchar(tty, START_CHAR(tty)); tty 1376 drivers/tty/rocket.c static void rp_stop(struct tty_struct *tty) tty 1378 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1381 drivers/tty/rocket.c printk(KERN_INFO "stop %s: %d %d....\n", tty->name, tty 1392 drivers/tty/rocket.c static void rp_start(struct tty_struct *tty) tty 1394 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1397 drivers/tty/rocket.c printk(KERN_INFO "start %s: %d %d....\n", tty->name, tty 1412 drivers/tty/rocket.c static void rp_wait_until_sent(struct tty_struct *tty, int timeout) tty 1414 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1466 drivers/tty/rocket.c static void rp_hangup(struct tty_struct *tty) tty 1469 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1478 drivers/tty/rocket.c rp_flush_buffer(tty); tty 1506 drivers/tty/rocket.c static int rp_put_char(struct tty_struct *tty, unsigned char ch) tty 1508 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1528 drivers/tty/rocket.c if (!tty->stopped && info->xmit_fifo_room == 0) tty 1531 drivers/tty/rocket.c if (tty->stopped || info->xmit_fifo_room == 0 || info->xmit_cnt != 0) { tty 1552 drivers/tty/rocket.c static int rp_write(struct tty_struct *tty, tty 1555 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1572 drivers/tty/rocket.c if (!tty->stopped && info->xmit_fifo_room < count) tty 1579 drivers/tty/rocket.c if (!tty->stopped && info->xmit_cnt == 0 && info->xmit_fifo_room > 0) { tty 1627 drivers/tty/rocket.c if ((retval > 0) && !tty->stopped) tty 1632 drivers/tty/rocket.c tty_wakeup(tty); tty 1634 drivers/tty/rocket.c wake_up_interruptible(&tty->poll_wait); tty 1646 drivers/tty/rocket.c static int rp_write_room(struct tty_struct *tty) tty 1648 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1667 drivers/tty/rocket.c static int rp_chars_in_buffer(struct tty_struct *tty) tty 1669 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1685 drivers/tty/rocket.c static void rp_flush_buffer(struct tty_struct *tty) tty 1687 drivers/tty/rocket.c struct r_port *info = tty->driver_data; tty 1699 drivers/tty/rocket.c wake_up_interruptible(&tty->poll_wait); tty 1701 drivers/tty/rocket.c tty_wakeup(tty); tty 15 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty; tty 52 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty; tty 54 drivers/tty/serdev/serdev-ttyport.c tty = tty_port_tty_get(port); tty 55 drivers/tty/serdev/serdev-ttyport.c if (!tty) tty 58 drivers/tty/serdev/serdev-ttyport.c if (test_and_clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags) && tty 63 drivers/tty/serdev/serdev-ttyport.c wake_up_interruptible(&tty->write_wait); tty 65 drivers/tty/serdev/serdev-ttyport.c tty_kref_put(tty); tty 80 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 85 drivers/tty/serdev/serdev-ttyport.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 86 drivers/tty/serdev/serdev-ttyport.c return tty->ops->write(serport->tty, data, len); tty 92 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 94 drivers/tty/serdev/serdev-ttyport.c tty_driver_flush_buffer(tty); tty 100 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 102 drivers/tty/serdev/serdev-ttyport.c return tty_write_room(tty); tty 108 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty; tty 112 drivers/tty/serdev/serdev-ttyport.c tty = tty_init_dev(serport->tty_drv, serport->tty_idx); tty 113 drivers/tty/serdev/serdev-ttyport.c if (IS_ERR(tty)) tty 114 drivers/tty/serdev/serdev-ttyport.c return PTR_ERR(tty); tty 115 drivers/tty/serdev/serdev-ttyport.c serport->tty = tty; tty 117 drivers/tty/serdev/serdev-ttyport.c if (!tty->ops->open || !tty->ops->close) { tty 122 drivers/tty/serdev/serdev-ttyport.c ret = tty->ops->open(serport->tty, NULL); tty 126 drivers/tty/serdev/serdev-ttyport.c tty_unlock(serport->tty); tty 129 drivers/tty/serdev/serdev-ttyport.c ktermios = tty->termios; tty 139 drivers/tty/serdev/serdev-ttyport.c tty_set_termios(tty, &ktermios); tty 146 drivers/tty/serdev/serdev-ttyport.c tty->ops->close(tty, NULL); tty 148 drivers/tty/serdev/serdev-ttyport.c tty_unlock(tty); tty 149 drivers/tty/serdev/serdev-ttyport.c tty_release_struct(tty, serport->tty_idx); tty 157 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 161 drivers/tty/serdev/serdev-ttyport.c tty_lock(tty); tty 162 drivers/tty/serdev/serdev-ttyport.c if (tty->ops->close) tty 163 drivers/tty/serdev/serdev-ttyport.c tty->ops->close(tty, NULL); tty 164 drivers/tty/serdev/serdev-ttyport.c tty_unlock(tty); tty 166 drivers/tty/serdev/serdev-ttyport.c tty_release_struct(tty, serport->tty_idx); tty 172 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 173 drivers/tty/serdev/serdev-ttyport.c struct ktermios ktermios = tty->termios; tty 179 drivers/tty/serdev/serdev-ttyport.c tty_set_termios(tty, &ktermios); tty 186 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 187 drivers/tty/serdev/serdev-ttyport.c struct ktermios ktermios = tty->termios; tty 194 drivers/tty/serdev/serdev-ttyport.c tty_set_termios(tty, &ktermios); tty 201 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 202 drivers/tty/serdev/serdev-ttyport.c struct ktermios ktermios = tty->termios; tty 211 drivers/tty/serdev/serdev-ttyport.c tty_set_termios(tty, &ktermios); tty 213 drivers/tty/serdev/serdev-ttyport.c if ((tty->termios.c_cflag & (PARENB | PARODD | CMSPAR)) != tty 223 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 225 drivers/tty/serdev/serdev-ttyport.c tty_wait_until_sent(tty, timeout); tty 231 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 233 drivers/tty/serdev/serdev-ttyport.c if (!tty->ops->tiocmget) tty 236 drivers/tty/serdev/serdev-ttyport.c return tty->ops->tiocmget(tty); tty 242 drivers/tty/serdev/serdev-ttyport.c struct tty_struct *tty = serport->tty; tty 244 drivers/tty/serdev/serdev-ttyport.c if (!tty->ops->tiocmset) tty 247 drivers/tty/serdev/serdev-ttyport.c return tty->ops->tiocmset(tty, set, clear); tty 271 drivers/tty/serial/8250/8250_mtk.c serial_out(up, UART_XON1, START_CHAR(port->state->port.tty)); tty 272 drivers/tty/serial/8250/8250_mtk.c serial_out(up, UART_XOFF1, STOP_CHAR(port->state->port.tty)); tty 3128 drivers/tty/serial/8250/8250_port.c if (port->state->port.tty && termios.c_cflag == 0) tty 3129 drivers/tty/serial/8250/8250_port.c termios.c_cflag = port->state->port.tty->termios.c_cflag; tty 1147 drivers/tty/serial/fsl_lpuart.c struct tty_struct *tty = port->tty; tty 1148 drivers/tty/serial/fsl_lpuart.c struct ktermios *termios = &tty->termios; tty 1150 drivers/tty/serial/fsl_lpuart.c baud = tty_get_baud_rate(tty); tty 286 drivers/tty/serial/ifx6x60.c static int ifx_spi_tiocmget(struct tty_struct *tty) tty 289 drivers/tty/serial/ifx6x60.c struct ifx_spi_device *ifx_dev = tty->driver_data; tty 312 drivers/tty/serial/ifx6x60.c static int ifx_spi_tiocmset(struct tty_struct *tty, tty 315 drivers/tty/serial/ifx6x60.c struct ifx_spi_device *ifx_dev = tty->driver_data; tty 340 drivers/tty/serial/ifx6x60.c static int ifx_spi_open(struct tty_struct *tty, struct file *filp) tty 342 drivers/tty/serial/ifx6x60.c return tty_port_open(&saved_ifx_dev->tty_port, tty, filp); tty 353 drivers/tty/serial/ifx6x60.c static void ifx_spi_close(struct tty_struct *tty, struct file *filp) tty 355 drivers/tty/serial/ifx6x60.c struct ifx_spi_device *ifx_dev = tty->driver_data; tty 356 drivers/tty/serial/ifx6x60.c tty_port_close(&ifx_dev->tty_port, tty, filp); tty 488 drivers/tty/serial/ifx6x60.c static int ifx_spi_write(struct tty_struct *tty, const unsigned char *buf, tty 491 drivers/tty/serial/ifx6x60.c struct ifx_spi_device *ifx_dev = tty->driver_data; tty 514 drivers/tty/serial/ifx6x60.c static int ifx_spi_write_room(struct tty_struct *tty) tty 516 drivers/tty/serial/ifx6x60.c struct ifx_spi_device *ifx_dev = tty->driver_data; tty 527 drivers/tty/serial/ifx6x60.c static int ifx_spi_chars_in_buffer(struct tty_struct *tty) tty 529 drivers/tty/serial/ifx6x60.c struct ifx_spi_device *ifx_dev = tty->driver_data; tty 541 drivers/tty/serial/ifx6x60.c static void ifx_spi_hangup(struct tty_struct *tty) tty 543 drivers/tty/serial/ifx6x60.c struct ifx_spi_device *ifx_dev = tty->driver_data; tty 554 drivers/tty/serial/ifx6x60.c static int ifx_port_activate(struct tty_port *port, struct tty_struct *tty) tty 567 drivers/tty/serial/ifx6x60.c tty->driver_data = ifx_dev; tty 712 drivers/tty/serial/jsm/jsm_cls.c cflag = C_BAUD(ch->uart_port.state->port.tty); tty 978 drivers/tty/serial/jsm/jsm_neo.c cflag = C_BAUD(ch->uart_port.state->port.tty); tty 156 drivers/tty/serial/jsm/jsm_tty.c termios = &port->state->port.tty->termios; tty 243 drivers/tty/serial/jsm/jsm_tty.c termios = &port->state->port.tty->termios; tty 526 drivers/tty/serial/jsm/jsm_tty.c tp = port->tty; tty 208 drivers/tty/serial/kgdb_nmi.c static int kgdb_nmi_tty_activate(struct tty_port *port, struct tty_struct *tty) tty 234 drivers/tty/serial/kgdb_nmi.c static int kgdb_nmi_tty_install(struct tty_driver *drv, struct tty_struct *tty) tty 247 drivers/tty/serial/kgdb_nmi.c tty->driver_data = priv; tty 249 drivers/tty/serial/kgdb_nmi.c ret = tty_port_install(&priv->port, drv, tty); tty 261 drivers/tty/serial/kgdb_nmi.c static void kgdb_nmi_tty_cleanup(struct tty_struct *tty) tty 263 drivers/tty/serial/kgdb_nmi.c struct kgdb_nmi_tty_priv *priv = tty->driver_data; tty 265 drivers/tty/serial/kgdb_nmi.c tty->driver_data = NULL; tty 270 drivers/tty/serial/kgdb_nmi.c static int kgdb_nmi_tty_open(struct tty_struct *tty, struct file *file) tty 272 drivers/tty/serial/kgdb_nmi.c struct kgdb_nmi_tty_priv *priv = tty->driver_data; tty 276 drivers/tty/serial/kgdb_nmi.c ret = tty_port_open(&priv->port, tty, file); tty 283 drivers/tty/serial/kgdb_nmi.c static void kgdb_nmi_tty_close(struct tty_struct *tty, struct file *file) tty 285 drivers/tty/serial/kgdb_nmi.c struct kgdb_nmi_tty_priv *priv = tty->driver_data; tty 291 drivers/tty/serial/kgdb_nmi.c tty_port_close(&priv->port, tty, file); tty 294 drivers/tty/serial/kgdb_nmi.c static void kgdb_nmi_tty_hangup(struct tty_struct *tty) tty 296 drivers/tty/serial/kgdb_nmi.c struct kgdb_nmi_tty_priv *priv = tty->driver_data; tty 301 drivers/tty/serial/kgdb_nmi.c static int kgdb_nmi_tty_write_room(struct tty_struct *tty) tty 307 drivers/tty/serial/kgdb_nmi.c static int kgdb_nmi_tty_write(struct tty_struct *tty, const unchar *buf, int c) tty 1052 drivers/tty/serial/pch_uart.c struct tty_struct *tty = tty_port_tty_get(&port->state->port); tty 1074 drivers/tty/serial/pch_uart.c if (tty == NULL) { tty 1078 drivers/tty/serial/pch_uart.c tty_kref_put(tty); tty 203 drivers/tty/serial/pic32_uart.c struct tty_port *tty; tty 214 drivers/tty/serial/pic32_uart.c tty = &port->state->port; tty 229 drivers/tty/serial/pic32_uart.c tty_insert_flip_char(tty, 0, TTY_OVERRUN); tty 265 drivers/tty/serial/pic32_uart.c tty_insert_flip_char(tty, c, flag); tty 271 drivers/tty/serial/pic32_uart.c tty_flip_buffer_push(tty); tty 359 drivers/tty/serial/samsung.c struct tty_port *tty, int count) tty 371 drivers/tty/serial/samsung.c if (!tty) { tty 375 drivers/tty/serial/samsung.c copied = tty_insert_flip_string(tty, tty 451 drivers/tty/serial/samsung.c struct tty_struct *tty = tty_port_tty_get(&ourport->port.state->port); tty 466 drivers/tty/serial/samsung.c if (tty) { tty 468 drivers/tty/serial/samsung.c tty_kref_put(tty); tty 553 drivers/tty/serial/samsung.c struct tty_struct *tty = tty_port_tty_get(&ourport->port.state->port); tty 582 drivers/tty/serial/samsung.c if (tty) { tty 584 drivers/tty/serial/samsung.c tty_kref_put(tty); tty 1644 drivers/tty/serial/samsung.c struct tty_struct *tty; tty 1649 drivers/tty/serial/samsung.c tty = uport->state->port.tty; tty 1651 drivers/tty/serial/samsung.c if (tty == NULL) tty 1654 drivers/tty/serial/samsung.c termios = &tty->termios; tty 636 drivers/tty/serial/serial-tegra.c struct tty_port *tty) tty 654 drivers/tty/serial/serial-tegra.c if (!uart_handle_sysrq_char(&tup->uport, ch) && tty) tty 655 drivers/tty/serial/serial-tegra.c tty_insert_flip_char(tty, ch, flag); tty 663 drivers/tty/serial/serial-tegra.c struct tty_port *tty, tty 673 drivers/tty/serial/serial-tegra.c if (!tty) { tty 683 drivers/tty/serial/serial-tegra.c copied = tty_insert_flip_string(tty, tty 697 drivers/tty/serial/serial-tegra.c struct tty_struct *tty = tty_port_tty_get(port); tty 707 drivers/tty/serial/serial-tegra.c if (tty) { tty 709 drivers/tty/serial/serial-tegra.c tty_kref_put(tty); tty 807 drivers/tty/serial/serial-tegra.c struct tty_struct *tty = tty_port_tty_get(&tup->uport.state->port); tty 811 drivers/tty/serial/serial-tegra.c if (tty) { tty 813 drivers/tty/serial/serial-tegra.c tty_kref_put(tty); tty 43 drivers/tty/serial/serial_core.c static void uart_change_speed(struct tty_struct *tty, struct uart_state *state, tty 45 drivers/tty/serial/serial_core.c static void uart_wait_until_sent(struct tty_struct *tty, int timeout); tty 107 drivers/tty/serial/serial_core.c static void uart_stop(struct tty_struct *tty) tty 109 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 119 drivers/tty/serial/serial_core.c static void __uart_start(struct tty_struct *tty) tty 121 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 128 drivers/tty/serial/serial_core.c static void uart_start(struct tty_struct *tty) tty 130 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 135 drivers/tty/serial/serial_core.c __uart_start(tty); tty 181 drivers/tty/serial/serial_core.c static int uart_port_startup(struct tty_struct *tty, struct uart_state *state, tty 222 drivers/tty/serial/serial_core.c tty->termios.c_cflag = uport->cons->cflag; tty 228 drivers/tty/serial/serial_core.c uart_change_speed(tty, state, NULL); tty 234 drivers/tty/serial/serial_core.c if (init_hw && C_BAUD(tty)) tty 249 drivers/tty/serial/serial_core.c static int uart_startup(struct tty_struct *tty, struct uart_state *state, tty 258 drivers/tty/serial/serial_core.c retval = uart_port_startup(tty, state, init_hw); tty 260 drivers/tty/serial/serial_core.c set_bit(TTY_IO_ERROR, &tty->flags); tty 272 drivers/tty/serial/serial_core.c static void uart_shutdown(struct tty_struct *tty, struct uart_state *state) tty 282 drivers/tty/serial/serial_core.c if (tty) tty 283 drivers/tty/serial/serial_core.c set_bit(TTY_IO_ERROR, &tty->flags); tty 291 drivers/tty/serial/serial_core.c if (uport && uart_console(uport) && tty) tty 292 drivers/tty/serial/serial_core.c uport->cons->cflag = tty->termios.c_cflag; tty 294 drivers/tty/serial/serial_core.c if (!tty || C_HUPCL(tty)) tty 500 drivers/tty/serial/serial_core.c static void uart_change_speed(struct tty_struct *tty, struct uart_state *state, tty 511 drivers/tty/serial/serial_core.c if (!tty || uport->type == PORT_UNKNOWN) tty 514 drivers/tty/serial/serial_core.c termios = &tty->termios; tty 540 drivers/tty/serial/serial_core.c __uart_start(tty); tty 545 drivers/tty/serial/serial_core.c static int uart_put_char(struct tty_struct *tty, unsigned char c) tty 547 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 569 drivers/tty/serial/serial_core.c static void uart_flush_chars(struct tty_struct *tty) tty 571 drivers/tty/serial/serial_core.c uart_start(tty); tty 574 drivers/tty/serial/serial_core.c static int uart_write(struct tty_struct *tty, tty 577 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 612 drivers/tty/serial/serial_core.c __uart_start(tty); tty 617 drivers/tty/serial/serial_core.c static int uart_write_room(struct tty_struct *tty) tty 619 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 630 drivers/tty/serial/serial_core.c static int uart_chars_in_buffer(struct tty_struct *tty) tty 632 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 643 drivers/tty/serial/serial_core.c static void uart_flush_buffer(struct tty_struct *tty) tty 645 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 658 drivers/tty/serial/serial_core.c pr_debug("uart_flush_buffer(%d) called\n", tty->index); tty 674 drivers/tty/serial/serial_core.c static void uart_send_xchar(struct tty_struct *tty, char ch) tty 676 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 696 drivers/tty/serial/serial_core.c static void uart_throttle(struct tty_struct *tty) tty 698 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 706 drivers/tty/serial/serial_core.c if (I_IXOFF(tty)) tty 708 drivers/tty/serial/serial_core.c if (C_CRTSCTS(tty)) tty 720 drivers/tty/serial/serial_core.c uart_send_xchar(tty, STOP_CHAR(tty)); tty 725 drivers/tty/serial/serial_core.c static void uart_unthrottle(struct tty_struct *tty) tty 727 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 735 drivers/tty/serial/serial_core.c if (I_IXOFF(tty)) tty 737 drivers/tty/serial/serial_core.c if (C_CRTSCTS(tty)) tty 749 drivers/tty/serial/serial_core.c uart_send_xchar(tty, START_CHAR(tty)); tty 796 drivers/tty/serial/serial_core.c static int uart_get_info_user(struct tty_struct *tty, tty 799 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 805 drivers/tty/serial/serial_core.c static int uart_set_info(struct tty_struct *tty, struct tty_port *port, tty 896 drivers/tty/serial/serial_core.c uart_shutdown(tty, state); tty 993 drivers/tty/serial/serial_core.c tty_name(port->tty)); tty 995 drivers/tty/serial/serial_core.c uart_change_speed(tty, state, NULL); tty 998 drivers/tty/serial/serial_core.c retval = uart_startup(tty, state, 1); tty 1008 drivers/tty/serial/serial_core.c static int uart_set_info_user(struct tty_struct *tty, struct serial_struct *ss) tty 1010 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1014 drivers/tty/serial/serial_core.c down_write(&tty->termios_rwsem); tty 1023 drivers/tty/serial/serial_core.c retval = uart_set_info(tty, port, state, ss); tty 1025 drivers/tty/serial/serial_core.c up_write(&tty->termios_rwsem); tty 1035 drivers/tty/serial/serial_core.c static int uart_get_lsr_info(struct tty_struct *tty, tty 1057 drivers/tty/serial/serial_core.c static int uart_tiocmget(struct tty_struct *tty) tty 1059 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1069 drivers/tty/serial/serial_core.c if (!tty_io_error(tty)) { tty 1081 drivers/tty/serial/serial_core.c uart_tiocmset(struct tty_struct *tty, unsigned int set, unsigned int clear) tty 1083 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1093 drivers/tty/serial/serial_core.c if (!tty_io_error(tty)) { tty 1102 drivers/tty/serial/serial_core.c static int uart_break_ctl(struct tty_struct *tty, int break_state) tty 1104 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1122 drivers/tty/serial/serial_core.c static int uart_do_autoconfig(struct tty_struct *tty,struct uart_state *state) tty 1147 drivers/tty/serial/serial_core.c uart_shutdown(tty, state); tty 1166 drivers/tty/serial/serial_core.c ret = uart_startup(tty, state, 1); tty 1253 drivers/tty/serial/serial_core.c static int uart_get_icount(struct tty_struct *tty, tty 1256 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1380 drivers/tty/serial/serial_core.c uart_ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg) tty 1382 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1394 drivers/tty/serial/serial_core.c down_write(&tty->termios_rwsem); tty 1395 drivers/tty/serial/serial_core.c ret = uart_do_autoconfig(tty, state); tty 1396 drivers/tty/serial/serial_core.c up_write(&tty->termios_rwsem); tty 1403 drivers/tty/serial/serial_core.c if (tty_io_error(tty)) { tty 1423 drivers/tty/serial/serial_core.c if (!uport || tty_io_error(tty)) { tty 1435 drivers/tty/serial/serial_core.c ret = uart_get_lsr_info(tty, state, uarg); tty 1464 drivers/tty/serial/serial_core.c static void uart_set_ldisc(struct tty_struct *tty) tty 1466 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1472 drivers/tty/serial/serial_core.c uport->ops->set_ldisc(uport, &tty->termios); tty 1476 drivers/tty/serial/serial_core.c static void uart_set_termios(struct tty_struct *tty, tty 1479 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1481 drivers/tty/serial/serial_core.c unsigned int cflag = tty->termios.c_cflag; tty 1497 drivers/tty/serial/serial_core.c tty->termios.c_cc[VSTART] != old_termios->c_cc[VSTART] || tty 1498 drivers/tty/serial/serial_core.c tty->termios.c_cc[VSTOP] != old_termios->c_cc[VSTOP]; tty 1508 drivers/tty/serial/serial_core.c tty->termios.c_ospeed == old_termios->c_ospeed && tty 1509 drivers/tty/serial/serial_core.c tty->termios.c_ispeed == old_termios->c_ispeed && tty 1510 drivers/tty/serial/serial_core.c ((tty->termios.c_iflag ^ old_termios->c_iflag) & iflag_mask) == 0 && tty 1515 drivers/tty/serial/serial_core.c uart_change_speed(tty, state, old_termios); tty 1517 drivers/tty/serial/serial_core.c cflag = tty->termios.c_cflag; tty 1525 drivers/tty/serial/serial_core.c if (!(cflag & CRTSCTS) || !tty_throttled(tty)) tty 1538 drivers/tty/serial/serial_core.c static void uart_close(struct tty_struct *tty, struct file *filp) tty 1540 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1543 drivers/tty/serial/serial_core.c struct uart_driver *drv = tty->driver->driver_state; tty 1546 drivers/tty/serial/serial_core.c state = drv->state + tty->index; tty 1554 drivers/tty/serial/serial_core.c pr_debug("uart_close(%d) called\n", tty->index); tty 1556 drivers/tty/serial/serial_core.c tty_port_close(tty->port, tty, filp); tty 1588 drivers/tty/serial/serial_core.c static void uart_wait_until_sent(struct tty_struct *tty, int timeout) tty 1590 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1655 drivers/tty/serial/serial_core.c static void uart_hangup(struct tty_struct *tty) tty 1657 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1662 drivers/tty/serial/serial_core.c pr_debug("uart_hangup(%d)\n", tty->index); tty 1669 drivers/tty/serial/serial_core.c uart_flush_buffer(tty); tty 1670 drivers/tty/serial/serial_core.c uart_shutdown(tty, state); tty 1749 drivers/tty/serial/serial_core.c static int uart_install(struct tty_driver *driver, struct tty_struct *tty) tty 1752 drivers/tty/serial/serial_core.c struct uart_state *state = drv->state + tty->index; tty 1754 drivers/tty/serial/serial_core.c tty->driver_data = state; tty 1756 drivers/tty/serial/serial_core.c return tty_standard_install(driver, tty); tty 1769 drivers/tty/serial/serial_core.c static int uart_open(struct tty_struct *tty, struct file *filp) tty 1771 drivers/tty/serial/serial_core.c struct uart_state *state = tty->driver_data; tty 1774 drivers/tty/serial/serial_core.c retval = tty_port_open(&state->port, tty, filp); tty 1781 drivers/tty/serial/serial_core.c static int uart_port_activate(struct tty_port *port, struct tty_struct *tty) tty 1796 drivers/tty/serial/serial_core.c ret = uart_startup(tty, state, 0); tty 2246 drivers/tty/serial/serial_core.c if (port->tty && termios.c_cflag == 0) tty 2247 drivers/tty/serial/serial_core.c termios = port->tty->termios; tty 2266 drivers/tty/serial/serial_core.c struct tty_struct *tty = port->tty; tty 2269 drivers/tty/serial/serial_core.c if (tty) tty 2270 drivers/tty/serial/serial_core.c uart_change_speed(tty, state, NULL); tty 2282 drivers/tty/serial/serial_core.c uart_shutdown(tty, state); tty 2895 drivers/tty/serial/serial_core.c struct tty_struct *tty; tty 2925 drivers/tty/serial/serial_core.c tty = tty_port_tty_get(port); tty 2926 drivers/tty/serial/serial_core.c if (tty) { tty 2927 drivers/tty/serial/serial_core.c tty_vhangup(port->tty); tty 2928 drivers/tty/serial/serial_core.c tty_kref_put(tty); tty 2997 drivers/tty/serial/serial_core.c struct tty_struct *tty = port->tty; tty 3002 drivers/tty/serial/serial_core.c if (tty) { tty 3003 drivers/tty/serial/serial_core.c ld = tty_ldisc_ref(tty); tty 3006 drivers/tty/serial/serial_core.c ld->ops->dcd_change(tty, status); tty 3016 drivers/tty/serial/serial_core.c else if (tty) tty 3017 drivers/tty/serial/serial_core.c tty_hangup(tty); tty 399 drivers/tty/serial/sirfsoc_uart.c struct tty_struct *tty; tty 400 drivers/tty/serial/sirfsoc_uart.c tty = tty_port_tty_get(&port->state->port); tty 401 drivers/tty/serial/sirfsoc_uart.c if (!tty) tty 1174 drivers/tty/serial/sirfsoc_uart.c struct tty_struct *tty; tty 1183 drivers/tty/serial/sirfsoc_uart.c tty = port->state->port.tty; tty 1199 drivers/tty/serial/sirfsoc_uart.c inserted = tty_insert_flip_string(tty->port, tty 1208 drivers/tty/serial/sirfsoc_uart.c tty_flip_buffer_push(tty->port); tty 395 drivers/tty/serial/sprd_serial.c struct tty_port *tty = &port->state->port; tty 398 drivers/tty/serial/sprd_serial.c tty_insert_flip_string(tty, sp->rx_buf_tail, sp->rx_dma.trans_len); tty 399 drivers/tty/serial/sprd_serial.c tty_flip_buffer_push(tty); tty 603 drivers/tty/serial/sprd_serial.c struct tty_port *tty = &port->state->port; tty 628 drivers/tty/serial/sprd_serial.c tty_flip_buffer_push(tty); tty 309 drivers/tty/serial/st-asc.c pm_wakeup_event(tport->tty->dev, 0); tty 225 drivers/tty/serial/stm32-usart.c pm_wakeup_event(tport->tty->dev, 0); tty 821 drivers/tty/synclink.c static int tiocmget(struct tty_struct *tty); tty 822 drivers/tty/synclink.c static int tiocmset(struct tty_struct *tty, tty 909 drivers/tty/synclink.c static void mgsl_wait_until_sent(struct tty_struct *tty, int timeout); tty 955 drivers/tty/synclink.c static void ldisc_receive_buf(struct tty_struct *tty, tty 959 drivers/tty/synclink.c if (!tty) tty 961 drivers/tty/synclink.c ld = tty_ldisc_ref(tty); tty 964 drivers/tty/synclink.c ld->ops->receive_buf(tty, data, flags, count); tty 974 drivers/tty/synclink.c static void mgsl_stop(struct tty_struct *tty) tty 976 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 979 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_stop")) tty 997 drivers/tty/synclink.c static void mgsl_start(struct tty_struct *tty) tty 999 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 1002 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_start")) tty 1119 drivers/tty/synclink.c struct tty_struct *tty = info->port.tty; tty 1126 drivers/tty/synclink.c if (tty) tty 1127 drivers/tty/synclink.c tty_wakeup(tty); tty 1261 drivers/tty/synclink.c if (info->port.tty->stopped || info->port.tty->hw_stopped) { tty 1352 drivers/tty/synclink.c if (info->port.tty) tty 1353 drivers/tty/synclink.c tty_hangup(info->port.tty); tty 1359 drivers/tty/synclink.c if (info->port.tty->hw_stopped) { tty 1363 drivers/tty/synclink.c info->port.tty->hw_stopped = 0; tty 1372 drivers/tty/synclink.c if (info->port.tty) tty 1373 drivers/tty/synclink.c info->port.tty->hw_stopped = 1; tty 1407 drivers/tty/synclink.c if (info->port.tty->stopped || info->port.tty->hw_stopped) { tty 1498 drivers/tty/synclink.c do_SAK(info->port.tty); tty 1781 drivers/tty/synclink.c if (capable(CAP_SYS_ADMIN) && info->port.tty) tty 1782 drivers/tty/synclink.c set_bit(TTY_IO_ERROR, &info->port.tty->flags); tty 1790 drivers/tty/synclink.c if (info->port.tty) tty 1791 drivers/tty/synclink.c clear_bit(TTY_IO_ERROR, &info->port.tty->flags); tty 1846 drivers/tty/synclink.c if (!info->port.tty || info->port.tty->termios.c_cflag & HUPCL) { tty 1855 drivers/tty/synclink.c if (info->port.tty) tty 1856 drivers/tty/synclink.c set_bit(TTY_IO_ERROR, &info->port.tty->flags); tty 1889 drivers/tty/synclink.c if (info->netcount || info->port.tty->termios.c_cflag & CREAD) tty 1902 drivers/tty/synclink.c if (!info->port.tty) tty 1909 drivers/tty/synclink.c cflag = info->port.tty->termios.c_cflag; tty 1957 drivers/tty/synclink.c info->params.data_rate = tty_get_baud_rate(info->port.tty); tty 1971 drivers/tty/synclink.c if (I_INPCK(info->port.tty)) tty 1973 drivers/tty/synclink.c if (I_BRKINT(info->port.tty) || I_PARMRK(info->port.tty)) tty 1976 drivers/tty/synclink.c if (I_IGNPAR(info->port.tty)) tty 1978 drivers/tty/synclink.c if (I_IGNBRK(info->port.tty)) { tty 1983 drivers/tty/synclink.c if (I_IGNPAR(info->port.tty)) tty 2000 drivers/tty/synclink.c static int mgsl_put_char(struct tty_struct *tty, unsigned char ch) tty 2002 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2011 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_put_char")) tty 2040 drivers/tty/synclink.c static void mgsl_flush_chars(struct tty_struct *tty) tty 2042 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2049 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_flush_chars")) tty 2052 drivers/tty/synclink.c if (info->xmit_cnt <= 0 || tty->stopped || tty->hw_stopped || tty 2090 drivers/tty/synclink.c static int mgsl_write(struct tty_struct * tty, tty 2094 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2101 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_write")) tty 2192 drivers/tty/synclink.c if (info->xmit_cnt && !tty->stopped && !tty->hw_stopped) { tty 2214 drivers/tty/synclink.c static int mgsl_write_room(struct tty_struct *tty) tty 2216 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2219 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_write_room")) tty 2249 drivers/tty/synclink.c static int mgsl_chars_in_buffer(struct tty_struct *tty) tty 2251 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2257 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_chars_in_buffer")) tty 2283 drivers/tty/synclink.c static void mgsl_flush_buffer(struct tty_struct *tty) tty 2285 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2292 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_flush_buffer")) tty 2300 drivers/tty/synclink.c tty_wakeup(tty); tty 2311 drivers/tty/synclink.c static void mgsl_send_xchar(struct tty_struct *tty, char ch) tty 2313 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2320 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_send_xchar")) tty 2340 drivers/tty/synclink.c static void mgsl_throttle(struct tty_struct * tty) tty 2342 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2349 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_throttle")) tty 2352 drivers/tty/synclink.c if (I_IXOFF(tty)) tty 2353 drivers/tty/synclink.c mgsl_send_xchar(tty, STOP_CHAR(tty)); tty 2355 drivers/tty/synclink.c if (C_CRTSCTS(tty)) { tty 2370 drivers/tty/synclink.c static void mgsl_unthrottle(struct tty_struct * tty) tty 2372 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2379 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_unthrottle")) tty 2382 drivers/tty/synclink.c if (I_IXOFF(tty)) { tty 2386 drivers/tty/synclink.c mgsl_send_xchar(tty, START_CHAR(tty)); tty 2389 drivers/tty/synclink.c if (C_CRTSCTS(tty)) { tty 2829 drivers/tty/synclink.c static int tiocmget(struct tty_struct *tty) tty 2831 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2854 drivers/tty/synclink.c static int tiocmset(struct tty_struct *tty, tty 2857 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 2886 drivers/tty/synclink.c static int mgsl_break(struct tty_struct *tty, int break_state) tty 2888 drivers/tty/synclink.c struct mgsl_struct * info = tty->driver_data; tty 2895 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_break")) tty 2914 drivers/tty/synclink.c static int msgl_get_icount(struct tty_struct *tty, tty 2918 drivers/tty/synclink.c struct mgsl_struct * info = tty->driver_data; tty 2950 drivers/tty/synclink.c static int mgsl_ioctl(struct tty_struct *tty, tty 2953 drivers/tty/synclink.c struct mgsl_struct * info = tty->driver_data; tty 2959 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_ioctl")) tty 2963 drivers/tty/synclink.c if (tty_io_error(tty)) tty 3018 drivers/tty/synclink.c static void mgsl_set_termios(struct tty_struct *tty, struct ktermios *old_termios) tty 3020 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 3025 drivers/tty/synclink.c tty->driver->name ); tty 3030 drivers/tty/synclink.c if ((old_termios->c_cflag & CBAUD) && !C_BAUD(tty)) { tty 3038 drivers/tty/synclink.c if (!(old_termios->c_cflag & CBAUD) && C_BAUD(tty)) { tty 3040 drivers/tty/synclink.c if (!C_CRTSCTS(tty) || !tty_throttled(tty)) tty 3048 drivers/tty/synclink.c if (old_termios->c_cflag & CRTSCTS && !C_CRTSCTS(tty)) { tty 3049 drivers/tty/synclink.c tty->hw_stopped = 0; tty 3050 drivers/tty/synclink.c mgsl_start(tty); tty 3067 drivers/tty/synclink.c static void mgsl_close(struct tty_struct *tty, struct file * filp) tty 3069 drivers/tty/synclink.c struct mgsl_struct * info = tty->driver_data; tty 3071 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_close")) tty 3078 drivers/tty/synclink.c if (tty_port_close_start(&info->port, tty, filp) == 0) tty 3083 drivers/tty/synclink.c mgsl_wait_until_sent(tty, info->timeout); tty 3084 drivers/tty/synclink.c mgsl_flush_buffer(tty); tty 3085 drivers/tty/synclink.c tty_ldisc_flush(tty); tty 3089 drivers/tty/synclink.c tty_port_close_end(&info->port, tty); tty 3090 drivers/tty/synclink.c info->port.tty = NULL; tty 3094 drivers/tty/synclink.c tty->driver->name, info->port.count); tty 3109 drivers/tty/synclink.c static void mgsl_wait_until_sent(struct tty_struct *tty, int timeout) tty 3111 drivers/tty/synclink.c struct mgsl_struct * info = tty->driver_data; tty 3121 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_wait_until_sent")) tty 3180 drivers/tty/synclink.c static void mgsl_hangup(struct tty_struct *tty) tty 3182 drivers/tty/synclink.c struct mgsl_struct * info = tty->driver_data; tty 3188 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_hangup")) tty 3191 drivers/tty/synclink.c mgsl_flush_buffer(tty); tty 3196 drivers/tty/synclink.c info->port.tty = NULL; tty 3247 drivers/tty/synclink.c static int block_til_ready(struct tty_struct *tty, struct file * filp, tty 3259 drivers/tty/synclink.c __FILE__,__LINE__, tty->driver->name ); tty 3261 drivers/tty/synclink.c if (filp->f_flags & O_NONBLOCK || tty_io_error(tty)) { tty 3267 drivers/tty/synclink.c if (C_CLOCAL(tty)) tty 3282 drivers/tty/synclink.c __FILE__,__LINE__, tty->driver->name, port->count ); tty 3290 drivers/tty/synclink.c if (C_BAUD(tty) && tty_port_initialized(port)) tty 3312 drivers/tty/synclink.c __FILE__,__LINE__, tty->driver->name, port->count ); tty 3314 drivers/tty/synclink.c tty_unlock(tty); tty 3316 drivers/tty/synclink.c tty_lock(tty); tty 3329 drivers/tty/synclink.c __FILE__,__LINE__, tty->driver->name, port->count ); tty 3338 drivers/tty/synclink.c static int mgsl_install(struct tty_driver *driver, struct tty_struct *tty) tty 3341 drivers/tty/synclink.c int line = tty->index; tty 3354 drivers/tty/synclink.c if (mgsl_paranoia_check(info, tty->name, "mgsl_open")) tty 3356 drivers/tty/synclink.c tty->driver_data = info; tty 3358 drivers/tty/synclink.c return tty_port_install(&info->port, driver, tty); tty 3371 drivers/tty/synclink.c static int mgsl_open(struct tty_struct *tty, struct file * filp) tty 3373 drivers/tty/synclink.c struct mgsl_struct *info = tty->driver_data; tty 3377 drivers/tty/synclink.c info->port.tty = tty; tty 3381 drivers/tty/synclink.c __FILE__,__LINE__,tty->driver->name, info->port.count); tty 3401 drivers/tty/synclink.c retval = block_til_ready(tty, filp, info); tty 3416 drivers/tty/synclink.c if (tty->count == 1) tty 3417 drivers/tty/synclink.c info->port.tty = NULL; /* tty layer will release tty struct */ tty 6435 drivers/tty/synclink.c struct tty_struct *tty = info->port.tty; tty 6578 drivers/tty/synclink.c ldisc_receive_buf(tty, info->intermediate_rxbuffer, info->flag_buf, framesize); tty 6633 drivers/tty/synclink.c struct tty_struct *tty = info->port.tty; tty 6750 drivers/tty/synclink.c ldisc_receive_buf(tty, info->intermediate_rxbuffer, info->flag_buf, framesize); tty 140 drivers/tty/synclink_gt.c static int open(struct tty_struct *tty, struct file * filp); tty 141 drivers/tty/synclink_gt.c static void close(struct tty_struct *tty, struct file * filp); tty 142 drivers/tty/synclink_gt.c static void hangup(struct tty_struct *tty); tty 143 drivers/tty/synclink_gt.c static void set_termios(struct tty_struct *tty, struct ktermios *old_termios); tty 145 drivers/tty/synclink_gt.c static int write(struct tty_struct *tty, const unsigned char *buf, int count); tty 146 drivers/tty/synclink_gt.c static int put_char(struct tty_struct *tty, unsigned char ch); tty 147 drivers/tty/synclink_gt.c static void send_xchar(struct tty_struct *tty, char ch); tty 148 drivers/tty/synclink_gt.c static void wait_until_sent(struct tty_struct *tty, int timeout); tty 149 drivers/tty/synclink_gt.c static int write_room(struct tty_struct *tty); tty 150 drivers/tty/synclink_gt.c static void flush_chars(struct tty_struct *tty); tty 151 drivers/tty/synclink_gt.c static void flush_buffer(struct tty_struct *tty); tty 152 drivers/tty/synclink_gt.c static void tx_hold(struct tty_struct *tty); tty 153 drivers/tty/synclink_gt.c static void tx_release(struct tty_struct *tty); tty 155 drivers/tty/synclink_gt.c static int ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg); tty 156 drivers/tty/synclink_gt.c static int chars_in_buffer(struct tty_struct *tty); tty 157 drivers/tty/synclink_gt.c static void throttle(struct tty_struct * tty); tty 158 drivers/tty/synclink_gt.c static void unthrottle(struct tty_struct * tty); tty 159 drivers/tty/synclink_gt.c static int set_break(struct tty_struct *tty, int break_state); tty 441 drivers/tty/synclink_gt.c static int block_til_ready(struct tty_struct *tty, struct file * filp,struct slgt_info *info); tty 512 drivers/tty/synclink_gt.c static int tiocmget(struct tty_struct *tty); tty 513 drivers/tty/synclink_gt.c static int tiocmset(struct tty_struct *tty, tty 515 drivers/tty/synclink_gt.c static int set_break(struct tty_struct *tty, int break_state); tty 631 drivers/tty/synclink_gt.c static void ldisc_receive_buf(struct tty_struct *tty, tty 635 drivers/tty/synclink_gt.c if (!tty) tty 637 drivers/tty/synclink_gt.c ld = tty_ldisc_ref(tty); tty 640 drivers/tty/synclink_gt.c ld->ops->receive_buf(tty, data, flags, count); tty 647 drivers/tty/synclink_gt.c static int open(struct tty_struct *tty, struct file *filp) tty 653 drivers/tty/synclink_gt.c line = tty->index; tty 662 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "open")) tty 669 drivers/tty/synclink_gt.c tty->driver_data = info; tty 670 drivers/tty/synclink_gt.c info->port.tty = tty; tty 696 drivers/tty/synclink_gt.c retval = block_til_ready(tty, filp, info); tty 706 drivers/tty/synclink_gt.c if (tty->count == 1) tty 707 drivers/tty/synclink_gt.c info->port.tty = NULL; /* tty layer will release tty struct */ tty 716 drivers/tty/synclink_gt.c static void close(struct tty_struct *tty, struct file *filp) tty 718 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 720 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "close")) tty 724 drivers/tty/synclink_gt.c if (tty_port_close_start(&info->port, tty, filp) == 0) tty 729 drivers/tty/synclink_gt.c wait_until_sent(tty, info->timeout); tty 730 drivers/tty/synclink_gt.c flush_buffer(tty); tty 731 drivers/tty/synclink_gt.c tty_ldisc_flush(tty); tty 736 drivers/tty/synclink_gt.c tty_port_close_end(&info->port, tty); tty 737 drivers/tty/synclink_gt.c info->port.tty = NULL; tty 739 drivers/tty/synclink_gt.c DBGINFO(("%s close exit, count=%d\n", tty->driver->name, info->port.count)); tty 742 drivers/tty/synclink_gt.c static void hangup(struct tty_struct *tty) tty 744 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 747 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "hangup")) tty 751 drivers/tty/synclink_gt.c flush_buffer(tty); tty 758 drivers/tty/synclink_gt.c info->port.tty = NULL; tty 766 drivers/tty/synclink_gt.c static void set_termios(struct tty_struct *tty, struct ktermios *old_termios) tty 768 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 771 drivers/tty/synclink_gt.c DBGINFO(("%s set_termios\n", tty->driver->name)); tty 776 drivers/tty/synclink_gt.c if ((old_termios->c_cflag & CBAUD) && !C_BAUD(tty)) { tty 784 drivers/tty/synclink_gt.c if (!(old_termios->c_cflag & CBAUD) && C_BAUD(tty)) { tty 786 drivers/tty/synclink_gt.c if (!C_CRTSCTS(tty) || !tty_throttled(tty)) tty 794 drivers/tty/synclink_gt.c if ((old_termios->c_cflag & CRTSCTS) && !C_CRTSCTS(tty)) { tty 795 drivers/tty/synclink_gt.c tty->hw_stopped = 0; tty 796 drivers/tty/synclink_gt.c tx_release(tty); tty 812 drivers/tty/synclink_gt.c static int write(struct tty_struct *tty, tty 816 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 819 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "write")) tty 827 drivers/tty/synclink_gt.c if (!count || tty->stopped || tty->hw_stopped) tty 848 drivers/tty/synclink_gt.c static int put_char(struct tty_struct *tty, unsigned char ch) tty 850 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 854 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "put_char")) tty 868 drivers/tty/synclink_gt.c static void send_xchar(struct tty_struct *tty, char ch) tty 870 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 873 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "send_xchar")) tty 885 drivers/tty/synclink_gt.c static void wait_until_sent(struct tty_struct *tty, int timeout) tty 887 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 892 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "wait_until_sent")) tty 927 drivers/tty/synclink_gt.c static int write_room(struct tty_struct *tty) tty 929 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 932 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "write_room")) tty 939 drivers/tty/synclink_gt.c static void flush_chars(struct tty_struct *tty) tty 941 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 944 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "flush_chars")) tty 948 drivers/tty/synclink_gt.c if (info->tx_count <= 0 || tty->stopped || tty 949 drivers/tty/synclink_gt.c tty->hw_stopped || !info->tx_buf) tty 960 drivers/tty/synclink_gt.c static void flush_buffer(struct tty_struct *tty) tty 962 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 965 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "flush_buffer")) tty 973 drivers/tty/synclink_gt.c tty_wakeup(tty); tty 979 drivers/tty/synclink_gt.c static void tx_hold(struct tty_struct *tty) tty 981 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 984 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "tx_hold")) tty 996 drivers/tty/synclink_gt.c static void tx_release(struct tty_struct *tty) tty 998 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 1001 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "tx_release")) tty 1021 drivers/tty/synclink_gt.c static int ioctl(struct tty_struct *tty, tty 1024 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 1028 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "ioctl")) tty 1033 drivers/tty/synclink_gt.c if (tty_io_error(tty)) tty 1096 drivers/tty/synclink_gt.c static int get_icount(struct tty_struct *tty, tty 1100 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 1184 drivers/tty/synclink_gt.c static long slgt_compat_ioctl(struct tty_struct *tty, tty 1187 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 1190 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "compat_ioctl")) tty 1214 drivers/tty/synclink_gt.c rc = ioctl(tty, cmd, (unsigned long)compat_ptr(arg)); tty 1217 drivers/tty/synclink_gt.c rc = ioctl(tty, cmd, arg); tty 1313 drivers/tty/synclink_gt.c static int chars_in_buffer(struct tty_struct *tty) tty 1315 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 1317 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "chars_in_buffer")) tty 1327 drivers/tty/synclink_gt.c static void throttle(struct tty_struct * tty) tty 1329 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 1332 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "throttle")) tty 1335 drivers/tty/synclink_gt.c if (I_IXOFF(tty)) tty 1336 drivers/tty/synclink_gt.c send_xchar(tty, STOP_CHAR(tty)); tty 1337 drivers/tty/synclink_gt.c if (C_CRTSCTS(tty)) { tty 1348 drivers/tty/synclink_gt.c static void unthrottle(struct tty_struct * tty) tty 1350 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 1353 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "unthrottle")) tty 1356 drivers/tty/synclink_gt.c if (I_IXOFF(tty)) { tty 1360 drivers/tty/synclink_gt.c send_xchar(tty, START_CHAR(tty)); tty 1362 drivers/tty/synclink_gt.c if (C_CRTSCTS(tty)) { tty 1374 drivers/tty/synclink_gt.c static int set_break(struct tty_struct *tty, int break_state) tty 1376 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 1380 drivers/tty/synclink_gt.c if (sanity_check(info, tty->name, "set_break")) tty 1970 drivers/tty/synclink_gt.c struct tty_struct *tty = info->port.tty; tty 1973 drivers/tty/synclink_gt.c if (tty) tty 1974 drivers/tty/synclink_gt.c tty_wakeup(tty); tty 2017 drivers/tty/synclink_gt.c if (info->port.tty) { tty 2018 drivers/tty/synclink_gt.c if (info->port.tty->hw_stopped) { tty 2020 drivers/tty/synclink_gt.c info->port.tty->hw_stopped = 0; tty 2026 drivers/tty/synclink_gt.c info->port.tty->hw_stopped = 1; tty 2063 drivers/tty/synclink_gt.c if (info->port.tty) tty 2064 drivers/tty/synclink_gt.c tty_hangup(info->port.tty); tty 2143 drivers/tty/synclink_gt.c if (info->port.tty) { tty 2148 drivers/tty/synclink_gt.c do_SAK(info->port.tty); tty 2302 drivers/tty/synclink_gt.c if (info->port.tty && (info->port.tty->stopped || info->port.tty->hw_stopped)) { tty 2418 drivers/tty/synclink_gt.c if (info->port.tty) tty 2419 drivers/tty/synclink_gt.c clear_bit(TTY_IO_ERROR, &info->port.tty->flags); tty 2456 drivers/tty/synclink_gt.c if (!info->port.tty || info->port.tty->termios.c_cflag & HUPCL) { tty 2465 drivers/tty/synclink_gt.c if (info->port.tty) tty 2466 drivers/tty/synclink_gt.c set_bit(TTY_IO_ERROR, &info->port.tty->flags); tty 2497 drivers/tty/synclink_gt.c (info->port.tty && info->port.tty->termios.c_cflag & CREAD)) tty 2511 drivers/tty/synclink_gt.c if (!info->port.tty) tty 2515 drivers/tty/synclink_gt.c cflag = info->port.tty->termios.c_cflag; tty 2547 drivers/tty/synclink_gt.c info->params.data_rate = tty_get_baud_rate(info->port.tty); tty 2561 drivers/tty/synclink_gt.c if (I_INPCK(info->port.tty)) tty 2563 drivers/tty/synclink_gt.c if (I_BRKINT(info->port.tty) || I_PARMRK(info->port.tty)) tty 2565 drivers/tty/synclink_gt.c if (I_IGNPAR(info->port.tty)) tty 2567 drivers/tty/synclink_gt.c if (I_IGNBRK(info->port.tty)) { tty 2572 drivers/tty/synclink_gt.c if (I_IGNPAR(info->port.tty)) tty 3149 drivers/tty/synclink_gt.c static int tiocmget(struct tty_struct *tty) tty 3151 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 3177 drivers/tty/synclink_gt.c static int tiocmset(struct tty_struct *tty, tty 3180 drivers/tty/synclink_gt.c struct slgt_info *info = tty->driver_data; tty 3229 drivers/tty/synclink_gt.c static int block_til_ready(struct tty_struct *tty, struct file *filp, tty 3239 drivers/tty/synclink_gt.c DBGINFO(("%s block_til_ready\n", tty->driver->name)); tty 3241 drivers/tty/synclink_gt.c if (filp->f_flags & O_NONBLOCK || tty_io_error(tty)) { tty 3247 drivers/tty/synclink_gt.c if (C_CLOCAL(tty)) tty 3266 drivers/tty/synclink_gt.c if (C_BAUD(tty) && tty_port_initialized(port)) tty 3286 drivers/tty/synclink_gt.c DBGINFO(("%s block_til_ready wait\n", tty->driver->name)); tty 3287 drivers/tty/synclink_gt.c tty_unlock(tty); tty 3289 drivers/tty/synclink_gt.c tty_lock(tty); tty 3302 drivers/tty/synclink_gt.c DBGINFO(("%s block_til_ready ready, rc=%d\n", tty->driver->name, retval)); tty 4615 drivers/tty/synclink_gt.c struct tty_struct *tty = info->port.tty; tty 4732 drivers/tty/synclink_gt.c ldisc_receive_buf(tty, info->tmp_rbuf, info->flag_buf, framesize); tty 4766 drivers/tty/synclink_gt.c ldisc_receive_buf(info->port.tty, info->rbufs[i].buf, tty 4953 drivers/tty/synclink_gt.c struct tty_struct *oldtty = info->port.tty; tty 4957 drivers/tty/synclink_gt.c info->port.tty = NULL; tty 4985 drivers/tty/synclink_gt.c info->port.tty = oldtty; tty 5025 drivers/tty/synclink_gt.c struct tty_struct *oldtty = info->port.tty; tty 5033 drivers/tty/synclink_gt.c info->port.tty = NULL; tty 5069 drivers/tty/synclink_gt.c info->port.tty = oldtty; tty 506 drivers/tty/synclinkmp.c static int open(struct tty_struct *tty, struct file * filp); tty 507 drivers/tty/synclinkmp.c static void close(struct tty_struct *tty, struct file * filp); tty 508 drivers/tty/synclinkmp.c static void hangup(struct tty_struct *tty); tty 509 drivers/tty/synclinkmp.c static void set_termios(struct tty_struct *tty, struct ktermios *old_termios); tty 511 drivers/tty/synclinkmp.c static int write(struct tty_struct *tty, const unsigned char *buf, int count); tty 512 drivers/tty/synclinkmp.c static int put_char(struct tty_struct *tty, unsigned char ch); tty 513 drivers/tty/synclinkmp.c static void send_xchar(struct tty_struct *tty, char ch); tty 514 drivers/tty/synclinkmp.c static void wait_until_sent(struct tty_struct *tty, int timeout); tty 515 drivers/tty/synclinkmp.c static int write_room(struct tty_struct *tty); tty 516 drivers/tty/synclinkmp.c static void flush_chars(struct tty_struct *tty); tty 517 drivers/tty/synclinkmp.c static void flush_buffer(struct tty_struct *tty); tty 518 drivers/tty/synclinkmp.c static void tx_hold(struct tty_struct *tty); tty 519 drivers/tty/synclinkmp.c static void tx_release(struct tty_struct *tty); tty 521 drivers/tty/synclinkmp.c static int ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg); tty 522 drivers/tty/synclinkmp.c static int chars_in_buffer(struct tty_struct *tty); tty 523 drivers/tty/synclinkmp.c static void throttle(struct tty_struct * tty); tty 524 drivers/tty/synclinkmp.c static void unthrottle(struct tty_struct * tty); tty 525 drivers/tty/synclinkmp.c static int set_break(struct tty_struct *tty, int break_state); tty 547 drivers/tty/synclinkmp.c static int tiocmget(struct tty_struct *tty); tty 548 drivers/tty/synclinkmp.c static int tiocmset(struct tty_struct *tty, tty 550 drivers/tty/synclinkmp.c static int set_break(struct tty_struct *tty, int break_state); tty 558 drivers/tty/synclinkmp.c static int block_til_ready(struct tty_struct *tty, struct file * filp,SLMP_INFO *info); tty 697 drivers/tty/synclinkmp.c static void ldisc_receive_buf(struct tty_struct *tty, tty 701 drivers/tty/synclinkmp.c if (!tty) tty 703 drivers/tty/synclinkmp.c ld = tty_ldisc_ref(tty); tty 706 drivers/tty/synclinkmp.c ld->ops->receive_buf(tty, data, flags, count); tty 713 drivers/tty/synclinkmp.c static int install(struct tty_driver *driver, struct tty_struct *tty) tty 716 drivers/tty/synclinkmp.c int line = tty->index; tty 727 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "open")) tty 736 drivers/tty/synclinkmp.c tty->driver_data = info; tty 738 drivers/tty/synclinkmp.c return tty_port_install(&info->port, driver, tty); tty 743 drivers/tty/synclinkmp.c static int open(struct tty_struct *tty, struct file *filp) tty 745 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 749 drivers/tty/synclinkmp.c info->port.tty = tty; tty 753 drivers/tty/synclinkmp.c __FILE__,__LINE__,tty->driver->name, info->port.count); tty 773 drivers/tty/synclinkmp.c retval = block_til_ready(tty, filp, info); tty 788 drivers/tty/synclinkmp.c if (tty->count == 1) tty 789 drivers/tty/synclinkmp.c info->port.tty = NULL; /* tty layer will release tty struct */ tty 800 drivers/tty/synclinkmp.c static void close(struct tty_struct *tty, struct file *filp) tty 802 drivers/tty/synclinkmp.c SLMP_INFO * info = tty->driver_data; tty 804 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "close")) tty 811 drivers/tty/synclinkmp.c if (tty_port_close_start(&info->port, tty, filp) == 0) tty 816 drivers/tty/synclinkmp.c wait_until_sent(tty, info->timeout); tty 818 drivers/tty/synclinkmp.c flush_buffer(tty); tty 819 drivers/tty/synclinkmp.c tty_ldisc_flush(tty); tty 823 drivers/tty/synclinkmp.c tty_port_close_end(&info->port, tty); tty 824 drivers/tty/synclinkmp.c info->port.tty = NULL; tty 828 drivers/tty/synclinkmp.c tty->driver->name, info->port.count); tty 834 drivers/tty/synclinkmp.c static void hangup(struct tty_struct *tty) tty 836 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 843 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "hangup")) tty 847 drivers/tty/synclinkmp.c flush_buffer(tty); tty 852 drivers/tty/synclinkmp.c info->port.tty = NULL; tty 862 drivers/tty/synclinkmp.c static void set_termios(struct tty_struct *tty, struct ktermios *old_termios) tty 864 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 869 drivers/tty/synclinkmp.c tty->driver->name ); tty 874 drivers/tty/synclinkmp.c if ((old_termios->c_cflag & CBAUD) && !C_BAUD(tty)) { tty 882 drivers/tty/synclinkmp.c if (!(old_termios->c_cflag & CBAUD) && C_BAUD(tty)) { tty 884 drivers/tty/synclinkmp.c if (!C_CRTSCTS(tty) || !tty_throttled(tty)) tty 892 drivers/tty/synclinkmp.c if (old_termios->c_cflag & CRTSCTS && !C_CRTSCTS(tty)) { tty 893 drivers/tty/synclinkmp.c tty->hw_stopped = 0; tty 894 drivers/tty/synclinkmp.c tx_release(tty); tty 908 drivers/tty/synclinkmp.c static int write(struct tty_struct *tty, tty 912 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 919 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "write")) tty 972 drivers/tty/synclinkmp.c if (info->tx_count && !tty->stopped && !tty->hw_stopped) { tty 988 drivers/tty/synclinkmp.c static int put_char(struct tty_struct *tty, unsigned char ch) tty 990 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 999 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "put_char")) tty 1025 drivers/tty/synclinkmp.c static void send_xchar(struct tty_struct *tty, char ch) tty 1027 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1034 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "send_xchar")) tty 1049 drivers/tty/synclinkmp.c static void wait_until_sent(struct tty_struct *tty, int timeout) tty 1051 drivers/tty/synclinkmp.c SLMP_INFO * info = tty->driver_data; tty 1061 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "wait_until_sent")) tty 1115 drivers/tty/synclinkmp.c static int write_room(struct tty_struct *tty) tty 1117 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1120 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "write_room")) tty 1140 drivers/tty/synclinkmp.c static void flush_chars(struct tty_struct *tty) tty 1142 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1149 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "flush_chars")) tty 1152 drivers/tty/synclinkmp.c if (info->tx_count <= 0 || tty->stopped || tty->hw_stopped || tty 1179 drivers/tty/synclinkmp.c static void flush_buffer(struct tty_struct *tty) tty 1181 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1188 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "flush_buffer")) tty 1196 drivers/tty/synclinkmp.c tty_wakeup(tty); tty 1201 drivers/tty/synclinkmp.c static void tx_hold(struct tty_struct *tty) tty 1203 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1206 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "tx_hold")) tty 1221 drivers/tty/synclinkmp.c static void tx_release(struct tty_struct *tty) tty 1223 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1226 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "tx_release")) tty 1249 drivers/tty/synclinkmp.c static int ioctl(struct tty_struct *tty, tty 1252 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1259 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "ioctl")) tty 1263 drivers/tty/synclinkmp.c if (tty_io_error(tty)) tty 1306 drivers/tty/synclinkmp.c static int get_icount(struct tty_struct *tty, tty 1309 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1425 drivers/tty/synclinkmp.c static int chars_in_buffer(struct tty_struct *tty) tty 1427 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1429 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "chars_in_buffer")) tty 1441 drivers/tty/synclinkmp.c static void throttle(struct tty_struct * tty) tty 1443 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1450 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "throttle")) tty 1453 drivers/tty/synclinkmp.c if (I_IXOFF(tty)) tty 1454 drivers/tty/synclinkmp.c send_xchar(tty, STOP_CHAR(tty)); tty 1456 drivers/tty/synclinkmp.c if (C_CRTSCTS(tty)) { tty 1466 drivers/tty/synclinkmp.c static void unthrottle(struct tty_struct * tty) tty 1468 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 1475 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "unthrottle")) tty 1478 drivers/tty/synclinkmp.c if (I_IXOFF(tty)) { tty 1482 drivers/tty/synclinkmp.c send_xchar(tty, START_CHAR(tty)); tty 1485 drivers/tty/synclinkmp.c if (C_CRTSCTS(tty)) { tty 1496 drivers/tty/synclinkmp.c static int set_break(struct tty_struct *tty, int break_state) tty 1499 drivers/tty/synclinkmp.c SLMP_INFO * info = tty->driver_data; tty 1506 drivers/tty/synclinkmp.c if (sanity_check(info, tty->name, "set_break")) tty 2033 drivers/tty/synclinkmp.c struct tty_struct *tty = info->port.tty; tty 2039 drivers/tty/synclinkmp.c if (tty) tty 2040 drivers/tty/synclinkmp.c tty_wakeup(tty); tty 2083 drivers/tty/synclinkmp.c struct tty_struct *tty = info->port.tty; tty 2109 drivers/tty/synclinkmp.c if (tty && (info->port.flags & ASYNC_SAK)) tty 2110 drivers/tty/synclinkmp.c do_SAK(tty); tty 2249 drivers/tty/synclinkmp.c if (info->port.tty && (info->port.tty->stopped || info->port.tty->hw_stopped)) { tty 2304 drivers/tty/synclinkmp.c if (info->port.tty && (info->port.tty->stopped || info->port.tty->hw_stopped)) { tty 2461 drivers/tty/synclinkmp.c if (info->port.tty) tty 2462 drivers/tty/synclinkmp.c tty_hangup(info->port.tty); tty 2468 drivers/tty/synclinkmp.c if ( info->port.tty ) { tty 2469 drivers/tty/synclinkmp.c if (info->port.tty->hw_stopped) { tty 2473 drivers/tty/synclinkmp.c info->port.tty->hw_stopped = 0; tty 2482 drivers/tty/synclinkmp.c info->port.tty->hw_stopped = 1; tty 2647 drivers/tty/synclinkmp.c if (info->port.tty) tty 2648 drivers/tty/synclinkmp.c clear_bit(TTY_IO_ERROR, &info->port.tty->flags); tty 2683 drivers/tty/synclinkmp.c if (!info->port.tty || info->port.tty->termios.c_cflag & HUPCL) { tty 2690 drivers/tty/synclinkmp.c if (info->port.tty) tty 2691 drivers/tty/synclinkmp.c set_bit(TTY_IO_ERROR, &info->port.tty->flags); tty 2724 drivers/tty/synclinkmp.c if (info->netcount || (info->port.tty && info->port.tty->termios.c_cflag & CREAD) ) tty 2737 drivers/tty/synclinkmp.c if (!info->port.tty) tty 2744 drivers/tty/synclinkmp.c cflag = info->port.tty->termios.c_cflag; tty 2792 drivers/tty/synclinkmp.c info->params.data_rate = tty_get_baud_rate(info->port.tty); tty 2807 drivers/tty/synclinkmp.c if (I_INPCK(info->port.tty)) tty 2809 drivers/tty/synclinkmp.c if (I_BRKINT(info->port.tty) || I_PARMRK(info->port.tty)) tty 2811 drivers/tty/synclinkmp.c if (I_IGNPAR(info->port.tty)) tty 2813 drivers/tty/synclinkmp.c if (I_IGNBRK(info->port.tty)) { tty 2818 drivers/tty/synclinkmp.c if (I_IGNPAR(info->port.tty)) tty 3173 drivers/tty/synclinkmp.c static int tiocmget(struct tty_struct *tty) tty 3175 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 3198 drivers/tty/synclinkmp.c static int tiocmset(struct tty_struct *tty, tty 3201 drivers/tty/synclinkmp.c SLMP_INFO *info = tty->driver_data; tty 3252 drivers/tty/synclinkmp.c static int block_til_ready(struct tty_struct *tty, struct file *filp, tty 3264 drivers/tty/synclinkmp.c __FILE__,__LINE__, tty->driver->name ); tty 3266 drivers/tty/synclinkmp.c if (filp->f_flags & O_NONBLOCK || tty_io_error(tty)) { tty 3273 drivers/tty/synclinkmp.c if (C_CLOCAL(tty)) tty 3288 drivers/tty/synclinkmp.c __FILE__,__LINE__, tty->driver->name, port->count ); tty 3296 drivers/tty/synclinkmp.c if (C_BAUD(tty) && tty_port_initialized(port)) tty 3318 drivers/tty/synclinkmp.c __FILE__,__LINE__, tty->driver->name, port->count ); tty 3320 drivers/tty/synclinkmp.c tty_unlock(tty); tty 3322 drivers/tty/synclinkmp.c tty_lock(tty); tty 3333 drivers/tty/synclinkmp.c __FILE__,__LINE__, tty->driver->name, port->count ); tty 4826 drivers/tty/synclinkmp.c struct tty_struct *tty = info->port.tty; tty 4967 drivers/tty/synclinkmp.c ldisc_receive_buf(tty,info->tmp_rx_buf, tty 5233 drivers/tty/synclinkmp.c struct tty_struct *oldtty = info->port.tty; tty 5237 drivers/tty/synclinkmp.c info->port.tty = NULL; tty 5281 drivers/tty/synclinkmp.c info->port.tty = oldtty; tty 136 drivers/tty/tty_audit.c void tty_audit_tiocsti(struct tty_struct *tty, char ch) tty 140 drivers/tty/tty_audit.c dev = MKDEV(tty->driver->major, tty->driver->minor_start) + tty->index; tty 201 drivers/tty/tty_audit.c void tty_audit_add_data(struct tty_struct *tty, const void *data, size_t size) tty 204 drivers/tty/tty_audit.c unsigned int icanon = !!L_ICANON(tty); tty 215 drivers/tty/tty_audit.c if (tty->driver->type == TTY_DRIVER_TYPE_PTY tty 216 drivers/tty/tty_audit.c && tty->driver->subtype == PTY_TYPE_MASTER) tty 219 drivers/tty/tty_audit.c if ((~audit_tty & AUDIT_TTY_LOG_PASSWD) && icanon && !L_ECHO(tty)) tty 227 drivers/tty/tty_audit.c dev = MKDEV(tty->driver->major, tty->driver->minor_start) + tty->index; tty 237 drivers/tty/tty_baudrate.c void tty_encode_baud_rate(struct tty_struct *tty, speed_t ibaud, speed_t obaud) tty 239 drivers/tty/tty_baudrate.c tty_termios_encode_baud_rate(&tty->termios, ibaud, obaud); tty 219 drivers/tty/tty_buffer.c void tty_buffer_flush(struct tty_struct *tty, struct tty_ldisc *ld) tty 221 drivers/tty/tty_buffer.c struct tty_port *port = tty->port; tty 238 drivers/tty/tty_buffer.c ld->ops->flush_buffer(tty); tty 461 drivers/tty/tty_buffer.c count = ld->ops->receive_buf2(ld->tty, p, f, count); tty 463 drivers/tty/tty_buffer.c count = min_t(int, count, ld->tty->receive_room); tty 465 drivers/tty/tty_buffer.c ld->ops->receive_buf(ld->tty, p, f, count); tty 113 drivers/tty/tty_io.c # define tty_debug_hangup(tty, f, args...) tty_debug(tty, f, ##args) tty 115 drivers/tty/tty_io.c # define tty_debug_hangup(tty, f, args...) do { } while (0) tty 159 drivers/tty/tty_io.c static void release_tty(struct tty_struct *tty, int idx); tty 170 drivers/tty/tty_io.c static void free_tty_struct(struct tty_struct *tty) tty 172 drivers/tty/tty_io.c tty_ldisc_deinit(tty); tty 173 drivers/tty/tty_io.c put_device(tty->dev); tty 174 drivers/tty/tty_io.c kfree(tty->write_buf); tty 175 drivers/tty/tty_io.c tty->magic = 0xDEADDEAD; tty 176 drivers/tty/tty_io.c kfree(tty); tty 181 drivers/tty/tty_io.c return ((struct tty_file_private *)file->private_data)->tty; tty 198 drivers/tty/tty_io.c void tty_add_file(struct tty_struct *tty, struct file *file) tty 202 drivers/tty/tty_io.c priv->tty = tty; tty 205 drivers/tty/tty_io.c spin_lock(&tty->files_lock); tty 206 drivers/tty/tty_io.c list_add(&priv->list, &tty->tty_files); tty 207 drivers/tty/tty_io.c spin_unlock(&tty->files_lock); tty 228 drivers/tty/tty_io.c struct tty_struct *tty = priv->tty; tty 230 drivers/tty/tty_io.c spin_lock(&tty->files_lock); tty 232 drivers/tty/tty_io.c spin_unlock(&tty->files_lock); tty 246 drivers/tty/tty_io.c const char *tty_name(const struct tty_struct *tty) tty 248 drivers/tty/tty_io.c if (!tty) /* Hmm. NULL pointer. That's fun. */ tty 250 drivers/tty/tty_io.c return tty->name; tty 255 drivers/tty/tty_io.c const char *tty_driver_name(const struct tty_struct *tty) tty 257 drivers/tty/tty_io.c if (!tty || !tty->driver) tty 259 drivers/tty/tty_io.c return tty->driver->name; tty 262 drivers/tty/tty_io.c static int tty_paranoia_check(struct tty_struct *tty, struct inode *inode, tty 266 drivers/tty/tty_io.c if (!tty) { tty 271 drivers/tty/tty_io.c if (tty->magic != TTY_MAGIC) { tty 281 drivers/tty/tty_io.c static int check_tty_count(struct tty_struct *tty, const char *routine) tty 287 drivers/tty/tty_io.c spin_lock(&tty->files_lock); tty 288 drivers/tty/tty_io.c list_for_each(p, &tty->tty_files) { tty 291 drivers/tty/tty_io.c spin_unlock(&tty->files_lock); tty 292 drivers/tty/tty_io.c if (tty->driver->type == TTY_DRIVER_TYPE_PTY && tty 293 drivers/tty/tty_io.c tty->driver->subtype == PTY_TYPE_SLAVE && tty 294 drivers/tty/tty_io.c tty->link && tty->link->count) tty 296 drivers/tty/tty_io.c if (tty_port_kopened(tty->port)) tty 298 drivers/tty/tty_io.c if (tty->count != (count + kopen_count)) { tty 299 drivers/tty/tty_io.c tty_warn(tty, "%s: tty->count(%d) != (#fd's(%d) + #kopen's(%d))\n", tty 300 drivers/tty/tty_io.c routine, tty->count, count, kopen_count); tty 471 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(file); tty 473 drivers/tty/tty_io.c if (tty && tty->ops && tty->ops->show_fdinfo) tty 474 drivers/tty/tty_io.c tty->ops->show_fdinfo(tty, m); tty 527 drivers/tty/tty_io.c void tty_wakeup(struct tty_struct *tty) tty 531 drivers/tty/tty_io.c if (test_bit(TTY_DO_WRITE_WAKEUP, &tty->flags)) { tty 532 drivers/tty/tty_io.c ld = tty_ldisc_ref(tty); tty 535 drivers/tty/tty_io.c ld->ops->write_wakeup(tty); tty 539 drivers/tty/tty_io.c wake_up_interruptible_poll(&tty->write_wait, EPOLLOUT); tty 566 drivers/tty/tty_io.c static void __tty_hangup(struct tty_struct *tty, int exit_session) tty 574 drivers/tty/tty_io.c if (!tty) tty 579 drivers/tty/tty_io.c if (redirect && file_tty(redirect) == tty) { tty 585 drivers/tty/tty_io.c tty_lock(tty); tty 587 drivers/tty/tty_io.c if (test_bit(TTY_HUPPED, &tty->flags)) { tty 588 drivers/tty/tty_io.c tty_unlock(tty); tty 598 drivers/tty/tty_io.c set_bit(TTY_HUPPING, &tty->flags); tty 603 drivers/tty/tty_io.c check_tty_count(tty, "tty_hangup"); tty 605 drivers/tty/tty_io.c spin_lock(&tty->files_lock); tty 607 drivers/tty/tty_io.c list_for_each_entry(priv, &tty->tty_files, list) { tty 617 drivers/tty/tty_io.c spin_unlock(&tty->files_lock); tty 619 drivers/tty/tty_io.c refs = tty_signal_session_leader(tty, exit_session); tty 622 drivers/tty/tty_io.c tty_kref_put(tty); tty 624 drivers/tty/tty_io.c tty_ldisc_hangup(tty, cons_filp != NULL); tty 626 drivers/tty/tty_io.c spin_lock_irq(&tty->ctrl_lock); tty 627 drivers/tty/tty_io.c clear_bit(TTY_THROTTLED, &tty->flags); tty 628 drivers/tty/tty_io.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 629 drivers/tty/tty_io.c put_pid(tty->session); tty 630 drivers/tty/tty_io.c put_pid(tty->pgrp); tty 631 drivers/tty/tty_io.c tty->session = NULL; tty 632 drivers/tty/tty_io.c tty->pgrp = NULL; tty 633 drivers/tty/tty_io.c tty->ctrl_status = 0; tty 634 drivers/tty/tty_io.c spin_unlock_irq(&tty->ctrl_lock); tty 643 drivers/tty/tty_io.c if (tty->ops->close) tty 645 drivers/tty/tty_io.c tty->ops->close(tty, cons_filp); tty 646 drivers/tty/tty_io.c } else if (tty->ops->hangup) tty 647 drivers/tty/tty_io.c tty->ops->hangup(tty); tty 653 drivers/tty/tty_io.c set_bit(TTY_HUPPED, &tty->flags); tty 654 drivers/tty/tty_io.c clear_bit(TTY_HUPPING, &tty->flags); tty 655 drivers/tty/tty_io.c tty_unlock(tty); tty 663 drivers/tty/tty_io.c struct tty_struct *tty = tty 666 drivers/tty/tty_io.c __tty_hangup(tty, 0); tty 677 drivers/tty/tty_io.c void tty_hangup(struct tty_struct *tty) tty 679 drivers/tty/tty_io.c tty_debug_hangup(tty, "hangup\n"); tty 680 drivers/tty/tty_io.c schedule_work(&tty->hangup_work); tty 694 drivers/tty/tty_io.c void tty_vhangup(struct tty_struct *tty) tty 696 drivers/tty/tty_io.c tty_debug_hangup(tty, "vhangup\n"); tty 697 drivers/tty/tty_io.c __tty_hangup(tty, 0); tty 711 drivers/tty/tty_io.c struct tty_struct *tty; tty 713 drivers/tty/tty_io.c tty = get_current_tty(); tty 714 drivers/tty/tty_io.c if (tty) { tty 715 drivers/tty/tty_io.c tty_vhangup(tty); tty 716 drivers/tty/tty_io.c tty_kref_put(tty); tty 731 drivers/tty/tty_io.c void tty_vhangup_session(struct tty_struct *tty) tty 733 drivers/tty/tty_io.c tty_debug_hangup(tty, "session hangup\n"); tty 734 drivers/tty/tty_io.c __tty_hangup(tty, 1); tty 769 drivers/tty/tty_io.c void __stop_tty(struct tty_struct *tty) tty 771 drivers/tty/tty_io.c if (tty->stopped) tty 773 drivers/tty/tty_io.c tty->stopped = 1; tty 774 drivers/tty/tty_io.c if (tty->ops->stop) tty 775 drivers/tty/tty_io.c tty->ops->stop(tty); tty 778 drivers/tty/tty_io.c void stop_tty(struct tty_struct *tty) tty 782 drivers/tty/tty_io.c spin_lock_irqsave(&tty->flow_lock, flags); tty 783 drivers/tty/tty_io.c __stop_tty(tty); tty 784 drivers/tty/tty_io.c spin_unlock_irqrestore(&tty->flow_lock, flags); tty 800 drivers/tty/tty_io.c void __start_tty(struct tty_struct *tty) tty 802 drivers/tty/tty_io.c if (!tty->stopped || tty->flow_stopped) tty 804 drivers/tty/tty_io.c tty->stopped = 0; tty 805 drivers/tty/tty_io.c if (tty->ops->start) tty 806 drivers/tty/tty_io.c tty->ops->start(tty); tty 807 drivers/tty/tty_io.c tty_wakeup(tty); tty 810 drivers/tty/tty_io.c void start_tty(struct tty_struct *tty) tty 814 drivers/tty/tty_io.c spin_lock_irqsave(&tty->flow_lock, flags); tty 815 drivers/tty/tty_io.c __start_tty(tty); tty 816 drivers/tty/tty_io.c spin_unlock_irqrestore(&tty->flow_lock, flags); tty 854 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(file); tty 857 drivers/tty/tty_io.c if (tty_paranoia_check(tty, inode, "tty_read")) tty 859 drivers/tty/tty_io.c if (!tty || tty_io_error(tty)) tty 864 drivers/tty/tty_io.c ld = tty_ldisc_ref_wait(tty); tty 868 drivers/tty/tty_io.c i = ld->ops->read(tty, file, buf, count); tty 879 drivers/tty/tty_io.c static void tty_write_unlock(struct tty_struct *tty) tty 881 drivers/tty/tty_io.c mutex_unlock(&tty->atomic_write_lock); tty 882 drivers/tty/tty_io.c wake_up_interruptible_poll(&tty->write_wait, EPOLLOUT); tty 885 drivers/tty/tty_io.c static int tty_write_lock(struct tty_struct *tty, int ndelay) tty 887 drivers/tty/tty_io.c if (!mutex_trylock(&tty->atomic_write_lock)) { tty 890 drivers/tty/tty_io.c if (mutex_lock_interruptible(&tty->atomic_write_lock)) tty 902 drivers/tty/tty_io.c struct tty_struct *tty, tty 910 drivers/tty/tty_io.c ret = tty_write_lock(tty, file->f_flags & O_NDELAY); tty 931 drivers/tty/tty_io.c if (test_bit(TTY_NO_WRITE_SPLIT, &tty->flags)) tty 937 drivers/tty/tty_io.c if (tty->write_cnt < chunk) { tty 948 drivers/tty/tty_io.c kfree(tty->write_buf); tty 949 drivers/tty/tty_io.c tty->write_cnt = chunk; tty 950 drivers/tty/tty_io.c tty->write_buf = buf_chunk; tty 959 drivers/tty/tty_io.c if (copy_from_user(tty->write_buf, buf, size)) tty 961 drivers/tty/tty_io.c ret = write(tty, file, tty->write_buf, size); tty 979 drivers/tty/tty_io.c tty_write_unlock(tty); tty 995 drivers/tty/tty_io.c void tty_write_message(struct tty_struct *tty, char *msg) tty 997 drivers/tty/tty_io.c if (tty) { tty 998 drivers/tty/tty_io.c mutex_lock(&tty->atomic_write_lock); tty 999 drivers/tty/tty_io.c tty_lock(tty); tty 1000 drivers/tty/tty_io.c if (tty->ops->write && tty->count > 0) tty 1001 drivers/tty/tty_io.c tty->ops->write(tty, msg, strlen(msg)); tty 1002 drivers/tty/tty_io.c tty_unlock(tty); tty 1003 drivers/tty/tty_io.c tty_write_unlock(tty); tty 1028 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(file); tty 1032 drivers/tty/tty_io.c if (tty_paranoia_check(tty, file_inode(file), "tty_write")) tty 1034 drivers/tty/tty_io.c if (!tty || !tty->ops->write || tty_io_error(tty)) tty 1037 drivers/tty/tty_io.c if (tty->ops->write_room == NULL) tty 1038 drivers/tty/tty_io.c tty_err(tty, "missing write_room method\n"); tty 1039 drivers/tty/tty_io.c ld = tty_ldisc_ref_wait(tty); tty 1045 drivers/tty/tty_io.c ret = do_tty_write(ld->ops->write, tty, file, buf, count); tty 1077 drivers/tty/tty_io.c int tty_send_xchar(struct tty_struct *tty, char ch) tty 1079 drivers/tty/tty_io.c int was_stopped = tty->stopped; tty 1081 drivers/tty/tty_io.c if (tty->ops->send_xchar) { tty 1082 drivers/tty/tty_io.c down_read(&tty->termios_rwsem); tty 1083 drivers/tty/tty_io.c tty->ops->send_xchar(tty, ch); tty 1084 drivers/tty/tty_io.c up_read(&tty->termios_rwsem); tty 1088 drivers/tty/tty_io.c if (tty_write_lock(tty, 0) < 0) tty 1091 drivers/tty/tty_io.c down_read(&tty->termios_rwsem); tty 1093 drivers/tty/tty_io.c start_tty(tty); tty 1094 drivers/tty/tty_io.c tty->ops->write(tty, &ch, 1); tty 1096 drivers/tty/tty_io.c stop_tty(tty); tty 1097 drivers/tty/tty_io.c up_read(&tty->termios_rwsem); tty 1098 drivers/tty/tty_io.c tty_write_unlock(tty); tty 1157 drivers/tty/tty_io.c struct tty_struct *tty; tty 1161 drivers/tty/tty_io.c tty = ERR_PTR(-EIO); tty 1163 drivers/tty/tty_io.c tty = driver->ops->lookup(driver, file, idx); tty 1165 drivers/tty/tty_io.c tty = driver->ttys[idx]; tty 1167 drivers/tty/tty_io.c if (!IS_ERR(tty)) tty 1168 drivers/tty/tty_io.c tty_kref_get(tty); tty 1169 drivers/tty/tty_io.c return tty; tty 1180 drivers/tty/tty_io.c void tty_init_termios(struct tty_struct *tty) tty 1183 drivers/tty/tty_io.c int idx = tty->index; tty 1185 drivers/tty/tty_io.c if (tty->driver->flags & TTY_DRIVER_RESET_TERMIOS) tty 1186 drivers/tty/tty_io.c tty->termios = tty->driver->init_termios; tty 1189 drivers/tty/tty_io.c tp = tty->driver->termios[idx]; tty 1191 drivers/tty/tty_io.c tty->termios = *tp; tty 1192 drivers/tty/tty_io.c tty->termios.c_line = tty->driver->init_termios.c_line; tty 1194 drivers/tty/tty_io.c tty->termios = tty->driver->init_termios; tty 1197 drivers/tty/tty_io.c tty->termios.c_ispeed = tty_termios_input_baud_rate(&tty->termios); tty 1198 drivers/tty/tty_io.c tty->termios.c_ospeed = tty_termios_baud_rate(&tty->termios); tty 1202 drivers/tty/tty_io.c int tty_standard_install(struct tty_driver *driver, struct tty_struct *tty) tty 1204 drivers/tty/tty_io.c tty_init_termios(tty); tty 1206 drivers/tty/tty_io.c tty->count++; tty 1207 drivers/tty/tty_io.c driver->ttys[tty->index] = tty; tty 1225 drivers/tty/tty_io.c struct tty_struct *tty) tty 1227 drivers/tty/tty_io.c return driver->ops->install ? driver->ops->install(driver, tty) : tty 1228 drivers/tty/tty_io.c tty_standard_install(driver, tty); tty 1241 drivers/tty/tty_io.c static void tty_driver_remove_tty(struct tty_driver *driver, struct tty_struct *tty) tty 1244 drivers/tty/tty_io.c driver->ops->remove(driver, tty); tty 1246 drivers/tty/tty_io.c driver->ttys[tty->index] = NULL; tty 1258 drivers/tty/tty_io.c static int tty_reopen(struct tty_struct *tty) tty 1260 drivers/tty/tty_io.c struct tty_driver *driver = tty->driver; tty 1268 drivers/tty/tty_io.c if (!tty->count) tty 1271 drivers/tty/tty_io.c if (test_bit(TTY_EXCLUSIVE, &tty->flags) && !capable(CAP_SYS_ADMIN)) tty 1274 drivers/tty/tty_io.c ld = tty_ldisc_ref_wait(tty); tty 1278 drivers/tty/tty_io.c retval = tty_ldisc_lock(tty, 5 * HZ); tty 1282 drivers/tty/tty_io.c if (!tty->ldisc) tty 1283 drivers/tty/tty_io.c retval = tty_ldisc_reinit(tty, tty->termios.c_line); tty 1284 drivers/tty/tty_io.c tty_ldisc_unlock(tty); tty 1288 drivers/tty/tty_io.c tty->count++; tty 1319 drivers/tty/tty_io.c struct tty_struct *tty; tty 1333 drivers/tty/tty_io.c tty = alloc_tty_struct(driver, idx); tty 1334 drivers/tty/tty_io.c if (!tty) { tty 1339 drivers/tty/tty_io.c tty_lock(tty); tty 1340 drivers/tty/tty_io.c retval = tty_driver_install_tty(driver, tty); tty 1344 drivers/tty/tty_io.c if (!tty->port) tty 1345 drivers/tty/tty_io.c tty->port = driver->ports[idx]; tty 1347 drivers/tty/tty_io.c WARN_RATELIMIT(!tty->port, tty 1349 drivers/tty/tty_io.c __func__, tty->driver->name); tty 1351 drivers/tty/tty_io.c retval = tty_ldisc_lock(tty, 5 * HZ); tty 1354 drivers/tty/tty_io.c tty->port->itty = tty; tty 1361 drivers/tty/tty_io.c retval = tty_ldisc_setup(tty, tty->link); tty 1364 drivers/tty/tty_io.c tty_ldisc_unlock(tty); tty 1366 drivers/tty/tty_io.c return tty; tty 1369 drivers/tty/tty_io.c tty_unlock(tty); tty 1370 drivers/tty/tty_io.c free_tty_struct(tty); tty 1377 drivers/tty/tty_io.c tty_ldisc_unlock(tty); tty 1378 drivers/tty/tty_io.c tty_info_ratelimited(tty, "ldisc open failed (%d), clearing slot %d\n", tty 1381 drivers/tty/tty_io.c tty_unlock(tty); tty 1382 drivers/tty/tty_io.c release_tty(tty, idx); tty 1392 drivers/tty/tty_io.c void tty_save_termios(struct tty_struct *tty) tty 1395 drivers/tty/tty_io.c int idx = tty->index; tty 1398 drivers/tty/tty_io.c if (tty->driver->flags & TTY_DRIVER_RESET_TERMIOS) tty 1402 drivers/tty/tty_io.c tp = tty->driver->termios[idx]; tty 1407 drivers/tty/tty_io.c tty->driver->termios[idx] = tp; tty 1409 drivers/tty/tty_io.c *tp = tty->termios; tty 1419 drivers/tty/tty_io.c static void tty_flush_works(struct tty_struct *tty) tty 1421 drivers/tty/tty_io.c flush_work(&tty->SAK_work); tty 1422 drivers/tty/tty_io.c flush_work(&tty->hangup_work); tty 1423 drivers/tty/tty_io.c if (tty->link) { tty 1424 drivers/tty/tty_io.c flush_work(&tty->link->SAK_work); tty 1425 drivers/tty/tty_io.c flush_work(&tty->link->hangup_work); tty 1446 drivers/tty/tty_io.c struct tty_struct *tty = tty 1448 drivers/tty/tty_io.c struct tty_driver *driver = tty->driver; tty 1451 drivers/tty/tty_io.c if (tty->ops->cleanup) tty 1452 drivers/tty/tty_io.c tty->ops->cleanup(tty); tty 1454 drivers/tty/tty_io.c tty->magic = 0; tty 1458 drivers/tty/tty_io.c spin_lock(&tty->files_lock); tty 1459 drivers/tty/tty_io.c list_del_init(&tty->tty_files); tty 1460 drivers/tty/tty_io.c spin_unlock(&tty->files_lock); tty 1462 drivers/tty/tty_io.c put_pid(tty->pgrp); tty 1463 drivers/tty/tty_io.c put_pid(tty->session); tty 1464 drivers/tty/tty_io.c free_tty_struct(tty); tty 1469 drivers/tty/tty_io.c struct tty_struct *tty = container_of(kref, struct tty_struct, kref); tty 1473 drivers/tty/tty_io.c INIT_WORK(&tty->hangup_work, release_one_tty); tty 1474 drivers/tty/tty_io.c schedule_work(&tty->hangup_work); tty 1485 drivers/tty/tty_io.c void tty_kref_put(struct tty_struct *tty) tty 1487 drivers/tty/tty_io.c if (tty) tty 1488 drivers/tty/tty_io.c kref_put(&tty->kref, queue_release_one_tty); tty 1504 drivers/tty/tty_io.c static void release_tty(struct tty_struct *tty, int idx) tty 1507 drivers/tty/tty_io.c WARN_ON(tty->index != idx); tty 1509 drivers/tty/tty_io.c if (tty->ops->shutdown) tty 1510 drivers/tty/tty_io.c tty->ops->shutdown(tty); tty 1511 drivers/tty/tty_io.c tty_save_termios(tty); tty 1512 drivers/tty/tty_io.c tty_driver_remove_tty(tty->driver, tty); tty 1513 drivers/tty/tty_io.c tty->port->itty = NULL; tty 1514 drivers/tty/tty_io.c if (tty->link) tty 1515 drivers/tty/tty_io.c tty->link->port->itty = NULL; tty 1516 drivers/tty/tty_io.c tty_buffer_cancel_work(tty->port); tty 1517 drivers/tty/tty_io.c if (tty->link) tty 1518 drivers/tty/tty_io.c tty_buffer_cancel_work(tty->link->port); tty 1520 drivers/tty/tty_io.c tty_kref_put(tty->link); tty 1521 drivers/tty/tty_io.c tty_kref_put(tty); tty 1533 drivers/tty/tty_io.c static int tty_release_checks(struct tty_struct *tty, int idx) tty 1536 drivers/tty/tty_io.c if (idx < 0 || idx >= tty->driver->num) { tty 1537 drivers/tty/tty_io.c tty_debug(tty, "bad idx %d\n", idx); tty 1542 drivers/tty/tty_io.c if (tty->driver->flags & TTY_DRIVER_DEVPTS_MEM) tty 1545 drivers/tty/tty_io.c if (tty != tty->driver->ttys[idx]) { tty 1546 drivers/tty/tty_io.c tty_debug(tty, "bad driver table[%d] = %p\n", tty 1547 drivers/tty/tty_io.c idx, tty->driver->ttys[idx]); tty 1550 drivers/tty/tty_io.c if (tty->driver->other) { tty 1551 drivers/tty/tty_io.c struct tty_struct *o_tty = tty->link; tty 1553 drivers/tty/tty_io.c if (o_tty != tty->driver->other->ttys[idx]) { tty 1554 drivers/tty/tty_io.c tty_debug(tty, "bad other table[%d] = %p\n", tty 1555 drivers/tty/tty_io.c idx, tty->driver->other->ttys[idx]); tty 1558 drivers/tty/tty_io.c if (o_tty->link != tty) { tty 1559 drivers/tty/tty_io.c tty_debug(tty, "bad link = %p\n", o_tty->link); tty 1575 drivers/tty/tty_io.c void tty_kclose(struct tty_struct *tty) tty 1580 drivers/tty/tty_io.c tty_ldisc_release(tty); tty 1583 drivers/tty/tty_io.c tty_flush_works(tty); tty 1585 drivers/tty/tty_io.c tty_debug_hangup(tty, "freeing structure\n"); tty 1593 drivers/tty/tty_io.c tty_port_set_kopened(tty->port, 0); tty 1594 drivers/tty/tty_io.c release_tty(tty, tty->index); tty 1607 drivers/tty/tty_io.c void tty_release_struct(struct tty_struct *tty, int idx) tty 1612 drivers/tty/tty_io.c tty_ldisc_release(tty); tty 1615 drivers/tty/tty_io.c tty_flush_works(tty); tty 1617 drivers/tty/tty_io.c tty_debug_hangup(tty, "freeing structure\n"); tty 1625 drivers/tty/tty_io.c release_tty(tty, idx); tty 1651 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(filp); tty 1658 drivers/tty/tty_io.c if (tty_paranoia_check(tty, inode, __func__)) tty 1661 drivers/tty/tty_io.c tty_lock(tty); tty 1662 drivers/tty/tty_io.c check_tty_count(tty, __func__); tty 1666 drivers/tty/tty_io.c idx = tty->index; tty 1667 drivers/tty/tty_io.c if (tty->driver->type == TTY_DRIVER_TYPE_PTY && tty 1668 drivers/tty/tty_io.c tty->driver->subtype == PTY_TYPE_MASTER) tty 1669 drivers/tty/tty_io.c o_tty = tty->link; tty 1671 drivers/tty/tty_io.c if (tty_release_checks(tty, idx)) { tty 1672 drivers/tty/tty_io.c tty_unlock(tty); tty 1676 drivers/tty/tty_io.c tty_debug_hangup(tty, "releasing (count=%d)\n", tty->count); tty 1678 drivers/tty/tty_io.c if (tty->ops->close) tty 1679 drivers/tty/tty_io.c tty->ops->close(tty, filp); tty 1700 drivers/tty/tty_io.c if (tty->count <= 1) { tty 1701 drivers/tty/tty_io.c if (waitqueue_active(&tty->read_wait)) { tty 1702 drivers/tty/tty_io.c wake_up_poll(&tty->read_wait, EPOLLIN); tty 1705 drivers/tty/tty_io.c if (waitqueue_active(&tty->write_wait)) { tty 1706 drivers/tty/tty_io.c wake_up_poll(&tty->write_wait, EPOLLOUT); tty 1725 drivers/tty/tty_io.c tty_warn(tty, "read/write wait queue active!\n"); tty 1736 drivers/tty/tty_io.c tty_warn(tty, "bad slave count (%d)\n", o_tty->count); tty 1740 drivers/tty/tty_io.c if (--tty->count < 0) { tty 1741 drivers/tty/tty_io.c tty_warn(tty, "bad tty->count (%d)\n", tty->count); tty 1742 drivers/tty/tty_io.c tty->count = 0; tty 1763 drivers/tty/tty_io.c if (!tty->count) { tty 1765 drivers/tty/tty_io.c session_clear_tty(tty->session); tty 1772 drivers/tty/tty_io.c final = !tty->count && !(o_tty && o_tty->count); tty 1775 drivers/tty/tty_io.c tty_unlock(tty); tty 1783 drivers/tty/tty_io.c tty_debug_hangup(tty, "final close\n"); tty 1785 drivers/tty/tty_io.c tty_release_struct(tty, idx); tty 1802 drivers/tty/tty_io.c struct tty_struct *tty; tty 1808 drivers/tty/tty_io.c tty = get_current_tty(); tty 1809 drivers/tty/tty_io.c if (!tty) tty 1814 drivers/tty/tty_io.c tty_lock(tty); tty 1815 drivers/tty/tty_io.c tty_kref_put(tty); /* safe to drop the kref now */ tty 1817 drivers/tty/tty_io.c retval = tty_reopen(tty); tty 1819 drivers/tty/tty_io.c tty_unlock(tty); tty 1820 drivers/tty/tty_io.c tty = ERR_PTR(retval); tty 1822 drivers/tty/tty_io.c return tty; tty 1891 drivers/tty/tty_io.c struct tty_struct *tty; tty 1903 drivers/tty/tty_io.c tty = tty_driver_lookup_tty(driver, NULL, index); tty 1904 drivers/tty/tty_io.c if (IS_ERR(tty)) tty 1907 drivers/tty/tty_io.c if (tty) { tty 1909 drivers/tty/tty_io.c tty_kref_put(tty); tty 1910 drivers/tty/tty_io.c tty = ERR_PTR(-EBUSY); tty 1912 drivers/tty/tty_io.c tty = tty_init_dev(driver, index); tty 1913 drivers/tty/tty_io.c if (IS_ERR(tty)) tty 1915 drivers/tty/tty_io.c tty_port_set_kopened(tty->port, 1); tty 1920 drivers/tty/tty_io.c return tty; tty 1943 drivers/tty/tty_io.c struct tty_struct *tty; tty 1956 drivers/tty/tty_io.c tty = tty_driver_lookup_tty(driver, filp, index); tty 1957 drivers/tty/tty_io.c if (IS_ERR(tty)) { tty 1962 drivers/tty/tty_io.c if (tty) { tty 1963 drivers/tty/tty_io.c if (tty_port_kopened(tty->port)) { tty 1964 drivers/tty/tty_io.c tty_kref_put(tty); tty 1966 drivers/tty/tty_io.c tty = ERR_PTR(-EBUSY); tty 1970 drivers/tty/tty_io.c retval = tty_lock_interruptible(tty); tty 1971 drivers/tty/tty_io.c tty_kref_put(tty); /* drop kref from tty_driver_lookup_tty() */ tty 1975 drivers/tty/tty_io.c tty = ERR_PTR(retval); tty 1978 drivers/tty/tty_io.c retval = tty_reopen(tty); tty 1980 drivers/tty/tty_io.c tty_unlock(tty); tty 1981 drivers/tty/tty_io.c tty = ERR_PTR(retval); tty 1984 drivers/tty/tty_io.c tty = tty_init_dev(driver, index); tty 1989 drivers/tty/tty_io.c return tty; tty 2018 drivers/tty/tty_io.c struct tty_struct *tty; tty 2030 drivers/tty/tty_io.c tty = tty_open_current_tty(device, filp); tty 2031 drivers/tty/tty_io.c if (!tty) tty 2032 drivers/tty/tty_io.c tty = tty_open_by_driver(device, inode, filp); tty 2034 drivers/tty/tty_io.c if (IS_ERR(tty)) { tty 2036 drivers/tty/tty_io.c retval = PTR_ERR(tty); tty 2043 drivers/tty/tty_io.c tty_add_file(tty, filp); tty 2045 drivers/tty/tty_io.c check_tty_count(tty, __func__); tty 2046 drivers/tty/tty_io.c tty_debug_hangup(tty, "opening (count=%d)\n", tty->count); tty 2048 drivers/tty/tty_io.c if (tty->ops->open) tty 2049 drivers/tty/tty_io.c retval = tty->ops->open(tty, filp); tty 2055 drivers/tty/tty_io.c tty_debug_hangup(tty, "open error %d, releasing\n", retval); tty 2057 drivers/tty/tty_io.c tty_unlock(tty); /* need to call tty_release without BTM */ tty 2073 drivers/tty/tty_io.c clear_bit(TTY_HUPPED, &tty->flags); tty 2078 drivers/tty/tty_io.c (tty->driver->type == TTY_DRIVER_TYPE_PTY && tty 2079 drivers/tty/tty_io.c tty->driver->subtype == PTY_TYPE_MASTER); tty 2081 drivers/tty/tty_io.c tty_open_proc_set_tty(filp, tty); tty 2082 drivers/tty/tty_io.c tty_unlock(tty); tty 2102 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(filp); tty 2106 drivers/tty/tty_io.c if (tty_paranoia_check(tty, file_inode(filp), "tty_poll")) tty 2109 drivers/tty/tty_io.c ld = tty_ldisc_ref_wait(tty); tty 2113 drivers/tty/tty_io.c ret = ld->ops->poll(tty, filp, wait); tty 2120 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(filp); tty 2124 drivers/tty/tty_io.c if (tty_paranoia_check(tty, file_inode(filp), "tty_fasync")) tty 2127 drivers/tty/tty_io.c retval = fasync_helper(fd, filp, on, &tty->fasync); tty 2135 drivers/tty/tty_io.c spin_lock_irqsave(&tty->ctrl_lock, flags); tty 2136 drivers/tty/tty_io.c if (tty->pgrp) { tty 2137 drivers/tty/tty_io.c pid = tty->pgrp; tty 2144 drivers/tty/tty_io.c spin_unlock_irqrestore(&tty->ctrl_lock, flags); tty 2155 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(filp); tty 2158 drivers/tty/tty_io.c tty_lock(tty); tty 2161 drivers/tty/tty_io.c tty_unlock(tty); tty 2183 drivers/tty/tty_io.c static int tiocsti(struct tty_struct *tty, char __user *p) tty 2188 drivers/tty/tty_io.c if ((current->signal->tty != tty) && !capable(CAP_SYS_ADMIN)) tty 2192 drivers/tty/tty_io.c tty_audit_tiocsti(tty, ch); tty 2193 drivers/tty/tty_io.c ld = tty_ldisc_ref_wait(tty); tty 2197 drivers/tty/tty_io.c ld->ops->receive_buf(tty, &ch, &mbz, 1); tty 2213 drivers/tty/tty_io.c static int tiocgwinsz(struct tty_struct *tty, struct winsize __user *arg) tty 2217 drivers/tty/tty_io.c mutex_lock(&tty->winsize_mutex); tty 2218 drivers/tty/tty_io.c err = copy_to_user(arg, &tty->winsize, sizeof(*arg)); tty 2219 drivers/tty/tty_io.c mutex_unlock(&tty->winsize_mutex); tty 2234 drivers/tty/tty_io.c int tty_do_resize(struct tty_struct *tty, struct winsize *ws) tty 2239 drivers/tty/tty_io.c mutex_lock(&tty->winsize_mutex); tty 2240 drivers/tty/tty_io.c if (!memcmp(ws, &tty->winsize, sizeof(*ws))) tty 2244 drivers/tty/tty_io.c pgrp = tty_get_pgrp(tty); tty 2249 drivers/tty/tty_io.c tty->winsize = *ws; tty 2251 drivers/tty/tty_io.c mutex_unlock(&tty->winsize_mutex); tty 2271 drivers/tty/tty_io.c static int tiocswinsz(struct tty_struct *tty, struct winsize __user *arg) tty 2277 drivers/tty/tty_io.c if (tty->ops->resize) tty 2278 drivers/tty/tty_io.c return tty->ops->resize(tty, &tmp_ws); tty 2280 drivers/tty/tty_io.c return tty_do_resize(tty, &tmp_ws); tty 2326 drivers/tty/tty_io.c static int tiocsetd(struct tty_struct *tty, int __user *p) tty 2334 drivers/tty/tty_io.c ret = tty_set_ldisc(tty, disc); tty 2350 drivers/tty/tty_io.c static int tiocgetd(struct tty_struct *tty, int __user *p) tty 2355 drivers/tty/tty_io.c ld = tty_ldisc_ref_wait(tty); tty 2376 drivers/tty/tty_io.c static int send_break(struct tty_struct *tty, unsigned int duration) tty 2380 drivers/tty/tty_io.c if (tty->ops->break_ctl == NULL) tty 2383 drivers/tty/tty_io.c if (tty->driver->flags & TTY_DRIVER_HARDWARE_BREAK) tty 2384 drivers/tty/tty_io.c retval = tty->ops->break_ctl(tty, duration); tty 2387 drivers/tty/tty_io.c if (tty_write_lock(tty, 0) < 0) tty 2389 drivers/tty/tty_io.c retval = tty->ops->break_ctl(tty, -1); tty 2394 drivers/tty/tty_io.c retval = tty->ops->break_ctl(tty, 0); tty 2396 drivers/tty/tty_io.c tty_write_unlock(tty); tty 2415 drivers/tty/tty_io.c static int tty_tiocmget(struct tty_struct *tty, int __user *p) tty 2419 drivers/tty/tty_io.c if (tty->ops->tiocmget) { tty 2420 drivers/tty/tty_io.c retval = tty->ops->tiocmget(tty); tty 2440 drivers/tty/tty_io.c static int tty_tiocmset(struct tty_struct *tty, unsigned int cmd, tty 2446 drivers/tty/tty_io.c if (tty->ops->tiocmset == NULL) tty 2467 drivers/tty/tty_io.c return tty->ops->tiocmset(tty, set, clear); tty 2470 drivers/tty/tty_io.c static int tty_tiocgicount(struct tty_struct *tty, void __user *arg) tty 2475 drivers/tty/tty_io.c if (tty->ops->get_icount) tty 2476 drivers/tty/tty_io.c retval = tty->ops->get_icount(tty, &icount); tty 2484 drivers/tty/tty_io.c static int tty_tiocsserial(struct tty_struct *tty, struct serial_struct __user *ss) tty 2501 drivers/tty/tty_io.c if (!tty->ops->set_serial) tty 2503 drivers/tty/tty_io.c return tty->ops->set_serial(tty, &v); tty 2506 drivers/tty/tty_io.c static int tty_tiocgserial(struct tty_struct *tty, struct serial_struct __user *ss) tty 2512 drivers/tty/tty_io.c if (!tty->ops->get_serial) tty 2514 drivers/tty/tty_io.c err = tty->ops->get_serial(tty, &v); tty 2524 drivers/tty/tty_io.c static struct tty_struct *tty_pair_get_tty(struct tty_struct *tty) tty 2526 drivers/tty/tty_io.c if (tty->driver->type == TTY_DRIVER_TYPE_PTY && tty 2527 drivers/tty/tty_io.c tty->driver->subtype == PTY_TYPE_MASTER) tty 2528 drivers/tty/tty_io.c tty = tty->link; tty 2529 drivers/tty/tty_io.c return tty; tty 2537 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(file); tty 2543 drivers/tty/tty_io.c if (tty_paranoia_check(tty, file_inode(file), "tty_ioctl")) tty 2546 drivers/tty/tty_io.c real_tty = tty_pair_get_tty(tty); tty 2557 drivers/tty/tty_io.c retval = tty_check_change(tty); tty 2561 drivers/tty/tty_io.c tty_wait_until_sent(tty, 0); tty 2573 drivers/tty/tty_io.c return tiocsti(tty, p); tty 2579 drivers/tty/tty_io.c return real_tty != tty ? -EINVAL : tioccons(file); tty 2581 drivers/tty/tty_io.c set_bit(TTY_EXCLUSIVE, &tty->flags); tty 2584 drivers/tty/tty_io.c clear_bit(TTY_EXCLUSIVE, &tty->flags); tty 2588 drivers/tty/tty_io.c int excl = test_bit(TTY_EXCLUSIVE, &tty->flags); tty 2592 drivers/tty/tty_io.c return tiocgetd(tty, p); tty 2594 drivers/tty/tty_io.c return tiocsetd(tty, p); tty 2598 drivers/tty/tty_io.c tty_vhangup(tty); tty 2609 drivers/tty/tty_io.c if (tty->ops->break_ctl) tty 2610 drivers/tty/tty_io.c return tty->ops->break_ctl(tty, -1); tty 2613 drivers/tty/tty_io.c if (tty->ops->break_ctl) tty 2614 drivers/tty/tty_io.c return tty->ops->break_ctl(tty, 0); tty 2622 drivers/tty/tty_io.c return send_break(tty, 250); tty 2625 drivers/tty/tty_io.c return send_break(tty, arg ? arg*100 : 250); tty 2628 drivers/tty/tty_io.c return tty_tiocmget(tty, p); tty 2632 drivers/tty/tty_io.c return tty_tiocmset(tty, cmd, p); tty 2634 drivers/tty/tty_io.c return tty_tiocgicount(tty, p); tty 2640 drivers/tty/tty_io.c tty_buffer_flush(tty, NULL); tty 2645 drivers/tty/tty_io.c return tty_tiocsserial(tty, p); tty 2647 drivers/tty/tty_io.c return tty_tiocgserial(tty, p); tty 2650 drivers/tty/tty_io.c return ptm_open_peer(file, tty, (int)arg); tty 2652 drivers/tty/tty_io.c retval = tty_jobctrl_ioctl(tty, real_tty, file, cmd, arg); tty 2656 drivers/tty/tty_io.c if (tty->ops->ioctl) { tty 2657 drivers/tty/tty_io.c retval = tty->ops->ioctl(tty, cmd, arg); tty 2661 drivers/tty/tty_io.c ld = tty_ldisc_ref_wait(tty); tty 2666 drivers/tty/tty_io.c retval = ld->ops->ioctl(tty, file, cmd, arg); tty 2698 drivers/tty/tty_io.c static int compat_tty_tiocsserial(struct tty_struct *tty, tty 2723 drivers/tty/tty_io.c if (!tty->ops->set_serial) tty 2725 drivers/tty/tty_io.c return tty->ops->set_serial(tty, &v); tty 2728 drivers/tty/tty_io.c static int compat_tty_tiocgserial(struct tty_struct *tty, tty 2738 drivers/tty/tty_io.c if (!tty->ops->get_serial) tty 2740 drivers/tty/tty_io.c err = tty->ops->get_serial(tty, &v); tty 2755 drivers/tty/tty_io.c struct tty_struct *tty = file_tty(file); tty 2834 drivers/tty/tty_io.c if (tty_paranoia_check(tty, file_inode(file), "tty_ioctl")) tty 2839 drivers/tty/tty_io.c return compat_tty_tiocsserial(tty, compat_ptr(arg)); tty 2841 drivers/tty/tty_io.c return compat_tty_tiocgserial(tty, compat_ptr(arg)); tty 2843 drivers/tty/tty_io.c if (tty->ops->compat_ioctl) { tty 2844 drivers/tty/tty_io.c retval = tty->ops->compat_ioctl(tty, cmd, arg); tty 2849 drivers/tty/tty_io.c ld = tty_ldisc_ref_wait(tty); tty 2853 drivers/tty/tty_io.c retval = ld->ops->compat_ioctl(tty, file, cmd, arg); tty 2855 drivers/tty/tty_io.c retval = ld->ops->ioctl(tty, file, tty 2889 drivers/tty/tty_io.c void __do_SAK(struct tty_struct *tty) tty 2892 drivers/tty/tty_io.c tty_hangup(tty); tty 2898 drivers/tty/tty_io.c if (!tty) tty 2900 drivers/tty/tty_io.c session = tty->session; tty 2902 drivers/tty/tty_io.c tty_ldisc_flush(tty); tty 2904 drivers/tty/tty_io.c tty_driver_flush_buffer(tty); tty 2909 drivers/tty/tty_io.c tty_notice(tty, "SAK: killed process %d (%s): by session\n", tty 2916 drivers/tty/tty_io.c if (p->signal->tty == tty) { tty 2917 drivers/tty/tty_io.c tty_notice(tty, "SAK: killed process %d (%s): by controlling tty\n", tty 2923 drivers/tty/tty_io.c i = iterate_fd(p->files, 0, this_tty, tty); tty 2925 drivers/tty/tty_io.c tty_notice(tty, "SAK: killed process %d (%s): by fd#%d\n", tty 2937 drivers/tty/tty_io.c struct tty_struct *tty = tty 2939 drivers/tty/tty_io.c __do_SAK(tty); tty 2948 drivers/tty/tty_io.c void do_SAK(struct tty_struct *tty) tty 2950 drivers/tty/tty_io.c if (!tty) tty 2952 drivers/tty/tty_io.c schedule_work(&tty->SAK_work); tty 2958 drivers/tty/tty_io.c static struct device *tty_get_device(struct tty_struct *tty) tty 2960 drivers/tty/tty_io.c dev_t devt = tty_devnum(tty); tty 2975 drivers/tty/tty_io.c struct tty_struct *tty; tty 2977 drivers/tty/tty_io.c tty = kzalloc(sizeof(*tty), GFP_KERNEL); tty 2978 drivers/tty/tty_io.c if (!tty) tty 2981 drivers/tty/tty_io.c kref_init(&tty->kref); tty 2982 drivers/tty/tty_io.c tty->magic = TTY_MAGIC; tty 2983 drivers/tty/tty_io.c if (tty_ldisc_init(tty)) { tty 2984 drivers/tty/tty_io.c kfree(tty); tty 2987 drivers/tty/tty_io.c tty->session = NULL; tty 2988 drivers/tty/tty_io.c tty->pgrp = NULL; tty 2989 drivers/tty/tty_io.c mutex_init(&tty->legacy_mutex); tty 2990 drivers/tty/tty_io.c mutex_init(&tty->throttle_mutex); tty 2991 drivers/tty/tty_io.c init_rwsem(&tty->termios_rwsem); tty 2992 drivers/tty/tty_io.c mutex_init(&tty->winsize_mutex); tty 2993 drivers/tty/tty_io.c init_ldsem(&tty->ldisc_sem); tty 2994 drivers/tty/tty_io.c init_waitqueue_head(&tty->write_wait); tty 2995 drivers/tty/tty_io.c init_waitqueue_head(&tty->read_wait); tty 2996 drivers/tty/tty_io.c INIT_WORK(&tty->hangup_work, do_tty_hangup); tty 2997 drivers/tty/tty_io.c mutex_init(&tty->atomic_write_lock); tty 2998 drivers/tty/tty_io.c spin_lock_init(&tty->ctrl_lock); tty 2999 drivers/tty/tty_io.c spin_lock_init(&tty->flow_lock); tty 3000 drivers/tty/tty_io.c spin_lock_init(&tty->files_lock); tty 3001 drivers/tty/tty_io.c INIT_LIST_HEAD(&tty->tty_files); tty 3002 drivers/tty/tty_io.c INIT_WORK(&tty->SAK_work, do_SAK_work); tty 3004 drivers/tty/tty_io.c tty->driver = driver; tty 3005 drivers/tty/tty_io.c tty->ops = driver->ops; tty 3006 drivers/tty/tty_io.c tty->index = idx; tty 3007 drivers/tty/tty_io.c tty_line_name(driver, idx, tty->name); tty 3008 drivers/tty/tty_io.c tty->dev = tty_get_device(tty); tty 3010 drivers/tty/tty_io.c return tty; tty 3025 drivers/tty/tty_io.c int tty_put_char(struct tty_struct *tty, unsigned char ch) tty 3027 drivers/tty/tty_io.c if (tty->ops->put_char) tty 3028 drivers/tty/tty_io.c return tty->ops->put_char(tty, ch); tty 3029 drivers/tty/tty_io.c return tty->ops->write(tty, &ch, 1); tty 3391 drivers/tty/tty_io.c dev_t tty_devnum(struct tty_struct *tty) tty 3393 drivers/tty/tty_io.c return MKDEV(tty->driver->major, tty->driver->minor_start) + tty->index; tty 31 drivers/tty/tty_ioctl.c # define tty_debug_wait_until_sent(tty, f, args...) tty_debug(tty, f, ##args) tty 33 drivers/tty/tty_ioctl.c # define tty_debug_wait_until_sent(tty, f, args...) do {} while (0) tty 56 drivers/tty/tty_ioctl.c int tty_chars_in_buffer(struct tty_struct *tty) tty 58 drivers/tty/tty_ioctl.c if (tty->ops->chars_in_buffer) tty 59 drivers/tty/tty_ioctl.c return tty->ops->chars_in_buffer(tty); tty 76 drivers/tty/tty_ioctl.c int tty_write_room(struct tty_struct *tty) tty 78 drivers/tty/tty_ioctl.c if (tty->ops->write_room) tty 79 drivers/tty/tty_ioctl.c return tty->ops->write_room(tty); tty 92 drivers/tty/tty_ioctl.c void tty_driver_flush_buffer(struct tty_struct *tty) tty 94 drivers/tty/tty_ioctl.c if (tty->ops->flush_buffer) tty 95 drivers/tty/tty_ioctl.c tty->ops->flush_buffer(tty); tty 109 drivers/tty/tty_ioctl.c void tty_throttle(struct tty_struct *tty) tty 111 drivers/tty/tty_ioctl.c down_write(&tty->termios_rwsem); tty 113 drivers/tty/tty_ioctl.c if (!test_and_set_bit(TTY_THROTTLED, &tty->flags) && tty 114 drivers/tty/tty_ioctl.c tty->ops->throttle) tty 115 drivers/tty/tty_ioctl.c tty->ops->throttle(tty); tty 116 drivers/tty/tty_ioctl.c tty->flow_change = 0; tty 117 drivers/tty/tty_ioctl.c up_write(&tty->termios_rwsem); tty 134 drivers/tty/tty_ioctl.c void tty_unthrottle(struct tty_struct *tty) tty 136 drivers/tty/tty_ioctl.c down_write(&tty->termios_rwsem); tty 137 drivers/tty/tty_ioctl.c if (test_and_clear_bit(TTY_THROTTLED, &tty->flags) && tty 138 drivers/tty/tty_ioctl.c tty->ops->unthrottle) tty 139 drivers/tty/tty_ioctl.c tty->ops->unthrottle(tty); tty 140 drivers/tty/tty_ioctl.c tty->flow_change = 0; tty 141 drivers/tty/tty_ioctl.c up_write(&tty->termios_rwsem); tty 157 drivers/tty/tty_ioctl.c int tty_throttle_safe(struct tty_struct *tty) tty 161 drivers/tty/tty_ioctl.c mutex_lock(&tty->throttle_mutex); tty 162 drivers/tty/tty_ioctl.c if (!tty_throttled(tty)) { tty 163 drivers/tty/tty_ioctl.c if (tty->flow_change != TTY_THROTTLE_SAFE) tty 166 drivers/tty/tty_ioctl.c set_bit(TTY_THROTTLED, &tty->flags); tty 167 drivers/tty/tty_ioctl.c if (tty->ops->throttle) tty 168 drivers/tty/tty_ioctl.c tty->ops->throttle(tty); tty 171 drivers/tty/tty_ioctl.c mutex_unlock(&tty->throttle_mutex); tty 188 drivers/tty/tty_ioctl.c int tty_unthrottle_safe(struct tty_struct *tty) tty 192 drivers/tty/tty_ioctl.c mutex_lock(&tty->throttle_mutex); tty 193 drivers/tty/tty_ioctl.c if (tty_throttled(tty)) { tty 194 drivers/tty/tty_ioctl.c if (tty->flow_change != TTY_UNTHROTTLE_SAFE) tty 197 drivers/tty/tty_ioctl.c clear_bit(TTY_THROTTLED, &tty->flags); tty 198 drivers/tty/tty_ioctl.c if (tty->ops->unthrottle) tty 199 drivers/tty/tty_ioctl.c tty->ops->unthrottle(tty); tty 202 drivers/tty/tty_ioctl.c mutex_unlock(&tty->throttle_mutex); tty 218 drivers/tty/tty_ioctl.c void tty_wait_until_sent(struct tty_struct *tty, long timeout) tty 220 drivers/tty/tty_ioctl.c tty_debug_wait_until_sent(tty, "wait until sent, timeout=%ld\n", timeout); tty 225 drivers/tty/tty_ioctl.c timeout = wait_event_interruptible_timeout(tty->write_wait, tty 226 drivers/tty/tty_ioctl.c !tty_chars_in_buffer(tty), timeout); tty 233 drivers/tty/tty_ioctl.c if (tty->ops->wait_until_sent) tty 234 drivers/tty/tty_ioctl.c tty->ops->wait_until_sent(tty, timeout); tty 243 drivers/tty/tty_ioctl.c static void unset_locked_termios(struct tty_struct *tty, struct ktermios *old) tty 245 drivers/tty/tty_ioctl.c struct ktermios *termios = &tty->termios; tty 246 drivers/tty/tty_ioctl.c struct ktermios *locked = &tty->termios_locked; tty 314 drivers/tty/tty_ioctl.c int tty_set_termios(struct tty_struct *tty, struct ktermios *new_termios) tty 319 drivers/tty/tty_ioctl.c WARN_ON(tty->driver->type == TTY_DRIVER_TYPE_PTY && tty 320 drivers/tty/tty_ioctl.c tty->driver->subtype == PTY_TYPE_MASTER); tty 328 drivers/tty/tty_ioctl.c down_write(&tty->termios_rwsem); tty 329 drivers/tty/tty_ioctl.c old_termios = tty->termios; tty 330 drivers/tty/tty_ioctl.c tty->termios = *new_termios; tty 331 drivers/tty/tty_ioctl.c unset_locked_termios(tty, &old_termios); tty 333 drivers/tty/tty_ioctl.c if (tty->ops->set_termios) tty 334 drivers/tty/tty_ioctl.c tty->ops->set_termios(tty, &old_termios); tty 336 drivers/tty/tty_ioctl.c tty_termios_copy_hw(&tty->termios, &old_termios); tty 338 drivers/tty/tty_ioctl.c ld = tty_ldisc_ref(tty); tty 341 drivers/tty/tty_ioctl.c ld->ops->set_termios(tty, &old_termios); tty 344 drivers/tty/tty_ioctl.c up_write(&tty->termios_rwsem); tty 362 drivers/tty/tty_ioctl.c static int set_termios(struct tty_struct *tty, void __user *arg, int opt) tty 366 drivers/tty/tty_ioctl.c int retval = tty_check_change(tty); tty 371 drivers/tty/tty_ioctl.c down_read(&tty->termios_rwsem); tty 372 drivers/tty/tty_ioctl.c tmp_termios = tty->termios; tty 373 drivers/tty/tty_ioctl.c up_read(&tty->termios_rwsem); tty 400 drivers/tty/tty_ioctl.c ld = tty_ldisc_ref(tty); tty 404 drivers/tty/tty_ioctl.c ld->ops->flush_buffer(tty); tty 409 drivers/tty/tty_ioctl.c tty_wait_until_sent(tty, 0); tty 414 drivers/tty/tty_ioctl.c tty_set_termios(tty, &tmp_termios); tty 423 drivers/tty/tty_ioctl.c static void copy_termios(struct tty_struct *tty, struct ktermios *kterm) tty 425 drivers/tty/tty_ioctl.c down_read(&tty->termios_rwsem); tty 426 drivers/tty/tty_ioctl.c *kterm = tty->termios; tty 427 drivers/tty/tty_ioctl.c up_read(&tty->termios_rwsem); tty 430 drivers/tty/tty_ioctl.c static void copy_termios_locked(struct tty_struct *tty, struct ktermios *kterm) tty 432 drivers/tty/tty_ioctl.c down_read(&tty->termios_rwsem); tty 433 drivers/tty/tty_ioctl.c *kterm = tty->termios_locked; tty 434 drivers/tty/tty_ioctl.c up_read(&tty->termios_rwsem); tty 437 drivers/tty/tty_ioctl.c static int get_termio(struct tty_struct *tty, struct termio __user *termio) tty 440 drivers/tty/tty_ioctl.c copy_termios(tty, &kterm); tty 459 drivers/tty/tty_ioctl.c static int set_termiox(struct tty_struct *tty, void __user *arg, int opt) tty 464 drivers/tty/tty_ioctl.c if (tty->termiox == NULL) tty 469 drivers/tty/tty_ioctl.c ld = tty_ldisc_ref(tty); tty 472 drivers/tty/tty_ioctl.c ld->ops->flush_buffer(tty); tty 476 drivers/tty/tty_ioctl.c tty_wait_until_sent(tty, 0); tty 481 drivers/tty/tty_ioctl.c down_write(&tty->termios_rwsem); tty 482 drivers/tty/tty_ioctl.c if (tty->ops->set_termiox) tty 483 drivers/tty/tty_ioctl.c tty->ops->set_termiox(tty, &tnew); tty 484 drivers/tty/tty_ioctl.c up_write(&tty->termios_rwsem); tty 497 drivers/tty/tty_ioctl.c static int get_sgflags(struct tty_struct *tty) tty 501 drivers/tty/tty_ioctl.c if (!L_ICANON(tty)) { tty 502 drivers/tty/tty_ioctl.c if (L_ISIG(tty)) tty 507 drivers/tty/tty_ioctl.c if (L_ECHO(tty)) tty 509 drivers/tty/tty_ioctl.c if (O_OPOST(tty)) tty 510 drivers/tty/tty_ioctl.c if (O_ONLCR(tty)) tty 515 drivers/tty/tty_ioctl.c static int get_sgttyb(struct tty_struct *tty, struct sgttyb __user *sgttyb) tty 519 drivers/tty/tty_ioctl.c down_read(&tty->termios_rwsem); tty 520 drivers/tty/tty_ioctl.c tmp.sg_ispeed = tty->termios.c_ispeed; tty 521 drivers/tty/tty_ioctl.c tmp.sg_ospeed = tty->termios.c_ospeed; tty 522 drivers/tty/tty_ioctl.c tmp.sg_erase = tty->termios.c_cc[VERASE]; tty 523 drivers/tty/tty_ioctl.c tmp.sg_kill = tty->termios.c_cc[VKILL]; tty 524 drivers/tty/tty_ioctl.c tmp.sg_flags = get_sgflags(tty); tty 525 drivers/tty/tty_ioctl.c up_read(&tty->termios_rwsem); tty 567 drivers/tty/tty_ioctl.c static int set_sgttyb(struct tty_struct *tty, struct sgttyb __user *sgttyb) tty 573 drivers/tty/tty_ioctl.c retval = tty_check_change(tty); tty 580 drivers/tty/tty_ioctl.c down_write(&tty->termios_rwsem); tty 581 drivers/tty/tty_ioctl.c termios = tty->termios; tty 590 drivers/tty/tty_ioctl.c up_write(&tty->termios_rwsem); tty 591 drivers/tty/tty_ioctl.c tty_set_termios(tty, &termios); tty 597 drivers/tty/tty_ioctl.c static int get_tchars(struct tty_struct *tty, struct tchars __user *tchars) tty 601 drivers/tty/tty_ioctl.c down_read(&tty->termios_rwsem); tty 602 drivers/tty/tty_ioctl.c tmp.t_intrc = tty->termios.c_cc[VINTR]; tty 603 drivers/tty/tty_ioctl.c tmp.t_quitc = tty->termios.c_cc[VQUIT]; tty 604 drivers/tty/tty_ioctl.c tmp.t_startc = tty->termios.c_cc[VSTART]; tty 605 drivers/tty/tty_ioctl.c tmp.t_stopc = tty->termios.c_cc[VSTOP]; tty 606 drivers/tty/tty_ioctl.c tmp.t_eofc = tty->termios.c_cc[VEOF]; tty 607 drivers/tty/tty_ioctl.c tmp.t_brkc = tty->termios.c_cc[VEOL2]; /* what is brkc anyway? */ tty 608 drivers/tty/tty_ioctl.c up_read(&tty->termios_rwsem); tty 612 drivers/tty/tty_ioctl.c static int set_tchars(struct tty_struct *tty, struct tchars __user *tchars) tty 618 drivers/tty/tty_ioctl.c down_write(&tty->termios_rwsem); tty 619 drivers/tty/tty_ioctl.c tty->termios.c_cc[VINTR] = tmp.t_intrc; tty 620 drivers/tty/tty_ioctl.c tty->termios.c_cc[VQUIT] = tmp.t_quitc; tty 621 drivers/tty/tty_ioctl.c tty->termios.c_cc[VSTART] = tmp.t_startc; tty 622 drivers/tty/tty_ioctl.c tty->termios.c_cc[VSTOP] = tmp.t_stopc; tty 623 drivers/tty/tty_ioctl.c tty->termios.c_cc[VEOF] = tmp.t_eofc; tty 624 drivers/tty/tty_ioctl.c tty->termios.c_cc[VEOL2] = tmp.t_brkc; /* what is brkc anyway? */ tty 625 drivers/tty/tty_ioctl.c up_write(&tty->termios_rwsem); tty 631 drivers/tty/tty_ioctl.c static int get_ltchars(struct tty_struct *tty, struct ltchars __user *ltchars) tty 635 drivers/tty/tty_ioctl.c down_read(&tty->termios_rwsem); tty 636 drivers/tty/tty_ioctl.c tmp.t_suspc = tty->termios.c_cc[VSUSP]; tty 638 drivers/tty/tty_ioctl.c tmp.t_dsuspc = tty->termios.c_cc[VSUSP]; tty 639 drivers/tty/tty_ioctl.c tmp.t_rprntc = tty->termios.c_cc[VREPRINT]; tty 641 drivers/tty/tty_ioctl.c tmp.t_flushc = tty->termios.c_cc[VEOL2]; tty 642 drivers/tty/tty_ioctl.c tmp.t_werasc = tty->termios.c_cc[VWERASE]; tty 643 drivers/tty/tty_ioctl.c tmp.t_lnextc = tty->termios.c_cc[VLNEXT]; tty 644 drivers/tty/tty_ioctl.c up_read(&tty->termios_rwsem); tty 648 drivers/tty/tty_ioctl.c static int set_ltchars(struct tty_struct *tty, struct ltchars __user *ltchars) tty 655 drivers/tty/tty_ioctl.c down_write(&tty->termios_rwsem); tty 656 drivers/tty/tty_ioctl.c tty->termios.c_cc[VSUSP] = tmp.t_suspc; tty 658 drivers/tty/tty_ioctl.c tty->termios.c_cc[VEOL2] = tmp.t_dsuspc; tty 659 drivers/tty/tty_ioctl.c tty->termios.c_cc[VREPRINT] = tmp.t_rprntc; tty 661 drivers/tty/tty_ioctl.c tty->termios.c_cc[VEOL2] = tmp.t_flushc; tty 662 drivers/tty/tty_ioctl.c tty->termios.c_cc[VWERASE] = tmp.t_werasc; tty 663 drivers/tty/tty_ioctl.c tty->termios.c_cc[VLNEXT] = tmp.t_lnextc; tty 664 drivers/tty/tty_ioctl.c up_write(&tty->termios_rwsem); tty 678 drivers/tty/tty_ioctl.c static int tty_change_softcar(struct tty_struct *tty, int arg) tty 684 drivers/tty/tty_ioctl.c down_write(&tty->termios_rwsem); tty 685 drivers/tty/tty_ioctl.c old = tty->termios; tty 686 drivers/tty/tty_ioctl.c tty->termios.c_cflag &= ~CLOCAL; tty 687 drivers/tty/tty_ioctl.c tty->termios.c_cflag |= bit; tty 688 drivers/tty/tty_ioctl.c if (tty->ops->set_termios) tty 689 drivers/tty/tty_ioctl.c tty->ops->set_termios(tty, &old); tty 690 drivers/tty/tty_ioctl.c if (C_CLOCAL(tty) != bit) tty 692 drivers/tty/tty_ioctl.c up_write(&tty->termios_rwsem); tty 708 drivers/tty/tty_ioctl.c int tty_mode_ioctl(struct tty_struct *tty, struct file *file, tty 718 drivers/tty/tty_ioctl.c if (tty->driver->type == TTY_DRIVER_TYPE_PTY && tty 719 drivers/tty/tty_ioctl.c tty->driver->subtype == PTY_TYPE_MASTER) tty 720 drivers/tty/tty_ioctl.c real_tty = tty->link; tty 722 drivers/tty/tty_ioctl.c real_tty = tty; tty 853 drivers/tty/tty_ioctl.c static int __tty_perform_flush(struct tty_struct *tty, unsigned long arg) tty 855 drivers/tty/tty_ioctl.c struct tty_ldisc *ld = tty->ldisc; tty 860 drivers/tty/tty_ioctl.c ld->ops->flush_buffer(tty); tty 861 drivers/tty/tty_ioctl.c tty_unthrottle(tty); tty 866 drivers/tty/tty_ioctl.c ld->ops->flush_buffer(tty); tty 867 drivers/tty/tty_ioctl.c tty_unthrottle(tty); tty 871 drivers/tty/tty_ioctl.c tty_driver_flush_buffer(tty); tty 879 drivers/tty/tty_ioctl.c int tty_perform_flush(struct tty_struct *tty, unsigned long arg) tty 882 drivers/tty/tty_ioctl.c int retval = tty_check_change(tty); tty 886 drivers/tty/tty_ioctl.c ld = tty_ldisc_ref_wait(tty); tty 887 drivers/tty/tty_ioctl.c retval = __tty_perform_flush(tty, arg); tty 894 drivers/tty/tty_ioctl.c int n_tty_ioctl_helper(struct tty_struct *tty, struct file *file, tty 901 drivers/tty/tty_ioctl.c retval = tty_check_change(tty); tty 906 drivers/tty/tty_ioctl.c spin_lock_irq(&tty->flow_lock); tty 907 drivers/tty/tty_ioctl.c if (!tty->flow_stopped) { tty 908 drivers/tty/tty_ioctl.c tty->flow_stopped = 1; tty 909 drivers/tty/tty_ioctl.c __stop_tty(tty); tty 911 drivers/tty/tty_ioctl.c spin_unlock_irq(&tty->flow_lock); tty 914 drivers/tty/tty_ioctl.c spin_lock_irq(&tty->flow_lock); tty 915 drivers/tty/tty_ioctl.c if (tty->flow_stopped) { tty 916 drivers/tty/tty_ioctl.c tty->flow_stopped = 0; tty 917 drivers/tty/tty_ioctl.c __start_tty(tty); tty 919 drivers/tty/tty_ioctl.c spin_unlock_irq(&tty->flow_lock); tty 922 drivers/tty/tty_ioctl.c if (STOP_CHAR(tty) != __DISABLED_CHAR) tty 923 drivers/tty/tty_ioctl.c retval = tty_send_xchar(tty, STOP_CHAR(tty)); tty 926 drivers/tty/tty_ioctl.c if (START_CHAR(tty) != __DISABLED_CHAR) tty 927 drivers/tty/tty_ioctl.c retval = tty_send_xchar(tty, START_CHAR(tty)); tty 934 drivers/tty/tty_ioctl.c retval = tty_check_change(tty); tty 937 drivers/tty/tty_ioctl.c return __tty_perform_flush(tty, arg); tty 940 drivers/tty/tty_ioctl.c return tty_mode_ioctl(tty, file, cmd, arg); tty 31 drivers/tty/tty_jobctrl.c int __tty_check_change(struct tty_struct *tty, int sig) tty 37 drivers/tty/tty_jobctrl.c if (current->signal->tty != tty) tty 43 drivers/tty/tty_jobctrl.c spin_lock_irqsave(&tty->ctrl_lock, flags); tty 44 drivers/tty/tty_jobctrl.c tty_pgrp = tty->pgrp; tty 45 drivers/tty/tty_jobctrl.c spin_unlock_irqrestore(&tty->ctrl_lock, flags); tty 62 drivers/tty/tty_jobctrl.c tty_warn(tty, "sig=%d, tty->pgrp == NULL!\n", sig); tty 67 drivers/tty/tty_jobctrl.c int tty_check_change(struct tty_struct *tty) tty 69 drivers/tty/tty_jobctrl.c return __tty_check_change(tty, SIGTTOU); tty 76 drivers/tty/tty_jobctrl.c struct tty_struct *tty; tty 78 drivers/tty/tty_jobctrl.c tty = p->signal->tty; tty 79 drivers/tty/tty_jobctrl.c p->signal->tty = NULL; tty 81 drivers/tty/tty_jobctrl.c tty_kref_put(tty); tty 94 drivers/tty/tty_jobctrl.c static void __proc_set_tty(struct tty_struct *tty) tty 98 drivers/tty/tty_jobctrl.c spin_lock_irqsave(&tty->ctrl_lock, flags); tty 103 drivers/tty/tty_jobctrl.c put_pid(tty->session); tty 104 drivers/tty/tty_jobctrl.c put_pid(tty->pgrp); tty 105 drivers/tty/tty_jobctrl.c tty->pgrp = get_pid(task_pgrp(current)); tty 106 drivers/tty/tty_jobctrl.c spin_unlock_irqrestore(&tty->ctrl_lock, flags); tty 107 drivers/tty/tty_jobctrl.c tty->session = get_pid(task_session(current)); tty 108 drivers/tty/tty_jobctrl.c if (current->signal->tty) { tty 109 drivers/tty/tty_jobctrl.c tty_debug(tty, "current tty %s not NULL!!\n", tty 110 drivers/tty/tty_jobctrl.c current->signal->tty->name); tty 111 drivers/tty/tty_jobctrl.c tty_kref_put(current->signal->tty); tty 114 drivers/tty/tty_jobctrl.c current->signal->tty = tty_kref_get(tty); tty 118 drivers/tty/tty_jobctrl.c static void proc_set_tty(struct tty_struct *tty) tty 121 drivers/tty/tty_jobctrl.c __proc_set_tty(tty); tty 128 drivers/tty/tty_jobctrl.c void tty_open_proc_set_tty(struct file *filp, struct tty_struct *tty) tty 133 drivers/tty/tty_jobctrl.c !current->signal->tty && tty 134 drivers/tty/tty_jobctrl.c tty->session == NULL) { tty 150 drivers/tty/tty_jobctrl.c __proc_set_tty(tty); tty 158 drivers/tty/tty_jobctrl.c struct tty_struct *tty; tty 162 drivers/tty/tty_jobctrl.c tty = tty_kref_get(current->signal->tty); tty 164 drivers/tty/tty_jobctrl.c return tty; tty 191 drivers/tty/tty_jobctrl.c int tty_signal_session_leader(struct tty_struct *tty, int exit_session) tty 198 drivers/tty/tty_jobctrl.c if (tty->session) { tty 199 drivers/tty/tty_jobctrl.c do_each_pid_task(tty->session, PIDTYPE_SID, p) { tty 201 drivers/tty/tty_jobctrl.c if (p->signal->tty == tty) { tty 202 drivers/tty/tty_jobctrl.c p->signal->tty = NULL; tty 214 drivers/tty/tty_jobctrl.c spin_lock(&tty->ctrl_lock); tty 215 drivers/tty/tty_jobctrl.c tty_pgrp = get_pid(tty->pgrp); tty 216 drivers/tty/tty_jobctrl.c if (tty->pgrp) tty 217 drivers/tty/tty_jobctrl.c p->signal->tty_old_pgrp = get_pid(tty->pgrp); tty 218 drivers/tty/tty_jobctrl.c spin_unlock(&tty->ctrl_lock); tty 220 drivers/tty/tty_jobctrl.c } while_each_pid_task(tty->session, PIDTYPE_SID, p); tty 259 drivers/tty/tty_jobctrl.c struct tty_struct *tty; tty 264 drivers/tty/tty_jobctrl.c tty = get_current_tty(); tty 265 drivers/tty/tty_jobctrl.c if (tty) { tty 266 drivers/tty/tty_jobctrl.c if (on_exit && tty->driver->type != TTY_DRIVER_TYPE_PTY) { tty 267 drivers/tty/tty_jobctrl.c tty_vhangup_session(tty); tty 269 drivers/tty/tty_jobctrl.c struct pid *tty_pgrp = tty_get_pgrp(tty); tty 277 drivers/tty/tty_jobctrl.c tty_kref_put(tty); tty 297 drivers/tty/tty_jobctrl.c tty = tty_kref_get(current->signal->tty); tty 298 drivers/tty/tty_jobctrl.c if (tty) { tty 300 drivers/tty/tty_jobctrl.c spin_lock_irqsave(&tty->ctrl_lock, flags); tty 301 drivers/tty/tty_jobctrl.c put_pid(tty->session); tty 302 drivers/tty/tty_jobctrl.c put_pid(tty->pgrp); tty 303 drivers/tty/tty_jobctrl.c tty->session = NULL; tty 304 drivers/tty/tty_jobctrl.c tty->pgrp = NULL; tty 305 drivers/tty/tty_jobctrl.c spin_unlock_irqrestore(&tty->ctrl_lock, flags); tty 306 drivers/tty/tty_jobctrl.c tty_kref_put(tty); tty 343 drivers/tty/tty_jobctrl.c static int tiocsctty(struct tty_struct *tty, struct file *file, int arg) tty 347 drivers/tty/tty_jobctrl.c tty_lock(tty); tty 350 drivers/tty/tty_jobctrl.c if (current->signal->leader && (task_session(current) == tty->session)) tty 357 drivers/tty/tty_jobctrl.c if (!current->signal->leader || current->signal->tty) { tty 362 drivers/tty/tty_jobctrl.c if (tty->session) { tty 371 drivers/tty/tty_jobctrl.c session_clear_tty(tty->session); tty 384 drivers/tty/tty_jobctrl.c proc_set_tty(tty); tty 387 drivers/tty/tty_jobctrl.c tty_unlock(tty); tty 398 drivers/tty/tty_jobctrl.c struct pid *tty_get_pgrp(struct tty_struct *tty) tty 403 drivers/tty/tty_jobctrl.c spin_lock_irqsave(&tty->ctrl_lock, flags); tty 404 drivers/tty/tty_jobctrl.c pgrp = get_pid(tty->pgrp); tty 405 drivers/tty/tty_jobctrl.c spin_unlock_irqrestore(&tty->ctrl_lock, flags); tty 443 drivers/tty/tty_jobctrl.c static int tiocgpgrp(struct tty_struct *tty, struct tty_struct *real_tty, pid_t __user *p) tty 451 drivers/tty/tty_jobctrl.c if (tty == real_tty && current->signal->tty != real_tty) tty 470 drivers/tty/tty_jobctrl.c static int tiocspgrp(struct tty_struct *tty, struct tty_struct *real_tty, pid_t __user *p) tty 480 drivers/tty/tty_jobctrl.c if (!current->signal->tty || tty 481 drivers/tty/tty_jobctrl.c (current->signal->tty != real_tty) || tty 497 drivers/tty/tty_jobctrl.c spin_lock_irq(&tty->ctrl_lock); tty 500 drivers/tty/tty_jobctrl.c spin_unlock_irq(&tty->ctrl_lock); tty 517 drivers/tty/tty_jobctrl.c static int tiocgsid(struct tty_struct *tty, struct tty_struct *real_tty, pid_t __user *p) tty 523 drivers/tty/tty_jobctrl.c if (tty == real_tty && current->signal->tty != real_tty) tty 534 drivers/tty/tty_jobctrl.c long tty_jobctrl_ioctl(struct tty_struct *tty, struct tty_struct *real_tty, tty 541 drivers/tty/tty_jobctrl.c if (current->signal->tty != tty) tty 548 drivers/tty/tty_jobctrl.c return tiocgpgrp(tty, real_tty, p); tty 550 drivers/tty/tty_jobctrl.c return tiocspgrp(tty, real_tty, p); tty 552 drivers/tty/tty_jobctrl.c return tiocgsid(tty, real_tty, p); tty 26 drivers/tty/tty_ldisc.c #define tty_ldisc_debug(tty, f, args...) tty_debug(tty, f, ##args) tty 28 drivers/tty/tty_ldisc.c #define tty_ldisc_debug(tty, f, args...) tty 166 drivers/tty/tty_ldisc.c static struct tty_ldisc *tty_ldisc_get(struct tty_struct *tty, int disc) tty 194 drivers/tty/tty_ldisc.c ld->tty = tty; tty 268 drivers/tty/tty_ldisc.c struct tty_ldisc *tty_ldisc_ref_wait(struct tty_struct *tty) tty 272 drivers/tty/tty_ldisc.c ldsem_down_read(&tty->ldisc_sem, MAX_SCHEDULE_TIMEOUT); tty 273 drivers/tty/tty_ldisc.c ld = tty->ldisc; tty 275 drivers/tty/tty_ldisc.c ldsem_up_read(&tty->ldisc_sem); tty 289 drivers/tty/tty_ldisc.c struct tty_ldisc *tty_ldisc_ref(struct tty_struct *tty) tty 293 drivers/tty/tty_ldisc.c if (ldsem_down_read_trylock(&tty->ldisc_sem)) { tty 294 drivers/tty/tty_ldisc.c ld = tty->ldisc; tty 296 drivers/tty/tty_ldisc.c ldsem_up_read(&tty->ldisc_sem); tty 312 drivers/tty/tty_ldisc.c ldsem_up_read(&ld->tty->ldisc_sem); tty 318 drivers/tty/tty_ldisc.c __tty_ldisc_lock(struct tty_struct *tty, unsigned long timeout) tty 320 drivers/tty/tty_ldisc.c return ldsem_down_write(&tty->ldisc_sem, timeout); tty 324 drivers/tty/tty_ldisc.c __tty_ldisc_lock_nested(struct tty_struct *tty, unsigned long timeout) tty 326 drivers/tty/tty_ldisc.c return ldsem_down_write_nested(&tty->ldisc_sem, tty 330 drivers/tty/tty_ldisc.c static inline void __tty_ldisc_unlock(struct tty_struct *tty) tty 332 drivers/tty/tty_ldisc.c ldsem_up_write(&tty->ldisc_sem); tty 335 drivers/tty/tty_ldisc.c int tty_ldisc_lock(struct tty_struct *tty, unsigned long timeout) tty 340 drivers/tty/tty_ldisc.c set_bit(TTY_LDISC_CHANGING, &tty->flags); tty 341 drivers/tty/tty_ldisc.c wake_up_interruptible_all(&tty->read_wait); tty 342 drivers/tty/tty_ldisc.c wake_up_interruptible_all(&tty->write_wait); tty 344 drivers/tty/tty_ldisc.c ret = __tty_ldisc_lock(tty, timeout); tty 347 drivers/tty/tty_ldisc.c set_bit(TTY_LDISC_HALTED, &tty->flags); tty 351 drivers/tty/tty_ldisc.c void tty_ldisc_unlock(struct tty_struct *tty) tty 353 drivers/tty/tty_ldisc.c clear_bit(TTY_LDISC_HALTED, &tty->flags); tty 355 drivers/tty/tty_ldisc.c clear_bit(TTY_LDISC_CHANGING, &tty->flags); tty 356 drivers/tty/tty_ldisc.c __tty_ldisc_unlock(tty); tty 360 drivers/tty/tty_ldisc.c tty_ldisc_lock_pair_timeout(struct tty_struct *tty, struct tty_struct *tty2, tty 365 drivers/tty/tty_ldisc.c if (tty < tty2) { tty 366 drivers/tty/tty_ldisc.c ret = __tty_ldisc_lock(tty, timeout); tty 370 drivers/tty/tty_ldisc.c __tty_ldisc_unlock(tty); tty 374 drivers/tty/tty_ldisc.c WARN_ON_ONCE(tty == tty2); tty 375 drivers/tty/tty_ldisc.c if (tty2 && tty != tty2) { tty 378 drivers/tty/tty_ldisc.c ret = __tty_ldisc_lock_nested(tty, timeout); tty 383 drivers/tty/tty_ldisc.c ret = __tty_ldisc_lock(tty, timeout); tty 389 drivers/tty/tty_ldisc.c set_bit(TTY_LDISC_HALTED, &tty->flags); tty 395 drivers/tty/tty_ldisc.c static void tty_ldisc_lock_pair(struct tty_struct *tty, struct tty_struct *tty2) tty 397 drivers/tty/tty_ldisc.c tty_ldisc_lock_pair_timeout(tty, tty2, MAX_SCHEDULE_TIMEOUT); tty 400 drivers/tty/tty_ldisc.c static void tty_ldisc_unlock_pair(struct tty_struct *tty, tty 403 drivers/tty/tty_ldisc.c __tty_ldisc_unlock(tty); tty 416 drivers/tty/tty_ldisc.c void tty_ldisc_flush(struct tty_struct *tty) tty 418 drivers/tty/tty_ldisc.c struct tty_ldisc *ld = tty_ldisc_ref(tty); tty 420 drivers/tty/tty_ldisc.c tty_buffer_flush(tty, ld); tty 442 drivers/tty/tty_ldisc.c static void tty_set_termios_ldisc(struct tty_struct *tty, int disc) tty 444 drivers/tty/tty_ldisc.c down_write(&tty->termios_rwsem); tty 445 drivers/tty/tty_ldisc.c tty->termios.c_line = disc; tty 446 drivers/tty/tty_ldisc.c up_write(&tty->termios_rwsem); tty 448 drivers/tty/tty_ldisc.c tty->disc_data = NULL; tty 449 drivers/tty/tty_ldisc.c tty->receive_room = 0; tty 463 drivers/tty/tty_ldisc.c static int tty_ldisc_open(struct tty_struct *tty, struct tty_ldisc *ld) tty 465 drivers/tty/tty_ldisc.c WARN_ON(test_and_set_bit(TTY_LDISC_OPEN, &tty->flags)); tty 469 drivers/tty/tty_ldisc.c ret = ld->ops->open(tty); tty 471 drivers/tty/tty_ldisc.c clear_bit(TTY_LDISC_OPEN, &tty->flags); tty 473 drivers/tty/tty_ldisc.c tty_ldisc_debug(tty, "%p: opened\n", ld); tty 488 drivers/tty/tty_ldisc.c static void tty_ldisc_close(struct tty_struct *tty, struct tty_ldisc *ld) tty 490 drivers/tty/tty_ldisc.c lockdep_assert_held_write(&tty->ldisc_sem); tty 491 drivers/tty/tty_ldisc.c WARN_ON(!test_bit(TTY_LDISC_OPEN, &tty->flags)); tty 492 drivers/tty/tty_ldisc.c clear_bit(TTY_LDISC_OPEN, &tty->flags); tty 494 drivers/tty/tty_ldisc.c ld->ops->close(tty); tty 495 drivers/tty/tty_ldisc.c tty_ldisc_debug(tty, "%p: closed\n", ld); tty 507 drivers/tty/tty_ldisc.c static int tty_ldisc_failto(struct tty_struct *tty, int ld) tty 509 drivers/tty/tty_ldisc.c struct tty_ldisc *disc = tty_ldisc_get(tty, ld); tty 512 drivers/tty/tty_ldisc.c lockdep_assert_held_write(&tty->ldisc_sem); tty 515 drivers/tty/tty_ldisc.c tty->ldisc = disc; tty 516 drivers/tty/tty_ldisc.c tty_set_termios_ldisc(tty, ld); tty 517 drivers/tty/tty_ldisc.c if ((r = tty_ldisc_open(tty, disc)) < 0) tty 531 drivers/tty/tty_ldisc.c static void tty_ldisc_restore(struct tty_struct *tty, struct tty_ldisc *old) tty 534 drivers/tty/tty_ldisc.c if (tty_ldisc_failto(tty, old->ops->num) < 0) { tty 535 drivers/tty/tty_ldisc.c const char *name = tty_name(tty); tty 541 drivers/tty/tty_ldisc.c if (tty_ldisc_failto(tty, N_TTY) < 0 && tty 542 drivers/tty/tty_ldisc.c tty_ldisc_failto(tty, N_NULL) < 0) tty 558 drivers/tty/tty_ldisc.c int tty_set_ldisc(struct tty_struct *tty, int disc) tty 563 drivers/tty/tty_ldisc.c new_ldisc = tty_ldisc_get(tty, disc); tty 567 drivers/tty/tty_ldisc.c tty_lock(tty); tty 568 drivers/tty/tty_ldisc.c retval = tty_ldisc_lock(tty, 5 * HZ); tty 572 drivers/tty/tty_ldisc.c if (!tty->ldisc) { tty 578 drivers/tty/tty_ldisc.c if (tty->ldisc->ops->num == disc) tty 581 drivers/tty/tty_ldisc.c if (test_bit(TTY_HUPPED, &tty->flags)) { tty 587 drivers/tty/tty_ldisc.c old_ldisc = tty->ldisc; tty 590 drivers/tty/tty_ldisc.c tty_ldisc_close(tty, old_ldisc); tty 593 drivers/tty/tty_ldisc.c tty->ldisc = new_ldisc; tty 594 drivers/tty/tty_ldisc.c tty_set_termios_ldisc(tty, disc); tty 596 drivers/tty/tty_ldisc.c retval = tty_ldisc_open(tty, new_ldisc); tty 600 drivers/tty/tty_ldisc.c tty_ldisc_restore(tty, old_ldisc); tty 603 drivers/tty/tty_ldisc.c if (tty->ldisc->ops->num != old_ldisc->ops->num && tty->ops->set_ldisc) { tty 604 drivers/tty/tty_ldisc.c down_read(&tty->termios_rwsem); tty 605 drivers/tty/tty_ldisc.c tty->ops->set_ldisc(tty); tty 606 drivers/tty/tty_ldisc.c up_read(&tty->termios_rwsem); tty 616 drivers/tty/tty_ldisc.c tty_ldisc_unlock(tty); tty 620 drivers/tty/tty_ldisc.c tty_buffer_restart_work(tty->port); tty 623 drivers/tty/tty_ldisc.c tty_unlock(tty); tty 634 drivers/tty/tty_ldisc.c static void tty_ldisc_kill(struct tty_struct *tty) tty 636 drivers/tty/tty_ldisc.c lockdep_assert_held_write(&tty->ldisc_sem); tty 637 drivers/tty/tty_ldisc.c if (!tty->ldisc) tty 642 drivers/tty/tty_ldisc.c tty_ldisc_close(tty, tty->ldisc); tty 643 drivers/tty/tty_ldisc.c tty_ldisc_put(tty->ldisc); tty 645 drivers/tty/tty_ldisc.c tty->ldisc = NULL; tty 655 drivers/tty/tty_ldisc.c static void tty_reset_termios(struct tty_struct *tty) tty 657 drivers/tty/tty_ldisc.c down_write(&tty->termios_rwsem); tty 658 drivers/tty/tty_ldisc.c tty->termios = tty->driver->init_termios; tty 659 drivers/tty/tty_ldisc.c tty->termios.c_ispeed = tty_termios_input_baud_rate(&tty->termios); tty 660 drivers/tty/tty_ldisc.c tty->termios.c_ospeed = tty_termios_baud_rate(&tty->termios); tty 661 drivers/tty/tty_ldisc.c up_write(&tty->termios_rwsem); tty 679 drivers/tty/tty_ldisc.c int tty_ldisc_reinit(struct tty_struct *tty, int disc) tty 684 drivers/tty/tty_ldisc.c lockdep_assert_held_write(&tty->ldisc_sem); tty 685 drivers/tty/tty_ldisc.c ld = tty_ldisc_get(tty, disc); tty 691 drivers/tty/tty_ldisc.c if (tty->ldisc) { tty 692 drivers/tty/tty_ldisc.c tty_ldisc_close(tty, tty->ldisc); tty 693 drivers/tty/tty_ldisc.c tty_ldisc_put(tty->ldisc); tty 697 drivers/tty/tty_ldisc.c tty->ldisc = ld; tty 698 drivers/tty/tty_ldisc.c tty_set_termios_ldisc(tty, disc); tty 699 drivers/tty/tty_ldisc.c retval = tty_ldisc_open(tty, tty->ldisc); tty 701 drivers/tty/tty_ldisc.c tty_ldisc_put(tty->ldisc); tty 702 drivers/tty/tty_ldisc.c tty->ldisc = NULL; tty 722 drivers/tty/tty_ldisc.c void tty_ldisc_hangup(struct tty_struct *tty, bool reinit) tty 726 drivers/tty/tty_ldisc.c tty_ldisc_debug(tty, "%p: hangup\n", tty->ldisc); tty 728 drivers/tty/tty_ldisc.c ld = tty_ldisc_ref(tty); tty 731 drivers/tty/tty_ldisc.c ld->ops->flush_buffer(tty); tty 732 drivers/tty/tty_ldisc.c tty_driver_flush_buffer(tty); tty 733 drivers/tty/tty_ldisc.c if ((test_bit(TTY_DO_WRITE_WAKEUP, &tty->flags)) && tty 735 drivers/tty/tty_ldisc.c ld->ops->write_wakeup(tty); tty 737 drivers/tty/tty_ldisc.c ld->ops->hangup(tty); tty 741 drivers/tty/tty_ldisc.c wake_up_interruptible_poll(&tty->write_wait, EPOLLOUT); tty 742 drivers/tty/tty_ldisc.c wake_up_interruptible_poll(&tty->read_wait, EPOLLIN); tty 750 drivers/tty/tty_ldisc.c tty_ldisc_lock(tty, MAX_SCHEDULE_TIMEOUT); tty 752 drivers/tty/tty_ldisc.c if (tty->driver->flags & TTY_DRIVER_RESET_TERMIOS) tty 753 drivers/tty/tty_ldisc.c tty_reset_termios(tty); tty 755 drivers/tty/tty_ldisc.c if (tty->ldisc) { tty 757 drivers/tty/tty_ldisc.c if (tty_ldisc_reinit(tty, tty->termios.c_line) < 0 && tty 758 drivers/tty/tty_ldisc.c tty_ldisc_reinit(tty, N_TTY) < 0) tty 759 drivers/tty/tty_ldisc.c WARN_ON(tty_ldisc_reinit(tty, N_NULL) < 0); tty 761 drivers/tty/tty_ldisc.c tty_ldisc_kill(tty); tty 763 drivers/tty/tty_ldisc.c tty_ldisc_unlock(tty); tty 776 drivers/tty/tty_ldisc.c int tty_ldisc_setup(struct tty_struct *tty, struct tty_struct *o_tty) tty 778 drivers/tty/tty_ldisc.c int retval = tty_ldisc_open(tty, tty->ldisc); tty 789 drivers/tty/tty_ldisc.c tty_ldisc_close(tty, tty->ldisc); tty 804 drivers/tty/tty_ldisc.c void tty_ldisc_release(struct tty_struct *tty) tty 806 drivers/tty/tty_ldisc.c struct tty_struct *o_tty = tty->link; tty 813 drivers/tty/tty_ldisc.c tty_ldisc_lock_pair(tty, o_tty); tty 814 drivers/tty/tty_ldisc.c tty_ldisc_kill(tty); tty 817 drivers/tty/tty_ldisc.c tty_ldisc_unlock_pair(tty, o_tty); tty 822 drivers/tty/tty_ldisc.c tty_ldisc_debug(tty, "released\n"); tty 834 drivers/tty/tty_ldisc.c int tty_ldisc_init(struct tty_struct *tty) tty 836 drivers/tty/tty_ldisc.c struct tty_ldisc *ld = tty_ldisc_get(tty, N_TTY); tty 839 drivers/tty/tty_ldisc.c tty->ldisc = ld; tty 850 drivers/tty/tty_ldisc.c void tty_ldisc_deinit(struct tty_struct *tty) tty 853 drivers/tty/tty_ldisc.c if (tty->ldisc) tty 854 drivers/tty/tty_ldisc.c tty_ldisc_put(tty->ldisc); tty 855 drivers/tty/tty_ldisc.c tty->ldisc = NULL; tty 14 drivers/tty/tty_mutex.c void tty_lock(struct tty_struct *tty) tty 16 drivers/tty/tty_mutex.c if (WARN(tty->magic != TTY_MAGIC, "L Bad %p\n", tty)) tty 18 drivers/tty/tty_mutex.c tty_kref_get(tty); tty 19 drivers/tty/tty_mutex.c mutex_lock(&tty->legacy_mutex); tty 23 drivers/tty/tty_mutex.c int tty_lock_interruptible(struct tty_struct *tty) tty 27 drivers/tty/tty_mutex.c if (WARN(tty->magic != TTY_MAGIC, "L Bad %p\n", tty)) tty 29 drivers/tty/tty_mutex.c tty_kref_get(tty); tty 30 drivers/tty/tty_mutex.c ret = mutex_lock_interruptible(&tty->legacy_mutex); tty 32 drivers/tty/tty_mutex.c tty_kref_put(tty); tty 36 drivers/tty/tty_mutex.c void tty_unlock(struct tty_struct *tty) tty 38 drivers/tty/tty_mutex.c if (WARN(tty->magic != TTY_MAGIC, "U Bad %p\n", tty)) tty 40 drivers/tty/tty_mutex.c mutex_unlock(&tty->legacy_mutex); tty 41 drivers/tty/tty_mutex.c tty_kref_put(tty); tty 45 drivers/tty/tty_mutex.c void tty_lock_slave(struct tty_struct *tty) tty 47 drivers/tty/tty_mutex.c if (tty && tty != tty->link) tty 48 drivers/tty/tty_mutex.c tty_lock(tty); tty 51 drivers/tty/tty_mutex.c void tty_unlock_slave(struct tty_struct *tty) tty 53 drivers/tty/tty_mutex.c if (tty && tty != tty->link) tty 54 drivers/tty/tty_mutex.c tty_unlock(tty); tty 57 drivers/tty/tty_mutex.c void tty_set_lock_subclass(struct tty_struct *tty) tty 59 drivers/tty/tty_mutex.c lockdep_set_subclass(&tty->legacy_mutex, TTY_LOCK_SLAVE); tty 27 drivers/tty/tty_port.c struct tty_struct *tty; tty 30 drivers/tty/tty_port.c tty = READ_ONCE(port->itty); tty 31 drivers/tty/tty_port.c if (!tty) tty 34 drivers/tty/tty_port.c disc = tty_ldisc_ref(tty); tty 47 drivers/tty/tty_port.c struct tty_struct *tty = tty_port_tty_get(port); tty 49 drivers/tty/tty_port.c if (tty) { tty 50 drivers/tty/tty_port.c tty_wakeup(tty); tty 51 drivers/tty/tty_port.c tty_kref_put(tty); tty 286 drivers/tty/tty_port.c struct tty_struct *tty; tty 289 drivers/tty/tty_port.c tty = tty_kref_get(port->tty); tty 291 drivers/tty/tty_port.c return tty; tty 303 drivers/tty/tty_port.c void tty_port_tty_set(struct tty_port *port, struct tty_struct *tty) tty 308 drivers/tty/tty_port.c tty_kref_put(port->tty); tty 309 drivers/tty/tty_port.c port->tty = tty_kref_get(tty); tty 314 drivers/tty/tty_port.c static void tty_port_shutdown(struct tty_port *port, struct tty_struct *tty) tty 326 drivers/tty/tty_port.c if (tty && C_HUPCL(tty)) tty 347 drivers/tty/tty_port.c struct tty_struct *tty; tty 352 drivers/tty/tty_port.c tty = port->tty; tty 353 drivers/tty/tty_port.c if (tty) tty 354 drivers/tty/tty_port.c set_bit(TTY_IO_ERROR, &tty->flags); tty 355 drivers/tty/tty_port.c port->tty = NULL; tty 358 drivers/tty/tty_port.c tty_port_shutdown(port, tty); tty 359 drivers/tty/tty_port.c tty_kref_put(tty); tty 373 drivers/tty/tty_port.c struct tty_struct *tty = tty_port_tty_get(port); tty 375 drivers/tty/tty_port.c if (tty && (!check_clocal || !C_CLOCAL(tty))) tty 376 drivers/tty/tty_port.c tty_hangup(tty); tty 377 drivers/tty/tty_port.c tty_kref_put(tty); tty 463 drivers/tty/tty_port.c struct tty_struct *tty, struct file *filp) tty 471 drivers/tty/tty_port.c if (tty_io_error(tty)) { tty 477 drivers/tty/tty_port.c if (C_BAUD(tty)) tty 483 drivers/tty/tty_port.c if (C_CLOCAL(tty)) tty 500 drivers/tty/tty_port.c if (C_BAUD(tty) && tty_port_initialized(port)) tty 525 drivers/tty/tty_port.c tty_unlock(tty); tty 527 drivers/tty/tty_port.c tty_lock(tty); tty 544 drivers/tty/tty_port.c static void tty_port_drain_delay(struct tty_port *port, struct tty_struct *tty) tty 546 drivers/tty/tty_port.c unsigned int bps = tty_get_baud_rate(tty); tty 560 drivers/tty/tty_port.c struct tty_struct *tty, struct file *filp) tty 568 drivers/tty/tty_port.c if (tty->count == 1 && port->count != 1) { tty 569 drivers/tty/tty_port.c tty_warn(tty, "%s: tty->count = 1 port count = %d\n", __func__, tty 574 drivers/tty/tty_port.c tty_warn(tty, "%s: bad port count (%d)\n", __func__, tty 585 drivers/tty/tty_port.c tty->closing = 1; tty 589 drivers/tty/tty_port.c if (tty->flow_stopped) tty 590 drivers/tty/tty_port.c tty_driver_flush_buffer(tty); tty 592 drivers/tty/tty_port.c tty_wait_until_sent(tty, port->closing_wait); tty 594 drivers/tty/tty_port.c tty_port_drain_delay(port, tty); tty 597 drivers/tty/tty_port.c tty_ldisc_flush(tty); tty 605 drivers/tty/tty_port.c void tty_port_close_end(struct tty_port *port, struct tty_struct *tty) tty 609 drivers/tty/tty_port.c tty_ldisc_flush(tty); tty 610 drivers/tty/tty_port.c tty->closing = 0; tty 631 drivers/tty/tty_port.c void tty_port_close(struct tty_port *port, struct tty_struct *tty, tty 634 drivers/tty/tty_port.c if (tty_port_close_start(port, tty, filp) == 0) tty 636 drivers/tty/tty_port.c tty_port_shutdown(port, tty); tty 638 drivers/tty/tty_port.c set_bit(TTY_IO_ERROR, &tty->flags); tty 639 drivers/tty/tty_port.c tty_port_close_end(port, tty); tty 655 drivers/tty/tty_port.c struct tty_struct *tty) tty 657 drivers/tty/tty_port.c tty->port = port; tty 658 drivers/tty/tty_port.c return tty_standard_install(driver, tty); tty 670 drivers/tty/tty_port.c int tty_port_open(struct tty_port *port, struct tty_struct *tty, tty 676 drivers/tty/tty_port.c tty_port_tty_set(port, tty); tty 687 drivers/tty/tty_port.c clear_bit(TTY_IO_ERROR, &tty->flags); tty 689 drivers/tty/tty_port.c int retval = port->ops->activate(port, tty); tty 698 drivers/tty/tty_port.c return tty_port_block_til_ready(port, tty, filp); tty 17 drivers/tty/ttynull.c static int ttynull_open(struct tty_struct *tty, struct file *filp) tty 19 drivers/tty/ttynull.c return tty_port_open(&ttynull_port, tty, filp); tty 22 drivers/tty/ttynull.c static void ttynull_close(struct tty_struct *tty, struct file *filp) tty 24 drivers/tty/ttynull.c tty_port_close(&ttynull_port, tty, filp); tty 27 drivers/tty/ttynull.c static void ttynull_hangup(struct tty_struct *tty) tty 32 drivers/tty/ttynull.c static int ttynull_write(struct tty_struct *tty, const unsigned char *buf, tty 38 drivers/tty/ttynull.c static int ttynull_write_room(struct tty_struct *tty) tty 33 drivers/tty/vcc.c struct tty_struct *tty; /* only populated while dev is open */ tty 285 drivers/tty/vcc.c static int vcc_rx_check(struct tty_struct *tty, int size) tty 287 drivers/tty/vcc.c if (WARN_ON(!tty || !tty->port)) tty 293 drivers/tty/vcc.c if (test_bit(TTY_THROTTLED, &tty->flags) || tty 294 drivers/tty/vcc.c (tty_buffer_request_room(tty->port, VCC_BUFF_LEN) < VCC_BUFF_LEN)) tty 300 drivers/tty/vcc.c static int vcc_rx(struct tty_struct *tty, char *buf, int size) tty 304 drivers/tty/vcc.c if (WARN_ON(!tty || !tty->port)) tty 307 drivers/tty/vcc.c len = tty_insert_flip_string(tty->port, buf, size); tty 309 drivers/tty/vcc.c tty_flip_buffer_push(tty->port); tty 317 drivers/tty/vcc.c struct tty_struct *tty; tty 321 drivers/tty/vcc.c tty = port->tty; tty 322 drivers/tty/vcc.c if (!tty) { tty 330 drivers/tty/vcc.c if (!vcc_rx_check(tty, VIO_VCC_MTU_SIZE)) { tty 349 drivers/tty/vcc.c vcc_rx(tty, pkt.data, pkt.tag.stype); tty 379 drivers/tty/vcc.c if (!port->tty || port->removed) tty 402 drivers/tty/vcc.c if (!port->tty || port->removed) tty 421 drivers/tty/vcc.c struct tty_struct *tty = port->tty; tty 424 drivers/tty/vcc.c if (tty) tty 425 drivers/tty/vcc.c tty_wakeup(tty); tty 693 drivers/tty/vcc.c if (port->tty) tty 694 drivers/tty/vcc.c tty_vhangup(port->tty); tty 710 drivers/tty/vcc.c if (port->tty) { tty 739 drivers/tty/vcc.c static int vcc_open(struct tty_struct *tty, struct file *vcc_file) tty 743 drivers/tty/vcc.c if (unlikely(!tty)) { tty 748 drivers/tty/vcc.c if (tty->count > 1) tty 751 drivers/tty/vcc.c port = vcc_get_ne(tty->index); tty 766 drivers/tty/vcc.c if (unlikely(!tty->port)) { tty 771 drivers/tty/vcc.c if (unlikely(!tty->port->ops)) { tty 776 drivers/tty/vcc.c return tty_port_open(tty->port, tty, vcc_file); tty 779 drivers/tty/vcc.c static void vcc_close(struct tty_struct *tty, struct file *vcc_file) tty 781 drivers/tty/vcc.c if (unlikely(!tty)) { tty 786 drivers/tty/vcc.c if (unlikely(tty->count > 1)) tty 789 drivers/tty/vcc.c if (unlikely(!tty->port)) { tty 794 drivers/tty/vcc.c tty_port_close(tty->port, tty, vcc_file); tty 809 drivers/tty/vcc.c static void vcc_hangup(struct tty_struct *tty) tty 813 drivers/tty/vcc.c if (unlikely(!tty)) { tty 818 drivers/tty/vcc.c port = vcc_get_ne(tty->index); tty 824 drivers/tty/vcc.c if (unlikely(!tty->port)) { tty 834 drivers/tty/vcc.c tty_port_hangup(tty->port); tty 837 drivers/tty/vcc.c static int vcc_write(struct tty_struct *tty, const unsigned char *buf, tty 847 drivers/tty/vcc.c if (unlikely(!tty)) { tty 852 drivers/tty/vcc.c port = vcc_get_ne(tty->index); tty 907 drivers/tty/vcc.c static int vcc_write_room(struct tty_struct *tty) tty 912 drivers/tty/vcc.c if (unlikely(!tty)) { tty 917 drivers/tty/vcc.c port = vcc_get_ne(tty->index); tty 930 drivers/tty/vcc.c static int vcc_chars_in_buffer(struct tty_struct *tty) tty 935 drivers/tty/vcc.c if (unlikely(!tty)) { tty 940 drivers/tty/vcc.c port = vcc_get_ne(tty->index); tty 953 drivers/tty/vcc.c static int vcc_break_ctl(struct tty_struct *tty, int state) tty 958 drivers/tty/vcc.c if (unlikely(!tty)) { tty 963 drivers/tty/vcc.c port = vcc_get_ne(tty->index); tty 987 drivers/tty/vcc.c static int vcc_install(struct tty_driver *driver, struct tty_struct *tty) tty 993 drivers/tty/vcc.c if (unlikely(!tty)) { tty 998 drivers/tty/vcc.c if (tty->index >= VCC_MAX_PORTS) tty 1001 drivers/tty/vcc.c ret = tty_standard_install(driver, tty); tty 1009 drivers/tty/vcc.c port_vcc = vcc_get(tty->index, true); tty 1012 drivers/tty/vcc.c tty->port = NULL; tty 1019 drivers/tty/vcc.c tty->port = port_tty; tty 1021 drivers/tty/vcc.c port_vcc->tty = tty; tty 1028 drivers/tty/vcc.c static void vcc_cleanup(struct tty_struct *tty) tty 1032 drivers/tty/vcc.c if (unlikely(!tty)) { tty 1037 drivers/tty/vcc.c port = vcc_get(tty->index, true); tty 1039 drivers/tty/vcc.c port->tty = NULL; tty 1042 drivers/tty/vcc.c vcc_table_remove(tty->index); tty 1051 drivers/tty/vcc.c tty_port_destroy(tty->port); tty 1052 drivers/tty/vcc.c kfree(tty->port); tty 1053 drivers/tty/vcc.c tty->port = NULL; tty 488 drivers/tty/vt/keyboard.c struct tty_struct *tty = vc->port.tty; tty 490 drivers/tty/vt/keyboard.c if (rep || !tty) tty 498 drivers/tty/vt/keyboard.c if (tty->stopped) tty 499 drivers/tty/vt/keyboard.c start_tty(tty); tty 501 drivers/tty/vt/keyboard.c stop_tty(tty); tty 1359 drivers/tty/vt/keyboard.c struct tty_struct *tty; tty 1364 drivers/tty/vt/keyboard.c tty = vc->port.tty; tty 1366 drivers/tty/vt/keyboard.c if (tty && (!tty->driver_data)) { tty 1368 drivers/tty/vt/keyboard.c tty->driver_data = vc; tty 1421 drivers/tty/vt/keyboard.c (tty && !L_ECHO(tty) && tty_chars_in_buffer(tty)))) { tty 179 drivers/tty/vt/selection.c struct tty_struct *tty) tty 186 drivers/tty/vt/selection.c return set_selection_kernel(&v, tty); tty 189 drivers/tty/vt/selection.c static int __set_selection_kernel(struct tiocl_selection *v, struct tty_struct *tty) tty 214 drivers/tty/vt/selection.c mouse_report(tty, v->sel_mode & TIOCL_SELBUTTONMASK, v->xs, tty 348 drivers/tty/vt/selection.c int set_selection_kernel(struct tiocl_selection *v, struct tty_struct *tty) tty 354 drivers/tty/vt/selection.c ret = __set_selection_kernel(v, tty); tty 369 drivers/tty/vt/selection.c int paste_selection(struct tty_struct *tty) tty 371 drivers/tty/vt/selection.c struct vc_data *vc = tty->driver_data; tty 382 drivers/tty/vt/selection.c ld = tty_ldisc_ref_wait(tty); tty 395 drivers/tty/vt/selection.c if (tty_throttled(tty)) { tty 157 drivers/tty/vt/vt.c static void con_flush_chars(struct tty_struct *tty); tty 1185 drivers/tty/vt/vt.c static int vc_do_resize(struct tty_struct *tty, struct vc_data *vc, tty 1302 drivers/tty/vt/vt.c if (tty) { tty 1310 drivers/tty/vt/vt.c tty_do_resize(tty, &ws); tty 1334 drivers/tty/vt/vt.c return vc_do_resize(vc->port.tty, vc, cols, rows); tty 1349 drivers/tty/vt/vt.c static int vt_resize(struct tty_struct *tty, struct winsize *ws) tty 1351 drivers/tty/vt/vt.c struct vc_data *vc = tty->driver_data; tty 1355 drivers/tty/vt/vt.c ret = vc_do_resize(tty, vc, ws->ws_col, ws->ws_row); tty 1818 drivers/tty/vt/vt.c static void cursor_report(struct vc_data *vc, struct tty_struct *tty) tty 1823 drivers/tty/vt/vt.c respond_string(buf, tty->port); tty 1826 drivers/tty/vt/vt.c static inline void status_report(struct tty_struct *tty) tty 1828 drivers/tty/vt/vt.c respond_string("\033[0n", tty->port); /* Terminal ok */ tty 1831 drivers/tty/vt/vt.c static inline void respond_ID(struct tty_struct *tty) tty 1833 drivers/tty/vt/vt.c respond_string(VT102ID, tty->port); tty 1836 drivers/tty/vt/vt.c void mouse_report(struct tty_struct *tty, int butt, int mrx, int mry) tty 1842 drivers/tty/vt/vt.c respond_string(buf, tty->port); tty 2120 drivers/tty/vt/vt.c static void do_con_trol(struct tty_struct *tty, struct vc_data *vc, int c) tty 2208 drivers/tty/vt/vt.c respond_ID(tty); tty 2338 drivers/tty/vt/vt.c status_report(tty); tty 2340 drivers/tty/vt/vt.c cursor_report(vc, tty); tty 2413 drivers/tty/vt/vt.c respond_ID(tty); tty 2582 drivers/tty/vt/vt.c static int do_con_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 2601 drivers/tty/vt/vt.c vc = tty->driver_data; tty 2625 drivers/tty/vt/vt.c while (!tty->stopped && count) { tty 2827 drivers/tty/vt/vt.c do_con_trol(tty, vc, orig); tty 3052 drivers/tty/vt/vt.c int tioclinux(struct tty_struct *tty, unsigned long arg) tty 3059 drivers/tty/vt/vt.c if (current->signal->tty != tty && !capable(CAP_SYS_ADMIN)) tty 3069 drivers/tty/vt/vt.c __user *)(p+1), tty); tty 3072 drivers/tty/vt/vt.c ret = paste_selection(tty); tty 3159 drivers/tty/vt/vt.c static int con_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 3163 drivers/tty/vt/vt.c retval = do_con_write(tty, buf, count); tty 3164 drivers/tty/vt/vt.c con_flush_chars(tty); tty 3169 drivers/tty/vt/vt.c static int con_put_char(struct tty_struct *tty, unsigned char ch) tty 3173 drivers/tty/vt/vt.c return do_con_write(tty, &ch, 1); tty 3176 drivers/tty/vt/vt.c static int con_write_room(struct tty_struct *tty) tty 3178 drivers/tty/vt/vt.c if (tty->stopped) tty 3183 drivers/tty/vt/vt.c static int con_chars_in_buffer(struct tty_struct *tty) tty 3193 drivers/tty/vt/vt.c static void con_throttle(struct tty_struct *tty) tty 3197 drivers/tty/vt/vt.c static void con_unthrottle(struct tty_struct *tty) tty 3199 drivers/tty/vt/vt.c struct vc_data *vc = tty->driver_data; tty 3207 drivers/tty/vt/vt.c static void con_stop(struct tty_struct *tty) tty 3210 drivers/tty/vt/vt.c if (!tty) tty 3212 drivers/tty/vt/vt.c console_num = tty->index; tty 3221 drivers/tty/vt/vt.c static void con_start(struct tty_struct *tty) tty 3224 drivers/tty/vt/vt.c if (!tty) tty 3226 drivers/tty/vt/vt.c console_num = tty->index; tty 3232 drivers/tty/vt/vt.c static void con_flush_chars(struct tty_struct *tty) tty 3241 drivers/tty/vt/vt.c vc = tty->driver_data; tty 3250 drivers/tty/vt/vt.c static int con_install(struct tty_driver *driver, struct tty_struct *tty) tty 3252 drivers/tty/vt/vt.c unsigned int currcons = tty->index; tty 3264 drivers/tty/vt/vt.c if (vc->port.tty) { tty 3269 drivers/tty/vt/vt.c ret = tty_port_install(&vc->port, driver, tty); tty 3273 drivers/tty/vt/vt.c tty->driver_data = vc; tty 3274 drivers/tty/vt/vt.c vc->port.tty = tty; tty 3277 drivers/tty/vt/vt.c if (!tty->winsize.ws_row && !tty->winsize.ws_col) { tty 3278 drivers/tty/vt/vt.c tty->winsize.ws_row = vc_cons[currcons].d->vc_rows; tty 3279 drivers/tty/vt/vt.c tty->winsize.ws_col = vc_cons[currcons].d->vc_cols; tty 3282 drivers/tty/vt/vt.c tty->termios.c_iflag |= IUTF8; tty 3284 drivers/tty/vt/vt.c tty->termios.c_iflag &= ~IUTF8; tty 3290 drivers/tty/vt/vt.c static int con_open(struct tty_struct *tty, struct file *filp) tty 3297 drivers/tty/vt/vt.c static void con_close(struct tty_struct *tty, struct file *filp) tty 3302 drivers/tty/vt/vt.c static void con_shutdown(struct tty_struct *tty) tty 3304 drivers/tty/vt/vt.c struct vc_data *vc = tty->driver_data; tty 3307 drivers/tty/vt/vt.c vc->port.tty = NULL; tty 3311 drivers/tty/vt/vt.c static void con_cleanup(struct tty_struct *tty) tty 3313 drivers/tty/vt/vt.c struct vc_data *vc = tty->driver_data; tty 350 drivers/tty/vt/vt_ioctl.c int vt_ioctl(struct tty_struct *tty, tty 353 drivers/tty/vt/vt_ioctl.c struct vc_data *vc = tty->driver_data; tty 367 drivers/tty/vt/vt_ioctl.c if (current->signal->tty == tty || capable(CAP_SYS_TTY_CONFIG)) tty 372 drivers/tty/vt/vt_ioctl.c ret = tioclinux(tty, arg); tty 522 drivers/tty/vt/vt_ioctl.c tty_ldisc_flush(tty); tty 1066 drivers/tty/vt/vt_ioctl.c struct tty_struct *tty; tty 1072 drivers/tty/vt/vt_ioctl.c tty = vc->port.tty; tty 1077 drivers/tty/vt/vt_ioctl.c if (tty) tty 1078 drivers/tty/vt/vt_ioctl.c __do_SAK(tty); tty 1188 drivers/tty/vt/vt_ioctl.c long vt_compat_ioctl(struct tty_struct *tty, tty 1191 drivers/tty/vt/vt_ioctl.c struct vc_data *vc = tty->driver_data; tty 1201 drivers/tty/vt/vt_ioctl.c if (current->signal->tty == tty || capable(CAP_SYS_TTY_CONFIG)) tty 1242 drivers/tty/vt/vt_ioctl.c return vt_ioctl(tty, cmd, arg); tty 1249 drivers/tty/vt/vt_ioctl.c return vt_ioctl(tty, cmd, (unsigned long)up); tty 53 drivers/usb/class/cdc-acm.c static void acm_tty_set_termios(struct tty_struct *tty, tty 600 drivers/usb/class/cdc-acm.c static int acm_tty_install(struct tty_driver *driver, struct tty_struct *tty) tty 605 drivers/usb/class/cdc-acm.c acm = acm_get_by_minor(tty->index); tty 609 drivers/usb/class/cdc-acm.c retval = tty_standard_install(driver, tty); tty 618 drivers/usb/class/cdc-acm.c tty->termios.c_lflag &= ~ECHO; tty 620 drivers/usb/class/cdc-acm.c tty->driver_data = acm; tty 629 drivers/usb/class/cdc-acm.c static int acm_tty_open(struct tty_struct *tty, struct file *filp) tty 631 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 633 drivers/usb/class/cdc-acm.c return tty_port_open(&acm->port, tty, filp); tty 655 drivers/usb/class/cdc-acm.c static int acm_port_activate(struct tty_port *port, struct tty_struct *tty) tty 673 drivers/usb/class/cdc-acm.c set_bit(TTY_NO_WRITE_SPLIT, &tty->flags); tty 684 drivers/usb/class/cdc-acm.c acm_tty_set_termios(tty, NULL); tty 753 drivers/usb/class/cdc-acm.c static void acm_tty_cleanup(struct tty_struct *tty) tty 755 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 760 drivers/usb/class/cdc-acm.c static void acm_tty_hangup(struct tty_struct *tty) tty 762 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 767 drivers/usb/class/cdc-acm.c static void acm_tty_close(struct tty_struct *tty, struct file *filp) tty 769 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 771 drivers/usb/class/cdc-acm.c tty_port_close(&acm->port, tty, filp); tty 774 drivers/usb/class/cdc-acm.c static int acm_tty_write(struct tty_struct *tty, tty 777 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 828 drivers/usb/class/cdc-acm.c static int acm_tty_write_room(struct tty_struct *tty) tty 830 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 838 drivers/usb/class/cdc-acm.c static int acm_tty_chars_in_buffer(struct tty_struct *tty) tty 840 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 853 drivers/usb/class/cdc-acm.c static void acm_tty_throttle(struct tty_struct *tty) tty 855 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 860 drivers/usb/class/cdc-acm.c static void acm_tty_unthrottle(struct tty_struct *tty) tty 862 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 872 drivers/usb/class/cdc-acm.c static int acm_tty_break_ctl(struct tty_struct *tty, int state) tty 874 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 884 drivers/usb/class/cdc-acm.c static int acm_tty_tiocmget(struct tty_struct *tty) tty 886 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 896 drivers/usb/class/cdc-acm.c static int acm_tty_tiocmset(struct tty_struct *tty, tty 899 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 915 drivers/usb/class/cdc-acm.c static int get_serial_info(struct tty_struct *tty, struct serial_struct *ss) tty 917 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 928 drivers/usb/class/cdc-acm.c static int set_serial_info(struct tty_struct *tty, struct serial_struct *ss) tty 930 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 1006 drivers/usb/class/cdc-acm.c static int acm_tty_get_icount(struct tty_struct *tty, tty 1009 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 1022 drivers/usb/class/cdc-acm.c static int acm_tty_ioctl(struct tty_struct *tty, tty 1025 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 1043 drivers/usb/class/cdc-acm.c static void acm_tty_set_termios(struct tty_struct *tty, tty 1046 drivers/usb/class/cdc-acm.c struct acm *acm = tty->driver_data; tty 1047 drivers/usb/class/cdc-acm.c struct ktermios *termios = &tty->termios; tty 1051 drivers/usb/class/cdc-acm.c newline.dwDTERate = cpu_to_le32(tty_get_baud_rate(tty)); tty 1074 drivers/usb/class/cdc-acm.c if (C_BAUD(tty) == B0) { tty 1539 drivers/usb/class/cdc-acm.c struct tty_struct *tty; tty 1560 drivers/usb/class/cdc-acm.c tty = tty_port_tty_get(&acm->port); tty 1561 drivers/usb/class/cdc-acm.c if (tty) { tty 1562 drivers/usb/class/cdc-acm.c tty_vhangup(tty); tty 1563 drivers/usb/class/cdc-acm.c tty_kref_put(tty); tty 289 drivers/usb/gadget/function/u_serial.c if (do_tty_wake && port->port.tty) tty 290 drivers/usb/gadget/function/u_serial.c tty_wakeup(port->port.tty); tty 309 drivers/usb/gadget/function/u_serial.c struct tty_struct *tty; tty 312 drivers/usb/gadget/function/u_serial.c tty = port->port.tty; tty 313 drivers/usb/gadget/function/u_serial.c if (!tty) tty 359 drivers/usb/gadget/function/u_serial.c struct tty_struct *tty; tty 366 drivers/usb/gadget/function/u_serial.c tty = port->port.tty; tty 373 drivers/usb/gadget/function/u_serial.c if (tty && tty_throttled(tty)) tty 393 drivers/usb/gadget/function/u_serial.c if (req->actual && tty) { tty 438 drivers/usb/gadget/function/u_serial.c if (!list_empty(queue) && !tty_throttled(tty)) tty 567 drivers/usb/gadget/function/u_serial.c tty_wakeup(port->port.tty); tty 587 drivers/usb/gadget/function/u_serial.c static int gs_open(struct tty_struct *tty, struct file *file) tty 589 drivers/usb/gadget/function/u_serial.c int port_num = tty->index; tty 649 drivers/usb/gadget/function/u_serial.c port->port_num, tty, file); tty 661 drivers/usb/gadget/function/u_serial.c tty->driver_data = port; tty 662 drivers/usb/gadget/function/u_serial.c port->port.tty = tty; tty 678 drivers/usb/gadget/function/u_serial.c pr_debug("gs_open: ttyGS%d (%p,%p)\n", port->port_num, tty, file); tty 699 drivers/usb/gadget/function/u_serial.c static void gs_close(struct tty_struct *tty, struct file *file) tty 701 drivers/usb/gadget/function/u_serial.c struct gs_port *port = tty->driver_data; tty 714 drivers/usb/gadget/function/u_serial.c pr_debug("gs_close: ttyGS%d (%p,%p) ...\n", port->port_num, tty, file); tty 747 drivers/usb/gadget/function/u_serial.c port->port.tty = NULL; tty 752 drivers/usb/gadget/function/u_serial.c port->port_num, tty, file); tty 759 drivers/usb/gadget/function/u_serial.c static int gs_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 761 drivers/usb/gadget/function/u_serial.c struct gs_port *port = tty->driver_data; tty 765 drivers/usb/gadget/function/u_serial.c port->port_num, tty, count); tty 778 drivers/usb/gadget/function/u_serial.c static int gs_put_char(struct tty_struct *tty, unsigned char ch) tty 780 drivers/usb/gadget/function/u_serial.c struct gs_port *port = tty->driver_data; tty 785 drivers/usb/gadget/function/u_serial.c port->port_num, tty, ch, __builtin_return_address(0)); tty 794 drivers/usb/gadget/function/u_serial.c static void gs_flush_chars(struct tty_struct *tty) tty 796 drivers/usb/gadget/function/u_serial.c struct gs_port *port = tty->driver_data; tty 799 drivers/usb/gadget/function/u_serial.c pr_vdebug("gs_flush_chars: (%d,%p)\n", port->port_num, tty); tty 807 drivers/usb/gadget/function/u_serial.c static int gs_write_room(struct tty_struct *tty) tty 809 drivers/usb/gadget/function/u_serial.c struct gs_port *port = tty->driver_data; tty 819 drivers/usb/gadget/function/u_serial.c port->port_num, tty, room); tty 824 drivers/usb/gadget/function/u_serial.c static int gs_chars_in_buffer(struct tty_struct *tty) tty 826 drivers/usb/gadget/function/u_serial.c struct gs_port *port = tty->driver_data; tty 835 drivers/usb/gadget/function/u_serial.c port->port_num, tty, chars); tty 841 drivers/usb/gadget/function/u_serial.c static void gs_unthrottle(struct tty_struct *tty) tty 843 drivers/usb/gadget/function/u_serial.c struct gs_port *port = tty->driver_data; tty 858 drivers/usb/gadget/function/u_serial.c static int gs_break_ctl(struct tty_struct *tty, int duration) tty 860 drivers/usb/gadget/function/u_serial.c struct gs_port *port = tty->driver_data; tty 1373 drivers/usb/gadget/function/u_serial.c if (port->port.tty) tty 1374 drivers/usb/gadget/function/u_serial.c tty_hangup(port->port.tty); tty 60 drivers/usb/host/xhci-dbgtty.c if (do_tty_wake && port->port.tty) tty 61 drivers/usb/host/xhci-dbgtty.c tty_wakeup(port->port.tty); tty 75 drivers/usb/host/xhci-dbgtty.c if (!port->port.tty) tty 172 drivers/usb/host/xhci-dbgtty.c static int dbc_tty_install(struct tty_driver *driver, struct tty_struct *tty) tty 176 drivers/usb/host/xhci-dbgtty.c tty->driver_data = port; tty 178 drivers/usb/host/xhci-dbgtty.c return tty_port_install(&port->port, driver, tty); tty 181 drivers/usb/host/xhci-dbgtty.c static int dbc_tty_open(struct tty_struct *tty, struct file *file) tty 183 drivers/usb/host/xhci-dbgtty.c struct dbc_port *port = tty->driver_data; tty 185 drivers/usb/host/xhci-dbgtty.c return tty_port_open(&port->port, tty, file); tty 188 drivers/usb/host/xhci-dbgtty.c static void dbc_tty_close(struct tty_struct *tty, struct file *file) tty 190 drivers/usb/host/xhci-dbgtty.c struct dbc_port *port = tty->driver_data; tty 192 drivers/usb/host/xhci-dbgtty.c tty_port_close(&port->port, tty, file); tty 195 drivers/usb/host/xhci-dbgtty.c static int dbc_tty_write(struct tty_struct *tty, tty 199 drivers/usb/host/xhci-dbgtty.c struct dbc_port *port = tty->driver_data; tty 211 drivers/usb/host/xhci-dbgtty.c static int dbc_tty_put_char(struct tty_struct *tty, unsigned char ch) tty 213 drivers/usb/host/xhci-dbgtty.c struct dbc_port *port = tty->driver_data; tty 224 drivers/usb/host/xhci-dbgtty.c static void dbc_tty_flush_chars(struct tty_struct *tty) tty 226 drivers/usb/host/xhci-dbgtty.c struct dbc_port *port = tty->driver_data; tty 234 drivers/usb/host/xhci-dbgtty.c static int dbc_tty_write_room(struct tty_struct *tty) tty 236 drivers/usb/host/xhci-dbgtty.c struct dbc_port *port = tty->driver_data; tty 247 drivers/usb/host/xhci-dbgtty.c static int dbc_tty_chars_in_buffer(struct tty_struct *tty) tty 249 drivers/usb/host/xhci-dbgtty.c struct dbc_port *port = tty->driver_data; tty 260 drivers/usb/host/xhci-dbgtty.c static void dbc_tty_unthrottle(struct tty_struct *tty) tty 262 drivers/usb/host/xhci-dbgtty.c struct dbc_port *port = tty->driver_data; tty 334 drivers/usb/host/xhci-dbgtty.c struct tty_struct *tty; tty 342 drivers/usb/host/xhci-dbgtty.c tty = port->port.tty; tty 346 drivers/usb/host/xhci-dbgtty.c if (tty && tty_throttled(tty)) tty 389 drivers/usb/host/xhci-dbgtty.c if (!list_empty(queue) && tty) { tty 390 drivers/usb/host/xhci-dbgtty.c if (!tty_throttled(tty)) { tty 404 drivers/usb/host/xhci-dbgtty.c static int dbc_port_activate(struct tty_port *_port, struct tty_struct *tty) tty 192 drivers/usb/serial/ark3116.c static void ark3116_set_termios(struct tty_struct *tty, tty 198 drivers/usb/serial/ark3116.c struct ktermios *termios = &tty->termios; tty 200 drivers/usb/serial/ark3116.c int bps = tty_get_baud_rate(tty); tty 302 drivers/usb/serial/ark3116.c if (I_IXOFF(tty) || I_IXON(tty)) { tty 327 drivers/usb/serial/ark3116.c static int ark3116_open(struct tty_struct *tty, struct usb_serial_port *port) tty 338 drivers/usb/serial/ark3116.c result = usb_serial_generic_open(tty, port); tty 375 drivers/usb/serial/ark3116.c if (tty) tty 376 drivers/usb/serial/ark3116.c ark3116_set_termios(tty, port, NULL); tty 390 drivers/usb/serial/ark3116.c static int ark3116_get_serial_info(struct tty_struct *tty, tty 393 drivers/usb/serial/ark3116.c struct usb_serial_port *port = tty->driver_data; tty 402 drivers/usb/serial/ark3116.c static int ark3116_tiocmget(struct tty_struct *tty) tty 404 drivers/usb/serial/ark3116.c struct usb_serial_port *port = tty->driver_data; tty 428 drivers/usb/serial/ark3116.c static int ark3116_tiocmset(struct tty_struct *tty, tty 431 drivers/usb/serial/ark3116.c struct usb_serial_port *port = tty->driver_data; tty 464 drivers/usb/serial/ark3116.c static void ark3116_break_ctl(struct tty_struct *tty, int break_state) tty 466 drivers/usb/serial/ark3116.c struct usb_serial_port *port = tty->driver_data; tty 41 drivers/usb/serial/belkin_sa.c static int belkin_sa_open(struct tty_struct *tty, tty 46 drivers/usb/serial/belkin_sa.c static void belkin_sa_set_termios(struct tty_struct *tty, tty 48 drivers/usb/serial/belkin_sa.c static void belkin_sa_break_ctl(struct tty_struct *tty, int break_state); tty 49 drivers/usb/serial/belkin_sa.c static int belkin_sa_tiocmget(struct tty_struct *tty); tty 50 drivers/usb/serial/belkin_sa.c static int belkin_sa_tiocmset(struct tty_struct *tty, tty 147 drivers/usb/serial/belkin_sa.c static int belkin_sa_open(struct tty_struct *tty, tty 158 drivers/usb/serial/belkin_sa.c retval = usb_serial_generic_open(tty, port); tty 277 drivers/usb/serial/belkin_sa.c static void belkin_sa_set_termios(struct tty_struct *tty, tty 291 drivers/usb/serial/belkin_sa.c struct ktermios *termios = &tty->termios; tty 322 drivers/usb/serial/belkin_sa.c baud = tty_get_baud_rate(tty); tty 332 drivers/usb/serial/belkin_sa.c tty_encode_baud_rate(tty, baud, baud); tty 420 drivers/usb/serial/belkin_sa.c static void belkin_sa_break_ctl(struct tty_struct *tty, int break_state) tty 422 drivers/usb/serial/belkin_sa.c struct usb_serial_port *port = tty->driver_data; tty 429 drivers/usb/serial/belkin_sa.c static int belkin_sa_tiocmget(struct tty_struct *tty) tty 431 drivers/usb/serial/belkin_sa.c struct usb_serial_port *port = tty->driver_data; tty 443 drivers/usb/serial/belkin_sa.c static int belkin_sa_tiocmset(struct tty_struct *tty, tty 446 drivers/usb/serial/belkin_sa.c struct usb_serial_port *port = tty->driver_data; tty 99 drivers/usb/serial/ch341.c static void ch341_set_termios(struct tty_struct *tty, tty 370 drivers/usb/serial/ch341.c static int ch341_open(struct tty_struct *tty, struct usb_serial_port *port) tty 375 drivers/usb/serial/ch341.c if (tty) tty 376 drivers/usb/serial/ch341.c ch341_set_termios(tty, port, NULL); tty 392 drivers/usb/serial/ch341.c r = usb_serial_generic_open(tty, port); tty 407 drivers/usb/serial/ch341.c static void ch341_set_termios(struct tty_struct *tty, tty 417 drivers/usb/serial/ch341.c if (old_termios && !tty_termios_hw_change(&tty->termios, old_termios)) tty 420 drivers/usb/serial/ch341.c baud_rate = tty_get_baud_rate(tty); tty 424 drivers/usb/serial/ch341.c switch (C_CSIZE(tty)) { tty 439 drivers/usb/serial/ch341.c if (C_PARENB(tty)) { tty 441 drivers/usb/serial/ch341.c if (C_PARODD(tty) == 0) tty 443 drivers/usb/serial/ch341.c if (C_CMSPAR(tty)) tty 447 drivers/usb/serial/ch341.c if (C_CSTOPB(tty)) tty 456 drivers/usb/serial/ch341.c tty_termios_copy_hw(&tty->termios, old_termios); tty 463 drivers/usb/serial/ch341.c if (C_BAUD(tty) == B0) tty 472 drivers/usb/serial/ch341.c static void ch341_break_ctl(struct tty_struct *tty, int break_state) tty 476 drivers/usb/serial/ch341.c struct usb_serial_port *port = tty->driver_data; tty 515 drivers/usb/serial/ch341.c static int ch341_tiocmset(struct tty_struct *tty, tty 518 drivers/usb/serial/ch341.c struct usb_serial_port *port = tty->driver_data; tty 542 drivers/usb/serial/ch341.c struct tty_struct *tty; tty 571 drivers/usb/serial/ch341.c tty = tty_port_tty_get(&port->port); tty 572 drivers/usb/serial/ch341.c if (tty) { tty 573 drivers/usb/serial/ch341.c usb_serial_handle_dcd_change(port, tty, tty 575 drivers/usb/serial/ch341.c tty_kref_put(tty); tty 616 drivers/usb/serial/ch341.c static int ch341_tiocmget(struct tty_struct *tty) tty 618 drivers/usb/serial/ch341.c struct usb_serial_port *port = tty->driver_data; tty 67 drivers/usb/serial/console.c struct tty_struct *tty = NULL; tty 133 drivers/usb/serial/console.c tty = kzalloc(sizeof(*tty), GFP_KERNEL); tty 134 drivers/usb/serial/console.c if (!tty) { tty 138 drivers/usb/serial/console.c kref_init(&tty->kref); tty 139 drivers/usb/serial/console.c tty->driver = usb_serial_tty_driver; tty 140 drivers/usb/serial/console.c tty->index = co->index; tty 141 drivers/usb/serial/console.c init_ldsem(&tty->ldisc_sem); tty 142 drivers/usb/serial/console.c spin_lock_init(&tty->files_lock); tty 143 drivers/usb/serial/console.c INIT_LIST_HEAD(&tty->tty_files); tty 144 drivers/usb/serial/console.c kref_get(&tty->driver->kref); tty 145 drivers/usb/serial/console.c __module_get(tty->driver->owner); tty 146 drivers/usb/serial/console.c tty->ops = &usb_console_fake_tty_ops; tty 147 drivers/usb/serial/console.c tty_init_termios(tty); tty 148 drivers/usb/serial/console.c tty_port_tty_set(&port->port, tty); tty 160 drivers/usb/serial/console.c tty->termios.c_cflag = cflag; tty 161 drivers/usb/serial/console.c tty_termios_encode_baud_rate(&tty->termios, baud, baud); tty 163 drivers/usb/serial/console.c serial->type->set_termios(tty, port, &dummy); tty 166 drivers/usb/serial/console.c tty_save_termios(tty); tty 167 drivers/usb/serial/console.c tty_kref_put(tty); tty 183 drivers/usb/serial/console.c tty_kref_put(tty); tty 32 drivers/usb/serial/cp210x.c static int cp210x_open(struct tty_struct *tty, struct usb_serial_port *); tty 808 drivers/usb/serial/cp210x.c static int cp210x_open(struct tty_struct *tty, struct usb_serial_port *port) tty 819 drivers/usb/serial/cp210x.c cp210x_get_termios(tty, port); tty 822 drivers/usb/serial/cp210x.c if (tty) tty 823 drivers/usb/serial/cp210x.c cp210x_change_speed(tty, port, NULL); tty 825 drivers/usb/serial/cp210x.c return usb_serial_generic_open(tty, port); tty 889 drivers/usb/serial/cp210x.c static void cp210x_get_termios(struct tty_struct *tty, tty 894 drivers/usb/serial/cp210x.c if (tty) { tty 895 drivers/usb/serial/cp210x.c cp210x_get_termios_port(tty->driver_data, tty 896 drivers/usb/serial/cp210x.c &tty->termios.c_cflag, &baud); tty 897 drivers/usb/serial/cp210x.c tty_encode_baud_rate(tty, baud, baud); tty 1119 drivers/usb/serial/cp210x.c static void cp210x_change_speed(struct tty_struct *tty, tty 1132 drivers/usb/serial/cp210x.c baud = clamp(tty->termios.c_ospeed, priv->min_speed, priv->max_speed); tty 1148 drivers/usb/serial/cp210x.c tty_encode_baud_rate(tty, baud, baud); tty 1151 drivers/usb/serial/cp210x.c static void cp210x_set_termios(struct tty_struct *tty, tty 1158 drivers/usb/serial/cp210x.c cflag = tty->termios.c_cflag; tty 1161 drivers/usb/serial/cp210x.c if (tty->termios.c_ospeed != old_termios->c_ospeed) tty 1162 drivers/usb/serial/cp210x.c cp210x_change_speed(tty, port, old_termios); tty 1275 drivers/usb/serial/cp210x.c static int cp210x_tiocmset(struct tty_struct *tty, tty 1278 drivers/usb/serial/cp210x.c struct usb_serial_port *port = tty->driver_data; tty 1317 drivers/usb/serial/cp210x.c static int cp210x_tiocmget(struct tty_struct *tty) tty 1319 drivers/usb/serial/cp210x.c struct usb_serial_port *port = tty->driver_data; tty 1339 drivers/usb/serial/cp210x.c static void cp210x_break_ctl(struct tty_struct *tty, int break_state) tty 1341 drivers/usb/serial/cp210x.c struct usb_serial_port *port = tty->driver_data; tty 51 drivers/usb/serial/cyberjack.c static int cyberjack_open(struct tty_struct *tty, tty 54 drivers/usb/serial/cyberjack.c static int cyberjack_write(struct tty_struct *tty, tty 56 drivers/usb/serial/cyberjack.c static int cyberjack_write_room(struct tty_struct *tty); tty 135 drivers/usb/serial/cyberjack.c static int cyberjack_open(struct tty_struct *tty, tty 160 drivers/usb/serial/cyberjack.c static int cyberjack_write(struct tty_struct *tty, tty 245 drivers/usb/serial/cyberjack.c static int cyberjack_write_room(struct tty_struct *tty) tty 117 drivers/usb/serial/cypress_m8.c static int cypress_open(struct tty_struct *tty, struct usb_serial_port *port); tty 120 drivers/usb/serial/cypress_m8.c static int cypress_write(struct tty_struct *tty, struct usb_serial_port *port, tty 123 drivers/usb/serial/cypress_m8.c static int cypress_write_room(struct tty_struct *tty); tty 124 drivers/usb/serial/cypress_m8.c static void cypress_earthmate_init_termios(struct tty_struct *tty); tty 125 drivers/usb/serial/cypress_m8.c static void cypress_set_termios(struct tty_struct *tty, tty 127 drivers/usb/serial/cypress_m8.c static int cypress_tiocmget(struct tty_struct *tty); tty 128 drivers/usb/serial/cypress_m8.c static int cypress_tiocmset(struct tty_struct *tty, tty 130 drivers/usb/serial/cypress_m8.c static int cypress_chars_in_buffer(struct tty_struct *tty); tty 131 drivers/usb/serial/cypress_m8.c static void cypress_throttle(struct tty_struct *tty); tty 132 drivers/usb/serial/cypress_m8.c static void cypress_unthrottle(struct tty_struct *tty); tty 288 drivers/usb/serial/cypress_m8.c static int cypress_serial_control(struct tty_struct *tty, tty 366 drivers/usb/serial/cypress_m8.c tty_encode_baud_rate(tty, tty 577 drivers/usb/serial/cypress_m8.c static int cypress_open(struct tty_struct *tty, struct usb_serial_port *port) tty 602 drivers/usb/serial/cypress_m8.c if (tty) tty 603 drivers/usb/serial/cypress_m8.c cypress_set_termios(tty, port, NULL); tty 656 drivers/usb/serial/cypress_m8.c static int cypress_write(struct tty_struct *tty, struct usb_serial_port *port, tty 792 drivers/usb/serial/cypress_m8.c static int cypress_write_room(struct tty_struct *tty) tty 794 drivers/usb/serial/cypress_m8.c struct usb_serial_port *port = tty->driver_data; tty 808 drivers/usb/serial/cypress_m8.c static int cypress_tiocmget(struct tty_struct *tty) tty 810 drivers/usb/serial/cypress_m8.c struct usb_serial_port *port = tty->driver_data; tty 834 drivers/usb/serial/cypress_m8.c static int cypress_tiocmset(struct tty_struct *tty, tty 837 drivers/usb/serial/cypress_m8.c struct usb_serial_port *port = tty->driver_data; tty 853 drivers/usb/serial/cypress_m8.c return cypress_write(tty, port, NULL, 0); tty 856 drivers/usb/serial/cypress_m8.c static void cypress_earthmate_init_termios(struct tty_struct *tty) tty 858 drivers/usb/serial/cypress_m8.c tty_encode_baud_rate(tty, 4800, 4800); tty 861 drivers/usb/serial/cypress_m8.c static void cypress_set_termios(struct tty_struct *tty, tty 873 drivers/usb/serial/cypress_m8.c tty->termios.c_cflag &= ~(CMSPAR|CRTSCTS); tty 875 drivers/usb/serial/cypress_m8.c cflag = tty->termios.c_cflag; tty 920 drivers/usb/serial/cypress_m8.c cypress_serial_control(tty, port, tty_get_baud_rate(tty), tty 928 drivers/usb/serial/cypress_m8.c cypress_serial_control(tty, port, 0, 0, 0, 0, 0, 0, CYPRESS_GET_CONFIG); tty 938 drivers/usb/serial/cypress_m8.c tty->termios.c_iflag /* input modes - */ tty 948 drivers/usb/serial/cypress_m8.c tty->termios.c_oflag /* output modes */ tty 951 drivers/usb/serial/cypress_m8.c tty->termios.c_lflag /* line discipline modes */ tty 967 drivers/usb/serial/cypress_m8.c cypress_write(tty, port, NULL, 0); tty 973 drivers/usb/serial/cypress_m8.c static int cypress_chars_in_buffer(struct tty_struct *tty) tty 975 drivers/usb/serial/cypress_m8.c struct usb_serial_port *port = tty->driver_data; tty 989 drivers/usb/serial/cypress_m8.c static void cypress_throttle(struct tty_struct *tty) tty 991 drivers/usb/serial/cypress_m8.c struct usb_serial_port *port = tty->driver_data; tty 1000 drivers/usb/serial/cypress_m8.c static void cypress_unthrottle(struct tty_struct *tty) tty 1002 drivers/usb/serial/cypress_m8.c struct usb_serial_port *port = tty->driver_data; tty 1030 drivers/usb/serial/cypress_m8.c struct tty_struct *tty; tty 1067 drivers/usb/serial/cypress_m8.c tty = tty_port_tty_get(&port->port); tty 1068 drivers/usb/serial/cypress_m8.c if (!tty) { tty 1124 drivers/usb/serial/cypress_m8.c if (tty && !C_CLOCAL(tty) && !(priv->current_status & UART_CD)) { tty 1126 drivers/usb/serial/cypress_m8.c tty_hangup(tty); tty 1155 drivers/usb/serial/cypress_m8.c tty_kref_put(tty); tty 217 drivers/usb/serial/digi_acceleport.c static void digi_rx_throttle(struct tty_struct *tty); tty 218 drivers/usb/serial/digi_acceleport.c static void digi_rx_unthrottle(struct tty_struct *tty); tty 219 drivers/usb/serial/digi_acceleport.c static void digi_set_termios(struct tty_struct *tty, tty 221 drivers/usb/serial/digi_acceleport.c static void digi_break_ctl(struct tty_struct *tty, int break_state); tty 222 drivers/usb/serial/digi_acceleport.c static int digi_tiocmget(struct tty_struct *tty); tty 223 drivers/usb/serial/digi_acceleport.c static int digi_tiocmset(struct tty_struct *tty, unsigned int set, tty 225 drivers/usb/serial/digi_acceleport.c static int digi_write(struct tty_struct *tty, struct usb_serial_port *port, tty 228 drivers/usb/serial/digi_acceleport.c static int digi_write_room(struct tty_struct *tty); tty 229 drivers/usb/serial/digi_acceleport.c static int digi_chars_in_buffer(struct tty_struct *tty); tty 230 drivers/usb/serial/digi_acceleport.c static int digi_open(struct tty_struct *tty, struct usb_serial_port *port); tty 634 drivers/usb/serial/digi_acceleport.c static void digi_rx_throttle(struct tty_struct *tty) tty 637 drivers/usb/serial/digi_acceleport.c struct usb_serial_port *port = tty->driver_data; tty 648 drivers/usb/serial/digi_acceleport.c static void digi_rx_unthrottle(struct tty_struct *tty) tty 652 drivers/usb/serial/digi_acceleport.c struct usb_serial_port *port = tty->driver_data; tty 674 drivers/usb/serial/digi_acceleport.c static void digi_set_termios(struct tty_struct *tty, tty 679 drivers/usb/serial/digi_acceleport.c unsigned int iflag = tty->termios.c_iflag; tty 680 drivers/usb/serial/digi_acceleport.c unsigned int cflag = tty->termios.c_cflag; tty 694 drivers/usb/serial/digi_acceleport.c baud = tty_get_baud_rate(tty); tty 703 drivers/usb/serial/digi_acceleport.c if (!C_CRTSCTS(tty) || !tty_throttled(tty)) tty 741 drivers/usb/serial/digi_acceleport.c tty->termios.c_cflag &= ~CMSPAR; tty 859 drivers/usb/serial/digi_acceleport.c tty_encode_baud_rate(tty, baud, baud); tty 863 drivers/usb/serial/digi_acceleport.c static void digi_break_ctl(struct tty_struct *tty, int break_state) tty 865 drivers/usb/serial/digi_acceleport.c struct usb_serial_port *port = tty->driver_data; tty 876 drivers/usb/serial/digi_acceleport.c static int digi_tiocmget(struct tty_struct *tty) tty 878 drivers/usb/serial/digi_acceleport.c struct usb_serial_port *port = tty->driver_data; tty 890 drivers/usb/serial/digi_acceleport.c static int digi_tiocmset(struct tty_struct *tty, tty 893 drivers/usb/serial/digi_acceleport.c struct usb_serial_port *port = tty->driver_data; tty 905 drivers/usb/serial/digi_acceleport.c static int digi_write(struct tty_struct *tty, struct usb_serial_port *port, tty 1045 drivers/usb/serial/digi_acceleport.c static int digi_write_room(struct tty_struct *tty) tty 1047 drivers/usb/serial/digi_acceleport.c struct usb_serial_port *port = tty->driver_data; tty 1065 drivers/usb/serial/digi_acceleport.c static int digi_chars_in_buffer(struct tty_struct *tty) tty 1067 drivers/usb/serial/digi_acceleport.c struct usb_serial_port *port = tty->driver_data; tty 1089 drivers/usb/serial/digi_acceleport.c static int digi_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1117 drivers/usb/serial/digi_acceleport.c if (tty) { tty 1118 drivers/usb/serial/digi_acceleport.c not_termios.c_cflag = ~tty->termios.c_cflag; tty 1119 drivers/usb/serial/digi_acceleport.c not_termios.c_iflag = ~tty->termios.c_iflag; tty 1120 drivers/usb/serial/digi_acceleport.c digi_set_termios(tty, port, ¬_termios); tty 1474 drivers/usb/serial/digi_acceleport.c struct tty_struct *tty; tty 1504 drivers/usb/serial/digi_acceleport.c tty = tty_port_tty_get(&port->port); tty 1507 drivers/usb/serial/digi_acceleport.c if (tty) tty 1508 drivers/usb/serial/digi_acceleport.c rts = C_CRTSCTS(tty); tty 1510 drivers/usb/serial/digi_acceleport.c if (tty && opcode == DIGI_CMD_READ_INPUT_SIGNALS) { tty 1544 drivers/usb/serial/digi_acceleport.c tty_kref_put(tty); tty 35 drivers/usb/serial/empeg.c static void empeg_init_termios(struct tty_struct *tty); tty 78 drivers/usb/serial/empeg.c static void empeg_init_termios(struct tty_struct *tty) tty 80 drivers/usb/serial/empeg.c struct ktermios *termios = &tty->termios; tty 119 drivers/usb/serial/empeg.c tty_encode_baud_rate(tty, 115200, 115200); tty 177 drivers/usb/serial/f81232.c struct tty_struct *tty; tty 204 drivers/usb/serial/f81232.c tty = tty_port_tty_get(&port->port); tty 205 drivers/usb/serial/f81232.c if (tty) { tty 206 drivers/usb/serial/f81232.c usb_serial_handle_dcd_change(port, tty, tty 209 drivers/usb/serial/f81232.c tty_kref_put(tty); tty 379 drivers/usb/serial/f81232.c static void f81232_break_ctl(struct tty_struct *tty, int break_state) tty 381 drivers/usb/serial/f81232.c struct usb_serial_port *port = tty->driver_data; tty 413 drivers/usb/serial/f81232.c static void f81232_set_baudrate(struct tty_struct *tty, tty 429 drivers/usb/serial/f81232.c tty_encode_baud_rate(tty, baudrate, baudrate); tty 530 drivers/usb/serial/f81232.c static void f81232_set_termios(struct tty_struct *tty, tty 540 drivers/usb/serial/f81232.c if (old_termios && !tty_termios_hw_change(&tty->termios, old_termios)) tty 543 drivers/usb/serial/f81232.c if (C_BAUD(tty) == B0) tty 548 drivers/usb/serial/f81232.c baudrate = tty_get_baud_rate(tty); tty 555 drivers/usb/serial/f81232.c f81232_set_baudrate(tty, port, baudrate, old_baud); tty 558 drivers/usb/serial/f81232.c if (C_PARENB(tty)) { tty 561 drivers/usb/serial/f81232.c if (!C_PARODD(tty)) tty 564 drivers/usb/serial/f81232.c if (C_CMSPAR(tty)) tty 568 drivers/usb/serial/f81232.c if (C_CSTOPB(tty)) tty 571 drivers/usb/serial/f81232.c switch (C_CSIZE(tty)) { tty 601 drivers/usb/serial/f81232.c static int f81232_tiocmget(struct tty_struct *tty) tty 604 drivers/usb/serial/f81232.c struct usb_serial_port *port = tty->driver_data; tty 626 drivers/usb/serial/f81232.c static int f81232_tiocmset(struct tty_struct *tty, tty 629 drivers/usb/serial/f81232.c struct usb_serial_port *port = tty->driver_data; tty 634 drivers/usb/serial/f81232.c static int f81232_open(struct tty_struct *tty, struct usb_serial_port *port) tty 643 drivers/usb/serial/f81232.c if (tty) tty 644 drivers/usb/serial/f81232.c f81232_set_termios(tty, port, NULL); tty 653 drivers/usb/serial/f81232.c result = usb_serial_generic_open(tty, port); tty 695 drivers/usb/serial/f81232.c static int f81232_get_serial_info(struct tty_struct *tty, tty 698 drivers/usb/serial/f81232.c struct usb_serial_port *port = tty->driver_data; tty 562 drivers/usb/serial/f81534.c struct tty_struct *tty, u32 baudrate, u32 old_baudrate, u8 lcr) tty 576 drivers/usb/serial/f81534.c tty_encode_baud_rate(tty, baudrate, baudrate); tty 659 drivers/usb/serial/f81534.c static void f81534_break_ctl(struct tty_struct *tty, int break_state) tty 661 drivers/usb/serial/f81534.c struct usb_serial_port *port = tty->driver_data; tty 948 drivers/usb/serial/f81534.c static void f81534_set_termios(struct tty_struct *tty, tty 957 drivers/usb/serial/f81534.c if (C_BAUD(tty) == B0) tty 962 drivers/usb/serial/f81534.c if (C_PARENB(tty)) { tty 965 drivers/usb/serial/f81534.c if (!C_PARODD(tty)) tty 968 drivers/usb/serial/f81534.c if (C_CMSPAR(tty)) tty 972 drivers/usb/serial/f81534.c if (C_CSTOPB(tty)) tty 975 drivers/usb/serial/f81534.c switch (C_CSIZE(tty)) { tty 991 drivers/usb/serial/f81534.c baud = tty_get_baud_rate(tty); tty 1002 drivers/usb/serial/f81534.c status = f81534_set_port_config(port, tty, baud, old_baud, new_lcr); tty 1017 drivers/usb/serial/f81534.c struct tty_struct *tty; tty 1050 drivers/usb/serial/f81534.c tty = tty_port_tty_get(&port->port); tty 1051 drivers/usb/serial/f81534.c if (!tty) tty 1054 drivers/usb/serial/f81534.c usb_serial_handle_dcd_change(port, tty, msr & UART_MSR_DCD); tty 1055 drivers/usb/serial/f81534.c tty_kref_put(tty); tty 1078 drivers/usb/serial/f81534.c static int f81534_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1094 drivers/usb/serial/f81534.c if (tty) tty 1095 drivers/usb/serial/f81534.c f81534_set_termios(tty, port, NULL); tty 1145 drivers/usb/serial/f81534.c static int f81534_get_serial_info(struct tty_struct *tty, tty 1148 drivers/usb/serial/f81534.c struct usb_serial_port *port = tty->driver_data; tty 1443 drivers/usb/serial/f81534.c static int f81534_tiocmget(struct tty_struct *tty) tty 1445 drivers/usb/serial/f81534.c struct usb_serial_port *port = tty->driver_data; tty 1471 drivers/usb/serial/f81534.c static int f81534_tiocmset(struct tty_struct *tty, unsigned int set, tty 1474 drivers/usb/serial/f81534.c struct usb_serial_port *port = tty->driver_data; tty 1487 drivers/usb/serial/f81534.c static int f81534_write(struct tty_struct *tty, struct usb_serial_port *port, tty 1067 drivers/usb/serial/ftdi_sio.c static int ftdi_open(struct tty_struct *tty, struct usb_serial_port *port); tty 1072 drivers/usb/serial/ftdi_sio.c static void ftdi_set_termios(struct tty_struct *tty, tty 1074 drivers/usb/serial/ftdi_sio.c static int ftdi_tiocmget(struct tty_struct *tty); tty 1075 drivers/usb/serial/ftdi_sio.c static int ftdi_tiocmset(struct tty_struct *tty, tty 1077 drivers/usb/serial/ftdi_sio.c static int ftdi_ioctl(struct tty_struct *tty, tty 1079 drivers/usb/serial/ftdi_sio.c static int get_serial_info(struct tty_struct *tty, tty 1081 drivers/usb/serial/ftdi_sio.c static int set_serial_info(struct tty_struct *tty, tty 1083 drivers/usb/serial/ftdi_sio.c static void ftdi_break_ctl(struct tty_struct *tty, int break_state); tty 1265 drivers/usb/serial/ftdi_sio.c static u32 get_ftdi_divisor(struct tty_struct *tty, tty 1274 drivers/usb/serial/ftdi_sio.c baud = tty_get_baud_rate(tty); tty 1368 drivers/usb/serial/ftdi_sio.c tty_encode_baud_rate(tty, baud, baud); tty 1372 drivers/usb/serial/ftdi_sio.c static int change_speed(struct tty_struct *tty, struct usb_serial_port *port) tty 1380 drivers/usb/serial/ftdi_sio.c index_value = get_ftdi_divisor(tty, port); tty 1473 drivers/usb/serial/ftdi_sio.c static int get_serial_info(struct tty_struct *tty, tty 1476 drivers/usb/serial/ftdi_sio.c struct usb_serial_port *port = tty->driver_data; tty 1485 drivers/usb/serial/ftdi_sio.c static int set_serial_info(struct tty_struct *tty, tty 1488 drivers/usb/serial/ftdi_sio.c struct usb_serial_port *port = tty->driver_data; tty 1530 drivers/usb/serial/ftdi_sio.c change_speed(tty, port); tty 2394 drivers/usb/serial/ftdi_sio.c static int ftdi_open(struct tty_struct *tty, struct usb_serial_port *port) tty 2411 drivers/usb/serial/ftdi_sio.c if (tty) tty 2412 drivers/usb/serial/ftdi_sio.c ftdi_set_termios(tty, port, NULL); tty 2414 drivers/usb/serial/ftdi_sio.c return usb_serial_generic_open(tty, port); tty 2509 drivers/usb/serial/ftdi_sio.c struct tty_struct *tty; tty 2512 drivers/usb/serial/ftdi_sio.c tty = tty_port_tty_get(&port->port); tty 2513 drivers/usb/serial/ftdi_sio.c if (tty) tty 2514 drivers/usb/serial/ftdi_sio.c usb_serial_handle_dcd_change(port, tty, tty 2516 drivers/usb/serial/ftdi_sio.c tty_kref_put(tty); tty 2592 drivers/usb/serial/ftdi_sio.c static void ftdi_break_ctl(struct tty_struct *tty, int break_state) tty 2594 drivers/usb/serial/ftdi_sio.c struct usb_serial_port *port = tty->driver_data; tty 2640 drivers/usb/serial/ftdi_sio.c static void ftdi_set_termios(struct tty_struct *tty, tty 2646 drivers/usb/serial/ftdi_sio.c struct ktermios *termios = &tty->termios; tty 2655 drivers/usb/serial/ftdi_sio.c tty_encode_baud_rate(tty, priv->force_baud, tty 2679 drivers/usb/serial/ftdi_sio.c if (C_CSIZE(tty) == CS6) { tty 2770 drivers/usb/serial/ftdi_sio.c if (change_speed(tty, port)) tty 2782 drivers/usb/serial/ftdi_sio.c if (C_CRTSCTS(tty)) { tty 2785 drivers/usb/serial/ftdi_sio.c } else if (I_IXON(tty)) { tty 2788 drivers/usb/serial/ftdi_sio.c value = STOP_CHAR(tty) << 8 | START_CHAR(tty); tty 2874 drivers/usb/serial/ftdi_sio.c static int ftdi_tiocmget(struct tty_struct *tty) tty 2876 drivers/usb/serial/ftdi_sio.c struct usb_serial_port *port = tty->driver_data; tty 2894 drivers/usb/serial/ftdi_sio.c static int ftdi_tiocmset(struct tty_struct *tty, tty 2897 drivers/usb/serial/ftdi_sio.c struct usb_serial_port *port = tty->driver_data; tty 2902 drivers/usb/serial/ftdi_sio.c static int ftdi_ioctl(struct tty_struct *tty, tty 2905 drivers/usb/serial/ftdi_sio.c struct usb_serial_port *port = tty->driver_data; tty 904 drivers/usb/serial/garmin_gps.c static int garmin_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1041 drivers/usb/serial/garmin_gps.c static int garmin_write(struct tty_struct *tty, struct usb_serial_port *port, tty 1113 drivers/usb/serial/garmin_gps.c static int garmin_write_room(struct tty_struct *tty) tty 1115 drivers/usb/serial/garmin_gps.c struct usb_serial_port *port = tty->driver_data; tty 1316 drivers/usb/serial/garmin_gps.c static void garmin_throttle(struct tty_struct *tty) tty 1318 drivers/usb/serial/garmin_gps.c struct usb_serial_port *port = tty->driver_data; tty 1329 drivers/usb/serial/garmin_gps.c static void garmin_unthrottle(struct tty_struct *tty) tty 1331 drivers/usb/serial/garmin_gps.c struct usb_serial_port *port = tty->driver_data; tty 106 drivers/usb/serial/generic.c int usb_serial_generic_open(struct tty_struct *tty, struct usb_serial_port *port) tty 213 drivers/usb/serial/generic.c int usb_serial_generic_write(struct tty_struct *tty, tty 233 drivers/usb/serial/generic.c int usb_serial_generic_write_room(struct tty_struct *tty) tty 235 drivers/usb/serial/generic.c struct usb_serial_port *port = tty->driver_data; tty 250 drivers/usb/serial/generic.c int usb_serial_generic_chars_in_buffer(struct tty_struct *tty) tty 252 drivers/usb/serial/generic.c struct usb_serial_port *port = tty->driver_data; tty 268 drivers/usb/serial/generic.c void usb_serial_generic_wait_until_sent(struct tty_struct *tty, long timeout) tty 270 drivers/usb/serial/generic.c struct usb_serial_port *port = tty->driver_data; tty 275 drivers/usb/serial/generic.c bps = tty_get_baud_rate(tty); tty 474 drivers/usb/serial/generic.c void usb_serial_generic_throttle(struct tty_struct *tty) tty 476 drivers/usb/serial/generic.c struct usb_serial_port *port = tty->driver_data; tty 482 drivers/usb/serial/generic.c void usb_serial_generic_unthrottle(struct tty_struct *tty) tty 484 drivers/usb/serial/generic.c struct usb_serial_port *port = tty->driver_data; tty 498 drivers/usb/serial/generic.c static bool usb_serial_generic_msr_changed(struct tty_struct *tty, tty 501 drivers/usb/serial/generic.c struct usb_serial_port *port = tty->driver_data; tty 527 drivers/usb/serial/generic.c int usb_serial_generic_tiocmiwait(struct tty_struct *tty, unsigned long arg) tty 529 drivers/usb/serial/generic.c struct usb_serial_port *port = tty->driver_data; tty 539 drivers/usb/serial/generic.c usb_serial_generic_msr_changed(tty, arg, &cnow)); tty 547 drivers/usb/serial/generic.c int usb_serial_generic_get_icount(struct tty_struct *tty, tty 550 drivers/usb/serial/generic.c struct usb_serial_port *port = tty->driver_data; tty 613 drivers/usb/serial/generic.c struct tty_struct *tty, unsigned int status) tty 619 drivers/usb/serial/generic.c if (tty) { tty 620 drivers/usb/serial/generic.c struct tty_ldisc *ld = tty_ldisc_ref(tty); tty 624 drivers/usb/serial/generic.c ld->ops->dcd_change(tty, status); tty 631 drivers/usb/serial/generic.c else if (tty && !C_CLOCAL(tty)) tty 632 drivers/usb/serial/generic.c tty_hangup(tty); tty 275 drivers/usb/serial/io_edgeport.c static int edge_open(struct tty_struct *tty, struct usb_serial_port *port); tty 277 drivers/usb/serial/io_edgeport.c static int edge_write(struct tty_struct *tty, struct usb_serial_port *port, tty 279 drivers/usb/serial/io_edgeport.c static int edge_write_room(struct tty_struct *tty); tty 280 drivers/usb/serial/io_edgeport.c static int edge_chars_in_buffer(struct tty_struct *tty); tty 281 drivers/usb/serial/io_edgeport.c static void edge_throttle(struct tty_struct *tty); tty 282 drivers/usb/serial/io_edgeport.c static void edge_unthrottle(struct tty_struct *tty); tty 283 drivers/usb/serial/io_edgeport.c static void edge_set_termios(struct tty_struct *tty, tty 286 drivers/usb/serial/io_edgeport.c static int edge_ioctl(struct tty_struct *tty, tty 288 drivers/usb/serial/io_edgeport.c static void edge_break(struct tty_struct *tty, int break_state); tty 289 drivers/usb/serial/io_edgeport.c static int edge_tiocmget(struct tty_struct *tty); tty 290 drivers/usb/serial/io_edgeport.c static int edge_tiocmset(struct tty_struct *tty, tty 314 drivers/usb/serial/io_edgeport.c static void change_port_settings(struct tty_struct *tty, tty 889 drivers/usb/serial/io_edgeport.c static int edge_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1188 drivers/usb/serial/io_edgeport.c static int edge_write(struct tty_struct *tty, struct usb_serial_port *port, tty 1401 drivers/usb/serial/io_edgeport.c static int edge_write_room(struct tty_struct *tty) tty 1403 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1437 drivers/usb/serial/io_edgeport.c static int edge_chars_in_buffer(struct tty_struct *tty) tty 1439 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1471 drivers/usb/serial/io_edgeport.c static void edge_throttle(struct tty_struct *tty) tty 1473 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1486 drivers/usb/serial/io_edgeport.c if (I_IXOFF(tty)) { tty 1487 drivers/usb/serial/io_edgeport.c unsigned char stop_char = STOP_CHAR(tty); tty 1488 drivers/usb/serial/io_edgeport.c status = edge_write(tty, port, &stop_char, 1); tty 1494 drivers/usb/serial/io_edgeport.c if (C_CRTSCTS(tty)) { tty 1509 drivers/usb/serial/io_edgeport.c static void edge_unthrottle(struct tty_struct *tty) tty 1511 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1524 drivers/usb/serial/io_edgeport.c if (I_IXOFF(tty)) { tty 1525 drivers/usb/serial/io_edgeport.c unsigned char start_char = START_CHAR(tty); tty 1526 drivers/usb/serial/io_edgeport.c status = edge_write(tty, port, &start_char, 1); tty 1531 drivers/usb/serial/io_edgeport.c if (C_CRTSCTS(tty)) { tty 1544 drivers/usb/serial/io_edgeport.c static void edge_set_termios(struct tty_struct *tty, tty 1558 drivers/usb/serial/io_edgeport.c change_port_settings(tty, edge_port, old_termios); tty 1591 drivers/usb/serial/io_edgeport.c static int edge_tiocmset(struct tty_struct *tty, tty 1594 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1620 drivers/usb/serial/io_edgeport.c static int edge_tiocmget(struct tty_struct *tty) tty 1622 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1640 drivers/usb/serial/io_edgeport.c static int get_serial_info(struct tty_struct *tty, tty 1643 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1662 drivers/usb/serial/io_edgeport.c static int edge_ioctl(struct tty_struct *tty, tty 1665 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1681 drivers/usb/serial/io_edgeport.c static void edge_break(struct tty_struct *tty, int break_state) tty 1683 drivers/usb/serial/io_edgeport.c struct usb_serial_port *port = tty->driver_data; tty 1867 drivers/usb/serial/io_edgeport.c struct tty_struct *tty; tty 1921 drivers/usb/serial/io_edgeport.c tty = tty_port_tty_get(&edge_port->port->port); tty 1922 drivers/usb/serial/io_edgeport.c if (tty) { tty 1923 drivers/usb/serial/io_edgeport.c change_port_settings(tty, tty 1924 drivers/usb/serial/io_edgeport.c edge_port, &tty->termios); tty 1925 drivers/usb/serial/io_edgeport.c tty_kref_put(tty); tty 2446 drivers/usb/serial/io_edgeport.c static void change_port_settings(struct tty_struct *tty, tty 2468 drivers/usb/serial/io_edgeport.c cflag = tty->termios.c_cflag; tty 2531 drivers/usb/serial/io_edgeport.c if (I_IXOFF(tty) || I_IXON(tty)) { tty 2532 drivers/usb/serial/io_edgeport.c unsigned char stop_char = STOP_CHAR(tty); tty 2533 drivers/usb/serial/io_edgeport.c unsigned char start_char = START_CHAR(tty); tty 2544 drivers/usb/serial/io_edgeport.c if (I_IXOFF(tty)) { tty 2553 drivers/usb/serial/io_edgeport.c if (I_IXON(tty)) { tty 2593 drivers/usb/serial/io_edgeport.c baud = tty_get_baud_rate(tty); tty 2604 drivers/usb/serial/io_edgeport.c tty_encode_baud_rate(tty, baud, baud); tty 224 drivers/usb/serial/io_ti.c static void edge_set_termios(struct tty_struct *tty, tty 226 drivers/usb/serial/io_ti.c static void edge_send(struct usb_serial_port *port, struct tty_struct *tty); tty 1558 drivers/usb/serial/io_ti.c struct tty_struct *tty; tty 1581 drivers/usb/serial/io_ti.c tty = tty_port_tty_get(&edge_port->port->port); tty 1583 drivers/usb/serial/io_ti.c if (tty && C_CRTSCTS(tty)) { tty 1585 drivers/usb/serial/io_ti.c tty_wakeup(tty); tty 1587 drivers/usb/serial/io_ti.c tty_kref_put(tty); tty 1812 drivers/usb/serial/io_ti.c struct tty_struct *tty; tty 1833 drivers/usb/serial/io_ti.c tty = tty_port_tty_get(&port->port); tty 1834 drivers/usb/serial/io_ti.c edge_send(port, tty); tty 1835 drivers/usb/serial/io_ti.c tty_kref_put(tty); tty 1838 drivers/usb/serial/io_ti.c static int edge_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1866 drivers/usb/serial/io_ti.c if (tty) tty 1867 drivers/usb/serial/io_ti.c edge_set_termios(tty, port, &tty->termios); tty 2016 drivers/usb/serial/io_ti.c static int edge_write(struct tty_struct *tty, struct usb_serial_port *port, tty 2033 drivers/usb/serial/io_ti.c edge_send(port, tty); tty 2038 drivers/usb/serial/io_ti.c static void edge_send(struct usb_serial_port *port, struct tty_struct *tty) tty 2084 drivers/usb/serial/io_ti.c if (tty) tty 2085 drivers/usb/serial/io_ti.c tty_wakeup(tty); tty 2088 drivers/usb/serial/io_ti.c static int edge_write_room(struct tty_struct *tty) tty 2090 drivers/usb/serial/io_ti.c struct usb_serial_port *port = tty->driver_data; tty 2108 drivers/usb/serial/io_ti.c static int edge_chars_in_buffer(struct tty_struct *tty) tty 2110 drivers/usb/serial/io_ti.c struct usb_serial_port *port = tty->driver_data; tty 2137 drivers/usb/serial/io_ti.c static void edge_throttle(struct tty_struct *tty) tty 2139 drivers/usb/serial/io_ti.c struct usb_serial_port *port = tty->driver_data; tty 2147 drivers/usb/serial/io_ti.c if (I_IXOFF(tty)) { tty 2148 drivers/usb/serial/io_ti.c unsigned char stop_char = STOP_CHAR(tty); tty 2149 drivers/usb/serial/io_ti.c status = edge_write(tty, port, &stop_char, 1); tty 2159 drivers/usb/serial/io_ti.c if (C_CRTSCTS(tty)) tty 2164 drivers/usb/serial/io_ti.c static void edge_unthrottle(struct tty_struct *tty) tty 2166 drivers/usb/serial/io_ti.c struct usb_serial_port *port = tty->driver_data; tty 2174 drivers/usb/serial/io_ti.c if (I_IXOFF(tty)) { tty 2175 drivers/usb/serial/io_ti.c unsigned char start_char = START_CHAR(tty); tty 2176 drivers/usb/serial/io_ti.c status = edge_write(tty, port, &start_char, 1); tty 2185 drivers/usb/serial/io_ti.c if (C_CRTSCTS(tty)) { tty 2228 drivers/usb/serial/io_ti.c static void change_port_settings(struct tty_struct *tty, tty 2240 drivers/usb/serial/io_ti.c tty->termios = *old_termios; tty 2244 drivers/usb/serial/io_ti.c cflag = tty->termios.c_cflag; tty 2310 drivers/usb/serial/io_ti.c config->cXon = START_CHAR(tty); tty 2311 drivers/usb/serial/io_ti.c config->cXoff = STOP_CHAR(tty); tty 2314 drivers/usb/serial/io_ti.c if (I_IXOFF(tty)) { tty 2322 drivers/usb/serial/io_ti.c if (I_IXON(tty)) { tty 2329 drivers/usb/serial/io_ti.c tty->termios.c_cflag &= ~CMSPAR; tty 2332 drivers/usb/serial/io_ti.c baud = tty_get_baud_rate(tty); tty 2339 drivers/usb/serial/io_ti.c tty_encode_baud_rate(tty, baud, baud); tty 2371 drivers/usb/serial/io_ti.c static void edge_set_termios(struct tty_struct *tty, tty 2379 drivers/usb/serial/io_ti.c change_port_settings(tty, edge_port, old_termios); tty 2382 drivers/usb/serial/io_ti.c static int edge_tiocmset(struct tty_struct *tty, tty 2385 drivers/usb/serial/io_ti.c struct usb_serial_port *port = tty->driver_data; tty 2413 drivers/usb/serial/io_ti.c static int edge_tiocmget(struct tty_struct *tty) tty 2415 drivers/usb/serial/io_ti.c struct usb_serial_port *port = tty->driver_data; tty 2440 drivers/usb/serial/io_ti.c static int get_serial_info(struct tty_struct *tty, tty 2443 drivers/usb/serial/io_ti.c struct usb_serial_port *port = tty->driver_data; tty 2462 drivers/usb/serial/io_ti.c static void edge_break(struct tty_struct *tty, int break_state) tty 2464 drivers/usb/serial/io_ti.c struct usb_serial_port *port = tty->driver_data; tty 30 drivers/usb/serial/ipaq.c static int ipaq_open(struct tty_struct *tty, tty 515 drivers/usb/serial/ipaq.c static int ipaq_open(struct tty_struct *tty, tty 547 drivers/usb/serial/ipaq.c return usb_serial_generic_open(tty, port); tty 132 drivers/usb/serial/ipw.c static int ipw_open(struct tty_struct *tty, struct usb_serial_port *port) tty 165 drivers/usb/serial/ipw.c usb_wwan_open(tty, port); tty 48 drivers/usb/serial/ir-usb.c static int ir_write(struct tty_struct *tty, struct usb_serial_port *port, tty 50 drivers/usb/serial/ir-usb.c static int ir_write_room(struct tty_struct *tty); tty 53 drivers/usb/serial/ir-usb.c static void ir_set_termios(struct tty_struct *tty, tty 259 drivers/usb/serial/ir-usb.c static int ir_write(struct tty_struct *tty, struct usb_serial_port *port, tty 343 drivers/usb/serial/ir-usb.c static int ir_write_room(struct tty_struct *tty) tty 345 drivers/usb/serial/ir-usb.c struct usb_serial_port *port = tty->driver_data; tty 388 drivers/usb/serial/ir-usb.c static void ir_set_termios(struct tty_struct *tty, tty 397 drivers/usb/serial/ir-usb.c baud = tty_get_baud_rate(tty); tty 444 drivers/usb/serial/ir-usb.c tty_termios_copy_hw(&tty->termios, old_termios); tty 445 drivers/usb/serial/ir-usb.c tty_encode_baud_rate(tty, baud, baud); tty 115 drivers/usb/serial/iuu_phoenix.c static int iuu_tiocmset(struct tty_struct *tty, tty 118 drivers/usb/serial/iuu_phoenix.c struct usb_serial_port *port = tty->driver_data; tty 144 drivers/usb/serial/iuu_phoenix.c static int iuu_tiocmget(struct tty_struct *tty) tty 146 drivers/usb/serial/iuu_phoenix.c struct usb_serial_port *port = tty->driver_data; tty 694 drivers/usb/serial/iuu_phoenix.c static int iuu_uart_write(struct tty_struct *tty, struct usb_serial_port *port, tty 877 drivers/usb/serial/iuu_phoenix.c static void iuu_set_termios(struct tty_struct *tty, tty 882 drivers/usb/serial/iuu_phoenix.c unsigned int cflag = tty->termios.c_cflag; tty 891 drivers/usb/serial/iuu_phoenix.c baud = tty->termios.c_ospeed; tty 922 drivers/usb/serial/iuu_phoenix.c tty_termios_copy_hw(&tty->termios, old_termios); tty 926 drivers/usb/serial/iuu_phoenix.c tty_encode_baud_rate(tty, baud, baud); tty 927 drivers/usb/serial/iuu_phoenix.c tty->termios.c_cflag &= ~(supported_mask|CSIZE); tty 928 drivers/usb/serial/iuu_phoenix.c tty->termios.c_cflag |= newval | csize; tty 943 drivers/usb/serial/iuu_phoenix.c static void iuu_init_termios(struct tty_struct *tty) tty 945 drivers/usb/serial/iuu_phoenix.c tty->termios.c_cflag = B9600 | CS8 | CSTOPB | CREAD | PARENB | CLOCAL; tty 946 drivers/usb/serial/iuu_phoenix.c tty->termios.c_ispeed = 9600; tty 947 drivers/usb/serial/iuu_phoenix.c tty->termios.c_ospeed = 9600; tty 948 drivers/usb/serial/iuu_phoenix.c tty->termios.c_lflag = 0; tty 949 drivers/usb/serial/iuu_phoenix.c tty->termios.c_oflag = 0; tty 950 drivers/usb/serial/iuu_phoenix.c tty->termios.c_iflag = 0; tty 953 drivers/usb/serial/iuu_phoenix.c static int iuu_open(struct tty_struct *tty, struct usb_serial_port *port) tty 962 drivers/usb/serial/iuu_phoenix.c baud = tty->termios.c_ospeed; tty 45 drivers/usb/serial/keyspan.c static int keyspan_open(struct tty_struct *tty, struct usb_serial_port *port); tty 53 drivers/usb/serial/keyspan.c static int keyspan_write_room(struct tty_struct *tty); tty 54 drivers/usb/serial/keyspan.c static int keyspan_write(struct tty_struct *tty, struct usb_serial_port *port, tty 57 drivers/usb/serial/keyspan.c static void keyspan_set_termios(struct tty_struct *tty, tty 60 drivers/usb/serial/keyspan.c static void keyspan_break_ctl(struct tty_struct *tty, int break_state); tty 61 drivers/usb/serial/keyspan.c static int keyspan_tiocmget(struct tty_struct *tty); tty 62 drivers/usb/serial/keyspan.c static int keyspan_tiocmset(struct tty_struct *tty, unsigned int set, tty 622 drivers/usb/serial/keyspan.c static void keyspan_break_ctl(struct tty_struct *tty, int break_state) tty 624 drivers/usb/serial/keyspan.c struct usb_serial_port *port = tty->driver_data; tty 638 drivers/usb/serial/keyspan.c static void keyspan_set_termios(struct tty_struct *tty, tty 648 drivers/usb/serial/keyspan.c cflag = tty->termios.c_cflag; tty 653 drivers/usb/serial/keyspan.c baud_rate = tty_get_baud_rate(tty); tty 663 drivers/usb/serial/keyspan.c tty_encode_baud_rate(tty, baud_rate, baud_rate); tty 669 drivers/usb/serial/keyspan.c tty->termios.c_cflag &= ~CMSPAR; tty 674 drivers/usb/serial/keyspan.c static int keyspan_tiocmget(struct tty_struct *tty) tty 676 drivers/usb/serial/keyspan.c struct usb_serial_port *port = tty->driver_data; tty 690 drivers/usb/serial/keyspan.c static int keyspan_tiocmset(struct tty_struct *tty, tty 693 drivers/usb/serial/keyspan.c struct usb_serial_port *port = tty->driver_data; tty 710 drivers/usb/serial/keyspan.c static int keyspan_write(struct tty_struct *tty, tty 1476 drivers/usb/serial/keyspan.c static int keyspan_write_room(struct tty_struct *tty) tty 1478 drivers/usb/serial/keyspan.c struct usb_serial_port *port = tty->driver_data; tty 1512 drivers/usb/serial/keyspan.c static int keyspan_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1563 drivers/usb/serial/keyspan.c if (tty) { tty 1564 drivers/usb/serial/keyspan.c cflag = tty->termios.c_cflag; tty 1567 drivers/usb/serial/keyspan.c baud_rate = tty_get_baud_rate(tty); tty 205 drivers/usb/serial/keyspan_pda.c static void keyspan_pda_rx_throttle(struct tty_struct *tty) tty 213 drivers/usb/serial/keyspan_pda.c struct usb_serial_port *port = tty->driver_data; tty 219 drivers/usb/serial/keyspan_pda.c static void keyspan_pda_rx_unthrottle(struct tty_struct *tty) tty 221 drivers/usb/serial/keyspan_pda.c struct usb_serial_port *port = tty->driver_data; tty 288 drivers/usb/serial/keyspan_pda.c static void keyspan_pda_break_ctl(struct tty_struct *tty, int break_state) tty 290 drivers/usb/serial/keyspan_pda.c struct usb_serial_port *port = tty->driver_data; tty 313 drivers/usb/serial/keyspan_pda.c static void keyspan_pda_set_termios(struct tty_struct *tty, tty 339 drivers/usb/serial/keyspan_pda.c speed = tty_get_baud_rate(tty); tty 349 drivers/usb/serial/keyspan_pda.c tty_termios_copy_hw(&tty->termios, old_termios); tty 350 drivers/usb/serial/keyspan_pda.c tty_encode_baud_rate(tty, speed, speed); tty 393 drivers/usb/serial/keyspan_pda.c static int keyspan_pda_tiocmget(struct tty_struct *tty) tty 395 drivers/usb/serial/keyspan_pda.c struct usb_serial_port *port = tty->driver_data; tty 414 drivers/usb/serial/keyspan_pda.c static int keyspan_pda_tiocmset(struct tty_struct *tty, tty 417 drivers/usb/serial/keyspan_pda.c struct usb_serial_port *port = tty->driver_data; tty 439 drivers/usb/serial/keyspan_pda.c static int keyspan_pda_write(struct tty_struct *tty, tty 569 drivers/usb/serial/keyspan_pda.c static int keyspan_pda_write_room(struct tty_struct *tty) tty 571 drivers/usb/serial/keyspan_pda.c struct usb_serial_port *port = tty->driver_data; tty 581 drivers/usb/serial/keyspan_pda.c static int keyspan_pda_chars_in_buffer(struct tty_struct *tty) tty 583 drivers/usb/serial/keyspan_pda.c struct usb_serial_port *port = tty->driver_data; tty 612 drivers/usb/serial/keyspan_pda.c static int keyspan_pda_open(struct tty_struct *tty, tty 56 drivers/usb/serial/kl5kusb105.c static int klsi_105_open(struct tty_struct *tty, struct usb_serial_port *port); tty 58 drivers/usb/serial/kl5kusb105.c static void klsi_105_set_termios(struct tty_struct *tty, tty 60 drivers/usb/serial/kl5kusb105.c static int klsi_105_tiocmget(struct tty_struct *tty); tty 244 drivers/usb/serial/kl5kusb105.c static int klsi_105_open(struct tty_struct *tty, struct usb_serial_port *port) tty 280 drivers/usb/serial/kl5kusb105.c rc = usb_serial_generic_open(tty, port); tty 398 drivers/usb/serial/kl5kusb105.c static void klsi_105_set_termios(struct tty_struct *tty, tty 404 drivers/usb/serial/kl5kusb105.c unsigned int iflag = tty->termios.c_iflag; tty 406 drivers/usb/serial/kl5kusb105.c unsigned int cflag = tty->termios.c_cflag; tty 422 drivers/usb/serial/kl5kusb105.c baud = tty_get_baud_rate(tty); tty 465 drivers/usb/serial/kl5kusb105.c tty_encode_baud_rate(tty, baud, baud); tty 497 drivers/usb/serial/kl5kusb105.c tty->termios.c_cflag &= ~(PARENB|PARODD|CSTOPB); tty 507 drivers/usb/serial/kl5kusb105.c tty->termios.c_cflag &= ~CRTSCTS; tty 518 drivers/usb/serial/kl5kusb105.c static int klsi_105_tiocmget(struct tty_struct *tty) tty 520 drivers/usb/serial/kl5kusb105.c struct usb_serial_port *port = tty->driver_data; tty 52 drivers/usb/serial/kobil_sct.c static int kobil_open(struct tty_struct *tty, struct usb_serial_port *port); tty 54 drivers/usb/serial/kobil_sct.c static int kobil_write(struct tty_struct *tty, struct usb_serial_port *port, tty 56 drivers/usb/serial/kobil_sct.c static int kobil_write_room(struct tty_struct *tty); tty 57 drivers/usb/serial/kobil_sct.c static int kobil_ioctl(struct tty_struct *tty, tty 59 drivers/usb/serial/kobil_sct.c static int kobil_tiocmget(struct tty_struct *tty); tty 60 drivers/usb/serial/kobil_sct.c static int kobil_tiocmset(struct tty_struct *tty, tty 64 drivers/usb/serial/kobil_sct.c static void kobil_set_termios(struct tty_struct *tty, tty 66 drivers/usb/serial/kobil_sct.c static void kobil_init_termios(struct tty_struct *tty); tty 156 drivers/usb/serial/kobil_sct.c static void kobil_init_termios(struct tty_struct *tty) tty 159 drivers/usb/serial/kobil_sct.c tty->termios.c_lflag = 0; tty 160 drivers/usb/serial/kobil_sct.c tty->termios.c_iflag &= ~(ISIG | ICANON | ECHO | IEXTEN | XCASE); tty 161 drivers/usb/serial/kobil_sct.c tty->termios.c_iflag |= IGNBRK | IGNPAR | IXOFF; tty 163 drivers/usb/serial/kobil_sct.c tty->termios.c_oflag &= ~ONLCR; tty 166 drivers/usb/serial/kobil_sct.c static int kobil_open(struct tty_struct *tty, struct usb_serial_port *port) tty 294 drivers/usb/serial/kobil_sct.c static int kobil_write(struct tty_struct *tty, struct usb_serial_port *port, tty 363 drivers/usb/serial/kobil_sct.c static int kobil_write_room(struct tty_struct *tty) tty 370 drivers/usb/serial/kobil_sct.c static int kobil_tiocmget(struct tty_struct *tty) tty 372 drivers/usb/serial/kobil_sct.c struct usb_serial_port *port = tty->driver_data; tty 418 drivers/usb/serial/kobil_sct.c static int kobil_tiocmset(struct tty_struct *tty, tty 421 drivers/usb/serial/kobil_sct.c struct usb_serial_port *port = tty->driver_data; tty 478 drivers/usb/serial/kobil_sct.c static void kobil_set_termios(struct tty_struct *tty, tty 484 drivers/usb/serial/kobil_sct.c int c_cflag = tty->termios.c_cflag; tty 491 drivers/usb/serial/kobil_sct.c tty_termios_copy_hw(&tty->termios, old); tty 495 drivers/usb/serial/kobil_sct.c speed = tty_get_baud_rate(tty); tty 516 drivers/usb/serial/kobil_sct.c tty->termios.c_cflag &= ~CMSPAR; tty 517 drivers/usb/serial/kobil_sct.c tty_encode_baud_rate(tty, speed, speed); tty 531 drivers/usb/serial/kobil_sct.c static int kobil_ioctl(struct tty_struct *tty, tty 534 drivers/usb/serial/kobil_sct.c struct usb_serial_port *port = tty->driver_data; tty 43 drivers/usb/serial/mct_u232.c static int mct_u232_open(struct tty_struct *tty, struct usb_serial_port *port); tty 47 drivers/usb/serial/mct_u232.c static void mct_u232_set_termios(struct tty_struct *tty, tty 49 drivers/usb/serial/mct_u232.c static void mct_u232_break_ctl(struct tty_struct *tty, int break_state); tty 50 drivers/usb/serial/mct_u232.c static int mct_u232_tiocmget(struct tty_struct *tty); tty 51 drivers/usb/serial/mct_u232.c static int mct_u232_tiocmset(struct tty_struct *tty, tty 53 drivers/usb/serial/mct_u232.c static void mct_u232_throttle(struct tty_struct *tty); tty 54 drivers/usb/serial/mct_u232.c static void mct_u232_unthrottle(struct tty_struct *tty); tty 174 drivers/usb/serial/mct_u232.c static int mct_u232_set_baud_rate(struct tty_struct *tty, tty 198 drivers/usb/serial/mct_u232.c tty_encode_baud_rate(tty, speed, speed); tty 229 drivers/usb/serial/mct_u232.c if (port && C_CRTSCTS(tty)) tty 413 drivers/usb/serial/mct_u232.c static int mct_u232_open(struct tty_struct *tty, struct usb_serial_port *port) tty 438 drivers/usb/serial/mct_u232.c if (tty && C_BAUD(tty)) tty 570 drivers/usb/serial/mct_u232.c tty = tty_port_tty_get(&port->port); tty 583 drivers/usb/serial/mct_u232.c tty_kref_put(tty); tty 596 drivers/usb/serial/mct_u232.c static void mct_u232_set_termios(struct tty_struct *tty, tty 602 drivers/usb/serial/mct_u232.c struct ktermios *termios = &tty->termios; tty 629 drivers/usb/serial/mct_u232.c mct_u232_set_baud_rate(tty, serial, port, tty_get_baud_rate(tty)); tty 681 drivers/usb/serial/mct_u232.c static void mct_u232_break_ctl(struct tty_struct *tty, int break_state) tty 683 drivers/usb/serial/mct_u232.c struct usb_serial_port *port = tty->driver_data; tty 699 drivers/usb/serial/mct_u232.c static int mct_u232_tiocmget(struct tty_struct *tty) tty 701 drivers/usb/serial/mct_u232.c struct usb_serial_port *port = tty->driver_data; tty 713 drivers/usb/serial/mct_u232.c static int mct_u232_tiocmset(struct tty_struct *tty, tty 716 drivers/usb/serial/mct_u232.c struct usb_serial_port *port = tty->driver_data; tty 738 drivers/usb/serial/mct_u232.c static void mct_u232_throttle(struct tty_struct *tty) tty 740 drivers/usb/serial/mct_u232.c struct usb_serial_port *port = tty->driver_data; tty 746 drivers/usb/serial/mct_u232.c if (C_CRTSCTS(tty)) { tty 756 drivers/usb/serial/mct_u232.c static void mct_u232_unthrottle(struct tty_struct *tty) tty 758 drivers/usb/serial/mct_u232.c struct usb_serial_port *port = tty->driver_data; tty 763 drivers/usb/serial/mct_u232.c if ((priv->rx_flags & THROTTLED) && C_CRTSCTS(tty)) { tty 170 drivers/usb/serial/metro-usb.c static int metrousb_open(struct tty_struct *tty, struct usb_serial_port *port) tty 269 drivers/usb/serial/metro-usb.c static void metrousb_throttle(struct tty_struct *tty) tty 271 drivers/usb/serial/metro-usb.c struct usb_serial_port *port = tty->driver_data; tty 281 drivers/usb/serial/metro-usb.c static int metrousb_tiocmget(struct tty_struct *tty) tty 284 drivers/usb/serial/metro-usb.c struct usb_serial_port *port = tty->driver_data; tty 295 drivers/usb/serial/metro-usb.c static int metrousb_tiocmset(struct tty_struct *tty, tty 298 drivers/usb/serial/metro-usb.c struct usb_serial_port *port = tty->driver_data; tty 304 drivers/usb/serial/metro-usb.c dev_dbg(tty->dev, "%s - set=%d, clear=%d\n", __func__, set, clear); tty 324 drivers/usb/serial/metro-usb.c static void metrousb_unthrottle(struct tty_struct *tty) tty 326 drivers/usb/serial/metro-usb.c struct usb_serial_port *port = tty->driver_data; tty 339 drivers/usb/serial/metro-usb.c dev_err(tty->dev, tty 996 drivers/usb/serial/mos7720.c static int mos7720_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1106 drivers/usb/serial/mos7720.c static int mos7720_chars_in_buffer(struct tty_struct *tty) tty 1108 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1160 drivers/usb/serial/mos7720.c static void mos7720_break(struct tty_struct *tty, int break_state) tty 1162 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1190 drivers/usb/serial/mos7720.c static int mos7720_write_room(struct tty_struct *tty) tty 1192 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1212 drivers/usb/serial/mos7720.c static int mos7720_write(struct tty_struct *tty, struct usb_serial_port *port, tty 1281 drivers/usb/serial/mos7720.c static void mos7720_throttle(struct tty_struct *tty) tty 1283 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1298 drivers/usb/serial/mos7720.c if (I_IXOFF(tty)) { tty 1299 drivers/usb/serial/mos7720.c unsigned char stop_char = STOP_CHAR(tty); tty 1300 drivers/usb/serial/mos7720.c status = mos7720_write(tty, port, &stop_char, 1); tty 1306 drivers/usb/serial/mos7720.c if (C_CRTSCTS(tty)) { tty 1313 drivers/usb/serial/mos7720.c static void mos7720_unthrottle(struct tty_struct *tty) tty 1315 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1328 drivers/usb/serial/mos7720.c if (I_IXOFF(tty)) { tty 1329 drivers/usb/serial/mos7720.c unsigned char start_char = START_CHAR(tty); tty 1330 drivers/usb/serial/mos7720.c status = mos7720_write(tty, port, &start_char, 1); tty 1336 drivers/usb/serial/mos7720.c if (C_CRTSCTS(tty)) { tty 1522 drivers/usb/serial/mos7720.c static void change_port_settings(struct tty_struct *tty, tty 1552 drivers/usb/serial/mos7720.c cflag = tty->termios.c_cflag; tty 1644 drivers/usb/serial/mos7720.c baud = tty_get_baud_rate(tty); tty 1663 drivers/usb/serial/mos7720.c tty_encode_baud_rate(tty, baud, baud); tty 1679 drivers/usb/serial/mos7720.c static void mos7720_set_termios(struct tty_struct *tty, tty 1696 drivers/usb/serial/mos7720.c change_port_settings(tty, mos7720_port, old_termios); tty 1715 drivers/usb/serial/mos7720.c static int get_lsr_info(struct tty_struct *tty, tty 1718 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1724 drivers/usb/serial/mos7720.c count = mos7720_chars_in_buffer(tty); tty 1738 drivers/usb/serial/mos7720.c static int mos7720_tiocmget(struct tty_struct *tty) tty 1740 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1759 drivers/usb/serial/mos7720.c static int mos7720_tiocmset(struct tty_struct *tty, tty 1762 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1789 drivers/usb/serial/mos7720.c static int get_serial_info(struct tty_struct *tty, tty 1792 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1806 drivers/usb/serial/mos7720.c static int mos7720_ioctl(struct tty_struct *tty, tty 1809 drivers/usb/serial/mos7720.c struct usb_serial_port *port = tty->driver_data; tty 1819 drivers/usb/serial/mos7720.c return get_lsr_info(tty, mos7720_port, tty 842 drivers/usb/serial/mos7840.c static int mos7840_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1120 drivers/usb/serial/mos7840.c static int mos7840_chars_in_buffer(struct tty_struct *tty) tty 1122 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1210 drivers/usb/serial/mos7840.c static void mos7840_break(struct tty_struct *tty, int break_state) tty 1212 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1249 drivers/usb/serial/mos7840.c static int mos7840_write_room(struct tty_struct *tty) tty 1251 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1285 drivers/usb/serial/mos7840.c static int mos7840_write(struct tty_struct *tty, struct usb_serial_port *port, tty 1388 drivers/usb/serial/mos7840.c static void mos7840_throttle(struct tty_struct *tty) tty 1390 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1408 drivers/usb/serial/mos7840.c if (I_IXOFF(tty)) { tty 1409 drivers/usb/serial/mos7840.c unsigned char stop_char = STOP_CHAR(tty); tty 1410 drivers/usb/serial/mos7840.c status = mos7840_write(tty, port, &stop_char, 1); tty 1415 drivers/usb/serial/mos7840.c if (C_CRTSCTS(tty)) { tty 1430 drivers/usb/serial/mos7840.c static void mos7840_unthrottle(struct tty_struct *tty) tty 1432 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1448 drivers/usb/serial/mos7840.c if (I_IXOFF(tty)) { tty 1449 drivers/usb/serial/mos7840.c unsigned char start_char = START_CHAR(tty); tty 1450 drivers/usb/serial/mos7840.c status = mos7840_write(tty, port, &start_char, 1); tty 1456 drivers/usb/serial/mos7840.c if (C_CRTSCTS(tty)) { tty 1465 drivers/usb/serial/mos7840.c static int mos7840_tiocmget(struct tty_struct *tty) tty 1467 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1497 drivers/usb/serial/mos7840.c static int mos7840_tiocmset(struct tty_struct *tty, tty 1500 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1686 drivers/usb/serial/mos7840.c static void mos7840_change_port_settings(struct tty_struct *tty, tty 1718 drivers/usb/serial/mos7840.c cflag = tty->termios.c_cflag; tty 1809 drivers/usb/serial/mos7840.c baud = tty_get_baud_rate(tty); tty 1843 drivers/usb/serial/mos7840.c static void mos7840_set_termios(struct tty_struct *tty, tty 1871 drivers/usb/serial/mos7840.c mos7840_change_port_settings(tty, mos7840_port, old_termios); tty 1900 drivers/usb/serial/mos7840.c static int mos7840_get_lsr_info(struct tty_struct *tty, tty 1906 drivers/usb/serial/mos7840.c count = mos7840_chars_in_buffer(tty); tty 1920 drivers/usb/serial/mos7840.c static int mos7840_get_serial_info(struct tty_struct *tty, tty 1923 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1942 drivers/usb/serial/mos7840.c static int mos7840_ioctl(struct tty_struct *tty, tty 1945 drivers/usb/serial/mos7840.c struct usb_serial_port *port = tty->driver_data; tty 1962 drivers/usb/serial/mos7840.c return mos7840_get_lsr_info(tty, argp); tty 291 drivers/usb/serial/mxuport.c static void mxuport_throttle(struct tty_struct *tty) tty 293 drivers/usb/serial/mxuport.c struct usb_serial_port *port = tty->driver_data; tty 309 drivers/usb/serial/mxuport.c static void mxuport_unthrottle(struct tty_struct *tty) tty 312 drivers/usb/serial/mxuport.c struct usb_serial_port *port = tty->driver_data; tty 705 drivers/usb/serial/mxuport.c static int mxuport_tiocmset(struct tty_struct *tty, unsigned int set, tty 708 drivers/usb/serial/mxuport.c struct usb_serial_port *port = tty->driver_data; tty 737 drivers/usb/serial/mxuport.c static int mxuport_tiocmget(struct tty_struct *tty) tty 740 drivers/usb/serial/mxuport.c struct usb_serial_port *port = tty->driver_data; tty 769 drivers/usb/serial/mxuport.c static int mxuport_set_termios_flow(struct tty_struct *tty, tty 774 drivers/usb/serial/mxuport.c u8 xon = START_CHAR(tty); tty 775 drivers/usb/serial/mxuport.c u8 xoff = STOP_CHAR(tty); tty 786 drivers/usb/serial/mxuport.c if (I_IXOFF(tty) || I_IXON(tty)) { tty 812 drivers/usb/serial/mxuport.c C_CRTSCTS(tty) != (old_termios->c_cflag & CRTSCTS)) { tty 813 drivers/usb/serial/mxuport.c if (C_CRTSCTS(tty)) tty 819 drivers/usb/serial/mxuport.c if (C_BAUD(tty)) { tty 822 drivers/usb/serial/mxuport.c if (C_CRTSCTS(tty)) tty 842 drivers/usb/serial/mxuport.c static void mxuport_set_termios(struct tty_struct *tty, tty 855 drivers/usb/serial/mxuport.c !tty_termios_hw_change(&tty->termios, old_termios) && tty 856 drivers/usb/serial/mxuport.c tty->termios.c_iflag == old_termios->c_iflag) { tty 866 drivers/usb/serial/mxuport.c switch (C_CSIZE(tty)) { tty 883 drivers/usb/serial/mxuport.c if (C_PARENB(tty)) { tty 884 drivers/usb/serial/mxuport.c if (C_CMSPAR(tty)) { tty 885 drivers/usb/serial/mxuport.c if (C_PARODD(tty)) tty 890 drivers/usb/serial/mxuport.c if (C_PARODD(tty)) tty 900 drivers/usb/serial/mxuport.c if (C_CSTOPB(tty)) tty 915 drivers/usb/serial/mxuport.c err = mxuport_set_termios_flow(tty, old_termios, port, serial); tty 919 drivers/usb/serial/mxuport.c baud = tty_get_baud_rate(tty); tty 1195 drivers/usb/serial/mxuport.c static int mxuport_open(struct tty_struct *tty, struct usb_serial_port *port) tty 1216 drivers/usb/serial/mxuport.c if (tty) tty 1217 drivers/usb/serial/mxuport.c mxuport_set_termios(tty, port, NULL); tty 1240 drivers/usb/serial/mxuport.c static void mxuport_break_ctl(struct tty_struct *tty, int break_state) tty 1242 drivers/usb/serial/mxuport.c struct usb_serial_port *port = tty->driver_data; tty 66 drivers/usb/serial/navman.c static int navman_open(struct tty_struct *tty, struct usb_serial_port *port) tty 87 drivers/usb/serial/navman.c static int navman_write(struct tty_struct *tty, struct usb_serial_port *port, tty 125 drivers/usb/serial/opticon.c static int opticon_open(struct tty_struct *tty, struct usb_serial_port *port) tty 141 drivers/usb/serial/opticon.c res = usb_serial_generic_open(tty, port); tty 177 drivers/usb/serial/opticon.c static int opticon_write(struct tty_struct *tty, struct usb_serial_port *port, tty 260 drivers/usb/serial/opticon.c static int opticon_write_room(struct tty_struct *tty) tty 262 drivers/usb/serial/opticon.c struct usb_serial_port *port = tty->driver_data; tty 282 drivers/usb/serial/opticon.c static int opticon_tiocmget(struct tty_struct *tty) tty 284 drivers/usb/serial/opticon.c struct usb_serial_port *port = tty->driver_data; tty 300 drivers/usb/serial/opticon.c static int opticon_tiocmset(struct tty_struct *tty, tty 303 drivers/usb/serial/opticon.c struct usb_serial_port *port = tty->driver_data; tty 331 drivers/usb/serial/opticon.c static int get_serial_info(struct tty_struct *tty, tty 334 drivers/usb/serial/opticon.c struct usb_serial_port *port = tty->driver_data; tty 119 drivers/usb/serial/oti6858.c static int oti6858_open(struct tty_struct *tty, struct usb_serial_port *port); tty 121 drivers/usb/serial/oti6858.c static void oti6858_set_termios(struct tty_struct *tty, tty 123 drivers/usb/serial/oti6858.c static void oti6858_init_termios(struct tty_struct *tty); tty 127 drivers/usb/serial/oti6858.c static int oti6858_write(struct tty_struct *tty, struct usb_serial_port *port, tty 129 drivers/usb/serial/oti6858.c static int oti6858_write_room(struct tty_struct *tty); tty 130 drivers/usb/serial/oti6858.c static int oti6858_chars_in_buffer(struct tty_struct *tty); tty 131 drivers/usb/serial/oti6858.c static int oti6858_tiocmget(struct tty_struct *tty); tty 132 drivers/usb/serial/oti6858.c static int oti6858_tiocmset(struct tty_struct *tty, tty 357 drivers/usb/serial/oti6858.c static int oti6858_write(struct tty_struct *tty, struct usb_serial_port *port, tty 368 drivers/usb/serial/oti6858.c static int oti6858_write_room(struct tty_struct *tty) tty 370 drivers/usb/serial/oti6858.c struct usb_serial_port *port = tty->driver_data; tty 381 drivers/usb/serial/oti6858.c static int oti6858_chars_in_buffer(struct tty_struct *tty) tty 383 drivers/usb/serial/oti6858.c struct usb_serial_port *port = tty->driver_data; tty 394 drivers/usb/serial/oti6858.c static void oti6858_init_termios(struct tty_struct *tty) tty 396 drivers/usb/serial/oti6858.c tty_encode_baud_rate(tty, 38400, 38400); tty 399 drivers/usb/serial/oti6858.c static void oti6858_set_termios(struct tty_struct *tty, tty 409 drivers/usb/serial/oti6858.c cflag = tty->termios.c_cflag; tty 439 drivers/usb/serial/oti6858.c br = tty_get_baud_rate(tty); tty 450 drivers/usb/serial/oti6858.c tty_encode_baud_rate(tty, real_br, real_br); tty 501 drivers/usb/serial/oti6858.c static int oti6858_open(struct tty_struct *tty, struct usb_serial_port *port) tty 551 drivers/usb/serial/oti6858.c if (tty) tty 552 drivers/usb/serial/oti6858.c oti6858_set_termios(tty, port, NULL); tty 580 drivers/usb/serial/oti6858.c static int oti6858_tiocmset(struct tty_struct *tty, tty 583 drivers/usb/serial/oti6858.c struct usb_serial_port *port = tty->driver_data; tty 610 drivers/usb/serial/oti6858.c static int oti6858_tiocmget(struct tty_struct *tty) tty 612 drivers/usb/serial/oti6858.c struct usb_serial_port *port = tty->driver_data; tty 500 drivers/usb/serial/pl2303.c static void pl2303_encode_baud_rate(struct tty_struct *tty, tty 509 drivers/usb/serial/pl2303.c baud = tty_get_baud_rate(tty); tty 527 drivers/usb/serial/pl2303.c tty_encode_baud_rate(tty, baud, baud); tty 584 drivers/usb/serial/pl2303.c static bool pl2303_enable_xonxoff(struct tty_struct *tty, const struct pl2303_type_data *type) tty 586 drivers/usb/serial/pl2303.c if (!I_IXON(tty) || I_IXANY(tty)) tty 589 drivers/usb/serial/pl2303.c if (START_CHAR(tty) != 0x11 || STOP_CHAR(tty) != 0x13) tty 598 drivers/usb/serial/pl2303.c static void pl2303_set_termios(struct tty_struct *tty, tty 609 drivers/usb/serial/pl2303.c if (old_termios && !pl2303_termios_change(&tty->termios, old_termios)) tty 616 drivers/usb/serial/pl2303.c tty->termios = *old_termios; tty 622 drivers/usb/serial/pl2303.c switch (C_CSIZE(tty)) { tty 639 drivers/usb/serial/pl2303.c pl2303_encode_baud_rate(tty, port, &buf[0]); tty 644 drivers/usb/serial/pl2303.c if (C_CSTOPB(tty)) { tty 649 drivers/usb/serial/pl2303.c if (C_CSIZE(tty) == CS5) { tty 661 drivers/usb/serial/pl2303.c if (C_PARENB(tty)) { tty 667 drivers/usb/serial/pl2303.c if (C_PARODD(tty)) { tty 668 drivers/usb/serial/pl2303.c if (C_CMSPAR(tty)) { tty 676 drivers/usb/serial/pl2303.c if (C_CMSPAR(tty)) { tty 710 drivers/usb/serial/pl2303.c if (C_BAUD(tty) == B0) tty 722 drivers/usb/serial/pl2303.c if (C_CRTSCTS(tty)) { tty 727 drivers/usb/serial/pl2303.c } else if (pl2303_enable_xonxoff(tty, spriv->type)) { tty 760 drivers/usb/serial/pl2303.c static int pl2303_open(struct tty_struct *tty, struct usb_serial_port *port) tty 776 drivers/usb/serial/pl2303.c if (tty) tty 777 drivers/usb/serial/pl2303.c pl2303_set_termios(tty, port, NULL); tty 786 drivers/usb/serial/pl2303.c result = usb_serial_generic_open(tty, port); tty 795 drivers/usb/serial/pl2303.c static int pl2303_tiocmset(struct tty_struct *tty, tty 798 drivers/usb/serial/pl2303.c struct usb_serial_port *port = tty->driver_data; tty 823 drivers/usb/serial/pl2303.c static int pl2303_tiocmget(struct tty_struct *tty) tty 825 drivers/usb/serial/pl2303.c struct usb_serial_port *port = tty->driver_data; tty 859 drivers/usb/serial/pl2303.c static int pl2303_get_serial(struct tty_struct *tty, tty 862 drivers/usb/serial/pl2303.c struct usb_serial_port *port = tty->driver_data; tty 892 drivers/usb/serial/pl2303.c static void pl2303_break_ctl(struct tty_struct *tty, int state) tty 894 drivers/usb/serial/pl2303.c struct usb_serial_port *port = tty->driver_data; tty 906 drivers/usb/serial/pl2303.c struct tty_struct *tty; tty 938 drivers/usb/serial/pl2303.c tty = tty_port_tty_get(&port->port); tty 939 drivers/usb/serial/pl2303.c if (tty) { tty 940 drivers/usb/serial/pl2303.c usb_serial_handle_dcd_change(port, tty, tty 942 drivers/usb/serial/pl2303.c tty_kref_put(tty); tty 263 drivers/usb/serial/quatech2.c static void qt2_set_termios(struct tty_struct *tty, tty 269 drivers/usb/serial/quatech2.c struct ktermios *termios = &tty->termios; tty 300 drivers/usb/serial/quatech2.c baud = tty_get_baud_rate(tty); tty 321 drivers/usb/serial/quatech2.c if (I_IXOFF(tty) || I_IXON(tty)) { tty 322 drivers/usb/serial/quatech2.c u16 x = ((u16) (START_CHAR(tty) << 8) | (u16) (STOP_CHAR(tty))); tty 336 drivers/usb/serial/quatech2.c static int qt2_open(struct tty_struct *tty, struct usb_serial_port *port) tty 399 drivers/usb/serial/quatech2.c if (tty) tty 400 drivers/usb/serial/quatech2.c qt2_set_termios(tty, port, &tty->termios); tty 456 drivers/usb/serial/quatech2.c static int get_serial_info(struct tty_struct *tty, tty 459 drivers/usb/serial/quatech2.c struct usb_serial_port *port = tty->driver_data; tty 758 drivers/usb/serial/quatech2.c static int qt2_tiocmget(struct tty_struct *tty) tty 760 drivers/usb/serial/quatech2.c struct usb_serial_port *port = tty->driver_data; tty 790 drivers/usb/serial/quatech2.c static int qt2_tiocmset(struct tty_struct *tty, tty 795 drivers/usb/serial/quatech2.c port_priv = usb_get_serial_port_data(tty->driver_data); tty 799 drivers/usb/serial/quatech2.c static void qt2_break_ctl(struct tty_struct *tty, int break_state) tty 801 drivers/usb/serial/quatech2.c struct usb_serial_port *port = tty->driver_data; tty 906 drivers/usb/serial/quatech2.c static int qt2_write_room(struct tty_struct *tty) tty 908 drivers/usb/serial/quatech2.c struct usb_serial_port *port = tty->driver_data; tty 927 drivers/usb/serial/quatech2.c static int qt2_write(struct tty_struct *tty, tty 360 drivers/usb/serial/sierra.c static int sierra_tiocmget(struct tty_struct *tty) tty 362 drivers/usb/serial/sierra.c struct usb_serial_port *port = tty->driver_data; tty 378 drivers/usb/serial/sierra.c static int sierra_tiocmset(struct tty_struct *tty, tty 381 drivers/usb/serial/sierra.c struct usb_serial_port *port = tty->driver_data; tty 434 drivers/usb/serial/sierra.c static int sierra_write(struct tty_struct *tty, struct usb_serial_port *port, tty 636 drivers/usb/serial/sierra.c static int sierra_write_room(struct tty_struct *tty) tty 638 drivers/usb/serial/sierra.c struct usb_serial_port *port = tty->driver_data; tty 655 drivers/usb/serial/sierra.c static int sierra_chars_in_buffer(struct tty_struct *tty) tty 657 drivers/usb/serial/sierra.c struct usb_serial_port *port = tty->driver_data; tty 790 drivers/usb/serial/sierra.c static int sierra_open(struct tty_struct *tty, struct usb_serial_port *port) tty 282 drivers/usb/serial/spcp8x5.c static void spcp8x5_init_termios(struct tty_struct *tty) tty 284 drivers/usb/serial/spcp8x5.c tty_encode_baud_rate(tty, 115200, 115200); tty 287 drivers/usb/serial/spcp8x5.c static void spcp8x5_set_termios(struct tty_struct *tty, tty 293 drivers/usb/serial/spcp8x5.c unsigned int cflag = tty->termios.c_cflag; tty 301 drivers/usb/serial/spcp8x5.c if (old_termios && !tty_termios_hw_change(&tty->termios, old_termios)) tty 321 drivers/usb/serial/spcp8x5.c baud = tty_get_baud_rate(tty); tty 391 drivers/usb/serial/spcp8x5.c static int spcp8x5_open(struct tty_struct *tty, struct usb_serial_port *port) tty 408 drivers/usb/serial/spcp8x5.c if (tty) tty 409 drivers/usb/serial/spcp8x5.c spcp8x5_set_termios(tty, port, NULL); tty 411 drivers/usb/serial/spcp8x5.c return usb_serial_generic_open(tty, port); tty 414 drivers/usb/serial/spcp8x5.c static int spcp8x5_tiocmset(struct tty_struct *tty, tty 417 drivers/usb/serial/spcp8x5.c struct usb_serial_port *port = tty->driver_data; tty 437 drivers/usb/serial/spcp8x5.c static int spcp8x5_tiocmget(struct tty_struct *tty) tty 439 drivers/usb/serial/spcp8x5.c struct usb_serial_port *port = tty->driver_data; tty 216 drivers/usb/serial/ssu100.c static void ssu100_set_termios(struct tty_struct *tty, tty 221 drivers/usb/serial/ssu100.c struct ktermios *termios = &tty->termios; tty 250 drivers/usb/serial/ssu100.c baud = tty_get_baud_rate(tty); tty 277 drivers/usb/serial/ssu100.c if (I_IXOFF(tty) || I_IXON(tty)) { tty 278 drivers/usb/serial/ssu100.c u16 x = ((u16)(START_CHAR(tty) << 8) | (u16)(STOP_CHAR(tty))); tty 292 drivers/usb/serial/ssu100.c static int ssu100_open(struct tty_struct *tty, struct usb_serial_port *port) tty 328 drivers/usb/serial/ssu100.c if (tty) tty 329 drivers/usb/serial/ssu100.c ssu100_set_termios(tty, port, &tty->termios); tty 331 drivers/usb/serial/ssu100.c return usb_serial_generic_open(tty, port); tty 334 drivers/usb/serial/ssu100.c static int get_serial_info(struct tty_struct *tty, tty 337 drivers/usb/serial/ssu100.c struct usb_serial_port *port = tty->driver_data; tty 379 drivers/usb/serial/ssu100.c static int ssu100_tiocmget(struct tty_struct *tty) tty 381 drivers/usb/serial/ssu100.c struct usb_serial_port *port = tty->driver_data; tty 410 drivers/usb/serial/ssu100.c static int ssu100_tiocmset(struct tty_struct *tty, tty 413 drivers/usb/serial/ssu100.c struct usb_serial_port *port = tty->driver_data; tty 91 drivers/usb/serial/symbolserial.c static int symbol_open(struct tty_struct *tty, struct usb_serial_port *port) tty 116 drivers/usb/serial/symbolserial.c static void symbol_throttle(struct tty_struct *tty) tty 118 drivers/usb/serial/symbolserial.c struct usb_serial_port *port = tty->driver_data; tty 126 drivers/usb/serial/symbolserial.c static void symbol_unthrottle(struct tty_struct *tty) tty 128 drivers/usb/serial/symbolserial.c struct usb_serial_port *port = tty->driver_data; tty 307 drivers/usb/serial/ti_usb_3410_5052.c static int ti_open(struct tty_struct *tty, struct usb_serial_port *port); tty 309 drivers/usb/serial/ti_usb_3410_5052.c static int ti_write(struct tty_struct *tty, struct usb_serial_port *port, tty 311 drivers/usb/serial/ti_usb_3410_5052.c static int ti_write_room(struct tty_struct *tty); tty 312 drivers/usb/serial/ti_usb_3410_5052.c static int ti_chars_in_buffer(struct tty_struct *tty); tty 314 drivers/usb/serial/ti_usb_3410_5052.c static void ti_throttle(struct tty_struct *tty); tty 315 drivers/usb/serial/ti_usb_3410_5052.c static void ti_unthrottle(struct tty_struct *tty); tty 316 drivers/usb/serial/ti_usb_3410_5052.c static void ti_set_termios(struct tty_struct *tty, tty 318 drivers/usb/serial/ti_usb_3410_5052.c static int ti_tiocmget(struct tty_struct *tty); tty 319 drivers/usb/serial/ti_usb_3410_5052.c static int ti_tiocmset(struct tty_struct *tty, tty 321 drivers/usb/serial/ti_usb_3410_5052.c static void ti_break(struct tty_struct *tty, int break_state); tty 331 drivers/usb/serial/ti_usb_3410_5052.c static int ti_get_serial_info(struct tty_struct *tty, tty 333 drivers/usb/serial/ti_usb_3410_5052.c static int ti_set_serial_info(struct tty_struct *tty, tty 337 drivers/usb/serial/ti_usb_3410_5052.c static void ti_stop_read(struct ti_port *tport, struct tty_struct *tty); tty 338 drivers/usb/serial/ti_usb_3410_5052.c static int ti_restart_read(struct ti_port *tport, struct tty_struct *tty); tty 642 drivers/usb/serial/ti_usb_3410_5052.c static int ti_open(struct tty_struct *tty, struct usb_serial_port *port) tty 685 drivers/usb/serial/ti_usb_3410_5052.c if (tty) tty 686 drivers/usb/serial/ti_usb_3410_5052.c ti_set_termios(tty, port, &tty->termios); tty 724 drivers/usb/serial/ti_usb_3410_5052.c if (tty) tty 725 drivers/usb/serial/ti_usb_3410_5052.c ti_set_termios(tty, port, &tty->termios); tty 812 drivers/usb/serial/ti_usb_3410_5052.c static int ti_write(struct tty_struct *tty, struct usb_serial_port *port, tty 832 drivers/usb/serial/ti_usb_3410_5052.c static int ti_write_room(struct tty_struct *tty) tty 834 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 848 drivers/usb/serial/ti_usb_3410_5052.c static int ti_chars_in_buffer(struct tty_struct *tty) tty 850 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 876 drivers/usb/serial/ti_usb_3410_5052.c static void ti_throttle(struct tty_struct *tty) tty 878 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 881 drivers/usb/serial/ti_usb_3410_5052.c if (I_IXOFF(tty) || C_CRTSCTS(tty)) tty 882 drivers/usb/serial/ti_usb_3410_5052.c ti_stop_read(tport, tty); tty 887 drivers/usb/serial/ti_usb_3410_5052.c static void ti_unthrottle(struct tty_struct *tty) tty 889 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 893 drivers/usb/serial/ti_usb_3410_5052.c if (I_IXOFF(tty) || C_CRTSCTS(tty)) { tty 894 drivers/usb/serial/ti_usb_3410_5052.c status = ti_restart_read(tport, tty); tty 901 drivers/usb/serial/ti_usb_3410_5052.c static void ti_set_termios(struct tty_struct *tty, tty 922 drivers/usb/serial/ti_usb_3410_5052.c switch (C_CSIZE(tty)) { tty 939 drivers/usb/serial/ti_usb_3410_5052.c tty->termios.c_cflag &= ~CMSPAR; tty 941 drivers/usb/serial/ti_usb_3410_5052.c if (C_PARENB(tty)) { tty 942 drivers/usb/serial/ti_usb_3410_5052.c if (C_PARODD(tty)) { tty 954 drivers/usb/serial/ti_usb_3410_5052.c if (C_CSTOPB(tty)) tty 959 drivers/usb/serial/ti_usb_3410_5052.c if (C_CRTSCTS(tty)) { tty 961 drivers/usb/serial/ti_usb_3410_5052.c if ((C_BAUD(tty)) != B0) tty 965 drivers/usb/serial/ti_usb_3410_5052.c ti_restart_read(tport, tty); tty 968 drivers/usb/serial/ti_usb_3410_5052.c if (I_IXOFF(tty) || I_IXON(tty)) { tty 969 drivers/usb/serial/ti_usb_3410_5052.c config->cXon = START_CHAR(tty); tty 970 drivers/usb/serial/ti_usb_3410_5052.c config->cXoff = STOP_CHAR(tty); tty 972 drivers/usb/serial/ti_usb_3410_5052.c if (I_IXOFF(tty)) tty 975 drivers/usb/serial/ti_usb_3410_5052.c ti_restart_read(tport, tty); tty 977 drivers/usb/serial/ti_usb_3410_5052.c if (I_IXON(tty)) tty 981 drivers/usb/serial/ti_usb_3410_5052.c baud = tty_get_baud_rate(tty); tty 990 drivers/usb/serial/ti_usb_3410_5052.c if ((C_BAUD(tty)) != B0) tty 991 drivers/usb/serial/ti_usb_3410_5052.c tty_encode_baud_rate(tty, baud, baud); tty 1012 drivers/usb/serial/ti_usb_3410_5052.c if (C_BAUD(tty) == B0) tty 1024 drivers/usb/serial/ti_usb_3410_5052.c static int ti_tiocmget(struct tty_struct *tty) tty 1026 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 1052 drivers/usb/serial/ti_usb_3410_5052.c static int ti_tiocmset(struct tty_struct *tty, tty 1055 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 1082 drivers/usb/serial/ti_usb_3410_5052.c static void ti_break(struct tty_struct *tty, int break_state) tty 1084 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 1398 drivers/usb/serial/ti_usb_3410_5052.c static int ti_get_serial_info(struct tty_struct *tty, tty 1401 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 1419 drivers/usb/serial/ti_usb_3410_5052.c static int ti_set_serial_info(struct tty_struct *tty, tty 1422 drivers/usb/serial/ti_usb_3410_5052.c struct usb_serial_port *port = tty->driver_data; tty 1439 drivers/usb/serial/ti_usb_3410_5052.c struct tty_struct *tty; tty 1462 drivers/usb/serial/ti_usb_3410_5052.c tty = tty_port_tty_get(&tport->tp_port->port); tty 1463 drivers/usb/serial/ti_usb_3410_5052.c if (tty && C_CRTSCTS(tty)) { tty 1465 drivers/usb/serial/ti_usb_3410_5052.c tty_wakeup(tty); tty 1467 drivers/usb/serial/ti_usb_3410_5052.c tty_kref_put(tty); tty 1471 drivers/usb/serial/ti_usb_3410_5052.c static void ti_stop_read(struct ti_port *tport, struct tty_struct *tty) tty 1484 drivers/usb/serial/ti_usb_3410_5052.c static int ti_restart_read(struct ti_port *tport, struct tty_struct *tty) tty 188 drivers/usb/serial/upd78f0730.c static int upd78f0730_tiocmget(struct tty_struct *tty) tty 190 drivers/usb/serial/upd78f0730.c struct device *dev = tty->dev; tty 192 drivers/usb/serial/upd78f0730.c struct usb_serial_port *port = tty->driver_data; tty 210 drivers/usb/serial/upd78f0730.c static int upd78f0730_tiocmset(struct tty_struct *tty, tty 213 drivers/usb/serial/upd78f0730.c struct device *dev = tty->dev; tty 214 drivers/usb/serial/upd78f0730.c struct usb_serial_port *port = tty->driver_data; tty 247 drivers/usb/serial/upd78f0730.c static void upd78f0730_break_ctl(struct tty_struct *tty, int break_state) tty 249 drivers/usb/serial/upd78f0730.c struct device *dev = tty->dev; tty 251 drivers/usb/serial/upd78f0730.c struct usb_serial_port *port = tty->driver_data; tty 273 drivers/usb/serial/upd78f0730.c struct tty_struct *tty = port->port.tty; tty 282 drivers/usb/serial/upd78f0730.c upd78f0730_tiocmset(tty, set, clear); tty 285 drivers/usb/serial/upd78f0730.c static speed_t upd78f0730_get_baud_rate(struct tty_struct *tty) tty 287 drivers/usb/serial/upd78f0730.c const speed_t baud_rate = tty_get_baud_rate(tty); tty 299 drivers/usb/serial/upd78f0730.c tty_encode_baud_rate(tty, 9600, 9600); tty 301 drivers/usb/serial/upd78f0730.c return tty_get_baud_rate(tty); tty 304 drivers/usb/serial/upd78f0730.c static void upd78f0730_set_termios(struct tty_struct *tty, tty 312 drivers/usb/serial/upd78f0730.c if (old_termios && !tty_termios_hw_change(&tty->termios, old_termios)) tty 315 drivers/usb/serial/upd78f0730.c if (C_BAUD(tty) == B0) tty 320 drivers/usb/serial/upd78f0730.c baud_rate = upd78f0730_get_baud_rate(tty); tty 326 drivers/usb/serial/upd78f0730.c switch (C_CSIZE(tty)) { tty 332 drivers/usb/serial/upd78f0730.c tty->termios.c_cflag &= ~CSIZE; tty 333 drivers/usb/serial/upd78f0730.c tty->termios.c_cflag |= CS8; tty 342 drivers/usb/serial/upd78f0730.c if (C_PARENB(tty)) { tty 343 drivers/usb/serial/upd78f0730.c if (C_PARODD(tty)) { tty 351 drivers/usb/serial/upd78f0730.c if (C_CMSPAR(tty)) { tty 352 drivers/usb/serial/upd78f0730.c tty->termios.c_cflag &= ~CMSPAR; tty 360 drivers/usb/serial/upd78f0730.c if (C_CSTOPB(tty)) { tty 368 drivers/usb/serial/upd78f0730.c if (C_CRTSCTS(tty)) { tty 369 drivers/usb/serial/upd78f0730.c tty->termios.c_cflag &= ~CRTSCTS; tty 372 drivers/usb/serial/upd78f0730.c if (I_IXOFF(tty) || I_IXON(tty)) { tty 373 drivers/usb/serial/upd78f0730.c tty->termios.c_iflag &= ~(IXOFF | IXON); tty 382 drivers/usb/serial/upd78f0730.c static int upd78f0730_open(struct tty_struct *tty, struct usb_serial_port *port) tty 394 drivers/usb/serial/upd78f0730.c if (tty) tty 395 drivers/usb/serial/upd78f0730.c upd78f0730_set_termios(tty, port, NULL); tty 397 drivers/usb/serial/upd78f0730.c return usb_serial_generic_open(tty, port); tty 176 drivers/usb/serial/usb-serial.c static int serial_install(struct tty_driver *driver, struct tty_struct *tty) tty 178 drivers/usb/serial/usb-serial.c int idx = tty->index; tty 198 drivers/usb/serial/usb-serial.c retval = tty_standard_install(driver, tty); tty 206 drivers/usb/serial/usb-serial.c serial->type->init_termios(tty); tty 208 drivers/usb/serial/usb-serial.c tty->driver_data = port; tty 222 drivers/usb/serial/usb-serial.c static int serial_port_activate(struct tty_port *tport, struct tty_struct *tty) tty 233 drivers/usb/serial/usb-serial.c retval = port->serial->type->open(tty, port); tty 242 drivers/usb/serial/usb-serial.c static int serial_open(struct tty_struct *tty, struct file *filp) tty 244 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 246 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 248 drivers/usb/serial/usb-serial.c return tty_port_open(&port->port, tty, filp); tty 271 drivers/usb/serial/usb-serial.c static void serial_hangup(struct tty_struct *tty) tty 273 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 275 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 280 drivers/usb/serial/usb-serial.c static void serial_close(struct tty_struct *tty, struct file *filp) tty 282 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 284 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 286 drivers/usb/serial/usb-serial.c tty_port_close(&port->port, tty, filp); tty 298 drivers/usb/serial/usb-serial.c static void serial_cleanup(struct tty_struct *tty) tty 300 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 304 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 312 drivers/usb/serial/usb-serial.c tty->driver_data = NULL; tty 323 drivers/usb/serial/usb-serial.c static int serial_write(struct tty_struct *tty, const unsigned char *buf, tty 326 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 332 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s - %d byte(s)\n", __func__, count); tty 334 drivers/usb/serial/usb-serial.c retval = port->serial->type->write(tty, port, buf, count); tty 341 drivers/usb/serial/usb-serial.c static int serial_write_room(struct tty_struct *tty) tty 343 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 345 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 347 drivers/usb/serial/usb-serial.c return port->serial->type->write_room(tty); tty 350 drivers/usb/serial/usb-serial.c static int serial_chars_in_buffer(struct tty_struct *tty) tty 352 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 355 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 360 drivers/usb/serial/usb-serial.c return serial->type->chars_in_buffer(tty); tty 363 drivers/usb/serial/usb-serial.c static void serial_wait_until_sent(struct tty_struct *tty, int timeout) tty 365 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 368 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 375 drivers/usb/serial/usb-serial.c port->serial->type->wait_until_sent(tty, timeout); tty 379 drivers/usb/serial/usb-serial.c static void serial_throttle(struct tty_struct *tty) tty 381 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 383 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 386 drivers/usb/serial/usb-serial.c port->serial->type->throttle(tty); tty 389 drivers/usb/serial/usb-serial.c static void serial_unthrottle(struct tty_struct *tty) tty 391 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 393 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 396 drivers/usb/serial/usb-serial.c port->serial->type->unthrottle(tty); tty 399 drivers/usb/serial/usb-serial.c static int serial_get_serial(struct tty_struct *tty, struct serial_struct *ss) tty 401 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 404 drivers/usb/serial/usb-serial.c return port->serial->type->get_serial(tty, ss); tty 408 drivers/usb/serial/usb-serial.c static int serial_set_serial(struct tty_struct *tty, struct serial_struct *ss) tty 410 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 413 drivers/usb/serial/usb-serial.c return port->serial->type->set_serial(tty, ss); tty 417 drivers/usb/serial/usb-serial.c static int serial_ioctl(struct tty_struct *tty, tty 420 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 423 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s - cmd 0x%04x\n", __func__, cmd); tty 428 drivers/usb/serial/usb-serial.c retval = port->serial->type->tiocmiwait(tty, arg); tty 432 drivers/usb/serial/usb-serial.c retval = port->serial->type->ioctl(tty, cmd, arg); tty 438 drivers/usb/serial/usb-serial.c static void serial_set_termios(struct tty_struct *tty, struct ktermios *old) tty 440 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 442 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 445 drivers/usb/serial/usb-serial.c port->serial->type->set_termios(tty, port, old); tty 447 drivers/usb/serial/usb-serial.c tty_termios_copy_hw(&tty->termios, old); tty 450 drivers/usb/serial/usb-serial.c static int serial_break(struct tty_struct *tty, int break_state) tty 452 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 454 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 457 drivers/usb/serial/usb-serial.c port->serial->type->break_ctl(tty, break_state); tty 497 drivers/usb/serial/usb-serial.c static int serial_tiocmget(struct tty_struct *tty) tty 499 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 501 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 504 drivers/usb/serial/usb-serial.c return port->serial->type->tiocmget(tty); tty 508 drivers/usb/serial/usb-serial.c static int serial_tiocmset(struct tty_struct *tty, tty 511 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 513 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 516 drivers/usb/serial/usb-serial.c return port->serial->type->tiocmset(tty, set, clear); tty 520 drivers/usb/serial/usb-serial.c static int serial_get_icount(struct tty_struct *tty, tty 523 drivers/usb/serial/usb-serial.c struct usb_serial_port *port = tty->driver_data; tty 525 drivers/usb/serial/usb-serial.c dev_dbg(tty->dev, "%s\n", __func__); tty 528 drivers/usb/serial/usb-serial.c return port->serial->type->get_icount(tty, icount); tty 1082 drivers/usb/serial/usb-serial.c struct tty_struct *tty; tty 1093 drivers/usb/serial/usb-serial.c tty = tty_port_tty_get(&port->port); tty 1094 drivers/usb/serial/usb-serial.c if (tty) { tty 1095 drivers/usb/serial/usb-serial.c tty_vhangup(tty); tty 1096 drivers/usb/serial/usb-serial.c tty_kref_put(tty); tty 10 drivers/usb/serial/usb-wwan.h extern int usb_wwan_open(struct tty_struct *tty, struct usb_serial_port *port); tty 14 drivers/usb/serial/usb-wwan.h extern int usb_wwan_write_room(struct tty_struct *tty); tty 15 drivers/usb/serial/usb-wwan.h extern int usb_wwan_tiocmget(struct tty_struct *tty); tty 16 drivers/usb/serial/usb-wwan.h extern int usb_wwan_tiocmset(struct tty_struct *tty, tty 18 drivers/usb/serial/usb-wwan.h extern int usb_wwan_get_serial_info(struct tty_struct *tty, tty 20 drivers/usb/serial/usb-wwan.h extern int usb_wwan_set_serial_info(struct tty_struct *tty, tty 22 drivers/usb/serial/usb-wwan.h extern int usb_wwan_write(struct tty_struct *tty, struct usb_serial_port *port, tty 24 drivers/usb/serial/usb-wwan.h extern int usb_wwan_chars_in_buffer(struct tty_struct *tty); tty 50 drivers/usb/serial/usb_debug.c static void usb_debug_break_ctl(struct tty_struct *tty, int break_state) tty 52 drivers/usb/serial/usb_debug.c struct usb_serial_port *port = tty->driver_data; tty 55 drivers/usb/serial/usb_debug.c usb_serial_generic_write(tty, port, USB_DEBUG_BRK, USB_DEBUG_BRK_SIZE); tty 89 drivers/usb/serial/usb_wwan.c int usb_wwan_tiocmget(struct tty_struct *tty) tty 91 drivers/usb/serial/usb_wwan.c struct usb_serial_port *port = tty->driver_data; tty 108 drivers/usb/serial/usb_wwan.c int usb_wwan_tiocmset(struct tty_struct *tty, tty 111 drivers/usb/serial/usb_wwan.c struct usb_serial_port *port = tty->driver_data; tty 135 drivers/usb/serial/usb_wwan.c int usb_wwan_get_serial_info(struct tty_struct *tty, tty 138 drivers/usb/serial/usb_wwan.c struct usb_serial_port *port = tty->driver_data; tty 142 drivers/usb/serial/usb_wwan.c ss->baud_base = tty_get_baud_rate(port->port.tty); tty 151 drivers/usb/serial/usb_wwan.c int usb_wwan_set_serial_info(struct tty_struct *tty, tty 154 drivers/usb/serial/usb_wwan.c struct usb_serial_port *port = tty->driver_data; tty 180 drivers/usb/serial/usb_wwan.c int usb_wwan_write(struct tty_struct *tty, struct usb_serial_port *port, tty 326 drivers/usb/serial/usb_wwan.c int usb_wwan_write_room(struct tty_struct *tty) tty 328 drivers/usb/serial/usb_wwan.c struct usb_serial_port *port = tty->driver_data; tty 347 drivers/usb/serial/usb_wwan.c int usb_wwan_chars_in_buffer(struct tty_struct *tty) tty 349 drivers/usb/serial/usb_wwan.c struct usb_serial_port *port = tty->driver_data; tty 369 drivers/usb/serial/usb_wwan.c int usb_wwan_open(struct tty_struct *tty, struct usb_serial_port *port) tty 36 drivers/usb/serial/visor.c static int visor_open(struct tty_struct *tty, struct usb_serial_port *port); tty 224 drivers/usb/serial/visor.c static int visor_open(struct tty_struct *tty, struct usb_serial_port *port) tty 235 drivers/usb/serial/visor.c result = usb_serial_generic_open(tty, port); tty 83 drivers/usb/serial/whiteheat.c static int whiteheat_open(struct tty_struct *tty, tty 86 drivers/usb/serial/whiteheat.c static int whiteheat_get_serial(struct tty_struct *tty, tty 88 drivers/usb/serial/whiteheat.c static void whiteheat_set_termios(struct tty_struct *tty, tty 90 drivers/usb/serial/whiteheat.c static int whiteheat_tiocmget(struct tty_struct *tty); tty 91 drivers/usb/serial/whiteheat.c static int whiteheat_tiocmset(struct tty_struct *tty, tty 93 drivers/usb/serial/whiteheat.c static void whiteheat_break_ctl(struct tty_struct *tty, int break_state); tty 161 drivers/usb/serial/whiteheat.c static void firm_setup_port(struct tty_struct *tty); tty 358 drivers/usb/serial/whiteheat.c static int whiteheat_open(struct tty_struct *tty, struct usb_serial_port *port) tty 380 drivers/usb/serial/whiteheat.c if (tty) tty 381 drivers/usb/serial/whiteheat.c firm_setup_port(tty); tty 387 drivers/usb/serial/whiteheat.c retval = usb_serial_generic_open(tty, port); tty 408 drivers/usb/serial/whiteheat.c static int whiteheat_tiocmget(struct tty_struct *tty) tty 410 drivers/usb/serial/whiteheat.c struct usb_serial_port *port = tty->driver_data; tty 423 drivers/usb/serial/whiteheat.c static int whiteheat_tiocmset(struct tty_struct *tty, tty 426 drivers/usb/serial/whiteheat.c struct usb_serial_port *port = tty->driver_data; tty 445 drivers/usb/serial/whiteheat.c static int whiteheat_get_serial(struct tty_struct *tty, tty 448 drivers/usb/serial/whiteheat.c struct usb_serial_port *port = tty->driver_data; tty 463 drivers/usb/serial/whiteheat.c static void whiteheat_set_termios(struct tty_struct *tty, tty 466 drivers/usb/serial/whiteheat.c firm_setup_port(tty); tty 469 drivers/usb/serial/whiteheat.c static void whiteheat_break_ctl(struct tty_struct *tty, int break_state) tty 471 drivers/usb/serial/whiteheat.c struct usb_serial_port *port = tty->driver_data; tty 633 drivers/usb/serial/whiteheat.c static void firm_setup_port(struct tty_struct *tty) tty 635 drivers/usb/serial/whiteheat.c struct usb_serial_port *port = tty->driver_data; tty 638 drivers/usb/serial/whiteheat.c unsigned int cflag = tty->termios.c_cflag; tty 689 drivers/usb/serial/whiteheat.c if (I_IXOFF(tty)) tty 695 drivers/usb/serial/whiteheat.c port_settings.xon = START_CHAR(tty); tty 696 drivers/usb/serial/whiteheat.c port_settings.xoff = STOP_CHAR(tty); tty 700 drivers/usb/serial/whiteheat.c baud = tty_get_baud_rate(tty); tty 705 drivers/usb/serial/whiteheat.c tty_encode_baud_rate(tty, baud, baud); tty 45 drivers/usb/serial/wishbone-serial.c static int wishbone_serial_open(struct tty_struct *tty, tty 58 drivers/usb/serial/wishbone-serial.c retval = usb_serial_generic_open(tty, port); tty 482 fs/proc/array.c if (sig->tty) { tty 483 fs/proc/array.c struct pid *pgrp = tty_get_pgrp(sig->tty); tty 486 fs/proc/array.c tty_nr = new_encode_dev(tty_devnum(sig->tty)); tty 1185 fs/quota/dquot.c struct tty_struct *tty; tty 1194 fs/quota/dquot.c tty = get_current_tty(); tty 1195 fs/quota/dquot.c if (!tty) tty 1197 fs/quota/dquot.c tty_write_message(tty, warn->w_sb->s_id); tty 1199 fs/quota/dquot.c tty_write_message(tty, ": warning, "); tty 1201 fs/quota/dquot.c tty_write_message(tty, ": write failed, "); tty 1202 fs/quota/dquot.c tty_write_message(tty, quotatypes[warn->w_dq_id.type]); tty 1223 fs/quota/dquot.c tty_write_message(tty, msg); tty 1224 fs/quota/dquot.c tty_kref_put(tty); tty 34 include/linux/devpts_fs.h int ptm_open_peer(struct file *master, struct tty_struct *tty, int flags); tty 38 include/linux/devpts_fs.h ptm_open_peer(struct file *master, struct tty_struct *tty, int flags) tty 150 include/linux/n_r3964.h struct tty_struct *tty; tty 162 include/linux/sched/signal.h struct tty_struct *tty; /* NULL if no tty */ tty 19 include/linux/selection.h struct tty_struct *tty); tty 21 include/linux/selection.h struct tty_struct *tty); tty 22 include/linux/selection.h extern int paste_selection(struct tty_struct *tty); tty 25 include/linux/selection.h extern void mouse_report(struct tty_struct * tty, int butt, int mrx, int mry); tty 433 include/linux/serial_core.h struct tty_struct *tty = port->state->port.tty; tty 434 include/linux/serial_core.h if ((tty && tty->stopped) || port->hw_stopped) tty 535 include/linux/serial_core.h do_SAK(state->port.tty); tty 147 include/linux/ti_wilink_st.h struct tty_struct *tty; tty 106 include/linux/tty.h #define INTR_CHAR(tty) ((tty)->termios.c_cc[VINTR]) tty 107 include/linux/tty.h #define QUIT_CHAR(tty) ((tty)->termios.c_cc[VQUIT]) tty 108 include/linux/tty.h #define ERASE_CHAR(tty) ((tty)->termios.c_cc[VERASE]) tty 109 include/linux/tty.h #define KILL_CHAR(tty) ((tty)->termios.c_cc[VKILL]) tty 110 include/linux/tty.h #define EOF_CHAR(tty) ((tty)->termios.c_cc[VEOF]) tty 111 include/linux/tty.h #define TIME_CHAR(tty) ((tty)->termios.c_cc[VTIME]) tty 112 include/linux/tty.h #define MIN_CHAR(tty) ((tty)->termios.c_cc[VMIN]) tty 113 include/linux/tty.h #define SWTC_CHAR(tty) ((tty)->termios.c_cc[VSWTC]) tty 114 include/linux/tty.h #define START_CHAR(tty) ((tty)->termios.c_cc[VSTART]) tty 115 include/linux/tty.h #define STOP_CHAR(tty) ((tty)->termios.c_cc[VSTOP]) tty 116 include/linux/tty.h #define SUSP_CHAR(tty) ((tty)->termios.c_cc[VSUSP]) tty 117 include/linux/tty.h #define EOL_CHAR(tty) ((tty)->termios.c_cc[VEOL]) tty 118 include/linux/tty.h #define REPRINT_CHAR(tty) ((tty)->termios.c_cc[VREPRINT]) tty 119 include/linux/tty.h #define DISCARD_CHAR(tty) ((tty)->termios.c_cc[VDISCARD]) tty 120 include/linux/tty.h #define WERASE_CHAR(tty) ((tty)->termios.c_cc[VWERASE]) tty 121 include/linux/tty.h #define LNEXT_CHAR(tty) ((tty)->termios.c_cc[VLNEXT]) tty 122 include/linux/tty.h #define EOL2_CHAR(tty) ((tty)->termios.c_cc[VEOL2]) tty 124 include/linux/tty.h #define _I_FLAG(tty, f) ((tty)->termios.c_iflag & (f)) tty 125 include/linux/tty.h #define _O_FLAG(tty, f) ((tty)->termios.c_oflag & (f)) tty 126 include/linux/tty.h #define _C_FLAG(tty, f) ((tty)->termios.c_cflag & (f)) tty 127 include/linux/tty.h #define _L_FLAG(tty, f) ((tty)->termios.c_lflag & (f)) tty 129 include/linux/tty.h #define I_IGNBRK(tty) _I_FLAG((tty), IGNBRK) tty 130 include/linux/tty.h #define I_BRKINT(tty) _I_FLAG((tty), BRKINT) tty 131 include/linux/tty.h #define I_IGNPAR(tty) _I_FLAG((tty), IGNPAR) tty 132 include/linux/tty.h #define I_PARMRK(tty) _I_FLAG((tty), PARMRK) tty 133 include/linux/tty.h #define I_INPCK(tty) _I_FLAG((tty), INPCK) tty 134 include/linux/tty.h #define I_ISTRIP(tty) _I_FLAG((tty), ISTRIP) tty 135 include/linux/tty.h #define I_INLCR(tty) _I_FLAG((tty), INLCR) tty 136 include/linux/tty.h #define I_IGNCR(tty) _I_FLAG((tty), IGNCR) tty 137 include/linux/tty.h #define I_ICRNL(tty) _I_FLAG((tty), ICRNL) tty 138 include/linux/tty.h #define I_IUCLC(tty) _I_FLAG((tty), IUCLC) tty 139 include/linux/tty.h #define I_IXON(tty) _I_FLAG((tty), IXON) tty 140 include/linux/tty.h #define I_IXANY(tty) _I_FLAG((tty), IXANY) tty 141 include/linux/tty.h #define I_IXOFF(tty) _I_FLAG((tty), IXOFF) tty 142 include/linux/tty.h #define I_IMAXBEL(tty) _I_FLAG((tty), IMAXBEL) tty 143 include/linux/tty.h #define I_IUTF8(tty) _I_FLAG((tty), IUTF8) tty 145 include/linux/tty.h #define O_OPOST(tty) _O_FLAG((tty), OPOST) tty 146 include/linux/tty.h #define O_OLCUC(tty) _O_FLAG((tty), OLCUC) tty 147 include/linux/tty.h #define O_ONLCR(tty) _O_FLAG((tty), ONLCR) tty 148 include/linux/tty.h #define O_OCRNL(tty) _O_FLAG((tty), OCRNL) tty 149 include/linux/tty.h #define O_ONOCR(tty) _O_FLAG((tty), ONOCR) tty 150 include/linux/tty.h #define O_ONLRET(tty) _O_FLAG((tty), ONLRET) tty 151 include/linux/tty.h #define O_OFILL(tty) _O_FLAG((tty), OFILL) tty 152 include/linux/tty.h #define O_OFDEL(tty) _O_FLAG((tty), OFDEL) tty 153 include/linux/tty.h #define O_NLDLY(tty) _O_FLAG((tty), NLDLY) tty 154 include/linux/tty.h #define O_CRDLY(tty) _O_FLAG((tty), CRDLY) tty 155 include/linux/tty.h #define O_TABDLY(tty) _O_FLAG((tty), TABDLY) tty 156 include/linux/tty.h #define O_BSDLY(tty) _O_FLAG((tty), BSDLY) tty 157 include/linux/tty.h #define O_VTDLY(tty) _O_FLAG((tty), VTDLY) tty 158 include/linux/tty.h #define O_FFDLY(tty) _O_FLAG((tty), FFDLY) tty 160 include/linux/tty.h #define C_BAUD(tty) _C_FLAG((tty), CBAUD) tty 161 include/linux/tty.h #define C_CSIZE(tty) _C_FLAG((tty), CSIZE) tty 162 include/linux/tty.h #define C_CSTOPB(tty) _C_FLAG((tty), CSTOPB) tty 163 include/linux/tty.h #define C_CREAD(tty) _C_FLAG((tty), CREAD) tty 164 include/linux/tty.h #define C_PARENB(tty) _C_FLAG((tty), PARENB) tty 165 include/linux/tty.h #define C_PARODD(tty) _C_FLAG((tty), PARODD) tty 166 include/linux/tty.h #define C_HUPCL(tty) _C_FLAG((tty), HUPCL) tty 167 include/linux/tty.h #define C_CLOCAL(tty) _C_FLAG((tty), CLOCAL) tty 168 include/linux/tty.h #define C_CIBAUD(tty) _C_FLAG((tty), CIBAUD) tty 169 include/linux/tty.h #define C_CRTSCTS(tty) _C_FLAG((tty), CRTSCTS) tty 170 include/linux/tty.h #define C_CMSPAR(tty) _C_FLAG((tty), CMSPAR) tty 172 include/linux/tty.h #define L_ISIG(tty) _L_FLAG((tty), ISIG) tty 173 include/linux/tty.h #define L_ICANON(tty) _L_FLAG((tty), ICANON) tty 174 include/linux/tty.h #define L_XCASE(tty) _L_FLAG((tty), XCASE) tty 175 include/linux/tty.h #define L_ECHO(tty) _L_FLAG((tty), ECHO) tty 176 include/linux/tty.h #define L_ECHOE(tty) _L_FLAG((tty), ECHOE) tty 177 include/linux/tty.h #define L_ECHOK(tty) _L_FLAG((tty), ECHOK) tty 178 include/linux/tty.h #define L_ECHONL(tty) _L_FLAG((tty), ECHONL) tty 179 include/linux/tty.h #define L_NOFLSH(tty) _L_FLAG((tty), NOFLSH) tty 180 include/linux/tty.h #define L_TOSTOP(tty) _L_FLAG((tty), TOSTOP) tty 181 include/linux/tty.h #define L_ECHOCTL(tty) _L_FLAG((tty), ECHOCTL) tty 182 include/linux/tty.h #define L_ECHOPRT(tty) _L_FLAG((tty), ECHOPRT) tty 183 include/linux/tty.h #define L_ECHOKE(tty) _L_FLAG((tty), ECHOKE) tty 184 include/linux/tty.h #define L_FLUSHO(tty) _L_FLAG((tty), FLUSHO) tty 185 include/linux/tty.h #define L_PENDIN(tty) _L_FLAG((tty), PENDIN) tty 186 include/linux/tty.h #define L_IEXTEN(tty) _L_FLAG((tty), IEXTEN) tty 187 include/linux/tty.h #define L_EXTPROC(tty) _L_FLAG((tty), EXTPROC) tty 218 include/linux/tty.h int (*activate)(struct tty_port *port, struct tty_struct *tty); tty 232 include/linux/tty.h struct tty_struct *tty; /* Back pointer */ tty 345 include/linux/tty.h struct tty_struct *tty; tty 378 include/linux/tty.h static inline void __tty_set_flow_change(struct tty_struct *tty, int val) tty 380 include/linux/tty.h tty->flow_change = val; tty 383 include/linux/tty.h static inline void tty_set_flow_change(struct tty_struct *tty, int val) tty 385 include/linux/tty.h tty->flow_change = val; tty 389 include/linux/tty.h static inline bool tty_io_nonblock(struct tty_struct *tty, struct file *file) tty 392 include/linux/tty.h test_bit(TTY_LDISC_CHANGING, &tty->flags); tty 395 include/linux/tty.h static inline bool tty_io_error(struct tty_struct *tty) tty 397 include/linux/tty.h return test_bit(TTY_IO_ERROR, &tty->flags); tty 400 include/linux/tty.h static inline bool tty_throttled(struct tty_struct *tty) tty 402 include/linux/tty.h return test_bit(TTY_THROTTLED, &tty->flags); tty 406 include/linux/tty.h extern void tty_kref_put(struct tty_struct *tty); tty 407 include/linux/tty.h extern struct pid *tty_get_pgrp(struct tty_struct *tty); tty 410 include/linux/tty.h extern dev_t tty_devnum(struct tty_struct *tty); tty 415 include/linux/tty.h extern const char *tty_name(const struct tty_struct *tty); tty 417 include/linux/tty.h extern void tty_kclose(struct tty_struct *tty); tty 419 include/linux/tty.h extern int tty_ldisc_lock(struct tty_struct *tty, unsigned long timeout); tty 420 include/linux/tty.h extern void tty_ldisc_unlock(struct tty_struct *tty); tty 422 include/linux/tty.h static inline void tty_kref_put(struct tty_struct *tty) tty 424 include/linux/tty.h static inline struct pid *tty_get_pgrp(struct tty_struct *tty) tty 430 include/linux/tty.h static inline dev_t tty_devnum(struct tty_struct *tty) tty 439 include/linux/tty.h static inline const char *tty_name(const struct tty_struct *tty) tty 443 include/linux/tty.h static inline void tty_kclose(struct tty_struct *tty) tty 464 include/linux/tty.h static inline struct tty_struct *tty_kref_get(struct tty_struct *tty) tty 466 include/linux/tty.h if (tty) tty 467 include/linux/tty.h kref_get(&tty->kref); tty 468 include/linux/tty.h return tty; tty 471 include/linux/tty.h extern const char *tty_driver_name(const struct tty_struct *tty); tty 472 include/linux/tty.h extern void tty_wait_until_sent(struct tty_struct *tty, long timeout); tty 473 include/linux/tty.h extern int __tty_check_change(struct tty_struct *tty, int sig); tty 474 include/linux/tty.h extern int tty_check_change(struct tty_struct *tty); tty 475 include/linux/tty.h extern void __stop_tty(struct tty_struct *tty); tty 476 include/linux/tty.h extern void stop_tty(struct tty_struct *tty); tty 477 include/linux/tty.h extern void __start_tty(struct tty_struct *tty); tty 478 include/linux/tty.h extern void start_tty(struct tty_struct *tty); tty 488 include/linux/tty.h extern void tty_write_message(struct tty_struct *tty, char *msg); tty 489 include/linux/tty.h extern int tty_send_xchar(struct tty_struct *tty, char ch); tty 490 include/linux/tty.h extern int tty_put_char(struct tty_struct *tty, unsigned char c); tty 491 include/linux/tty.h extern int tty_chars_in_buffer(struct tty_struct *tty); tty 492 include/linux/tty.h extern int tty_write_room(struct tty_struct *tty); tty 493 include/linux/tty.h extern void tty_driver_flush_buffer(struct tty_struct *tty); tty 494 include/linux/tty.h extern void tty_throttle(struct tty_struct *tty); tty 495 include/linux/tty.h extern void tty_unthrottle(struct tty_struct *tty); tty 496 include/linux/tty.h extern int tty_throttle_safe(struct tty_struct *tty); tty 497 include/linux/tty.h extern int tty_unthrottle_safe(struct tty_struct *tty); tty 498 include/linux/tty.h extern int tty_do_resize(struct tty_struct *tty, struct winsize *ws); tty 500 include/linux/tty.h extern void tty_hangup(struct tty_struct *tty); tty 501 include/linux/tty.h extern void tty_vhangup(struct tty_struct *tty); tty 502 include/linux/tty.h extern void tty_vhangup_session(struct tty_struct *tty); tty 504 include/linux/tty.h extern void do_SAK(struct tty_struct *tty); tty 505 include/linux/tty.h extern void __do_SAK(struct tty_struct *tty); tty 506 include/linux/tty.h extern void tty_open_proc_set_tty(struct file *filp, struct tty_struct *tty); tty 507 include/linux/tty.h extern int tty_signal_session_leader(struct tty_struct *tty, int exit_session); tty 511 include/linux/tty.h extern void tty_buffer_flush(struct tty_struct *tty, struct tty_ldisc *ld); tty 521 include/linux/tty.h extern void tty_encode_baud_rate(struct tty_struct *tty, tty 534 include/linux/tty.h static inline speed_t tty_get_baud_rate(struct tty_struct *tty) tty 536 include/linux/tty.h return tty_termios_baud_rate(&tty->termios); tty 541 include/linux/tty.h extern int tty_set_termios(struct tty_struct *tty, struct ktermios *kt); tty 546 include/linux/tty.h extern void tty_ldisc_hangup(struct tty_struct *tty, bool reset); tty 547 include/linux/tty.h extern int tty_ldisc_reinit(struct tty_struct *tty, int disc); tty 550 include/linux/tty.h extern void tty_wakeup(struct tty_struct *tty); tty 551 include/linux/tty.h extern void tty_ldisc_flush(struct tty_struct *tty); tty 554 include/linux/tty.h extern int tty_mode_ioctl(struct tty_struct *tty, struct file *file, tty 556 include/linux/tty.h extern long tty_jobctrl_ioctl(struct tty_struct *tty, struct tty_struct *real_tty, tty 558 include/linux/tty.h extern int tty_perform_flush(struct tty_struct *tty, unsigned long arg); tty 562 include/linux/tty.h extern void tty_add_file(struct tty_struct *tty, struct file *file); tty 565 include/linux/tty.h extern void tty_release_struct(struct tty_struct *tty, int idx); tty 567 include/linux/tty.h extern void tty_init_termios(struct tty_struct *tty); tty 568 include/linux/tty.h extern void tty_save_termios(struct tty_struct *tty); tty 570 include/linux/tty.h struct tty_struct *tty); tty 574 include/linux/tty.h #define tty_is_writelocked(tty) (mutex_is_locked(&tty->atomic_write_lock)) tty 687 include/linux/tty.h extern void tty_port_tty_set(struct tty_port *port, struct tty_struct *tty); tty 695 include/linux/tty.h struct tty_struct *tty, struct file *filp); tty 697 include/linux/tty.h struct tty_struct *tty, struct file *filp); tty 698 include/linux/tty.h extern void tty_port_close_end(struct tty_port *port, struct tty_struct *tty); tty 700 include/linux/tty.h struct tty_struct *tty, struct file *filp); tty 702 include/linux/tty.h struct tty_struct *tty); tty 704 include/linux/tty.h struct tty_struct *tty, struct file *filp); tty 712 include/linux/tty.h extern int tty_set_ldisc(struct tty_struct *tty, int disc); tty 713 include/linux/tty.h extern int tty_ldisc_setup(struct tty_struct *tty, struct tty_struct *o_tty); tty 714 include/linux/tty.h extern void tty_ldisc_release(struct tty_struct *tty); tty 715 include/linux/tty.h extern int __must_check tty_ldisc_init(struct tty_struct *tty); tty 716 include/linux/tty.h extern void tty_ldisc_deinit(struct tty_struct *tty); tty 730 include/linux/tty.h extern void tty_audit_add_data(struct tty_struct *tty, const void *data, tty 734 include/linux/tty.h extern void tty_audit_tiocsti(struct tty_struct *tty, char ch); tty 737 include/linux/tty.h static inline void tty_audit_add_data(struct tty_struct *tty, const void *data, tty 741 include/linux/tty.h static inline void tty_audit_tiocsti(struct tty_struct *tty, char ch) tty 757 include/linux/tty.h extern int n_tty_ioctl_helper(struct tty_struct *tty, struct file *file, tty 762 include/linux/tty.h extern int vt_ioctl(struct tty_struct *tty, tty 765 include/linux/tty.h extern long vt_compat_ioctl(struct tty_struct *tty, tty 770 include/linux/tty.h extern void tty_lock(struct tty_struct *tty); tty 771 include/linux/tty.h extern int tty_lock_interruptible(struct tty_struct *tty); tty 772 include/linux/tty.h extern void tty_unlock(struct tty_struct *tty); tty 773 include/linux/tty.h extern void tty_lock_slave(struct tty_struct *tty); tty 774 include/linux/tty.h extern void tty_unlock_slave(struct tty_struct *tty); tty 775 include/linux/tty.h extern void tty_set_lock_subclass(struct tty_struct *tty); tty 785 include/linux/tty.h #define tty_msg(fn, tty, f, ...) \ tty 786 include/linux/tty.h fn("%s %s: " f, tty_driver_name(tty), tty_name(tty), ##__VA_ARGS__) tty 788 include/linux/tty.h #define tty_debug(tty, f, ...) tty_msg(pr_debug, tty, f, ##__VA_ARGS__) tty 789 include/linux/tty.h #define tty_info(tty, f, ...) tty_msg(pr_info, tty, f, ##__VA_ARGS__) tty 790 include/linux/tty.h #define tty_notice(tty, f, ...) tty_msg(pr_notice, tty, f, ##__VA_ARGS__) tty 791 include/linux/tty.h #define tty_warn(tty, f, ...) tty_msg(pr_warn, tty, f, ##__VA_ARGS__) tty 792 include/linux/tty.h #define tty_err(tty, f, ...) tty_msg(pr_err, tty, f, ##__VA_ARGS__) tty 794 include/linux/tty.h #define tty_info_ratelimited(tty, f, ...) \ tty 795 include/linux/tty.h tty_msg(pr_info_ratelimited, tty, f, ##__VA_ARGS__) tty 257 include/linux/tty_driver.h int (*install)(struct tty_driver *driver, struct tty_struct *tty); tty 258 include/linux/tty_driver.h void (*remove)(struct tty_driver *driver, struct tty_struct *tty); tty 259 include/linux/tty_driver.h int (*open)(struct tty_struct * tty, struct file * filp); tty 260 include/linux/tty_driver.h void (*close)(struct tty_struct * tty, struct file * filp); tty 261 include/linux/tty_driver.h void (*shutdown)(struct tty_struct *tty); tty 262 include/linux/tty_driver.h void (*cleanup)(struct tty_struct *tty); tty 263 include/linux/tty_driver.h int (*write)(struct tty_struct * tty, tty 265 include/linux/tty_driver.h int (*put_char)(struct tty_struct *tty, unsigned char ch); tty 266 include/linux/tty_driver.h void (*flush_chars)(struct tty_struct *tty); tty 267 include/linux/tty_driver.h int (*write_room)(struct tty_struct *tty); tty 268 include/linux/tty_driver.h int (*chars_in_buffer)(struct tty_struct *tty); tty 269 include/linux/tty_driver.h int (*ioctl)(struct tty_struct *tty, tty 271 include/linux/tty_driver.h long (*compat_ioctl)(struct tty_struct *tty, tty 273 include/linux/tty_driver.h void (*set_termios)(struct tty_struct *tty, struct ktermios * old); tty 274 include/linux/tty_driver.h void (*throttle)(struct tty_struct * tty); tty 275 include/linux/tty_driver.h void (*unthrottle)(struct tty_struct * tty); tty 276 include/linux/tty_driver.h void (*stop)(struct tty_struct *tty); tty 277 include/linux/tty_driver.h void (*start)(struct tty_struct *tty); tty 278 include/linux/tty_driver.h void (*hangup)(struct tty_struct *tty); tty 279 include/linux/tty_driver.h int (*break_ctl)(struct tty_struct *tty, int state); tty 280 include/linux/tty_driver.h void (*flush_buffer)(struct tty_struct *tty); tty 281 include/linux/tty_driver.h void (*set_ldisc)(struct tty_struct *tty); tty 282 include/linux/tty_driver.h void (*wait_until_sent)(struct tty_struct *tty, int timeout); tty 283 include/linux/tty_driver.h void (*send_xchar)(struct tty_struct *tty, char ch); tty 284 include/linux/tty_driver.h int (*tiocmget)(struct tty_struct *tty); tty 285 include/linux/tty_driver.h int (*tiocmset)(struct tty_struct *tty, tty 287 include/linux/tty_driver.h int (*resize)(struct tty_struct *tty, struct winsize *ws); tty 288 include/linux/tty_driver.h int (*set_termiox)(struct tty_struct *tty, struct termiox *tnew); tty 289 include/linux/tty_driver.h int (*get_icount)(struct tty_struct *tty, tty 291 include/linux/tty_driver.h int (*get_serial)(struct tty_struct *tty, struct serial_struct *p); tty 292 include/linux/tty_driver.h int (*set_serial)(struct tty_struct *tty, struct serial_struct *p); tty 293 include/linux/tty_driver.h void (*show_fdinfo)(struct tty_struct *tty, struct seq_file *m); tty 186 include/linux/tty_ldisc.h void (*flush_buffer)(struct tty_struct *tty); tty 187 include/linux/tty_ldisc.h ssize_t (*read)(struct tty_struct *tty, struct file *file, tty 189 include/linux/tty_ldisc.h ssize_t (*write)(struct tty_struct *tty, struct file *file, tty 191 include/linux/tty_ldisc.h int (*ioctl)(struct tty_struct *tty, struct file *file, tty 193 include/linux/tty_ldisc.h int (*compat_ioctl)(struct tty_struct *tty, struct file *file, tty 195 include/linux/tty_ldisc.h void (*set_termios)(struct tty_struct *tty, struct ktermios *old); tty 198 include/linux/tty_ldisc.h int (*hangup)(struct tty_struct *tty); tty 217 include/linux/tty_ldisc.h struct tty_struct *tty; tty 274 include/linux/usb/serial.h int (*open)(struct tty_struct *tty, struct usb_serial_port *port); tty 276 include/linux/usb/serial.h int (*write)(struct tty_struct *tty, struct usb_serial_port *port, tty 279 include/linux/usb/serial.h int (*write_room)(struct tty_struct *tty); tty 280 include/linux/usb/serial.h int (*ioctl)(struct tty_struct *tty, tty 282 include/linux/usb/serial.h int (*get_serial)(struct tty_struct *tty, struct serial_struct *ss); tty 283 include/linux/usb/serial.h int (*set_serial)(struct tty_struct *tty, struct serial_struct *ss); tty 284 include/linux/usb/serial.h void (*set_termios)(struct tty_struct *tty, tty 286 include/linux/usb/serial.h void (*break_ctl)(struct tty_struct *tty, int break_state); tty 287 include/linux/usb/serial.h int (*chars_in_buffer)(struct tty_struct *tty); tty 288 include/linux/usb/serial.h void (*wait_until_sent)(struct tty_struct *tty, long timeout); tty 290 include/linux/usb/serial.h void (*throttle)(struct tty_struct *tty); tty 291 include/linux/usb/serial.h void (*unthrottle)(struct tty_struct *tty); tty 292 include/linux/usb/serial.h int (*tiocmget)(struct tty_struct *tty); tty 293 include/linux/usb/serial.h int (*tiocmset)(struct tty_struct *tty, tty 295 include/linux/usb/serial.h int (*tiocmiwait)(struct tty_struct *tty, unsigned long arg); tty 296 include/linux/usb/serial.h int (*get_icount)(struct tty_struct *tty, tty 304 include/linux/usb/serial.h void (*init_termios)(struct tty_struct *tty); tty 341 include/linux/usb/serial.h extern int usb_serial_generic_open(struct tty_struct *tty, tty 345 include/linux/usb/serial.h extern int usb_serial_generic_write(struct tty_struct *tty, tty 349 include/linux/usb/serial.h extern int usb_serial_generic_write_room(struct tty_struct *tty); tty 350 include/linux/usb/serial.h extern int usb_serial_generic_chars_in_buffer(struct tty_struct *tty); tty 351 include/linux/usb/serial.h extern void usb_serial_generic_wait_until_sent(struct tty_struct *tty, tty 355 include/linux/usb/serial.h extern void usb_serial_generic_throttle(struct tty_struct *tty); tty 356 include/linux/usb/serial.h extern void usb_serial_generic_unthrottle(struct tty_struct *tty); tty 357 include/linux/usb/serial.h extern int usb_serial_generic_tiocmiwait(struct tty_struct *tty, tty 359 include/linux/usb/serial.h extern int usb_serial_generic_get_icount(struct tty_struct *tty, tty 372 include/linux/usb/serial.h struct tty_struct *tty, tty 58 include/linux/vt_kern.h int tioclinux(struct tty_struct *tty, unsigned long arg); tty 450 include/net/nfc/nci_core.h struct tty_struct *tty; tty 419 kernel/acct.c struct tty_struct *tty; tty 457 kernel/acct.c tty = current->signal->tty; /* Safe as we hold the siglock */ tty 458 kernel/acct.c ac->ac_tty = tty ? old_encode_dev(tty_devnum(tty)) : 0; tty 2111 kernel/audit.c struct tty_struct *tty = NULL; tty 2116 kernel/audit.c tty = tty_kref_get(current->signal->tty); tty 2118 kernel/audit.c return tty; tty 2121 kernel/audit.c void audit_put_tty(struct tty_struct *tty) tty 2123 kernel/audit.c tty_kref_put(tty); tty 2130 kernel/audit.c struct tty_struct *tty; tty 2136 kernel/audit.c tty = audit_get_tty(); tty 2152 kernel/audit.c tty ? tty_name(tty) : "(none)", tty 2154 kernel/audit.c audit_put_tty(tty); tty 2210 kernel/audit.c struct tty_struct *tty; tty 2222 kernel/audit.c tty = audit_get_tty(); tty 2227 kernel/audit.c oldloginuid, loginuid, tty ? tty_name(tty) : "(none)", tty 2229 kernel/audit.c audit_put_tty(tty); tty 247 kernel/audit.h extern void audit_put_tty(struct tty_struct *tty); tty 97 kernel/exit.c struct tty_struct *uninitialized_var(tty); tty 120 kernel/exit.c tty = sig->tty; tty 121 kernel/exit.c sig->tty = NULL; tty 172 kernel/exit.c tty_kref_put(tty); tty 2183 kernel/fork.c p->signal->tty = tty_kref_get(current->signal->tty); tty 111 net/bluetooth/rfcomm/tty.c static int rfcomm_dev_activate(struct tty_port *port, struct tty_struct *tty) tty 118 net/bluetooth/rfcomm/tty.c set_bit(TTY_IO_ERROR, &tty->flags); tty 320 net/bluetooth/rfcomm/tty.c struct device *tty; tty 330 net/bluetooth/rfcomm/tty.c tty = tty_port_register_device(&dev->port, rfcomm_tty_driver, tty 332 net/bluetooth/rfcomm/tty.c if (IS_ERR(tty)) { tty 334 net/bluetooth/rfcomm/tty.c return PTR_ERR(tty); tty 337 net/bluetooth/rfcomm/tty.c dev->tty_dev = tty; tty 440 net/bluetooth/rfcomm/tty.c struct tty_struct *tty; tty 466 net/bluetooth/rfcomm/tty.c tty = tty_port_tty_get(&dev->port); tty 467 net/bluetooth/rfcomm/tty.c if (tty) { tty 468 net/bluetooth/rfcomm/tty.c tty_vhangup(tty); tty 469 net/bluetooth/rfcomm/tty.c tty_kref_put(tty); tty 684 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_cleanup(struct tty_struct *tty) tty 686 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = tty->driver_data; tty 691 net/bluetooth/rfcomm/tty.c tty->driver_data = NULL; tty 707 net/bluetooth/rfcomm/tty.c static int rfcomm_tty_install(struct tty_driver *driver, struct tty_struct *tty) tty 713 net/bluetooth/rfcomm/tty.c dev = rfcomm_dev_get(tty->index); tty 721 net/bluetooth/rfcomm/tty.c tty->driver_data = dev; tty 726 net/bluetooth/rfcomm/tty.c err = tty_port_install(&dev->port, driver, tty); tty 728 net/bluetooth/rfcomm/tty.c rfcomm_tty_cleanup(tty); tty 745 net/bluetooth/rfcomm/tty.c static int rfcomm_tty_open(struct tty_struct *tty, struct file *filp) tty 747 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = tty->driver_data; tty 750 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p id %d", tty, tty->index); tty 755 net/bluetooth/rfcomm/tty.c err = tty_port_open(&dev->port, tty, filp); tty 771 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_close(struct tty_struct *tty, struct file *filp) tty 773 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 775 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p dev %p dlc %p opened %d", tty, dev, dev->dlc, tty 778 net/bluetooth/rfcomm/tty.c tty_port_close(&dev->port, tty, filp); tty 781 net/bluetooth/rfcomm/tty.c static int rfcomm_tty_write(struct tty_struct *tty, const unsigned char *buf, int count) tty 783 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 788 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p count %d", tty, count); tty 810 net/bluetooth/rfcomm/tty.c static int rfcomm_tty_write_room(struct tty_struct *tty) tty 812 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 818 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p room %d", tty, room); tty 823 net/bluetooth/rfcomm/tty.c static int rfcomm_tty_ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg) tty 825 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p cmd 0x%02x", tty, cmd); tty 856 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_set_termios(struct tty_struct *tty, struct ktermios *old) tty 858 net/bluetooth/rfcomm/tty.c struct ktermios *new = &tty->termios; tty 865 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 867 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p termios %p", tty, old); tty 995 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_throttle(struct tty_struct *tty) tty 997 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 999 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p dev %p", tty, dev); tty 1004 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_unthrottle(struct tty_struct *tty) tty 1006 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 1008 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p dev %p", tty, dev); tty 1013 net/bluetooth/rfcomm/tty.c static int rfcomm_tty_chars_in_buffer(struct tty_struct *tty) tty 1015 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 1017 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p dev %p", tty, dev); tty 1028 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_flush_buffer(struct tty_struct *tty) tty 1030 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 1032 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p dev %p", tty, dev); tty 1038 net/bluetooth/rfcomm/tty.c tty_wakeup(tty); tty 1041 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_send_xchar(struct tty_struct *tty, char ch) tty 1043 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p ch %c", tty, ch); tty 1046 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_wait_until_sent(struct tty_struct *tty, int timeout) tty 1048 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p timeout %d", tty, timeout); tty 1051 net/bluetooth/rfcomm/tty.c static void rfcomm_tty_hangup(struct tty_struct *tty) tty 1053 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 1055 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p dev %p", tty, dev); tty 1060 net/bluetooth/rfcomm/tty.c static int rfcomm_tty_tiocmget(struct tty_struct *tty) tty 1062 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 1064 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p dev %p", tty, dev); tty 1069 net/bluetooth/rfcomm/tty.c static int rfcomm_tty_tiocmset(struct tty_struct *tty, unsigned int set, unsigned int clear) tty 1071 net/bluetooth/rfcomm/tty.c struct rfcomm_dev *dev = (struct rfcomm_dev *) tty->driver_data; tty 1075 net/bluetooth/rfcomm/tty.c BT_DBG("tty %p dev %p set 0x%02x clear 0x%02x", tty, dev, set, clear); tty 86 net/nfc/nci/uart.c struct tty_struct *tty = nu->tty; tty 98 net/nfc/nci/uart.c set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 99 net/nfc/nci/uart.c len = tty->ops->write(tty, skb->data, skb->len); tty 117 net/nfc/nci/uart.c static int nci_uart_set_driver(struct tty_struct *tty, unsigned int driver) tty 133 net/nfc/nci/uart.c nu->tty = tty; tty 134 net/nfc/nci/uart.c tty->disc_data = nu; tty 141 net/nfc/nci/uart.c tty->disc_data = NULL; tty 145 net/nfc/nci/uart.c tty->disc_data = NULL; tty 163 net/nfc/nci/uart.c static int nci_uart_tty_open(struct tty_struct *tty) tty 168 net/nfc/nci/uart.c if (!tty->ops->write) tty 171 net/nfc/nci/uart.c tty->disc_data = NULL; tty 172 net/nfc/nci/uart.c tty->receive_room = 65536; tty 175 net/nfc/nci/uart.c tty_driver_flush_buffer(tty); tty 185 net/nfc/nci/uart.c static void nci_uart_tty_close(struct tty_struct *tty) tty 187 net/nfc/nci/uart.c struct nci_uart *nu = (void *)tty->disc_data; tty 190 net/nfc/nci/uart.c tty->disc_data = NULL; tty 201 net/nfc/nci/uart.c nu->tty = NULL; tty 217 net/nfc/nci/uart.c static void nci_uart_tty_wakeup(struct tty_struct *tty) tty 219 net/nfc/nci/uart.c struct nci_uart *nu = (void *)tty->disc_data; tty 224 net/nfc/nci/uart.c clear_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); tty 226 net/nfc/nci/uart.c if (tty != nu->tty) tty 244 net/nfc/nci/uart.c static void nci_uart_tty_receive(struct tty_struct *tty, const u8 *data, tty 247 net/nfc/nci/uart.c struct nci_uart *nu = (void *)tty->disc_data; tty 249 net/nfc/nci/uart.c if (!nu || tty != nu->tty) tty 256 net/nfc/nci/uart.c tty_unthrottle(tty); tty 272 net/nfc/nci/uart.c static int nci_uart_tty_ioctl(struct tty_struct *tty, struct file *file, tty 275 net/nfc/nci/uart.c struct nci_uart *nu = (void *)tty->disc_data; tty 281 net/nfc/nci/uart.c return nci_uart_set_driver(tty, (unsigned int)arg); tty 286 net/nfc/nci/uart.c err = n_tty_ioctl_helper(tty, file, cmd, arg); tty 294 net/nfc/nci/uart.c static ssize_t nci_uart_tty_read(struct tty_struct *tty, struct file *file, tty 300 net/nfc/nci/uart.c static ssize_t nci_uart_tty_write(struct tty_struct *tty, struct file *file, tty 306 net/nfc/nci/uart.c static __poll_t nci_uart_tty_poll(struct tty_struct *tty, tty 335 net/nfc/nci/uart.c nfc_err(nu->tty->dev, tty 380 net/nfc/nci/uart.c nfc_err(nu->tty->dev, "corrupted RX packet\n"); tty 437 net/nfc/nci/uart.c if (!nu->tty) tty 440 net/nfc/nci/uart.c down_read(&nu->tty->termios_rwsem); tty 441 net/nfc/nci/uart.c new_termios = nu->tty->termios; tty 442 net/nfc/nci/uart.c up_read(&nu->tty->termios_rwsem); tty 450 net/nfc/nci/uart.c tty_set_termios(nu->tty, &new_termios); tty 642 security/apparmor/file.c struct tty_struct *tty; tty 645 security/apparmor/file.c tty = get_current_tty(); tty 646 security/apparmor/file.c if (!tty) tty 649 security/apparmor/file.c spin_lock(&tty->files_lock); tty 650 security/apparmor/file.c if (!list_empty(&tty->tty_files)) { tty 654 security/apparmor/file.c file_priv = list_first_entry(&tty->tty_files, tty 661 security/apparmor/file.c spin_unlock(&tty->files_lock); tty 662 security/apparmor/file.c tty_kref_put(tty); tty 2455 security/selinux/hooks.c struct tty_struct *tty; tty 2459 security/selinux/hooks.c tty = get_current_tty(); tty 2460 security/selinux/hooks.c if (tty) { tty 2461 security/selinux/hooks.c spin_lock(&tty->files_lock); tty 2462 security/selinux/hooks.c if (!list_empty(&tty->tty_files)) { tty 2470 security/selinux/hooks.c file_priv = list_first_entry(&tty->tty_files, tty 2476 security/selinux/hooks.c spin_unlock(&tty->files_lock); tty 2477 security/selinux/hooks.c tty_kref_put(tty); tty 25 sound/soc/codecs/cx20442.c struct tty_struct *tty; tty 164 sound/soc/codecs/cx20442.c if (!cx20442->tty || !cx20442->tty->ops->write) tty 193 sound/soc/codecs/cx20442.c if (cx20442->tty->ops->write(cx20442->tty, buf, len) != len) tty 212 sound/soc/codecs/cx20442.c static int v253_open(struct tty_struct *tty) tty 217 sound/soc/codecs/cx20442.c if (!tty->ops->write) tty 221 sound/soc/codecs/cx20442.c if (!tty->disc_data) tty 224 sound/soc/codecs/cx20442.c tty->receive_room = 16; tty 225 sound/soc/codecs/cx20442.c if (tty->ops->write(tty, v253_init, len) != len) { tty 232 sound/soc/codecs/cx20442.c tty->disc_data = NULL; tty 237 sound/soc/codecs/cx20442.c static void v253_close(struct tty_struct *tty) tty 239 sound/soc/codecs/cx20442.c struct snd_soc_component *component = tty->disc_data; tty 242 sound/soc/codecs/cx20442.c tty->disc_data = NULL; tty 250 sound/soc/codecs/cx20442.c cx20442->tty = NULL; tty 255 sound/soc/codecs/cx20442.c static int v253_hangup(struct tty_struct *tty) tty 257 sound/soc/codecs/cx20442.c v253_close(tty); tty 262 sound/soc/codecs/cx20442.c static void v253_receive(struct tty_struct *tty, tty 265 sound/soc/codecs/cx20442.c struct snd_soc_component *component = tty->disc_data; tty 273 sound/soc/codecs/cx20442.c if (!cx20442->tty) { tty 277 sound/soc/codecs/cx20442.c cx20442->tty = tty; tty 283 sound/soc/codecs/cx20442.c static void v253_wakeup(struct tty_struct *tty) tty 382 sound/soc/codecs/cx20442.c cx20442->tty = NULL; tty 395 sound/soc/codecs/cx20442.c if (cx20442->tty) { tty 396 sound/soc/codecs/cx20442.c struct tty_struct *tty = cx20442->tty; tty 397 sound/soc/codecs/cx20442.c tty_hangup(tty); tty 281 sound/soc/ti/ams-delta.c static int cx81801_open(struct tty_struct *tty) tty 292 sound/soc/ti/ams-delta.c tty->disc_data = cx20442_codec; tty 294 sound/soc/ti/ams-delta.c ret = v253_ops.open(tty); tty 297 sound/soc/ti/ams-delta.c tty->disc_data = NULL; tty 303 sound/soc/ti/ams-delta.c static void cx81801_close(struct tty_struct *tty) tty 305 sound/soc/ti/ams-delta.c struct snd_soc_component *component = tty->disc_data; tty 316 sound/soc/ti/ams-delta.c v253_ops.close(tty); tty 333 sound/soc/ti/ams-delta.c static int cx81801_hangup(struct tty_struct *tty) tty 335 sound/soc/ti/ams-delta.c cx81801_close(tty); tty 340 sound/soc/ti/ams-delta.c static void cx81801_receive(struct tty_struct *tty, tty 343 sound/soc/ti/ams-delta.c struct snd_soc_component *component = tty->disc_data; tty 356 sound/soc/ti/ams-delta.c v253_ops.receive_buf(tty, cp, fp, count); tty 370 sound/soc/ti/ams-delta.c v253_ops.receive_buf(tty, cp, fp, count); tty 392 sound/soc/ti/ams-delta.c static void cx81801_wakeup(struct tty_struct *tty) tty 394 sound/soc/ti/ams-delta.c v253_ops.write_wakeup(tty);