Date: Thu, 31 Oct 2013 22:46:04 +0000 (UTC) From: Marcel Moolenaar <marcel@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r257475 - head/sys/ia64/ia64 Message-ID: <201310312246.r9VMk4kn093823@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: marcel Date: Thu Oct 31 22:46:03 2013 New Revision: 257475 URL: http://svnweb.freebsd.org/changeset/base/257475 Log: Respect the kern.smp.disabled tunable. When we're scanning the MADT in ia64_probe_sapics(), we also create PCPU structures for any Local SAPICs we encounter. When SMP is disabled, this leaves us with partially setup PCPU structures, which typically results in panics when we're iterating over CPUs. When SMP is disabled, we now prevent the creation of the PCPU structures. Modified: head/sys/ia64/ia64/mp_machdep.c Modified: head/sys/ia64/ia64/mp_machdep.c ============================================================================== --- head/sys/ia64/ia64/mp_machdep.c Thu Oct 31 21:16:47 2013 (r257474) +++ head/sys/ia64/ia64/mp_machdep.c Thu Oct 31 22:46:03 2013 (r257475) @@ -65,6 +65,8 @@ __FBSDID("$FreeBSD$"); extern uint64_t bdata[]; +extern int smp_disabled; + MALLOC_DEFINE(M_SMP, "SMP", "SMP related allocations"); void ia64_ap_startup(void); @@ -294,6 +296,9 @@ cpu_mp_add(u_int acpi_id, u_int id, u_in void *dpcpu; u_int cpuid, sapic_id; + if (smp_disabled) + return; + sapic_id = SAPIC_ID_SET(id, eid); cpuid = (IA64_LID_GET_SAPIC_ID(ia64_get_lid()) == sapic_id) ? 0 : smp_cpus++;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201310312246.r9VMk4kn093823>