/* This routine is called when the 3270 tty is closed. We wait for the remaining request to be completed. Then we clean up.  */
static void tty3270_close(struct tty_struct *tty, struct file *filp)
/* This routine is called when the 3270 tty is closed. We wait for the remaining request to be completed. Then we clean up.  */
static void tty3270_close(struct tty_struct *tty, struct file *filp)
{
	struct tty3270 *tp;
	if (tty->count > 1)
		return;
	tp = (struct tty3270 *) tty->driver_data;
	if (tp) {
		tty->driver_data = NULL;
		tp->tty = tp->kbd->tty = NULL;
		raw3270_put_view(&tp->view);
	}
}