Date: Tue, 3 Feb 2009 21:55:48 +0200 From: Kostik Belousov <kostikbel@gmail.com> To: Martin Cracauer <cracauer@cons.org> Cc: freebsd-smp@freebsd.org Subject: Re: Kernel code: executing once on each CPU? Message-ID: <20090203195548.GA9427@deviant.kiev.zoral.com.ua> In-Reply-To: <20090203175728.GA55080@cons.org> References: <20090203175728.GA55080@cons.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--oyUTqETQ0mS9luUI Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Feb 03, 2009 at 12:57:28PM -0500, Martin Cracauer wrote: > Is there a facility in FreeBSD that allows me to have a piece of code > executed on each processor, then return to the original thread when > that has been completed? >=20 > I need to collect some data that's local to the individual CPUs/cores. >=20 > In Linux there is/was smp_call_function(func, ...). Look at the smp_rendezvous() in the subr_smp.c. Note that the functions are called in quite restricted context. --oyUTqETQ0mS9luUI Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkmIoUQACgkQC3+MBN1Mb4gBJwCdE1XHla19zwLZ0AFOWtG4labv B1AAnjWoUiybp6vIgJTtoiHvu6jF4cky =eRq4 -----END PGP SIGNATURE----- --oyUTqETQ0mS9luUI--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090203195548.GA9427>