Lines Matching refs:mask
60 #define CPUMASK_ORBIT(mask, i) ((mask).ary[((i) >> 6) & 3] |= \ argument
62 #define CPUMASK_NANDBIT(mask, i) ((mask).ary[((i) >> 6) & 3] &= \ argument
64 #define CPUMASK_ASSZERO(mask) do { \ argument
65 (mask).ary[0] = 0; \
66 (mask).ary[1] = 0; \
67 (mask).ary[2] = 0; \
68 (mask).ary[3] = 0; \
86 #define fio_cpu_count(mask) CPU_COUNT((mask)) argument
88 static inline int fio_cpuset_init(os_cpu_mask_t *mask) in fio_cpuset_init() argument
90 CPUMASK_ASSZERO(*mask); in fio_cpuset_init()
94 static inline int fio_cpuset_exit(os_cpu_mask_t *mask) in fio_cpuset_exit() argument
99 static inline void fio_cpu_clear(os_cpu_mask_t *mask, int cpu) in fio_cpu_clear() argument
101 CPUMASK_NANDBIT(*mask, cpu); in fio_cpu_clear()
104 static inline void fio_cpu_set(os_cpu_mask_t *mask, int cpu) in fio_cpu_set() argument
106 CPUMASK_ORBIT(*mask, cpu); in fio_cpu_set()
109 static inline int fio_cpu_isset(os_cpu_mask_t *mask, int cpu) in fio_cpu_isset() argument
111 if (CPUMASK_TESTBIT(*mask, cpu)) in fio_cpu_isset()
117 static inline int fio_setaffinity(int pid, os_cpu_mask_t mask) in fio_setaffinity() argument
125 if (!CPUMASK_TESTBIT(mask, i)) in fio_setaffinity()
140 static inline int fio_getaffinity(int pid, os_cpu_mask_t *mask) in fio_getaffinity() argument
145 if (usched_set(pid, USCHED_GET_CPUMASK, mask, sizeof(*mask))) in fio_getaffinity()