Changeset View
Changeset View
Standalone View
Standalone View
head/sys/kern/tty.c
Show First 20 Lines • Show All 1,199 Lines • ▼ Show 20 Lines | tty_to_xtty(struct tty *tp, struct xtty *xt) | ||||
xt->xt_inlow = tp->t_inlow; | xt->xt_inlow = tp->t_inlow; | ||||
xt->xt_outsize = ttyoutq_getsize(&tp->t_outq); | xt->xt_outsize = ttyoutq_getsize(&tp->t_outq); | ||||
xt->xt_outcc = ttyoutq_bytesused(&tp->t_outq); | xt->xt_outcc = ttyoutq_bytesused(&tp->t_outq); | ||||
xt->xt_outlow = tp->t_outlow; | xt->xt_outlow = tp->t_outlow; | ||||
xt->xt_column = tp->t_column; | xt->xt_column = tp->t_column; | ||||
xt->xt_pgid = tp->t_pgrp ? tp->t_pgrp->pg_id : 0; | xt->xt_pgid = tp->t_pgrp ? tp->t_pgrp->pg_id : 0; | ||||
xt->xt_sid = tp->t_session ? tp->t_session->s_sid : 0; | xt->xt_sid = tp->t_session ? tp->t_session->s_sid : 0; | ||||
xt->xt_flags = tp->t_flags; | xt->xt_flags = tp->t_flags; | ||||
xt->xt_dev = tp->t_dev ? dev2udev(tp->t_dev) : NODEV; | xt->xt_dev = tp->t_dev ? dev2udev(tp->t_dev) : (uint32_t)NODEV; | ||||
} | } | ||||
static int | static int | ||||
sysctl_kern_ttys(SYSCTL_HANDLER_ARGS) | sysctl_kern_ttys(SYSCTL_HANDLER_ARGS) | ||||
{ | { | ||||
unsigned long lsize; | unsigned long lsize; | ||||
struct xtty *xtlist, *xt; | struct xtty *xtlist, *xt; | ||||
struct tty *tp; | struct tty *tp; | ||||
▲ Show 20 Lines • Show All 1,131 Lines • Show Last 20 Lines |