ttywait
ttywait(sp->s_ttyp);
error = ttywait(tp);
if ((error = ttywait(tp)) == 0)
int ttywait (struct tty *tp);