Module Name: src
Committed By: rin
Date: Fri Aug 9 08:05:57 UTC 2019
Modified Files:
src/sys/arch/alpha/alpha: promcons.c
src/sys/arch/alpha/conf: GENERIC
Log Message:
Add CONSPEED option, which changes baud rate of serial console.
To generate a diff of this commit:
cvs rdiff -u -r1.39 -r1.40 src/sys/arch/alpha/alpha/promcons.c
cvs rdiff -u -r1.395 -r1.396 src/sys/arch/alpha/conf/GENERIC
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/alpha/alpha/promcons.c
diff -u src/sys/arch/alpha/alpha/promcons.c:1.39 src/sys/arch/alpha/alpha/promcons.c:1.40
--- src/sys/arch/alpha/alpha/promcons.c:1.39 Fri Jul 25 08:10:31 2014
+++ src/sys/arch/alpha/alpha/promcons.c Fri Aug 9 08:05:57 2019
@@ -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 @@ __KERNEL_RCSID(0, "$NetBSD: promcons.c,v
#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 @@ promopen(dev_t dev, int flag, int mode,
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;
Index: src/sys/arch/alpha/conf/GENERIC
diff -u src/sys/arch/alpha/conf/GENERIC:1.395 src/sys/arch/alpha/conf/GENERIC:1.396
--- src/sys/arch/alpha/conf/GENERIC:1.395 Fri Aug 9 08:02:23 2019
+++ src/sys/arch/alpha/conf/GENERIC Fri Aug 9 08:05:57 2019
@@ -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 @@ include "arch/alpha/conf/std.alpha"
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 DDB_HISTORY_SIZE=512 # enable h
#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