summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2018-05-31 09:13:00 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2018-05-31 09:13:00 +0000
commit4d9aeb25b75325536a32b31749e2a1fe9eee9490 (patch)
tree2bfcedc9843b93584d0e0302b2ed54844a84711b /sys
parentd315b26d9f140c430c33d4fc814886200ace4ddb (diff)
Remove comcnspeed and comcnmode. They serve no purpose anymore. Configuring
the serial port speed can be done through the device tree and these days everybody uses 8N1 for the mode. ok patrick@, visa@, jsg@
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/armv7/armv7/armv7_machdep.c12
-rw-r--r--sys/arch/armv7/dev/com_fdt.c8
-rw-r--r--sys/arch/armv7/dev/pluart.c7
-rw-r--r--sys/dev/fdt/imxuart.c5
4 files changed, 6 insertions, 26 deletions
diff --git a/sys/arch/armv7/armv7/armv7_machdep.c b/sys/arch/armv7/armv7/armv7_machdep.c
index 99020084e6a..41abc53ac50 100644
--- a/sys/arch/armv7/armv7/armv7_machdep.c
+++ b/sys/arch/armv7/armv7/armv7_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: armv7_machdep.c,v 1.53 2018/05/15 11:11:35 kettenis Exp $ */
+/* $OpenBSD: armv7_machdep.c,v 1.54 2018/05/31 09:12:59 kettenis Exp $ */
/* $NetBSD: lubbock_machdep.c,v 1.2 2003/07/15 00:25:06 lukem Exp $ */
/*
@@ -207,16 +207,6 @@ void consinit(void);
bs_protos(bs_notimpl);
-#ifndef CONSPEED
-#define CONSPEED B115200 /* What u-boot */
-#endif
-#ifndef CONMODE
-#define CONMODE ((TTYDEF_CFLAG & ~(CSIZE | CSTOPB | PARENB)) | CS8) /* 8N1 */
-#endif
-
-int comcnspeed = CONSPEED;
-int comcnmode = CONMODE;
-
int stdout_node;
int stdout_speed;
diff --git a/sys/arch/armv7/dev/com_fdt.c b/sys/arch/armv7/dev/com_fdt.c
index 2f5fd019924..55fe4132e52 100644
--- a/sys/arch/armv7/dev/com_fdt.c
+++ b/sys/arch/armv7/dev/com_fdt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: com_fdt.c,v 1.13 2018/05/14 19:25:54 kettenis Exp $ */
+/* $OpenBSD: com_fdt.c,v 1.14 2018/05/31 09:12:59 kettenis Exp $ */
/*
* Copyright (c) 2016 Patrick Wildt <patrick@blueri.se>
*
@@ -39,9 +39,6 @@ int com_fdt_match(struct device *, void *, void *);
void com_fdt_attach(struct device *, struct device *, void *);
int com_fdt_intr_designware(void *);
-extern int comcnspeed;
-extern int comcnmode;
-
struct cfattach com_fdt_ca = {
sizeof (struct com_softc), com_fdt_match, com_fdt_attach
};
@@ -135,8 +132,7 @@ com_fdt_attach(struct device *parent, struct device *self, void *aux)
SET(sc->sc_hwflags, COM_HW_CONSOLE);
SET(sc->sc_swflags, COM_SW_SOFTCAR);
comconsfreq = sc->sc_frequency;
- comconsrate = stdout_speed ? stdout_speed : comcnspeed;
- comconscflag = comcnmode;
+ comconsrate = stdout_speed ? stdout_speed : B115200;
}
if (bus_space_map(sc->sc_iot, faa->fa_reg[0].addr,
diff --git a/sys/arch/armv7/dev/pluart.c b/sys/arch/armv7/dev/pluart.c
index 400fa891af8..12d041c7f64 100644
--- a/sys/arch/armv7/dev/pluart.c
+++ b/sys/arch/armv7/dev/pluart.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pluart.c,v 1.7 2018/02/19 08:59:52 mpi Exp $ */
+/* $OpenBSD: pluart.c,v 1.8 2018/05/31 09:12:59 kettenis Exp $ */
/*
* Copyright (c) 2014 Patrick Wildt <patrick@blueri.se>
@@ -182,9 +182,6 @@ struct pluart_softc *pluart_sc(dev_t dev);
int pluart_intr(void *);
-extern int comcnspeed;
-extern int comcnmode;
-
/* XXX - we imitate 'com' serial ports and take over their entry points */
/* XXX: These belong elsewhere */
cdev_decl(pluart);
@@ -214,7 +211,7 @@ pluart_init_cons(void)
if (fdt_get_reg(node, 0, &reg))
return;
- pluartcnattach(&armv7_bs_tag, reg.addr, comcnspeed, comcnmode);
+ pluartcnattach(&armv7_bs_tag, reg.addr, B115200, TTYDEF_CFLAG);
}
int
diff --git a/sys/dev/fdt/imxuart.c b/sys/dev/fdt/imxuart.c
index 3880835ff59..7bb1c1be3d1 100644
--- a/sys/dev/fdt/imxuart.c
+++ b/sys/dev/fdt/imxuart.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: imxuart.c,v 1.1 2018/03/29 20:33:53 patrick Exp $ */
+/* $OpenBSD: imxuart.c,v 1.2 2018/05/31 09:12:59 kettenis Exp $ */
/*
* Copyright (c) 2005 Dale Rahn <drahn@motorola.com>
*
@@ -107,9 +107,6 @@ struct imxuart_softc *imxuart_sc(dev_t dev);
int imxuart_intr(void *);
-extern int comcnspeed;
-extern int comcnmode;
-
/* XXX - we imitate 'com' serial ports and take over their entry points */
/* XXX: These belong elsewhere */
cdev_decl(com);