Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/alpha Add CONSPEED option, which changes baud rate ...



details:   https://anonhg.NetBSD.org/src/rev/849d3edb0cf3
branches:  trunk
changeset: 1002654:849d3edb0cf3
user:      rin <rin%NetBSD.org@localhost>
date:      Fri Aug 09 08:05:57 2019 +0000

description:
Add CONSPEED option, which changes baud rate of serial console.

diffstat:

 sys/arch/alpha/alpha/promcons.c |  10 +++++++---
 sys/arch/alpha/conf/GENERIC     |   6 ++++--
 2 files changed, 11 insertions(+), 5 deletions(-)

diffs (65 lines):

diff -r 7930e6c7e484 -r 849d3edb0cf3 sys/arch/alpha/alpha/promcons.c
--- a/sys/arch/alpha/alpha/promcons.c   Fri Aug 09 08:04:16 2019 +0000
+++ b/sys/arch/alpha/alpha/promcons.c   Fri Aug 09 08:05:57 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: promcons.c,v 1.39 2014/07/25 08:10:31 dholland Exp $ */
+/* $NetBSD: promcons.c,v 1.40 2019/08/09 08:05:57 rin Exp $ */
 
 /*
  * Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
@@ -29,7 +29,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: promcons.c,v 1.39 2014/07/25 08:10:31 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: promcons.c,v 1.40 2019/08/09 08:05:57 rin Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -51,6 +51,10 @@
 #include <machine/cpuconf.h>
 #include <machine/prom.h>
 
+#ifndef CONSPEED
+#define        CONSPEED 9600
+#endif
+
 #ifdef _PMAP_MAY_USE_PROM_CONSOLE
 
 dev_type_open(promopen);
@@ -129,7 +133,7 @@
                tp->t_oflag = TTYDEF_OFLAG;
                tp->t_cflag = TTYDEF_CFLAG|CLOCAL;
                tp->t_lflag = TTYDEF_LFLAG;
-               tp->t_ispeed = tp->t_ospeed = 9600;
+               tp->t_ispeed = tp->t_ospeed = CONSPEED;
                ttsetwater(tp);
 
                setuptimeout = 1;
diff -r 7930e6c7e484 -r 849d3edb0cf3 sys/arch/alpha/conf/GENERIC
--- a/sys/arch/alpha/conf/GENERIC       Fri Aug 09 08:04:16 2019 +0000
+++ b/sys/arch/alpha/conf/GENERIC       Fri Aug 09 08:05:57 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.395 2019/08/09 08:02:23 rin Exp $
+# $NetBSD: GENERIC,v 1.396 2019/08/09 08:05:57 rin Exp $
 #
 # This machine description file is used to generate the default NetBSD
 # kernel.
@@ -19,7 +19,7 @@
 
 options        INCLUDE_CONFIG_FILE     # embed config file in kernel binary
 
-ident          "GENERIC-$Revision: 1.395 $"
+ident          "GENERIC-$Revision: 1.396 $"
 
 maxusers 32
 
@@ -66,6 +66,8 @@
 #options       KGDB_DEVADDR=0x2f8      # at this address
 #options       KGDB_DEVRATE=57600      # at this comm. rate
 
+#options       CONSPEED=57600          # Console speed (default to 9600)
+
 # File systems
 file-system    FFS             # Fast file system
 file-system    MFS             # Memory-based file system



Home | Main Index | Thread Index | Old Index