Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/hp700 Rename hppa_ncpus hppa_ncpu.
details: https://anonhg.NetBSD.org/src/rev/4f64a4cb8159
branches: trunk
changeset: 761535:4f64a4cb8159
user: skrll <skrll%NetBSD.org@localhost>
date: Mon Jan 31 14:11:02 2011 +0000
description:
Rename hppa_ncpus hppa_ncpu.
Increment for primary CPU only for now.
diffstat:
sys/arch/hp700/dev/cpu.c | 11 ++++++++---
sys/arch/hp700/include/cpu.h | 6 +++---
2 files changed, 11 insertions(+), 6 deletions(-)
diffs (72 lines):
diff -r a29603e82e13 -r 4f64a4cb8159 sys/arch/hp700/dev/cpu.c
--- a/sys/arch/hp700/dev/cpu.c Mon Jan 31 12:10:58 2011 +0000
+++ b/sys/arch/hp700/dev/cpu.c Mon Jan 31 14:11:02 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu.c,v 1.17 2011/01/23 21:53:39 skrll Exp $ */
+/* $NetBSD: cpu.c,v 1.18 2011/01/31 14:11: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.17 2011/01/23 21:53:39 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.18 2011/01/31 14:11:02 skrll Exp $");
#include "opt_multiprocessor.h"
@@ -56,7 +56,8 @@
};
#ifdef MULTIPROCESSOR
-int hppa_ncpus;
+
+int hppa_ncpu;
struct cpu_info *cpu_hatch_info;
static volatile int start_secondary_cpu;
@@ -192,6 +193,7 @@
if (ci->ci_hpa == hppa_mcpuhpa) {
ci->ci_flags |= CPUF_PRIMARY|CPUF_RUNNING;
+ hppa_ncpu++;
} else {
int err;
@@ -278,6 +280,9 @@
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)
diff -r a29603e82e13 -r 4f64a4cb8159 sys/arch/hp700/include/cpu.h
--- a/sys/arch/hp700/include/cpu.h Mon Jan 31 12:10:58 2011 +0000
+++ b/sys/arch/hp700/include/cpu.h Mon Jan 31 14:11:02 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu.h,v 1.63 2011/01/25 21:27:48 skrll Exp $ */
+/* $NetBSD: cpu.h,v 1.64 2011/01/31 14:11:02 skrll Exp $ */
/* $OpenBSD: cpu.h,v 1.55 2008/07/23 17:39:35 kettenis Exp $ */
@@ -298,14 +298,14 @@
#ifdef MULTIPROCESSOR
/* Number of CPUs in the system */
-extern int hppa_ncpus;
+extern int hppa_ncpu;
#define HPPA_MAXCPUS 4
#define cpu_number() (curcpu()->ci_cpuid)
#define CPU_IS_PRIMARY(ci) ((ci)->ci_cpuid == 0)
#define CPU_INFO_ITERATOR int
-#define CPU_INFO_FOREACH(cii, ci) cii = 0; ci = &cpus[0], cii < hppa_ncpus; cii++, ci++
+#define CPU_INFO_FOREACH(cii, ci) cii = 0; ci = &cpus[0], cii < hppa_ncpu; cii++, ci++
void cpu_boot_secondary_processors(void);
Home |
Main Index |
Thread Index |
Old Index