add a delay before serial console is initialized, to allow any

outstanding PROM output to drain.  Move the console-type printfs
so that they're only printed if console selection fails.
This commit is contained in:
cgd 1996-06-14 20:38:11 +00:00
parent ef8b4f596a
commit 5c5c2d1804
3 changed files with 21 additions and 12 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: dec_2100_a50.c,v 1.9 1996/06/13 04:53:48 cgd Exp $ */
/* $NetBSD: dec_2100_a50.c,v 1.10 1996/06/14 20:38:11 cgd Exp $ */
/*
* Copyright (c) 1995, 1996 Carnegie-Mellon University.
@ -93,9 +93,6 @@ dec_2100_a50_consinit()
ctb = (struct ctb *)(((caddr_t)hwrpb) + hwrpb->rpb_ctb_off);
printf("ctb->ctb_term_type = 0x%lx\n", ctb->ctb_term_type);
printf("ctb->ctb_turboslot = 0x%lx\n", ctb->ctb_turboslot);
switch (ctb->ctb_term_type) {
case 2:
/* serial console ... */
@ -111,6 +108,9 @@ dec_2100_a50_consinit()
static struct consdev comcons = { NULL, NULL,
comcngetc, comcnputc, comcnpollc, NODEV, 1 };
/* Delay to allow PROM putchars to complete */
DELAY(10000);
comconsaddr = 0x3f8;
comconsinit = 0;
comconsbc = &acp->ac_bc;
@ -134,6 +134,9 @@ dec_2100_a50_consinit()
break;
default:
printf("ctb->ctb_term_type = 0x%lx\n", ctb->ctb_term_type);
printf("ctb->ctb_turboslot = 0x%lx\n", ctb->ctb_turboslot);
panic("consinit: unknown console type %d\n",
ctb->ctb_term_type);
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: dec_axppci_33.c,v 1.7 1996/06/13 04:53:55 cgd Exp $ */
/* $NetBSD: dec_axppci_33.c,v 1.8 1996/06/14 20:38:13 cgd Exp $ */
/*
* Copyright (c) 1995, 1996 Carnegie-Mellon University.
@ -76,9 +76,6 @@ dec_axppci_33_consinit()
ctb = (struct ctb *)(((caddr_t)hwrpb) + hwrpb->rpb_ctb_off);
printf("ctb->ctb_term_type = 0x%lx\n", ctb->ctb_term_type);
printf("ctb->ctb_turboslot = 0x%lx\n", ctb->ctb_turboslot);
switch (ctb->ctb_term_type) {
case 2:
/* serial console ... */
@ -94,6 +91,9 @@ dec_axppci_33_consinit()
static struct consdev comcons = { NULL, NULL,
comcngetc, comcnputc, comcnpollc, NODEV, 1 };
/* Delay to allow PROM putchars to complete */
DELAY(10000);
comconsaddr = 0x3f8;
comconsinit = 0;
comconsbc = &lcp->lc_bc;
@ -117,6 +117,9 @@ dec_axppci_33_consinit()
break;
default:
printf("ctb->ctb_term_type = 0x%lx\n", ctb->ctb_term_type);
printf("ctb->ctb_turboslot = 0x%lx\n", ctb->ctb_turboslot);
panic("consinit: unknown console type %d\n",
ctb->ctb_term_type);
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: dec_kn20aa.c,v 1.7 1996/06/13 04:53:59 cgd Exp $ */
/* $NetBSD: dec_kn20aa.c,v 1.8 1996/06/14 20:38:14 cgd Exp $ */
/*
* Copyright (c) 1995, 1996 Carnegie-Mellon University.
@ -76,9 +76,6 @@ dec_kn20aa_consinit()
ctb = (struct ctb *)(((caddr_t)hwrpb) + hwrpb->rpb_ctb_off);
printf("ctb->ctb_term_type = 0x%lx\n", ctb->ctb_term_type);
printf("ctb->ctb_turboslot = 0x%lx\n", ctb->ctb_turboslot);
switch (ctb->ctb_term_type) {
case 2:
/* serial console ... */
@ -94,6 +91,9 @@ dec_kn20aa_consinit()
static struct consdev comcons = { NULL, NULL,
comcngetc, comcnputc, comcnpollc, NODEV, 1 };
/* Delay to allow PROM putchars to complete */
DELAY(10000);
comconsaddr = 0x3f8;
comconsinit = 0;
comconsbc = &ccp->cc_bc;
@ -117,6 +117,9 @@ dec_kn20aa_consinit()
break;
default:
printf("ctb->ctb_term_type = 0x%lx\n", ctb->ctb_term_type);
printf("ctb->ctb_turboslot = 0x%lx\n", ctb->ctb_turboslot);
panic("consinit: unknown console type %d\n",
ctb->ctb_term_type);
}