Date: Sat, 30 May 2009 15:20:26 +0000 (UTC) From: Adrian Chadd <adrian@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r193098 - head/sys/i386/xen Message-ID: <200905301520.n4UFKQZY011583@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: adrian Date: Sat May 30 15:20:25 2009 New Revision: 193098 URL: http://svn.freebsd.org/changeset/base/193098 Log: Even though I'm not quite sure that the call_func stuff will work properly in all the places/cases IPI messages will be generated, at least be consistent with how the call_data pointer is assigned and cleared (ie, all done inside the spinlock. Ensure that its NULL before continuing, just to try and identify situations where things are going horribly wrong. Modified: head/sys/i386/xen/mp_machdep.c Modified: head/sys/i386/xen/mp_machdep.c ============================================================================== --- head/sys/i386/xen/mp_machdep.c Sat May 30 15:19:40 2009 (r193097) +++ head/sys/i386/xen/mp_machdep.c Sat May 30 15:20:25 2009 (r193098) @@ -973,14 +973,14 @@ smp_tlb_shootdown(u_int vector, vm_offse u_int ncpu; struct _call_data data; - call_data = &data; - ncpu = mp_ncpus - 1; /* does not shootdown self */ if (ncpu < 1) return; /* no other cpus */ if (!(read_eflags() & PSL_I)) panic("%s: interrupts disabled", __func__); mtx_lock_spin(&smp_ipi_mtx); + KASSERT(call_data == NULL, ("call_data isn't null?!")); + call_data = &data; call_data->func_id = vector; call_data->arg1 = addr1; call_data->arg2 = addr2; @@ -1021,6 +1021,7 @@ smp_targeted_tlb_shootdown(cpumask_t mas if (!(read_eflags() & PSL_I)) panic("%s: interrupts disabled", __func__); mtx_lock_spin(&smp_ipi_mtx); + KASSERT(call_data == NULL, ("call_data isn't null?!")); call_data = &data; call_data->func_id = vector; call_data->arg1 = addr1;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200905301520.n4UFKQZY011583>