get_mempolicy(): store policy in per-process VM structure

This commit is contained in:
Balazs Gerofi
2016-10-16 09:10:36 +09:00
parent b88d75720f
commit 99a02e2941
3 changed files with 16 additions and 11 deletions

View File

@ -168,6 +168,15 @@
#define PROCESS_NUMA_MASK_BITS 64
enum {
MPOL_DEFAULT,
MPOL_PREFERRED,
MPOL_BIND,
MPOL_INTERLEAVE,
MPOL_LOCAL,
MPOL_MAX, /* always last member of enum */
};
#include <waitq.h>
#include <futex.h>
@ -598,6 +607,7 @@ struct process_vm {
long currss;
DECLARE_BITMAP(numa_mask, PROCESS_NUMA_MASK_BITS);
int numa_mem_policy;
};
static inline int has_cap_ipc_lock(struct thread *th)