Lines Matching refs:mempolicy

122 static struct mempolicy default_policy = {
128 static struct mempolicy preferred_node_policy[MAX_NUMNODES];
156 struct mempolicy *get_task_policy(struct task_struct *p) in get_task_policy()
158 struct mempolicy *pol = p->mempolicy; in get_task_policy()
176 int (*create)(struct mempolicy *pol, const nodemask_t *nodes);
177 void (*rebind)(struct mempolicy *pol, const nodemask_t *nodes);
180 static inline int mpol_store_user_nodemask(const struct mempolicy *pol) in mpol_store_user_nodemask()
193 static int mpol_new_interleave(struct mempolicy *pol, const nodemask_t *nodes) in mpol_new_interleave()
201 static int mpol_new_preferred(struct mempolicy *pol, const nodemask_t *nodes) in mpol_new_preferred()
212 static int mpol_new_bind(struct mempolicy *pol, const nodemask_t *nodes) in mpol_new_bind()
229 static int mpol_set_nodemask(struct mempolicy *pol, in mpol_set_nodemask()
268 static struct mempolicy *mpol_new(unsigned short mode, unsigned short flags, in mpol_new()
271 struct mempolicy *policy; in mpol_new()
313 void __mpol_put(struct mempolicy *p) in __mpol_put()
320 static void mpol_rebind_default(struct mempolicy *pol, const nodemask_t *nodes) in mpol_rebind_default()
324 static void mpol_rebind_nodemask(struct mempolicy *pol, const nodemask_t *nodes) in mpol_rebind_nodemask()
344 static void mpol_rebind_preferred(struct mempolicy *pol, in mpol_rebind_preferred()
375 static void mpol_rebind_policy(struct mempolicy *pol, const nodemask_t *newmask) in mpol_rebind_policy()
395 mpol_rebind_policy(tsk->mempolicy, new); in mpol_rebind_task()
770 struct mempolicy *pol) in vma_replace_policy()
773 struct mempolicy *old; in vma_replace_policy()
774 struct mempolicy *new; in vma_replace_policy()
803 unsigned long end, struct mempolicy *new_pol) in mbind_range()
865 struct mempolicy *new, *old; in do_set_mempolicy()
884 old = current->mempolicy; in do_set_mempolicy()
885 current->mempolicy = new; in do_set_mempolicy()
901 static void get_policy_nodemask(struct mempolicy *p, nodemask_t *nodes) in get_policy_nodemask()
945 struct mempolicy *pol = current->mempolicy, *pol_refcount = NULL; in do_get_mempolicy()
998 } else if (pol == current->mempolicy && in do_get_mempolicy()
1273 struct mempolicy *new; in do_mbind()
1779 struct mempolicy *__get_vma_policy(struct vm_area_struct *vma, in __get_vma_policy()
1782 struct mempolicy *pol = NULL; in __get_vma_policy()
1816 static struct mempolicy *get_vma_policy(struct vm_area_struct *vma, in get_vma_policy()
1819 struct mempolicy *pol = __get_vma_policy(vma, addr); in get_vma_policy()
1829 struct mempolicy *pol; in vma_policy_mof()
1849 static int apply_policy_zone(struct mempolicy *policy, enum zone_type zone) in apply_policy_zone()
1873 nodemask_t *policy_nodemask(gfp_t gfp, struct mempolicy *policy) in policy_nodemask()
1885 static int policy_node(gfp_t gfp, struct mempolicy *policy, int nd) in policy_node()
1902 static unsigned interleave_nodes(struct mempolicy *policy) in interleave_nodes()
1919 struct mempolicy *policy; in mempolicy_slab_node()
1925 policy = current->mempolicy; in mempolicy_slab_node()
1964 static unsigned offset_il_node(struct mempolicy *pol, unsigned long n) in offset_il_node()
1981 static inline unsigned interleave_nid(struct mempolicy *pol, in interleave_nid()
2019 struct mempolicy **mpol, nodemask_t **nodemask) in huge_node()
2055 struct mempolicy *mempolicy; in init_nodemask_of_mempolicy() local
2058 if (!(mask && current->mempolicy)) in init_nodemask_of_mempolicy()
2062 mempolicy = current->mempolicy; in init_nodemask_of_mempolicy()
2063 switch (mempolicy->mode) { in init_nodemask_of_mempolicy()
2065 if (mempolicy->flags & MPOL_F_LOCAL) in init_nodemask_of_mempolicy()
2068 nid = mempolicy->v.preferred_node; in init_nodemask_of_mempolicy()
2074 *mask = mempolicy->v.nodes; in init_nodemask_of_mempolicy()
2099 struct mempolicy *mempolicy; in mempolicy_nodemask_intersects() local
2105 mempolicy = tsk->mempolicy; in mempolicy_nodemask_intersects()
2106 if (!mempolicy) in mempolicy_nodemask_intersects()
2109 switch (mempolicy->mode) { in mempolicy_nodemask_intersects()
2120 ret = nodes_intersects(mempolicy->v.nodes, *mask); in mempolicy_nodemask_intersects()
2176 struct mempolicy *pol; in alloc_pages_vma()
2258 struct mempolicy *pol = &default_policy; in alloc_pages_current()
2281 struct mempolicy *pol = mpol_dup(vma_policy(src)); in vma_dup_policy()
2301 struct mempolicy *__mpol_dup(struct mempolicy *old) in __mpol_dup()
2303 struct mempolicy *new = kmem_cache_alloc(policy_cache, GFP_KERNEL); in __mpol_dup()
2309 if (old == current->mempolicy) { in __mpol_dup()
2325 bool __mpol_equal(struct mempolicy *a, struct mempolicy *b) in __mpol_equal()
2422 struct mempolicy *
2425 struct mempolicy *pol = NULL; in mpol_shared_policy_lookup()
2465 struct mempolicy *pol; in mpol_misplaced()
2537 struct mempolicy *pol; in mpol_put_task_policy()
2540 pol = task->mempolicy; in mpol_put_task_policy()
2541 task->mempolicy = NULL; in mpol_put_task_policy()
2554 unsigned long end, struct mempolicy *pol) in sp_node_init()
2562 struct mempolicy *pol) in sp_alloc()
2565 struct mempolicy *newpol; in sp_alloc()
2588 struct mempolicy *mpol_new = NULL; in shared_policy_replace()
2658 void mpol_shared_policy_init(struct shared_policy *sp, struct mempolicy *mpol) in mpol_shared_policy_init()
2667 struct mempolicy *new; in mpol_shared_policy_init()
2698 struct vm_area_struct *vma, struct mempolicy *npol) in mpol_set_shared_policy()
2794 sizeof(struct mempolicy), in numa_policy_init()
2802 preferred_node_policy[nid] = (struct mempolicy) { in numa_policy_init()
2874 int mpol_parse_str(char *str, struct mempolicy **mpol) in mpol_parse_str()
2876 struct mempolicy *new = NULL; in mpol_parse_str()
3006 void mpol_to_str(char *buffer, int maxlen, struct mempolicy *pol) in mpol_to_str()