コード例 #1
0
/*
 * For all online tty's, try sending data to
 * the lower levels.
 */
static void
ctc_tty_task(ctc_tty_info *info)
{
	unsigned long saveflags;
	int again;

	spin_lock_irqsave(&ctc_tty_lock, saveflags);
	if ((!ctc_tty_shuttingdown) && info) {
		again = ctc_tty_tint(info);
		if (!again)
			info->lsr |= UART_LSR_TEMT;
		again |= ctc_tty_readmodem(info);
		if (again) {
			queue_task(&info->tq, &tq_immediate);
			mark_bh(IMMEDIATE_BH);
		}
	}
	spin_unlock_irqrestore(&ctc_tty_lock, saveflags);
}
コード例 #2
0
/*
 * For all online tty's, try sending data to
 * the lower levels.
 */
static void
ctc_tty_task(unsigned long arg)
{
	ctc_tty_info *info = (void *)arg;
	unsigned long saveflags;
	int again;

	DBF_TEXT(trace, 3, __FUNCTION__);
	spin_lock_irqsave(&ctc_tty_lock, saveflags);
	if ((!ctc_tty_shuttingdown) && info) {
		again = ctc_tty_tint(info);
		if (!again)
			info->lsr |= UART_LSR_TEMT;
		again |= ctc_tty_readmodem(info);
		if (again) {
			tasklet_schedule(&info->tasklet);
		}
	}
	spin_unlock_irqrestore(&ctc_tty_lock, saveflags);
}