summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>1996-06-10 07:32:39 +0000
committerderaadt <deraadt@openbsd.org>1996-06-10 07:32:39 +0000
commit7eabf6bd0f2d8cf4a9ca25ef29d96b4e5578643e (patch)
tree781f604645ac467afe11a621721cfb0f0bfb7963
parenttty stats (diff)
downloadwireguard-openbsd-7eabf6bd0f2d8cf4a9ca25ef29d96b4e5578643e.tar.xz
wireguard-openbsd-7eabf6bd0f2d8cf4a9ca25ef29d96b4e5578643e.zip
tty_attach()
-rw-r--r--sys/arch/i386/isa/pccons.c9
-rw-r--r--sys/arch/i386/isa/pcvt/pcvt_drv.c5
-rw-r--r--sys/dev/ic/com.c9
-rw-r--r--sys/dev/ic/z8530tty.c5
-rw-r--r--sys/dev/isa/com.c9
-rw-r--r--sys/dev/isa/cy.c6
6 files changed, 26 insertions, 17 deletions
diff --git a/sys/arch/i386/isa/pccons.c b/sys/arch/i386/isa/pccons.c
index e851e7a6dfc..ce662d0d87d 100644
--- a/sys/arch/i386/isa/pccons.c
+++ b/sys/arch/i386/isa/pccons.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: pccons.c,v 1.15 1996/05/25 22:17:51 deraadt Exp $ */
-/* $NetBSD: pccons.c,v 1.99 1996/05/12 23:12:33 mycroft Exp $ */
+/* $OpenBSD: pccons.c,v 1.16 1996/06/10 07:35:35 deraadt Exp $ */
+/* $NetBSD: pccons.c,v 1.99.4.1 1996/06/04 20:03:53 cgd Exp $ */
/*-
* Copyright (c) 1993, 1994, 1995 Charles Hannum. All rights reserved.
@@ -512,9 +512,10 @@ pcopen(dev, flag, mode, p)
if (sc == 0)
return ENXIO;
- if (!sc->sc_tty)
+ if (!sc->sc_tty) {
tp = sc->sc_tty = ttymalloc();
- else
+ tty_attach(tp);
+ } else
tp = sc->sc_tty;
tp->t_oproc = pcstart;
diff --git a/sys/arch/i386/isa/pcvt/pcvt_drv.c b/sys/arch/i386/isa/pcvt/pcvt_drv.c
index 110c112ae21..3e4044d3639 100644
--- a/sys/arch/i386/isa/pcvt/pcvt_drv.c
+++ b/sys/arch/i386/isa/pcvt/pcvt_drv.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pcvt_drv.c,v 1.13 1996/05/25 22:17:55 deraadt Exp $ */
+/* $OpenBSD: pcvt_drv.c,v 1.14 1996/06/10 07:35:40 deraadt Exp $ */
/*
* Copyright (c) 1992, 1995 Hellmuth Michaelis and Joerg Wunsch.
@@ -245,6 +245,9 @@ pcattach(struct isa_device *dev)
#if PCVT_NETBSD > 100
vs[i].vs_tty = ttymalloc();
+#if PCVT_NETBSD >= 120
+ tty_attach(vs[i].vs_tty);
+#endif /* PCVT_NETBSD >= 120 */
#else /* !PCVT_NETBSD > 100 */
#if PCVT_NETBSD
diff --git a/sys/dev/ic/com.c b/sys/dev/ic/com.c
index e5da21469df..eb37eb9cef6 100644
--- a/sys/dev/ic/com.c
+++ b/sys/dev/ic/com.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: com.c,v 1.15 1996/05/26 00:27:14 deraadt Exp $ */
-/* $NetBSD: com.c,v 1.82 1996/05/12 23:52:00 mycroft Exp $ */
+/* $OpenBSD: com.c,v 1.16 1996/06/10 07:32:39 deraadt Exp $ */
+/* $NetBSD: com.c,v 1.82.4.1 1996/06/02 09:08:00 mrg Exp $ */
/*-
* Copyright (c) 1993, 1994, 1995, 1996
@@ -757,9 +757,10 @@ comopen(dev, flag, mode, p)
if (!sc || ISSET(sc->sc_hwflags, COM_HW_ABSENT|COM_HW_ABSENT_PENDING))
return ENXIO;
- if (!sc->sc_tty)
+ if (!sc->sc_tty) {
tp = sc->sc_tty = ttymalloc();
- else
+ tty_attach(tp);
+ } else
tp = sc->sc_tty;
tp->t_oproc = comstart;
diff --git a/sys/dev/ic/z8530tty.c b/sys/dev/ic/z8530tty.c
index 9a62a507339..2aedeeaa73d 100644
--- a/sys/dev/ic/z8530tty.c
+++ b/sys/dev/ic/z8530tty.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: z8530tty.c,v 1.4 1996/05/26 00:27:08 deraadt Exp $ */
-/* $NetBSD: z8530tty.c,v 1.8 1996/05/17 22:49:23 gwr Exp $ */
+/* $OpenBSD: z8530tty.c,v 1.5 1996/06/10 07:34:14 deraadt Exp $ */
+/* $NetBSD: z8530tty.c,v 1.8.4.1 1996/06/03 20:01:07 gwr Exp $ */
/*
* Copyright (c) 1994 Gordon W. Ross
@@ -259,6 +259,7 @@ zstty_attach(parent, self, aux)
tp->t_oproc = zsstart;
tp->t_param = zsparam;
tp->t_hwiflow = zshwiflow;
+ tty_attach(tp);
zst->zst_tty = tp;
zst->zst_rbhiwat = zstty_rbuf_size; /* impossible value */
diff --git a/sys/dev/isa/com.c b/sys/dev/isa/com.c
index e5da21469df..eb37eb9cef6 100644
--- a/sys/dev/isa/com.c
+++ b/sys/dev/isa/com.c
@@ -1,5 +1,5 @@
-/* $OpenBSD: com.c,v 1.15 1996/05/26 00:27:14 deraadt Exp $ */
-/* $NetBSD: com.c,v 1.82 1996/05/12 23:52:00 mycroft Exp $ */
+/* $OpenBSD: com.c,v 1.16 1996/06/10 07:32:39 deraadt Exp $ */
+/* $NetBSD: com.c,v 1.82.4.1 1996/06/02 09:08:00 mrg Exp $ */
/*-
* Copyright (c) 1993, 1994, 1995, 1996
@@ -757,9 +757,10 @@ comopen(dev, flag, mode, p)
if (!sc || ISSET(sc->sc_hwflags, COM_HW_ABSENT|COM_HW_ABSENT_PENDING))
return ENXIO;
- if (!sc->sc_tty)
+ if (!sc->sc_tty) {
tp = sc->sc_tty = ttymalloc();
- else
+ tty_attach(tp);
+ } else
tp = sc->sc_tty;
tp->t_oproc = comstart;
diff --git a/sys/dev/isa/cy.c b/sys/dev/isa/cy.c
index c99765308e7..03e1cf74756 100644
--- a/sys/dev/isa/cy.c
+++ b/sys/dev/isa/cy.c
@@ -1,4 +1,4 @@
-/* $NetBSD: cy.c,v 1.12 1995/06/28 04:31:32 cgd Exp $ */
+/* $NetBSD: cy.c,v 1.12.6.1 1996/06/02 09:08:03 mrg Exp $ */
/* XXX THIS DRIVER IS BROKEN. IT WILL NOT EVEN COMPILE. */
@@ -337,8 +337,10 @@ cyopen(dev_t dev, int flag, int mode, struct proc *p)
infop = info[unit];
base = infop->base_addr;
- if (!cy_tty[unit])
+ if (!cy_tty[unit]) {
infop->tty = cy_tty[unit] = ttymalloc();
+ tty_attach(infop->tty);
+ }
tp = infop->tty;
tp->t_oproc = cystart;