Lines Matching refs:keys
33 * We give each process its own keys, which are shared by all threads. The keys
57 static __always_inline void ptrauth_keys_init_kernel(struct ptrauth_keys_kernel *keys)
60 get_random_bytes(&keys->apia, sizeof(keys->apia));
63 static __always_inline void ptrauth_keys_switch_kernel(struct ptrauth_keys_kernel *keys)
68 __ptrauth_key_install_nosync(APIA, keys->apia);
74 static inline void ptrauth_keys_install_user(struct ptrauth_keys_user *keys)
77 __ptrauth_key_install_nosync(APIB, keys->apib);
78 __ptrauth_key_install_nosync(APDA, keys->apda);
79 __ptrauth_key_install_nosync(APDB, keys->apdb);
83 __ptrauth_key_install_nosync(APGA, keys->apga);
86 static inline void ptrauth_keys_init_user(struct ptrauth_keys_user *keys)
89 get_random_bytes(&keys->apia, sizeof(keys->apia));
90 get_random_bytes(&keys->apib, sizeof(keys->apib));
91 get_random_bytes(&keys->apda, sizeof(keys->apda));
92 get_random_bytes(&keys->apdb, sizeof(keys->apdb));
96 get_random_bytes(&keys->apga, sizeof(keys->apga));
98 ptrauth_keys_install_user(keys);
103 extern int ptrauth_set_enabled_keys(struct task_struct *tsk, unsigned long keys,
123 /* enable all keys */ \
136 #define ptrauth_set_enabled_keys(tsk, keys, enabled) (-EINVAL)