/linux-6.3-rc2/include/linux/ |
A D | tty.h | 62 #define I_INPCK(tty) _I_FLAG((tty), INPCK) argument 64 #define I_INLCR(tty) _I_FLAG((tty), INLCR) argument 65 #define I_IGNCR(tty) _I_FLAG((tty), IGNCR) argument 66 #define I_ICRNL(tty) _I_FLAG((tty), ICRNL) argument 67 #define I_IUCLC(tty) _I_FLAG((tty), IUCLC) argument 68 #define I_IXON(tty) _I_FLAG((tty), IXON) argument 69 #define I_IXANY(tty) _I_FLAG((tty), IXANY) argument 70 #define I_IXOFF(tty) _I_FLAG((tty), IXOFF) argument 89 #define C_BAUD(tty) _C_FLAG((tty), CBAUD) argument 101 #define L_ISIG(tty) _L_FLAG((tty), ISIG) argument [all …]
|
A D | tty_driver.h | 357 void (*shutdown)(struct tty_struct *tty); 358 void (*cleanup)(struct tty_struct *tty); 359 int (*write)(struct tty_struct * tty, 365 int (*ioctl)(struct tty_struct *tty, 370 void (*throttle)(struct tty_struct * tty); 372 void (*stop)(struct tty_struct *tty); 373 void (*start)(struct tty_struct *tty); 374 void (*hangup)(struct tty_struct *tty); 380 int (*tiocmget)(struct tty_struct *tty); 381 int (*tiocmset)(struct tty_struct *tty, [all …]
|
A D | tty_ldisc.h | 218 int (*open)(struct tty_struct *tty); 219 void (*close)(struct tty_struct *tty); 220 void (*flush_buffer)(struct tty_struct *tty); 221 ssize_t (*read)(struct tty_struct *tty, struct file *file, 226 int (*ioctl)(struct tty_struct *tty, unsigned int cmd, 233 void (*hangup)(struct tty_struct *tty); 240 void (*write_wakeup)(struct tty_struct *tty); 241 void (*dcd_change)(struct tty_struct *tty, bool active); 252 struct tty_struct *tty; member 264 void tty_ldisc_flush(struct tty_struct *tty); [all …]
|
/linux-6.3-rc2/drivers/tty/ |
A D | tty_ldisc.c | 27 #define tty_ldisc_debug(tty, f, args...) tty_debug(tty, f, ##args) argument 168 ld->tty = tty; in tty_ldisc_get() 567 tty->ops->set_ldisc(tty); in tty_set_ldisc() 608 tty_ldisc_close(tty, tty->ldisc); in tty_ldisc_kill() 623 tty->termios = tty->driver->init_termios; in tty_reset_termios() 655 tty_ldisc_close(tty, tty->ldisc); in tty_ldisc_reinit() 662 retval = tty_ldisc_open(tty, tty->ldisc); in tty_ldisc_reinit() 689 tty_ldisc_debug(tty, "%p: hangup\n", tty->ldisc); in tty_ldisc_hangup() 720 if (tty_ldisc_reinit(tty, tty->termios.c_line) < 0 && in tty_ldisc_hangup() 740 int retval = tty_ldisc_open(tty, tty->ldisc); in tty_ldisc_setup() [all …]
|
A D | n_tty.c | 786 tty->ops->flush_chars(tty); in commit_echoes() 803 tty->ops->flush_chars(tty); in process_echoes() 979 if (!L_ECHOK(tty) || !L_ECHOKE(tty) || !L_ECHOE(tty)) { in eraser() 1289 if (tty->flow.stopped && !tty->flow.tco_stopped && I_IXON(tty) && I_IXANY(tty)) { in n_tty_receive_char_special() 1321 if (c == REPRINT_CHAR(tty) && L_ECHO(tty) && L_IEXTEN(tty)) { in n_tty_receive_char_special() 1410 if (tty->flow.stopped && !tty->flow.tco_stopped && I_IXON(tty) && I_IXANY(tty)) { in n_tty_receive_char() 1617 tty->ops->flush_chars(tty); in __receive_buf() 1784 if (I_ISTRIP(tty) || I_IUCLC(tty) || I_IGNCR(tty) || in n_tty_set_termios() 1785 I_ICRNL(tty) || I_INLCR(tty) || L_ICANON(tty) || in n_tty_set_termios() 1786 I_IXON(tty) || L_ISIG(tty) || L_ECHO(tty) || in n_tty_set_termios() [all …]
|
A D | tty_io.c | 199 priv->tty = tty; in tty_add_file() 253 if (!tty || !tty->driver) in tty_driver_name() 461 if (tty && tty->ops && tty->ops->show_fdinfo) in tty_show_fdinfo() 654 tty->ops->hangup(tty); in __tty_hangup() 756 tty->ops->stop(tty); in __stop_tty() 789 tty->ops->start(tty); in __start_tty() 1078 if (!tty || !tty->ops->write || tty_io_error(tty)) in file_tty_write() 1432 tty->port->itty = tty; in tty_init_dev() 1530 tty->ops->cleanup(tty); in release_one_tty() 1588 tty->ops->shutdown(tty); in release_tty() [all …]
|
A D | tty_ioctl.c | 61 return tty->ops->chars_in_buffer(tty); in tty_chars_in_buffer() 80 return tty->ops->write_room(tty); in tty_write_room() 96 tty->ops->flush_buffer(tty); in tty_driver_flush_buffer() 118 tty->ops->unthrottle(tty); in tty_unthrottle() 148 tty->ops->throttle(tty); in tty_throttle_safe() 179 tty->ops->unthrottle(tty); in tty_unthrottle_safe() 214 tty->ops->wait_until_sent(tty, timeout); in tty_wait_until_sent() 363 tty->ops->set_termios(tty, &old_termios); in tty_set_termios() 745 tty->ops->set_termios(tty, &old); in tty_change_softcar() 963 retval = tty_send_xchar(tty, STOP_CHAR(tty)); in n_tty_ioctl_helper() [all …]
|
A D | pty.c | 36 # define tty_debug_hangup(tty, f, args...) tty_debug(tty, f, ##args) argument 64 if (!tty->link) in pty_close() 195 if (tty->link) { in pty_signal() 222 if (!tty || !tty->link) in pty_open() 246 if (tty->link && tty->link->ctrl.packet) { in pty_set_termios() 326 if (tty->link && tty->link->ctrl.packet) { in pty_start() 339 if (tty->link && tty->link->ctrl.packet) { in pty_stop() 419 tty->count++; in pty_common_install() 714 if (!tty) in pts_unix98_lookup() 716 return tty; in pts_unix98_lookup() [all …]
|
A D | tty_jobctrl.c | 39 if (current->signal->tty != tty) in __tty_check_change() 81 tty = p->signal->tty; in proc_clear_tty() 118 current->signal->tty = tty_kref_get(tty); in __proc_set_tty() 166 tty = tty_kref_get(current->signal->tty); in get_current_tty() 168 return tty; in get_current_tty() 206 if (p->signal->tty == tty) { in tty_signal_session_leader() 273 if (tty) { in disassociate_ctty() 306 tty = tty_kref_get(current->signal->tty); in disassociate_ctty() 309 if (tty) { in disassociate_ctty() 469 if (tty == real_tty && current->signal->tty != real_tty) in tiocgpgrp() [all …]
|
A D | tty.h | 9 #define tty_msg(fn, tty, f, ...) \ argument 10 fn("%s %s: " f, tty_driver_name(tty), tty_name(tty), ##__VA_ARGS__) 12 #define tty_debug(tty, f, ...) tty_msg(pr_debug, tty, f, ##__VA_ARGS__) argument 13 #define tty_notice(tty, f, ...) tty_msg(pr_notice, tty, f, ##__VA_ARGS__) argument 14 #define tty_warn(tty, f, ...) tty_msg(pr_warn, tty, f, ##__VA_ARGS__) argument 15 #define tty_err(tty, f, ...) tty_msg(pr_err, tty, f, ##__VA_ARGS__) argument 17 #define tty_info_ratelimited(tty, f, ...) \ argument 49 tty->flow_change = val; in __tty_set_flow_change() 54 tty->flow_change = val; in tty_set_flow_change() 63 void __stop_tty(struct tty_struct *tty); [all …]
|
A D | tty_mutex.c | 15 void tty_lock(struct tty_struct *tty) in tty_lock() argument 17 tty_kref_get(tty); in tty_lock() 18 mutex_lock(&tty->legacy_mutex); in tty_lock() 26 tty_kref_get(tty); in tty_lock_interruptible() 29 tty_kref_put(tty); in tty_lock_interruptible() 35 mutex_unlock(&tty->legacy_mutex); in tty_unlock() 36 tty_kref_put(tty); in tty_unlock() 42 if (tty && tty != tty->link) in tty_lock_slave() 43 tty_lock(tty); in tty_lock_slave() 48 if (tty && tty != tty->link) in tty_unlock_slave() [all …]
|
A D | tty_port.c | 32 if (!tty) in tty_port_default_receive_buf() 53 if (!tty) in tty_port_default_lookahead_buf() 70 if (tty) { in tty_port_default_wakeup() 71 tty_wakeup(tty); in tty_port_default_wakeup() 328 tty = tty_kref_get(port->tty); in tty_port_tty_get() 330 return tty; in tty_port_tty_get() 348 port->tty = tty_kref_get(tty); in tty_port_tty_set() 375 if (tty && C_HUPCL(tty)) in tty_port_shutdown() 401 tty = port->tty; in tty_port_hangup() 402 if (tty) in tty_port_hangup() [all …]
|
A D | amiserial.c | 340 if (port->tty) in check_modem_status() 493 if (C_BAUD(tty)) in startup() 656 if (I_BRKINT(tty) || I_PARMRK(tty)) in change_speed() 809 tty_wakeup(tty); in rs_flush_buffer() 857 rs_send_xchar(tty, STOP_CHAR(tty)); in rs_throttle() 879 rs_send_xchar(tty, START_CHAR(tty)); in rs_unthrottle() 899 tty_lock(tty); in get_serial_info() 925 tty_lock(tty); in set_serial_info() 1191 if (!C_CRTSCTS(tty) || !tty_throttled(tty)) in rs_set_termios() 1201 rs_start(tty); in rs_set_termios() [all …]
|
A D | n_hdlc.c | 201 tty->disc_data = NULL; in n_hdlc_tty_close() 241 n_hdlc->tty_for_write_work = tty; in n_hdlc_tty_open() 242 tty->disc_data = n_hdlc; in n_hdlc_tty_open() 243 tty->receive_room = 65536; in n_hdlc_tty_open() 249 tty_driver_flush_buffer(tty); in n_hdlc_tty_open() 288 actual = tty->ops->write(tty, tbuf->buf, tbuf->count); in n_hdlc_send_frames() 346 n_hdlc_send_frames(n_hdlc, tty); in n_hdlc_tty_write_work() 411 if (tty->fasync != NULL) in n_hdlc_tty_receive() 568 n_hdlc_send_frames(n_hdlc, tty); in n_hdlc_tty_write() 626 flush_tx_queue(tty); in n_hdlc_tty_ioctl() [all …]
|
A D | vcc.c | 279 if (WARN_ON(!tty || !tty->port)) in vcc_rx_check() 296 if (WARN_ON(!tty || !tty->port)) in vcc_rx() 313 tty = port->tty; in vcc_ldc_read() 314 if (!tty) { in vcc_ldc_read() 413 struct tty_struct *tty = port->tty; in vcc_tx_timer() local 416 if (tty) in vcc_tx_timer() 683 if (port->tty) in vcc_remove() 697 if (port->tty) { in vcc_remove() 756 return tty_port_open(tty->port, tty, vcc_file); in vcc_open() 769 tty_port_close(tty->port, tty, vcc_file); in vcc_close() [all …]
|
/linux-6.3-rc2/drivers/tty/ipwireless/ |
A D | tty.c | 92 if (!tty) in ipw_open() 101 tty->port.tty = linux_tty; in ipw_open() 117 struct tty_struct *linux_tty = tty->port.tty; in do_ipw_close() 120 tty->port.tty = NULL; in do_ipw_close() 133 if (!tty) in ipw_hangup() 195 if (!tty) in ipw_write() 236 if (!tty) in ipw_write_room() 254 if (!tty) in ipwireless_get_serial_info() 276 if (!tty) in ipw_chars_in_buffer() 623 && tty->port.tty) { in ipwireless_tty_notify_control_line_change() [all …]
|
/linux-6.3-rc2/drivers/tty/serdev/ |
A D | serdev-ttyport.c | 80 struct tty_struct *tty = serport->tty; in ttyport_write_buf() local 92 struct tty_struct *tty = serport->tty; in ttyport_write_flush() local 100 struct tty_struct *tty = serport->tty; in ttyport_write_room() local 115 serport->tty = tty; in ttyport_open() 146 tty->ops->close(tty, NULL); in ttyport_open() 157 struct tty_struct *tty = serport->tty; in ttyport_close() local 163 tty->ops->close(tty, NULL); in ttyport_close() 172 struct tty_struct *tty = serport->tty; in ttyport_set_baudrate() local 186 struct tty_struct *tty = serport->tty; in ttyport_set_flow_control() local 201 struct tty_struct *tty = serport->tty; in ttyport_set_parity() local [all …]
|
/linux-6.3-rc2/drivers/accessibility/speakup/ |
A D | spk_ttyio.c | 156 if (IS_ERR(tty)) in spk_ttyio_initialise_ldisc() 160 ret = tty->ops->open(tty, NULL); in spk_ttyio_initialise_ldisc() 185 tty_unlock(tty); in spk_ttyio_initialise_ldisc() 204 tty_lock(tty); in spk_ttyio_initialise_ldisc() 206 tty->ops->close(tty, NULL); in spk_ttyio_initialise_ldisc() 233 ret = tty->ops->write(tty, &ch, 1); in spk_ttyio_out() 276 tty->ops->send_xchar(tty, ch); in spk_ttyio_send_xchar() 284 tty->ops->tiocmset(tty, set, clear); in spk_ttyio_tiocmset() 337 tty->ops->flush_buffer(tty); in spk_ttyio_flush_buffer() 360 tty_lock(tty); in spk_ttyio_release() [all …]
|
A D | selection.c | 39 tty = xchg(&ssw->tty, NULL); in __speakup_set_selection() 54 tty_kref_put(tty); in __speakup_set_selection() 70 tty_kref_get(tty); in speakup_set_selection() 71 if (cmpxchg(&speakup_sel_work.tty, NULL, tty)) { in speakup_set_selection() 101 tty = xchg(&speakup_sel_work.tty, NULL); in speakup_cancel_selection() 102 if (tty) in speakup_cancel_selection() 110 struct tty_struct *tty = xchg(&ssw->tty, NULL); in __speakup_paste_selection() local 113 tty_kref_put(tty); in __speakup_paste_selection() 124 if (cmpxchg(&speakup_paste_work.tty, NULL, tty)) { in speakup_paste_selection() 138 tty = xchg(&speakup_paste_work.tty, NULL); in speakup_cancel_paste() [all …]
|
/linux-6.3-rc2/net/nfc/nci/ |
A D | uart.c | 74 struct tty_struct *tty = nu->tty; in nci_uart_write_work() local 87 len = tty->ops->write(tty, skb->data, skb->len); in nci_uart_write_work() 121 nu->tty = tty; in nci_uart_set_driver() 122 tty->disc_data = nu; in nci_uart_set_driver() 156 if (!tty->ops->write) in nci_uart_tty_open() 159 tty->disc_data = NULL; in nci_uart_tty_open() 189 nu->tty = NULL; in nci_uart_tty_close() 214 if (tty != nu->tty) in nci_uart_tty_wakeup() 303 if (!nu || tty != nu->tty) in nci_uart_tty_receive() 310 tty_unthrottle(tty); in nci_uart_tty_receive() [all …]
|
/linux-6.3-rc2/drivers/usb/serial/ |
A D | upd78f0730.c | 267 struct tty_struct *tty = port->port.tty; in upd78f0730_dtr_rts() local 309 if (C_BAUD(tty) == B0) in upd78f0730_set_termios() 320 switch (C_CSIZE(tty)) { in upd78f0730_set_termios() 327 tty->termios.c_cflag |= CS8; in upd78f0730_set_termios() 336 if (C_PARENB(tty)) { in upd78f0730_set_termios() 337 if (C_PARODD(tty)) { in upd78f0730_set_termios() 345 if (C_CMSPAR(tty)) { in upd78f0730_set_termios() 354 if (C_CSTOPB(tty)) { in upd78f0730_set_termios() 362 if (C_CRTSCTS(tty)) { in upd78f0730_set_termios() 366 if (I_IXOFF(tty) || I_IXON(tty)) { in upd78f0730_set_termios() [all …]
|
/linux-6.3-rc2/drivers/input/serio/ |
A D | serport.c | 32 struct tty_struct *tty; member 47 return -(serport->tty->ops->write(serport->tty, &data, 1) != 1); in serport_serio_write() 78 static int serport_ldisc_open(struct tty_struct *tty) in serport_ldisc_open() argument 89 serport->tty = tty; in serport_ldisc_open() 93 tty->disc_data = serport; in serport_ldisc_open() 94 tty->receive_room = 256; in serport_ldisc_open() 95 set_bit(TTY_DO_WRITE_WAKEUP, &tty->flags); in serport_ldisc_open() 182 serio->dev.parent = tty->dev; in serport_ldisc_read() 199 struct serport *serport = tty->disc_data; in serport_set_type() 219 serport_set_type(tty, type); in serport_ldisc_ioctl() [all …]
|
/linux-6.3-rc2/drivers/bluetooth/ |
A D | hci_ldisc.c | 148 struct tty_struct *tty = hu->tty; in hci_uart_write_work() local 163 len = tty->ops->write(tty, skb->data, skb->len); in hci_uart_write_work() 228 struct tty_struct *tty = hu->tty; in hci_uart_flush() local 310 struct tty_struct *tty = hu->tty; in hci_uart_set_flow_control() local 332 status = tty->driver->ops->tiocmget(tty); in hci_uart_set_flow_control() 345 status = tty->driver->ops->tiocmget(tty); in hci_uart_set_flow_control() 375 struct tty_struct *tty = hu->tty; in hci_uart_set_baudrate() local 386 tty->termios.c_ispeed, tty->termios.c_ospeed); in hci_uart_set_baudrate() 503 hu->tty = tty; in hci_uart_tty_open() 582 if (tty != hu->tty) in hci_uart_tty_wakeup() [all …]
|
/linux-6.3-rc2/sound/soc/codecs/ |
A D | cx20442.c | 25 struct tty_struct *tty; member 164 if (!cx20442->tty || !cx20442->tty->ops->write) in cx20442_write() 193 if (cx20442->tty->ops->write(cx20442->tty, buf, len) != len) in cx20442_write() 221 if (!tty->disc_data) in v253_open() 225 if (tty->ops->write(tty, v253_init, len) != len) { in v253_open() 250 cx20442->tty = NULL; in v253_close() 257 v253_close(tty); in v253_hangup() 276 cx20442->tty = tty; in v253_receive() 387 if (cx20442->tty) { in cx20442_component_remove() 388 struct tty_struct *tty = cx20442->tty; in cx20442_component_remove() local [all …]
|
/linux-6.3-rc2/drivers/mmc/core/ |
A D | sdio_uart.c | 429 tty->flow.stopped || tty->hw_stopped) { in sdio_uart_transmit_chars() 431 tty_kref_put(tty); in sdio_uart_transmit_chars() 443 tty_wakeup(tty); in sdio_uart_transmit_chars() 447 tty_kref_put(tty); in sdio_uart_transmit_chars() 477 if (tty && C_CRTSCTS(tty)) { in sdio_uart_check_modem_status() 492 tty_kref_put(tty); in sdio_uart_check_modem_status() 631 if (C_BAUD(tty)) in sdio_uart_activate() 634 if (C_CRTSCTS(tty)) in sdio_uart_activate() 816 if (!I_IXOFF(tty) && !C_CRTSCTS(tty)) in sdio_uart_throttle() 822 if (I_IXOFF(tty)) { in sdio_uart_throttle() [all …]
|