Esempio n. 1
0
static void acm_tty_hangup(struct tty_struct *tty)
{
	struct acm *acm = tty->driver_data;
	tty_port_hangup(&acm->port);
	mutex_lock(&open_mutex);
	acm_port_down(acm);
	mutex_unlock(&open_mutex);
}
Esempio n. 2
0
static void acm_tty_close(struct tty_struct *tty, struct file *filp)
{
	struct acm *acm = tty->driver_data;

	/* Perform the closing process and see if we need to do the hardware
	   shutdown */
	if (!acm || tty_port_close_start(&acm->port, tty, filp) == 0)
		return;
	acm_port_down(acm, 0);
	tty_port_close_end(&acm->port, tty);
	mutex_lock(&open_mutex);
	tty_port_tty_set(&acm->port, NULL);
	if (!acm->dev)
		acm_tty_unregister(acm);
	mutex_unlock(&open_mutex);
}
Esempio n. 3
0
static void acm_tty_hangup(struct tty_struct *tty)
{
	struct acm *acm = tty->driver_data;
	tty_port_hangup(&acm->port);
	acm_port_down(acm);
}