svn commit: r204910 - in stable/7/sys: amd64/amd64 i386/i386

John Baldwin jhb at FreeBSD.org
Tue Mar 9 13:08:58 UTC 2010


Author: jhb
Date: Tue Mar  9 13:08:57 2010
New Revision: 204910
URL: http://svn.freebsd.org/changeset/base/204910

Log:
  Don't include disabled CPUs in the topology map.  ULE assumes that all CPUs
  in the topology map were present and enabled.  Booting a system with
  hyperthreading and at least one CPU would cause ULE to attempt to use a
  disabled CPU when rebalancing load resulting in a panic.  This is a direct
  commit to 7 as the topology code is different in 8 and later.

Modified:
  stable/7/sys/amd64/amd64/mp_machdep.c
  stable/7/sys/i386/i386/mp_machdep.c

Modified: stable/7/sys/amd64/amd64/mp_machdep.c
==============================================================================
--- stable/7/sys/amd64/amd64/mp_machdep.c	Tue Mar  9 10:31:03 2010	(r204909)
+++ stable/7/sys/amd64/amd64/mp_machdep.c	Tue Mar  9 13:08:57 2010	(r204910)
@@ -200,7 +200,8 @@ mp_topology(void)
 	group = &mp_groups[0];
 	groups = 1;
 	for (cpu = 0, apic_id = 0; apic_id <= MAX_APIC_ID; apic_id++) {
-		if (!cpu_info[apic_id].cpu_present)
+		if (!cpu_info[apic_id].cpu_present ||
+		    cpu_info[apic_id].cpu_disabled)
 			continue;
 		/*
 		 * If the current group has members and we're not a logical

Modified: stable/7/sys/i386/i386/mp_machdep.c
==============================================================================
--- stable/7/sys/i386/i386/mp_machdep.c	Tue Mar  9 10:31:03 2010	(r204909)
+++ stable/7/sys/i386/i386/mp_machdep.c	Tue Mar  9 13:08:57 2010	(r204910)
@@ -255,7 +255,8 @@ mp_topology(void)
 	group = &mp_groups[0];
 	groups = 1;
 	for (cpu = 0, apic_id = 0; apic_id <= MAX_APIC_ID; apic_id++) {
-		if (!cpu_info[apic_id].cpu_present)
+		if (!cpu_info[apic_id].cpu_present ||
+		    cpu_info[apic_id].cpu_disabled)
 			continue;
 		/*
 		 * If the current group has members and we're not a logical


More information about the svn-src-all mailing list