Lines Matching refs:mempolicy

126 static struct mempolicy default_policy = {
131 static struct mempolicy preferred_node_policy[MAX_NUMNODES];
161 struct mempolicy *get_task_policy(struct task_struct *p) in get_task_policy()
163 struct mempolicy *pol = p->mempolicy; in get_task_policy()
181 int (*create)(struct mempolicy *pol, const nodemask_t *nodes);
182 void (*rebind)(struct mempolicy *pol, const nodemask_t *nodes);
185 static inline int mpol_store_user_nodemask(const struct mempolicy *pol) in mpol_store_user_nodemask()
198 static int mpol_new_nodemask(struct mempolicy *pol, const nodemask_t *nodes) in mpol_new_nodemask()
206 static int mpol_new_preferred(struct mempolicy *pol, const nodemask_t *nodes) in mpol_new_preferred()
224 static int mpol_set_nodemask(struct mempolicy *pol, in mpol_set_nodemask()
261 static struct mempolicy *mpol_new(unsigned short mode, unsigned short flags, in mpol_new()
264 struct mempolicy *policy; in mpol_new()
308 void __mpol_put(struct mempolicy *p) in __mpol_put()
315 static void mpol_rebind_default(struct mempolicy *pol, const nodemask_t *nodes) in mpol_rebind_default()
319 static void mpol_rebind_nodemask(struct mempolicy *pol, const nodemask_t *nodes) in mpol_rebind_nodemask()
339 static void mpol_rebind_preferred(struct mempolicy *pol, in mpol_rebind_preferred()
352 static void mpol_rebind_policy(struct mempolicy *pol, const nodemask_t *newmask) in mpol_rebind_policy()
372 mpol_rebind_policy(tsk->mempolicy, new); in mpol_rebind_task()
762 struct mempolicy *pol) in vma_replace_policy()
765 struct mempolicy *old; in vma_replace_policy()
766 struct mempolicy *new; in vma_replace_policy()
795 unsigned long end, struct mempolicy *new_pol) in mbind_range()
854 struct mempolicy *new, *old; in do_set_mempolicy()
875 old = current->mempolicy; in do_set_mempolicy()
876 current->mempolicy = new; in do_set_mempolicy()
892 static void get_policy_nodemask(struct mempolicy *p, nodemask_t *nodes) in get_policy_nodemask()
933 struct mempolicy *pol = current->mempolicy, *pol_refcount = NULL; in do_get_mempolicy()
986 } else if (pol == current->mempolicy && in do_get_mempolicy()
1262 struct mempolicy *new; in do_mbind()
1493 struct mempolicy *new, *old; in SYSCALL_DEFINE4()
1749 struct mempolicy *__get_vma_policy(struct vm_area_struct *vma, in __get_vma_policy()
1752 struct mempolicy *pol = NULL; in __get_vma_policy()
1786 static struct mempolicy *get_vma_policy(struct vm_area_struct *vma, in get_vma_policy()
1789 struct mempolicy *pol = __get_vma_policy(vma, addr); in get_vma_policy()
1799 struct mempolicy *pol; in vma_policy_mof()
1819 bool apply_policy_zone(struct mempolicy *policy, enum zone_type zone) in apply_policy_zone()
1843 nodemask_t *policy_nodemask(gfp_t gfp, struct mempolicy *policy) in policy_nodemask()
1866 static int policy_node(gfp_t gfp, struct mempolicy *policy, int nd) in policy_node()
1888 static unsigned interleave_nodes(struct mempolicy *policy) in interleave_nodes()
1905 struct mempolicy *policy; in mempolicy_slab_node()
1911 policy = current->mempolicy; in mempolicy_slab_node()
1951 static unsigned offset_il_node(struct mempolicy *pol, unsigned long n) in offset_il_node()
1977 static inline unsigned interleave_nid(struct mempolicy *pol, in interleave_nid()
2015 struct mempolicy **mpol, nodemask_t **nodemask) in huge_node()
2053 struct mempolicy *mempolicy; in init_nodemask_of_mempolicy() local
2055 if (!(mask && current->mempolicy)) in init_nodemask_of_mempolicy()
2059 mempolicy = current->mempolicy; in init_nodemask_of_mempolicy()
2060 switch (mempolicy->mode) { in init_nodemask_of_mempolicy()
2065 *mask = mempolicy->nodes; in init_nodemask_of_mempolicy()
2094 struct mempolicy *mempolicy; in mempolicy_in_oom_domain() local
2101 mempolicy = tsk->mempolicy; in mempolicy_in_oom_domain()
2102 if (mempolicy && mempolicy->mode == MPOL_BIND) in mempolicy_in_oom_domain()
2103 ret = nodes_intersects(mempolicy->nodes, *mask); in mempolicy_in_oom_domain()
2129 int nid, struct mempolicy *pol) in alloc_pages_preferred_many()
2167 struct mempolicy *pol; in vma_alloc_folio()
2267 struct mempolicy *pol = &default_policy; in alloc_pages()
2302 struct mempolicy *pol, unsigned long nr_pages, in alloc_pages_bulk_array_interleave()
2337 struct mempolicy *pol, unsigned long nr_pages, in alloc_pages_bulk_array_preferred_many()
2365 struct mempolicy *pol = &default_policy; in alloc_pages_bulk_array_mempolicy()
2385 struct mempolicy *pol = mpol_dup(vma_policy(src)); in vma_dup_policy()
2405 struct mempolicy *__mpol_dup(struct mempolicy *old) in __mpol_dup()
2407 struct mempolicy *new = kmem_cache_alloc(policy_cache, GFP_KERNEL); in __mpol_dup()
2413 if (old == current->mempolicy) { in __mpol_dup()
2429 bool __mpol_equal(struct mempolicy *a, struct mempolicy *b) in __mpol_equal()
2527 struct mempolicy *
2530 struct mempolicy *pol = NULL; in mpol_shared_policy_lookup()
2567 struct mempolicy *pol; in mpol_misplaced()
2649 struct mempolicy *pol; in mpol_put_task_policy()
2652 pol = task->mempolicy; in mpol_put_task_policy()
2653 task->mempolicy = NULL; in mpol_put_task_policy()
2666 unsigned long end, struct mempolicy *pol) in sp_node_init()
2674 struct mempolicy *pol) in sp_alloc()
2677 struct mempolicy *newpol; in sp_alloc()
2700 struct mempolicy *mpol_new = NULL; in shared_policy_replace()
2771 void mpol_shared_policy_init(struct shared_policy *sp, struct mempolicy *mpol) in mpol_shared_policy_init()
2780 struct mempolicy *new; in mpol_shared_policy_init()
2811 struct vm_area_struct *vma, struct mempolicy *npol) in mpol_set_shared_policy()
2907 sizeof(struct mempolicy), in numa_policy_init()
2915 preferred_node_policy[nid] = (struct mempolicy) { in numa_policy_init()
2985 int mpol_parse_str(char *str, struct mempolicy **mpol) in mpol_parse_str()
2987 struct mempolicy *new = NULL; in mpol_parse_str()
3119 void mpol_to_str(char *buffer, int maxlen, struct mempolicy *pol) in mpol_to_str()