Date: Mon, 16 Jun 2014 22:42:45 GMT From: op@FreeBSD.org To: svn-soc-all@FreeBSD.org Subject: socsvn commit: r269655 - in soc2014/op/freebsd-base/sys/i386: i386 include Message-ID: <201406162242.s5GMgjKL027129@socsvn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: op Date: Mon Jun 16 22:42:45 2014 New Revision: 269655 URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=269655 Log: SMAP i386: added IS_BSP() macro to i386/include/pcpu.h git: https://github.com/opntr/opBSD/commits/op/gsoc2014/smap Signed-off-by: Oliver Pinter <oliver.pntr@gmail.com> Modified: soc2014/op/freebsd-base/sys/i386/i386/initcpu.c soc2014/op/freebsd-base/sys/i386/include/pcpu.h Modified: soc2014/op/freebsd-base/sys/i386/i386/initcpu.c ============================================================================== --- soc2014/op/freebsd-base/sys/i386/i386/initcpu.c Mon Jun 16 22:41:00 2014 (r269654) +++ soc2014/op/freebsd-base/sys/i386/i386/initcpu.c Mon Jun 16 22:42:45 2014 (r269655) @@ -34,6 +34,7 @@ #include <sys/param.h> #include <sys/kernel.h> +#include <sys/pcpu.h> #include <sys/systm.h> #include <sys/sysctl.h> Modified: soc2014/op/freebsd-base/sys/i386/include/pcpu.h ============================================================================== --- soc2014/op/freebsd-base/sys/i386/include/pcpu.h Mon Jun 16 22:41:00 2014 (r269654) +++ soc2014/op/freebsd-base/sys/i386/include/pcpu.h Mon Jun 16 22:42:45 2014 (r269655) @@ -250,6 +250,8 @@ } #define curpcb (__curpcb()) +#define IS_BSP() (PCPU_GET(cpuid) == 0) + #else /* !lint || defined(__GNUCLIKE_ASM) && defined(__GNUCLIKE___TYPEOF) */ #error "this file needs to be ported to your compiler"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201406162242.s5GMgjKL027129>