MCPcopy Create free account
hub / github.com/F-Stack/f-stack / ttydisc_rint_poll

Function ttydisc_rint_poll

freebsd/kern/tty_ttydisc.c:1150–1171  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1148}
1149
1150size_t
1151ttydisc_rint_poll(struct tty *tp)
1152{
1153 size_t l;
1154
1155 tty_assert_locked(tp);
1156
1157 if (ttyhook_hashook(tp, rint_poll))
1158 return ttyhook_rint_poll(tp);
1159
1160 /*
1161 * XXX: Still allow character input when there's no space in the
1162 * buffers, but we haven't entered the high watermark. This is
1163 * to allow backspace characters to be inserted when in
1164 * canonical mode.
1165 */
1166 l = ttyinq_bytesleft(&tp->t_inq);
1167 if (l == 0 && (tp->t_flags & TF_HIWAT_IN) == 0)
1168 return (1);
1169
1170 return (l);
1171}
1172
1173static void
1174ttydisc_wakeup_watermark(struct tty *tp)

Callers 2

ptsdev_pollFunction · 0.85
pts_kqops_write_eventFunction · 0.85

Calls 2

ttyhook_rint_pollFunction · 0.85
ttyinq_bytesleftFunction · 0.85

Tested by

no test coverage detected