Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/sparc64/dev comcons in dev/ic/com.c is now declared...
details: https://anonhg.NetBSD.org/src/rev/a5637fd17cf1
branches: trunk
changeset: 749024:a5637fd17cf1
user: nakayama <nakayama%NetBSD.org@localhost>
date: Sat Nov 14 03:43:52 2009 +0000
description:
comcons in dev/ic/com.c is now declared as static, so don't peek it
directly but use it via cn_tab.
Tested on my Netra X1.
diffstat:
sys/arch/sparc64/dev/com_ebus.c | 19 +++++++++----------
1 files changed, 9 insertions(+), 10 deletions(-)
diffs (51 lines):
diff -r 4452cd57ed12 -r a5637fd17cf1 sys/arch/sparc64/dev/com_ebus.c
--- a/sys/arch/sparc64/dev/com_ebus.c Sat Nov 14 01:56:21 2009 +0000
+++ b/sys/arch/sparc64/dev/com_ebus.c Sat Nov 14 03:43:52 2009 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: com_ebus.c,v 1.28 2008/05/29 14:51:26 mrg Exp $ */
+/* $NetBSD: com_ebus.c,v 1.29 2009/11/14 03:43:52 nakayama Exp $ */
/*
* Copyright (c) 1999, 2000 Matthew R. Green
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: com_ebus.c,v 1.28 2008/05/29 14:51:26 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: com_ebus.c,v 1.29 2009/11/14 03:43:52 nakayama Exp $");
#include <sys/types.h>
#include <sys/param.h>
@@ -148,7 +148,6 @@
com_is_output = (ea->ea_node == prom_instance_to_package(prom_stdout()));
if (com_is_input || com_is_output) {
- extern struct consdev comcons;
struct consdev *cn_orig;
/* Record some info to attach console. */
@@ -161,17 +160,17 @@
sc->sc_frequency, COM_TYPE_NORMAL, kma.kmta_cflag)) {
aprint_error("Error: comcnattach failed\n");
}
- cn_tab = cn_orig;
if (com_is_input) {
- cn_tab->cn_dev = comcons.cn_dev;
- cn_tab->cn_probe = comcons.cn_probe;
- cn_tab->cn_init = comcons.cn_init;
- cn_tab->cn_getc = comcons.cn_getc;
- cn_tab->cn_pollc = comcons.cn_pollc;
+ cn_orig->cn_dev = cn_tab->cn_dev;
+ cn_orig->cn_probe = cn_tab->cn_probe;
+ cn_orig->cn_init = cn_tab->cn_init;
+ cn_orig->cn_getc = cn_tab->cn_getc;
+ cn_orig->cn_pollc = cn_tab->cn_pollc;
}
if (com_is_output) {
- cn_tab->cn_putc = comcons.cn_putc;
+ cn_orig->cn_putc = cn_tab->cn_putc;
}
+ cn_tab = cn_orig;
kma.kmta_consdev = cn_tab;
}
/* Now attach the driver */
Home |
Main Index |
Thread Index |
Old Index