summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorfsmp <fsmp@FreeBSD.org>1997-08-10 19:32:38 +0000
committerfsmp <fsmp@FreeBSD.org>1997-08-10 19:32:38 +0000
commitf76cbffb979aec0ebd0cda902aa42bcb5492c6a4 (patch)
tree636ffb01c72cc272d1649bc18e0e00a72d273d38 /sys
parentcda69874ef4c7bc9289ad428e079718847f8cc8f (diff)
downloadFreeBSD-src-f76cbffb979aec0ebd0cda902aa42bcb5492c6a4.zip
FreeBSD-src-f76cbffb979aec0ebd0cda902aa42bcb5492c6a4.tar.gz
Cheap fix for kern/4255.
If the problem is seen this fix suggests a compile-time work-around then panics.
Diffstat (limited to 'sys')
-rw-r--r--sys/amd64/amd64/mp_machdep.c14
-rw-r--r--sys/amd64/amd64/mptable.c14
-rw-r--r--sys/amd64/include/mptable.h14
-rw-r--r--sys/i386/i386/mp_machdep.c14
-rw-r--r--sys/i386/i386/mptable.c14
-rw-r--r--sys/i386/include/mptable.h14
-rw-r--r--sys/kern/subr_smp.c14
7 files changed, 70 insertions, 28 deletions
diff --git a/sys/amd64/amd64/mp_machdep.c b/sys/amd64/amd64/mp_machdep.c
index db6db90..ce107d9 100644
--- a/sys/amd64/amd64/mp_machdep.c
+++ b/sys/amd64/amd64/mp_machdep.c
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: mp_machdep.c,v 1.26 1997/08/09 22:12:14 smp Exp $
+ * $Id: mp_machdep.c,v 1.40 1997/08/09 23:01:03 fsmp Exp $
*/
#include "opt_smp.h"
@@ -724,12 +724,18 @@ mptable_pass1(void)
/* qualify the numbers */
if (mp_naps > NCPU)
+#if 0 /* XXX FIXME: kern/4255 */
printf("Warning: only using %d of %d available CPUs!\n",
NCPU, mp_naps);
-#if 0
- /** XXX we consider this legal now (but should we?) */
+#else
+ {
+ printf("NCPU cannot be different than actual CPU count.\n");
+ printf(" add 'options NCPU=%d' to your kernel config file,\n",
+ mp_naps);
+ printf(" then rerun config & rebuild your SMP kernel\n");
mustpanic = 1;
-#endif
+ }
+#endif /* XXX FIXME: kern/4255 */
if (mp_nbusses > NBUS) {
printf("found %d busses, increase NBUS\n", mp_nbusses);
mustpanic = 1;
diff --git a/sys/amd64/amd64/mptable.c b/sys/amd64/amd64/mptable.c
index db6db90..ce107d9 100644
--- a/sys/amd64/amd64/mptable.c
+++ b/sys/amd64/amd64/mptable.c
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: mp_machdep.c,v 1.26 1997/08/09 22:12:14 smp Exp $
+ * $Id: mp_machdep.c,v 1.40 1997/08/09 23:01:03 fsmp Exp $
*/
#include "opt_smp.h"
@@ -724,12 +724,18 @@ mptable_pass1(void)
/* qualify the numbers */
if (mp_naps > NCPU)
+#if 0 /* XXX FIXME: kern/4255 */
printf("Warning: only using %d of %d available CPUs!\n",
NCPU, mp_naps);
-#if 0
- /** XXX we consider this legal now (but should we?) */
+#else
+ {
+ printf("NCPU cannot be different than actual CPU count.\n");
+ printf(" add 'options NCPU=%d' to your kernel config file,\n",
+ mp_naps);
+ printf(" then rerun config & rebuild your SMP kernel\n");
mustpanic = 1;
-#endif
+ }
+#endif /* XXX FIXME: kern/4255 */
if (mp_nbusses > NBUS) {
printf("found %d busses, increase NBUS\n", mp_nbusses);
mustpanic = 1;
diff --git a/sys/amd64/include/mptable.h b/sys/amd64/include/mptable.h
index db6db90..ce107d9 100644
--- a/sys/amd64/include/mptable.h
+++ b/sys/amd64/include/mptable.h
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: mp_machdep.c,v 1.26 1997/08/09 22:12:14 smp Exp $
+ * $Id: mp_machdep.c,v 1.40 1997/08/09 23:01:03 fsmp Exp $
*/
#include "opt_smp.h"
@@ -724,12 +724,18 @@ mptable_pass1(void)
/* qualify the numbers */
if (mp_naps > NCPU)
+#if 0 /* XXX FIXME: kern/4255 */
printf("Warning: only using %d of %d available CPUs!\n",
NCPU, mp_naps);
-#if 0
- /** XXX we consider this legal now (but should we?) */
+#else
+ {
+ printf("NCPU cannot be different than actual CPU count.\n");
+ printf(" add 'options NCPU=%d' to your kernel config file,\n",
+ mp_naps);
+ printf(" then rerun config & rebuild your SMP kernel\n");
mustpanic = 1;
-#endif
+ }
+#endif /* XXX FIXME: kern/4255 */
if (mp_nbusses > NBUS) {
printf("found %d busses, increase NBUS\n", mp_nbusses);
mustpanic = 1;
diff --git a/sys/i386/i386/mp_machdep.c b/sys/i386/i386/mp_machdep.c
index db6db90..ce107d9 100644
--- a/sys/i386/i386/mp_machdep.c
+++ b/sys/i386/i386/mp_machdep.c
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: mp_machdep.c,v 1.26 1997/08/09 22:12:14 smp Exp $
+ * $Id: mp_machdep.c,v 1.40 1997/08/09 23:01:03 fsmp Exp $
*/
#include "opt_smp.h"
@@ -724,12 +724,18 @@ mptable_pass1(void)
/* qualify the numbers */
if (mp_naps > NCPU)
+#if 0 /* XXX FIXME: kern/4255 */
printf("Warning: only using %d of %d available CPUs!\n",
NCPU, mp_naps);
-#if 0
- /** XXX we consider this legal now (but should we?) */
+#else
+ {
+ printf("NCPU cannot be different than actual CPU count.\n");
+ printf(" add 'options NCPU=%d' to your kernel config file,\n",
+ mp_naps);
+ printf(" then rerun config & rebuild your SMP kernel\n");
mustpanic = 1;
-#endif
+ }
+#endif /* XXX FIXME: kern/4255 */
if (mp_nbusses > NBUS) {
printf("found %d busses, increase NBUS\n", mp_nbusses);
mustpanic = 1;
diff --git a/sys/i386/i386/mptable.c b/sys/i386/i386/mptable.c
index db6db90..ce107d9 100644
--- a/sys/i386/i386/mptable.c
+++ b/sys/i386/i386/mptable.c
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: mp_machdep.c,v 1.26 1997/08/09 22:12:14 smp Exp $
+ * $Id: mp_machdep.c,v 1.40 1997/08/09 23:01:03 fsmp Exp $
*/
#include "opt_smp.h"
@@ -724,12 +724,18 @@ mptable_pass1(void)
/* qualify the numbers */
if (mp_naps > NCPU)
+#if 0 /* XXX FIXME: kern/4255 */
printf("Warning: only using %d of %d available CPUs!\n",
NCPU, mp_naps);
-#if 0
- /** XXX we consider this legal now (but should we?) */
+#else
+ {
+ printf("NCPU cannot be different than actual CPU count.\n");
+ printf(" add 'options NCPU=%d' to your kernel config file,\n",
+ mp_naps);
+ printf(" then rerun config & rebuild your SMP kernel\n");
mustpanic = 1;
-#endif
+ }
+#endif /* XXX FIXME: kern/4255 */
if (mp_nbusses > NBUS) {
printf("found %d busses, increase NBUS\n", mp_nbusses);
mustpanic = 1;
diff --git a/sys/i386/include/mptable.h b/sys/i386/include/mptable.h
index db6db90..ce107d9 100644
--- a/sys/i386/include/mptable.h
+++ b/sys/i386/include/mptable.h
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: mp_machdep.c,v 1.26 1997/08/09 22:12:14 smp Exp $
+ * $Id: mp_machdep.c,v 1.40 1997/08/09 23:01:03 fsmp Exp $
*/
#include "opt_smp.h"
@@ -724,12 +724,18 @@ mptable_pass1(void)
/* qualify the numbers */
if (mp_naps > NCPU)
+#if 0 /* XXX FIXME: kern/4255 */
printf("Warning: only using %d of %d available CPUs!\n",
NCPU, mp_naps);
-#if 0
- /** XXX we consider this legal now (but should we?) */
+#else
+ {
+ printf("NCPU cannot be different than actual CPU count.\n");
+ printf(" add 'options NCPU=%d' to your kernel config file,\n",
+ mp_naps);
+ printf(" then rerun config & rebuild your SMP kernel\n");
mustpanic = 1;
-#endif
+ }
+#endif /* XXX FIXME: kern/4255 */
if (mp_nbusses > NBUS) {
printf("found %d busses, increase NBUS\n", mp_nbusses);
mustpanic = 1;
diff --git a/sys/kern/subr_smp.c b/sys/kern/subr_smp.c
index db6db90..ce107d9 100644
--- a/sys/kern/subr_smp.c
+++ b/sys/kern/subr_smp.c
@@ -22,7 +22,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: mp_machdep.c,v 1.26 1997/08/09 22:12:14 smp Exp $
+ * $Id: mp_machdep.c,v 1.40 1997/08/09 23:01:03 fsmp Exp $
*/
#include "opt_smp.h"
@@ -724,12 +724,18 @@ mptable_pass1(void)
/* qualify the numbers */
if (mp_naps > NCPU)
+#if 0 /* XXX FIXME: kern/4255 */
printf("Warning: only using %d of %d available CPUs!\n",
NCPU, mp_naps);
-#if 0
- /** XXX we consider this legal now (but should we?) */
+#else
+ {
+ printf("NCPU cannot be different than actual CPU count.\n");
+ printf(" add 'options NCPU=%d' to your kernel config file,\n",
+ mp_naps);
+ printf(" then rerun config & rebuild your SMP kernel\n");
mustpanic = 1;
-#endif
+ }
+#endif /* XXX FIXME: kern/4255 */
if (mp_nbusses > NBUS) {
printf("found %d busses, increase NBUS\n", mp_nbusses);
mustpanic = 1;
OpenPOWER on IntegriCloud