Module Name: src
Committed By: martin
Date: Tue Dec 1 09:26:36 UTC 2009
Modified Files:
src/sys/arch/sparc64/sparc64: cpu.c
Log Message:
Revert part of previous - the removal of the "first cpu to attach is
bootstrap cpu" requirement already fixed everything - no need to use
cf_unit for a bogus test here.
To generate a diff of this commit:
cvs rdiff -u -r1.86 -r1.87 src/sys/arch/sparc64/sparc64/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/sparc64/sparc64/cpu.c
diff -u src/sys/arch/sparc64/sparc64/cpu.c:1.86 src/sys/arch/sparc64/sparc64/cpu.c:1.87
--- src/sys/arch/sparc64/sparc64/cpu.c:1.86 Tue Dec 1 00:06:31 2009
+++ src/sys/arch/sparc64/sparc64/cpu.c Tue Dec 1 09:26:36 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: cpu.c,v 1.86 2009/12/01 00:06:31 martin Exp $ */
+/* $NetBSD: cpu.c,v 1.87 2009/12/01 09:26:36 martin Exp $ */
/*
* Copyright (c) 1996
@@ -52,7 +52,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.86 2009/12/01 00:06:31 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.87 2009/12/01 09:26:36 martin Exp $");
#include "opt_multiprocessor.h"
@@ -190,12 +190,14 @@
if (strcmp(cf->cf_name, ma->ma_name) != 0)
return 0;
+#ifndef MULTIPROCESSOR
/*
- * Make sure cpu0 attaches to the currently running cpu (which
- * is the boot cpu always, as we did not fire up others at this point)
+ * If we are going to only attach a single cpu, make sure
+ * to pick the one we are running on right now.
*/
- if (cf->cf_unit == 0 && upaid_from_node(ma->ma_node) != CPU_UPAID)
+ if (upaid_from_node(ma->ma_node) != CPU_UPAID)
return 0;
+#endif
return 1;
}