Module Name: src
Committed By: skrll
Date: Wed May 23 07:06:02 UTC 2012
Modified Files:
src/sys/arch/hp700/dev: cpu.c
Log Message:
Count the cpus as they attach so that CPU_INFO_FOREACH works before
hatching the secondary cpus.
To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/hp700/dev/cpu.c
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/hp700/dev/cpu.c
diff -u src/sys/arch/hp700/dev/cpu.c:1.24 src/sys/arch/hp700/dev/cpu.c:1.25
--- src/sys/arch/hp700/dev/cpu.c:1.24 Mon May 21 21:15:39 2012
+++ src/sys/arch/hp700/dev/cpu.c Wed May 23 07:06:02 2012
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu.c,v 1.24 2012/05/21 21:15:39 skrll Exp $ */
+/* $NetBSD: cpu.c,v 1.25 2012/05/23 07:06:02 skrll Exp $ */
/* $OpenBSD: cpu.c,v 1.29 2009/02/08 18:33:28 miod Exp $ */
@@ -29,7 +29,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.24 2012/05/21 21:15:39 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.25 2012/05/23 07:06:02 skrll Exp $");
#include "opt_multiprocessor.h"
@@ -179,7 +179,6 @@ cpuattach(device_t parent, device_t self
if (ci->ci_hpa == hppa_mcpuhpa) {
ci->ci_flags |= CPUF_PRIMARY|CPUF_RUNNING;
- hppa_ncpu++;
} else {
int err;
@@ -190,6 +189,7 @@ cpuattach(device_t parent, device_t self
return;
}
}
+ hppa_ncpu++;
#endif
@@ -266,9 +266,6 @@ cpu_hatch(void)
struct cpu_info *ci = curcpu();
ci->ci_flags |= CPUF_RUNNING;
-#if 0
- hppa_ncpu++;
-#endif
/* Wait for additional CPUs to spinup. */
while (!start_secondary_cpu)