summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2009-10-16 14:38:16 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2009-10-16 14:38:16 +0000
commitdcf4f08c8ec36b42aa67cb5879c90fbc96fb4b40 (patch)
treee949722eedb10dc2669d0a482d533d0be5316a97
parent3f1e5768eb5c6a694481de466bb6e2e23353127e (diff)
Honour serial console speed on O2 too.
-rw-r--r--sys/arch/sgi/localbus/com_lbus.c4
-rw-r--r--sys/arch/sgi/sgi/ip32_machdep.c5
2 files changed, 6 insertions, 3 deletions
diff --git a/sys/arch/sgi/localbus/com_lbus.c b/sys/arch/sgi/localbus/com_lbus.c
index ff2e444bcb0..20d1ef6050c 100644
--- a/sys/arch/sgi/localbus/com_lbus.c
+++ b/sys/arch/sgi/localbus/com_lbus.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: com_lbus.c,v 1.9 2009/03/29 21:53:52 sthen Exp $ */
+/* $OpenBSD: com_lbus.c,v 1.10 2009/10/16 14:38:13 miod Exp $ */
/*
* Copyright (c) 2001-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
@@ -84,7 +84,7 @@ com_macebus_attach(struct device *parent, struct device *self, void *aux)
/* If it's in use as the console, then it's there. */
if (ca->ca_baseaddr == comconsaddr && !comconsattached) {
- if (comcnattach(sc->sc_iot, sc->sc_iobase, TTYDEF_SPEED,
+ if (comcnattach(sc->sc_iot, sc->sc_iobase, comconsrate,
sc->sc_frequency, (TTYDEF_CFLAG & ~(CSIZE | PARENB)) | CS8))
panic("failed to setup serial console!");
sc->sc_ioh = comconsioh;
diff --git a/sys/arch/sgi/sgi/ip32_machdep.c b/sys/arch/sgi/sgi/ip32_machdep.c
index 343da1cda59..da93222cc9c 100644
--- a/sys/arch/sgi/sgi/ip32_machdep.c
+++ b/sys/arch/sgi/sgi/ip32_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip32_machdep.c,v 1.8 2009/10/16 00:15:49 miod Exp $ */
+/* $OpenBSD: ip32_machdep.c,v 1.9 2009/10/16 14:38:15 miod Exp $ */
/*
* Copyright (c) 2003-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
@@ -154,6 +154,9 @@ ip32_setup()
comconsaddr = MACE_ISA_SER1_OFFS;
comconsfreq = 1843200;
comconsiot = &macebus_tag;
+ comconsrate = bios_getenvint("dbaud");
+ if (comconsrate < 50 || comconsrate > 115200)
+ comconsrate = 9600;
/* not sure if there is a way to tell O2 and O2+ apart */
hw_prod = "O2";