Lines Matching refs:pkey
12 extern int arch_set_user_pkey_access(struct task_struct *tsk, int pkey,
34 int prot, int pkey);
36 int prot, int pkey) in arch_override_mprotect_pkey() argument
41 return __arch_override_mprotect_pkey(vma, prot, pkey); in arch_override_mprotect_pkey()
44 extern int __arch_set_user_pkey_access(struct task_struct *tsk, int pkey,
50 #define mm_set_pkey_allocated(mm, pkey) do { \ argument
51 mm_pkey_allocation_map(mm) |= (1U << pkey); \
53 #define mm_set_pkey_free(mm, pkey) do { \ argument
54 mm_pkey_allocation_map(mm) &= ~(1U << pkey); \
58 bool mm_pkey_is_allocated(struct mm_struct *mm, int pkey) in mm_pkey_is_allocated() argument
65 if (pkey < 0) in mm_pkey_is_allocated()
67 if (pkey >= arch_max_pkey()) in mm_pkey_is_allocated()
74 if (pkey == mm->context.execute_only_pkey) in mm_pkey_is_allocated()
77 return mm_pkey_allocation_map(mm) & (1U << pkey); in mm_pkey_is_allocated()
111 int mm_pkey_free(struct mm_struct *mm, int pkey) in mm_pkey_free() argument
113 if (!mm_pkey_is_allocated(mm, pkey)) in mm_pkey_free()
116 mm_set_pkey_free(mm, pkey); in mm_pkey_free()
121 extern int arch_set_user_pkey_access(struct task_struct *tsk, int pkey,
123 extern int __arch_set_user_pkey_access(struct task_struct *tsk, int pkey,