diff options
Diffstat (limited to 'include/linux/mem_encrypt.h')
-rw-r--r-- | include/linux/mem_encrypt.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/mem_encrypt.h b/include/linux/mem_encrypt.h index 570f4fcff13f..1255f09f5e42 100644 --- a/include/linux/mem_encrypt.h +++ b/include/linux/mem_encrypt.h | |||
@@ -35,6 +35,14 @@ static inline unsigned long sme_get_me_mask(void) | |||
35 | return sme_me_mask; | 35 | return sme_me_mask; |
36 | } | 36 | } |
37 | 37 | ||
38 | /* | ||
39 | * The __sme_set() and __sme_clr() macros are useful for adding or removing | ||
40 | * the encryption mask from a value (e.g. when dealing with pagetable | ||
41 | * entries). | ||
42 | */ | ||
43 | #define __sme_set(x) ((unsigned long)(x) | sme_me_mask) | ||
44 | #define __sme_clr(x) ((unsigned long)(x) & ~sme_me_mask) | ||
45 | |||
38 | #endif /* __ASSEMBLY__ */ | 46 | #endif /* __ASSEMBLY__ */ |
39 | 47 | ||
40 | #endif /* __MEM_ENCRYPT_H__ */ | 48 | #endif /* __MEM_ENCRYPT_H__ */ |