PERFORCE change 138327 for review

John Birrell jb at FreeBSD.org
Sun Mar 23 03:47:59 UTC 2008


http://perforce.freebsd.org/chv.cgi?CH=138327

Change 138327 by jb at jb_freebsd1 on 2008/03/23 03:47:53

	Ensure the sync includes the current CPU.
	
	Fix the bug where the current CPU would get called twice,

Affected files ...

.. //depot/projects/dtrace/src/sys/kern/subr_smp.c#13 edit

Differences ...

==== //depot/projects/dtrace/src/sys/kern/subr_smp.c#13 (text+ko) ====

@@ -376,7 +376,7 @@
 	mtx_lock_spin(&smp_ipi_mtx);
 
 	/* set static function pointers */
-	smp_rv_cpumask = map & ~(1 << curcpu);
+	smp_rv_cpumask = map;
 	smp_rv_setup_func = setup_func;
 	smp_rv_action_func = action_func;
 	smp_rv_teardown_func = teardown_func;
@@ -386,11 +386,10 @@
 	atomic_store_rel_int(&smp_rv_waiters[0], 0);
 
 	/* signal other processors, which will enter the IPI with interrupts off */
-	ipi_selected(map, IPI_RENDEZVOUS);
+	ipi_selected(map & ~(1 << curcpu), IPI_RENDEZVOUS);
 
 	/* Check if the current CPU is in the map */
 	if ((map & (1 << curcpu)) != 0)
-		/* call executor function for the current CPU */
 		smp_rendezvous_action();
 
 	if (teardown_func == smp_no_rendevous_barrier)


More information about the p4-projects mailing list