本文整理汇总了C++中I_IXOFF函数的典型用法代码示例。如果您正苦于以下问题:C++ I_IXOFF函数的具体用法?C++ I_IXOFF怎么用?C++ I_IXOFF使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了I_IXOFF函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: xmbrs_unthrottle
static void xmbrs_unthrottle(struct tty_struct * tty)
{
struct xmb_serial *info = (struct xmb_serial *)tty->driver_data;
#ifdef SERIAL_DEBUG_THROTTLE
char buf[64];
printk("unthrottle %s: %d....\n", _tty_name(tty, buf),
tty->ldisc.chars_in_buffer(tty));
#endif
if (serial_paranoia_check(info, tty->device, "xmbrs_unthrottle"))
return;
if (I_IXOFF(tty)) {
if (info->x_char)
info->x_char = 0;
else {
/* Force START_CHAR (xon) out */
volatile unsigned int *uartp;
unsigned long flags;
info->x_char = START_CHAR(tty);
uartp = (volatile unsigned int *) info->addr;
save_flags_cli(flags);
EnableInterrupts(uartp);
force_tx_fifo_fill(info);
restore_flags(flags);
}
}
}
示例2: rs_throttle
/*
* ------------------------------------------------------------
* rs_throttle()
*
* This routine is called by the upper-layer tty layer to signal that
* incoming characters should be throttled.
* ------------------------------------------------------------
*/
static void rs_throttle(struct tty_struct * tty)
{
if (I_IXOFF(tty))
rs_send_xchar(tty, STOP_CHAR(tty));
printk(KERN_INFO "simrs_throttle called\n");
}
示例3: rs_360_unthrottle
static void rs_360_unthrottle(struct tty_struct * tty)
{
ser_info_t *info = (ser_info_t *)tty->driver_data;
#ifdef SERIAL_DEBUG_THROTTLE
char buf[64];
printk("unthrottle %s: %d....\n", _tty_name(tty, buf),
tty->ldisc.chars_in_buffer(tty));
#endif
if (serial_paranoia_check(info, tty->name, "rs_unthrottle"))
return;
if (I_IXOFF(tty)) {
if (info->x_char)
info->x_char = 0;
else
rs_360_send_xchar(tty, START_CHAR(tty));
}
#ifdef modem_control
if (tty->termios->c_cflag & CRTSCTS)
info->MCR |= UART_MCR_RTS;
local_irq_disable();
serial_out(info, UART_MCR, info->MCR);
local_irq_enable();
#endif
}
示例4: dz_throttle
/*
* ------------------------------------------------------------
* dz_throttle () and dz_unthrottle ()
*
* This routine is called by the upper-layer tty layer to signal that
* incoming characters should be throttled (or not).
* ------------------------------------------------------------
*/
static void dz_throttle(struct tty_struct *tty)
{
struct dz_serial *info = (struct dz_serial *) tty->driver_data;
if (I_IXOFF(tty))
info->x_char = STOP_CHAR(tty);
}
示例5: rs_unthrottle
static void rs_unthrottle(struct tty_struct * tty)
{
struct serial_state *info = tty->driver_data;
unsigned long flags;
#ifdef SERIAL_DEBUG_THROTTLE
char buf[64];
printk("unthrottle %s: %d....\n", tty_name(tty, buf),
tty->ldisc.chars_in_buffer(tty));
#endif
if (serial_paranoia_check(info, tty->name, "rs_unthrottle"))
return;
if (I_IXOFF(tty)) {
if (info->x_char)
info->x_char = 0;
else
rs_send_xchar(tty, START_CHAR(tty));
}
if (tty->termios->c_cflag & CRTSCTS)
info->MCR |= SER_RTS;
local_irq_save(flags);
rtsdtr_ctrl(info->MCR);
local_irq_restore(flags);
}
示例6: sio_unthrottle
static void sio_unthrottle(struct tty_struct *tty)
{
if (I_IXOFF(tty)) {
if (x_char)
x_char = 0;
else
sio_send_xchar(tty, START_CHAR(tty));
}
}
示例7: dz_unthrottle
static void dz_unthrottle(struct tty_struct *tty)
{
struct dz_serial *info = (struct dz_serial *) tty->driver_data;
if (I_IXOFF(tty)) {
if (info->x_char)
info->x_char = 0;
else
info->x_char = START_CHAR(tty);
}
}
示例8: rs_unthrottle
static void rs_unthrottle(struct tty_struct * tty)
{
struct serial_state *info = tty->driver_data;
if (I_IXOFF(tty)) {
if (info->x_char)
info->x_char = 0;
else
rs_send_xchar(tty, START_CHAR(tty));
}
printk(KERN_INFO "simrs_unthrottle called\n");
}
示例9: ctc_tty_unthrottle
static void
ctc_tty_unthrottle(struct tty_struct *tty)
{
ctc_tty_info *info = (ctc_tty_info *) tty->driver_data;
if (ctc_tty_paranoia_check(info, tty->device, "ctc_tty_unthrottle"))
return;
info->mcr |= UART_MCR_RTS;
if (I_IXOFF(tty))
ctc_tty_inject(info, START_CHAR(tty));
ctc_tty_transmit_status(info);
}
示例10: ctc_tty_throttle
/*
* ------------------------------------------------------------
* ctc_tty_throttle()
*
* This routine is called by the upper-layer tty layer to signal that
* incoming characters should be throttled.
* ------------------------------------------------------------
*/
static void
ctc_tty_throttle(struct tty_struct *tty)
{
ctc_tty_info *info = (ctc_tty_info *) tty->driver_data;
DBF_TEXT(trace, 4, __FUNCTION__);
if (ctc_tty_paranoia_check(info, tty->name, "ctc_tty_throttle"))
return;
info->mcr &= ~UART_MCR_RTS;
if (I_IXOFF(tty))
ctc_tty_inject(info, STOP_CHAR(tty));
ctc_tty_transmit_status(info);
}
示例11: scc_unthrottle
static void scc_unthrottle (struct tty_struct * tty)
{
struct scc_port *port = tty->driver_data;
unsigned long flags;
SCC_ACCESS_INIT(port);
if (tty->termios->c_cflag & CRTSCTS) {
local_irq_save(flags);
SCCmod(TX_CTRL_REG, 0xff, TCR_RTS);
local_irq_restore(flags);
}
if (I_IXOFF(tty))
scc_send_xchar(tty, START_CHAR(tty));
}
示例12: scc_throttle
static void scc_throttle (struct tty_struct * tty)
{
struct scc_port *port = (struct scc_port *)tty->driver_data;
unsigned long flags;
SCC_ACCESS_INIT(port);
if (tty->termios->c_cflag & CRTSCTS) {
save_flags(flags);
cli();
SCCmod(TX_CTRL_REG, ~TCR_RTS, 0);
restore_flags(flags);
}
if (I_IXOFF(tty))
scc_send_xchar(tty, STOP_CHAR(tty));
}
示例13: nullmodem_unthrottle
static void nullmodem_unthrottle(struct tty_struct * tty)
{
unsigned long flags;
struct nullmodem_end *end = tty->driver_data;
dprintf("%s - #%d\n", __FUNCTION__, tty->index);
if (tty->termios.c_cflag & CRTSCTS)
{
spin_lock_irqsave(&end->pair->spin, flags);
change_pins(end, TIOCM_RTS, 0);
spin_unlock_irqrestore(&end->pair->spin, flags);
}
if (I_IXOFF(tty))
nullmodem_send_xchar(tty, START_CHAR(tty));
}
示例14: rs_throttle
/*
* Throttle characters as directed by upper tty layer
*/
static void rs_throttle(struct tty_struct * tty)
{
#ifdef TX3912_UART_DEBUG_THROTTLE
char buf[64];
printk("throttle %s: %d....\n", tty_name(tty, buf),
tty->ldisc.chars_in_buffer(tty));
#endif
func_enter();
if (I_IXOFF(tty))
rs_send_xchar(tty, STOP_CHAR(tty));
func_exit();
}
示例15: tty_receive_char
static void tty_receive_char(struct tty_struct *tty, char ch)
{
if(tty == NULL) return;
if(I_IXON(tty) && !I_IXOFF(tty) && !tty->raw) {
if(ch == STOP_CHAR(tty)){
stop_tty(tty);
return;
}
else if(ch == START_CHAR(tty)){
start_tty(tty);
return;
}
}
tty_insert_flip_char(tty, ch, TTY_NORMAL);
}