From db2cc4bf42ecb8d09ee4141a77fd802c7a8c63b4 Mon Sep 17 00:00:00 2001 From: Marco S Hyman Date: Tue, 8 Jun 2004 18:09:32 +0000 Subject: pull ncpus support from smp tree into main branch. remove alpha specific definition of ncpus. OK (and tested on alpha) deraadt@ --- sys/arch/alpha/alpha/machdep.c | 7 ++----- sys/arch/alpha/alpha/mainbus.c | 3 +-- 2 files changed, 3 insertions(+), 7 deletions(-) (limited to 'sys/arch/alpha') diff --git a/sys/arch/alpha/alpha/machdep.c b/sys/arch/alpha/alpha/machdep.c index cbe22050ad6..3501a26890a 100644 --- a/sys/arch/alpha/alpha/machdep.c +++ b/sys/arch/alpha/alpha/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.86 2004/03/10 23:02:53 tom Exp $ */ +/* $OpenBSD: machdep.c,v 1.87 2004/06/08 18:09:31 marc Exp $ */ /* $NetBSD: machdep.c,v 1.210 2000/06/01 17:12:38 thorpej Exp $ */ /*- @@ -191,9 +191,6 @@ struct user *proc0paddr; /* Number of machine cycles per microsecond */ u_int64_t cycles_per_usec; -/* number of cpus in the box. really! */ -int ncpus; - struct bootinfo_kernel bootinfo; /* For built-in TCDS */ @@ -760,7 +757,7 @@ nobootinfo: * Figure out the number of cpus in the box, from RPB fields. * Really. We mean it. */ - for (i = 0; i < hwrpb->rpb_pcs_cnt; i++) { + for (ncpus = 0, i = 0; i < hwrpb->rpb_pcs_cnt; i++) { struct pcs *pcsp; pcsp = LOCATE_PCS(hwrpb, i); diff --git a/sys/arch/alpha/alpha/mainbus.c b/sys/arch/alpha/alpha/mainbus.c index ed2715f4487..dd9dc6011a4 100644 --- a/sys/arch/alpha/alpha/mainbus.c +++ b/sys/arch/alpha/alpha/mainbus.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mainbus.c,v 1.11 2002/03/14 01:26:26 millert Exp $ */ +/* $OpenBSD: mainbus.c,v 1.12 2004/06/08 18:09:31 marc Exp $ */ /* $NetBSD: mainbus.c,v 1.27 1998/06/24 01:10:35 ross Exp $ */ /* @@ -76,7 +76,6 @@ mbattach(parent, self, aux) struct mainbus_attach_args ma; struct pcs *pcsp; int i, cpuattachcnt; - extern int ncpus; mainbus_found = 1; -- cgit v1.2.3