Lines Matching refs:tp
70 typedef int xencons_init_t(device_t dev, struct tty *tp,
227 xencons_init_hypervisor(device_t dev, struct tty *tp,
233 cons = tty_softc(tp);
236 intr_handler, tp, INTR_TYPE_TTY | INTR_MPSAFE, &cons->intr_handle);
280 xencons_init_ring(device_t dev, struct tty *tp, driver_intr_t intr_handler)
285 cons = tty_softc(tp);
291 intr_handler, tp, INTR_TYPE_TTY | INTR_MPSAFE, &cons->intr_handle);
509 xencons_tx(struct tty *tp)
515 cons = tty_softc(tp);
517 tty_assert_locked(tp);
527 while (!cons_full && ttydisc_getc(tp, &c, 1) == 1)
536 struct tty *tp;
540 tp = arg;
541 cons = tty_softc(tp);
557 tty_lock(tp);
562 ttydisc_rint(tp, ret, 0);
564 ttydisc_rint_done(tp);
565 tty_unlock(tp);
578 struct tty *tp;
580 tp = arg;
582 xencons_tx_flush(tty_softc(tp), 1);
643 xencons_tty_open(struct tty *tp)
647 cons = tty_softc(tp);
655 xencons_tty_close(struct tty *tp)
659 cons = tty_softc(tp);
667 struct tty *tp;
670 tp = v;
671 cons = tty_softc(tp);
673 if (!xencons_tx(tp))
675 xencons_timeout, tp);
679 xencons_tty_outwakeup(struct tty *tp)
683 cons = tty_softc(tp);
687 if (!xencons_tx(tp))
689 xencons_timeout, tp);
722 struct tty *tp;
732 tp = tty_alloc(&xencons_ttydevsw, cons);
733 tty_makedev(tp, NULL, "%s%r", driver_name, 0);
734 device_set_softc(dev, tp);
736 callout_init_mtx(&cons->callout, tty_getlock(tp), 0);
738 err = cons->ops->init(dev, tp, xencons_intr);
747 tp, SHUTDOWN_PRI_DEFAULT)) == NULL)
757 struct tty *tp;
760 tp = device_get_softc(dev);
761 cons = tty_softc(tp);
764 err = cons->ops->init(dev, tp, xencons_intr);