aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/cpuset.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/cpuset.h')
-rw-r--r--include/linux/cpuset.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/include/linux/cpuset.h b/include/linux/cpuset.h
index 37d2dd7ca3e9..34081c168af5 100644
--- a/include/linux/cpuset.h
+++ b/include/linux/cpuset.h
@@ -14,6 +14,8 @@
14 14
15#ifdef CONFIG_CPUSETS 15#ifdef CONFIG_CPUSETS
16 16
17extern int number_of_cpusets; /* How many cpusets are defined in system? */
18
17extern int cpuset_init(void); 19extern int cpuset_init(void);
18extern void cpuset_init_smp(void); 20extern void cpuset_init_smp(void);
19extern void cpuset_fork(struct task_struct *p); 21extern void cpuset_fork(struct task_struct *p);
@@ -25,7 +27,13 @@ void cpuset_update_task_memory_state(void);
25#define cpuset_nodes_subset_current_mems_allowed(nodes) \ 27#define cpuset_nodes_subset_current_mems_allowed(nodes) \
26 nodes_subset((nodes), current->mems_allowed) 28 nodes_subset((nodes), current->mems_allowed)
27int cpuset_zonelist_valid_mems_allowed(struct zonelist *zl); 29int cpuset_zonelist_valid_mems_allowed(struct zonelist *zl);
28extern int cpuset_zone_allowed(struct zone *z, gfp_t gfp_mask); 30
31extern int __cpuset_zone_allowed(struct zone *z, gfp_t gfp_mask);
32static int inline cpuset_zone_allowed(struct zone *z, gfp_t gfp_mask)
33{
34 return number_of_cpusets <= 1 || __cpuset_zone_allowed(z, gfp_mask);
35}
36
29extern int cpuset_excl_nodes_overlap(const struct task_struct *p); 37extern int cpuset_excl_nodes_overlap(const struct task_struct *p);
30 38
31#define cpuset_memory_pressure_bump() \ 39#define cpuset_memory_pressure_bump() \