]> git.saurik.com Git - apple/xnu.git/blobdiff - bsd/sys/process_policy.h
xnu-2782.30.5.tar.gz
[apple/xnu.git] / bsd / sys / process_policy.h
index 35341278faab1122ccb0719f69a4f84b50051f9e..4aec9e13ea6604978cb7964ba5be0bc18515db41 100644 (file)
 #include <sys/types.h>
 #include <stdint.h>
 
+#ifndef XNU_KERNEL_PRIVATE
+#include <TargetConditionals.h>
+#endif
+
 __BEGIN_DECLS
 
 /* defns of scope */
@@ -61,11 +65,7 @@ __BEGIN_DECLS
 #define PROC_POLICY_HARDWARE_ACCESS    2       /* access to various hardware */
 #define PROC_POLICY_RESOURCE_STARVATION        3       /* behavior on resource starvation */
 #define PROC_POLICY_RESOURCE_USAGE     4       /* behavior on resource consumption */
-#if BUILD_LIBSYSCALL
-#define PROC_POLICY_APP_LIFECYCLE      5       /* app life cycle management */
-#else /* BUILD_LIBSYSCALL */
 #define PROC_POLICY_RESERVED           5       /* behavior on resource consumption */
-#endif /* BUILD_LIBSYSCALL */
 #define PROC_POLICY_APPTYPE            6       /* behavior on resource consumption */
 #define PROC_POLICY_BOOST               7       /* importance boost/drop */
 
@@ -75,11 +75,7 @@ __BEGIN_DECLS
 #define PROC_POLICY_BG_DISKTHROTTLE    2       /* disk accesses throttled */
 #define PROC_POLICY_BG_NETTHROTTLE     4       /* network accesses throttled */
 #define PROC_POLICY_BG_GPUDENY         8       /* no access to GPU */
-#if BUILD_LIBSYSCALL
-#define PROC_POLICY_BG_ALL            0x0F
-#else /* BUILD_LIBSYSCALL */
 #define PROC_POLICY_BG_ALL            0x07
-#endif /* BUILD_LIBSYSCALL */
 #define PROC_POLICY_BG_DEFAULT         PROC_POLICY_BG_ALL
 
 /* sub policies for hardware */
@@ -165,20 +161,10 @@ typedef struct proc_policy_cpuusage_attr {
        uint64_t        ppattr_cpu_attr_deadline;     /* 64bit deadline in nsecs */
 } proc_policy_cpuusage_attr_t;
 
-#if BUILD_LIBSYSCALL
-/* sub policies for app lifecycle management */
-#define        PROC_POLICY_APPLIFE_NONE        0       /* does nothing.. */
-#define        PROC_POLICY_APPLIFE_STATE       1       /* sets the app to various lifecycle states */
-#define        PROC_POLICY_APPLIFE_DEVSTATUS   2       /* notes the device in inactive or short/long term */
-#define        PROC_POLICY_APPLIFE_PIDBIND     3       /* a thread is to be bound to another processes app state */
-#endif /* BUILD_LIBSYSCALL */
 
 /* sub policies for PROC_POLICY_APPTYPE */
 #define        PROC_POLICY_APPTYPE_NONE        0       /* does nothing.. */
 #define        PROC_POLICY_APPTYPE_MODIFY      1       /* sets the app to various lifecycle states */
-#if BUILD_LIBSYSCALL
-#define        PROC_POLICY_APPTYPE_THREADTHR   2       /* notes the device in inactive or short/long term */
-#endif /* BUILD_LIBSYSCALL */
 
 /* exported apptypes for PROC_POLICY_APPTYPE */
 #define PROC_POLICY_OSX_APPTYPE_TAL             1       /* TAL-launched app */