svn commit: r284925 - in head/sys/i386: i386 include

Konstantin Belousov kib at FreeBSD.org
Mon Jun 29 10:35:02 UTC 2015


Author: kib
Date: Mon Jun 29 10:35:00 2015
New Revision: 284925
URL: https://svnweb.freebsd.org/changeset/base/284925

Log:
  Move CS_SECURE() and EFL_SECURE() macros to the machine/frame.h.  They
  are useful for most implementations of sendsig().
  
  Sponsored by:	The FreeBSD Foundation
  MFC after:	1 week

Modified:
  head/sys/i386/i386/machdep.c
  head/sys/i386/include/frame.h

Modified: head/sys/i386/i386/machdep.c
==============================================================================
--- head/sys/i386/i386/machdep.c	Mon Jun 29 10:33:04 2015	(r284924)
+++ head/sys/i386/i386/machdep.c	Mon Jun 29 10:35:00 2015	(r284925)
@@ -166,9 +166,6 @@ CTASSERT(offsetof(struct pcpu, pc_curthr
 extern register_t init386(int first);
 extern void dblfault_handler(void);
 
-#define	CS_SECURE(cs)		(ISPL(cs) == SEL_UPL)
-#define	EFL_SECURE(ef, oef)	((((ef) ^ (oef)) & ~PSL_USERCHANGE) == 0)
-
 #if !defined(CPU_DISABLE_SSE) && defined(I686_CPU)
 #define CPU_ENABLE_SSE
 #endif

Modified: head/sys/i386/include/frame.h
==============================================================================
--- head/sys/i386/include/frame.h	Mon Jun 29 10:33:04 2015	(r284924)
+++ head/sys/i386/include/frame.h	Mon Jun 29 10:35:00 2015	(r284925)
@@ -4,3 +4,11 @@
 /* $FreeBSD$ */
 
 #include <x86/frame.h>
+
+#ifndef __I386_FRAME_H__
+#define	__i386_FRAME_H__
+
+#define	CS_SECURE(cs)		(ISPL(cs) == SEL_UPL)
+#define	EFL_SECURE(ef, oef)	((((ef) ^ (oef)) & ~PSL_USERCHANGE) == 0)
+
+#endif


More information about the svn-src-head mailing list