summaryrefslogtreecommitdiffstats
path: root/sys/dev/nmdm
diff options
context:
space:
mode:
authormp <mp@FreeBSD.org>2001-08-11 00:18:15 +0000
committermp <mp@FreeBSD.org>2001-08-11 00:18:15 +0000
commitf1340e224fac9e28419af080702431c2270c59af (patch)
tree86d11e5fb023d8dde60e3542cd604a49a2d6d972 /sys/dev/nmdm
parent5dc8929a4df9432ed9fce8866220f39176df199d (diff)
downloadFreeBSD-src-f1340e224fac9e28419af080702431c2270c59af.zip
FreeBSD-src-f1340e224fac9e28419af080702431c2270c59af.tar.gz
Remove unused nmdmpoll function.
Approved by: julian
Diffstat (limited to 'sys/dev/nmdm')
-rw-r--r--sys/dev/nmdm/nmdm.c63
1 files changed, 0 insertions, 63 deletions
diff --git a/sys/dev/nmdm/nmdm.c b/sys/dev/nmdm/nmdm.c
index b38f60e..c705e06 100644
--- a/sys/dev/nmdm/nmdm.c
+++ b/sys/dev/nmdm/nmdm.c
@@ -483,69 +483,6 @@ nmdmstop(tp, flush)
wakeup_other(tp, flag);
}
-#if 0
-static int
-nmdmpoll(dev_t dev, int events, struct proc *p)
-{
- register struct tty *tp = dev->si_tty;
- register struct tty *tp2;
- int revents = 0;
- int s;
- struct softpart *ourpart, *otherpart;
-
- GETPARTS(tp, ourpart, otherpart);
- tp2 = &otherpart->nm_tty;
-
- if ((tp->t_state & TS_CONNECTED) == 0)
- return (seltrue(dev, events, p) | POLLHUP);
-
- /*
- * Need to block timeouts (ttrstart).
- */
- s = spltty();
-
- /*
- * First check if there is something to report immediatly.
- */
- if ((events & (POLLIN | POLLRDNORM))) {
- if (tp->t_iflag & ICANON) {
- if (tp->t_canq.c_cc)
- revents |= events & (POLLIN | POLLRDNORM);
- } else {
- if (tp->t_rawq.c_cc + tp->t_canq.c_cc)
- revents |= events & (POLLIN | POLLRDNORM);
- }
- }
-
- /*
- * check if there is room in the other tty's input buffers.
- */
- if ((events & (POLLOUT | POLLWRNORM))
- && ((tp2->t_rawq.c_cc + tp2->t_canq.c_cc < TTYHOG - 2)
- || (tp2->t_canq.c_cc == 0 && (tp2->t_iflag & ICANON)))) {
- revents |= events & (POLLOUT | POLLWRNORM);
- }
-
- if (events & POLLHUP)
- if ((tp->t_state & TS_CARR_ON) == 0)
- revents |= POLLHUP;
-
- /*
- * If nothing immediate, set us to return when something IS found.
- */
- if (revents == 0) {
- if (events & (POLLIN | POLLRDNORM))
- selrecord(p, &tp->t_rsel);
-
- if (events & (POLLOUT | POLLWRNORM))
- selrecord(p, &tp->t_wsel);
- }
- splx(s);
-
- return (revents);
-}
-#endif /* 0 */
-
/*ARGSUSED*/
static int
nmdmioctl(dev, cmd, data, flag, p)
OpenPOWER on IntegriCloud