#ifndef _ASM_X86_PKRU_H
#define _ASM_X86_PKRU_H
#include <asm/cpufeature.h>
#define PKRU_AD_BIT …
#define PKRU_WD_BIT …
#define PKRU_BITS_PER_PKEY …
#ifdef CONFIG_X86_INTEL_MEMORY_PROTECTION_KEYS
extern u32 init_pkru_value;
#define pkru_get_init_value() …
#else
#define init_pkru_value …
#define pkru_get_init_value …
#endif
static inline bool __pkru_allows_read(u32 pkru, u16 pkey)
{ … }
static inline bool __pkru_allows_write(u32 pkru, u16 pkey)
{ … }
static inline u32 read_pkru(void)
{ … }
static inline void write_pkru(u32 pkru)
{ … }
static inline void pkru_write_default(void)
{ … }
#endif