diff options
author | Ingo Franzki <ifranzki@linux.ibm.com> | 2018-08-23 11:49:38 -0400 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2018-10-10 01:37:18 -0400 |
commit | cb26b9ff7187ea79698f5e872d713f30affcc0a3 (patch) | |
tree | 8efa20448fa9ac8480880510a35d75795cc9186e /arch/s390/include/uapi | |
parent | af504452d10ece7c6d68bc9f90f478ebecd7ce76 (diff) |
s390/pkey: Introduce new API for random protected key verification
Introduce a new ioctl API and in-kernel API to verify if a
random protected key is still valid. A protected key is
invalid when its wrapping key verification pattern does not
match the verification pattern of the LPAR. Each time an LPAR
is activated, a new LPAR wrapping key is generated and the
wrapping key verification pattern is updated.
Both APIs are described in detail in the header files
arch/s390/include/asm/pkey.h and arch/s390/include/uapi/asm/pkey.h.
Signed-off-by: Ingo Franzki <ifranzki@linux.ibm.com>
Reviewed-by: Harald Freudenberger <freude@linux.ibm.com>
Reviewed-by: Hendrik Brueckner <brueckner@linux.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch/s390/include/uapi')
-rw-r--r-- | arch/s390/include/uapi/asm/pkey.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/s390/include/uapi/asm/pkey.h b/arch/s390/include/uapi/asm/pkey.h index 10a7bc7c5fa9..fef08dbd2e8d 100644 --- a/arch/s390/include/uapi/asm/pkey.h +++ b/arch/s390/include/uapi/asm/pkey.h | |||
@@ -139,4 +139,13 @@ struct pkey_genprotk { | |||
139 | 139 | ||
140 | #define PKEY_GENPROTK _IOWR(PKEY_IOCTL_MAGIC, 0x08, struct pkey_genprotk) | 140 | #define PKEY_GENPROTK _IOWR(PKEY_IOCTL_MAGIC, 0x08, struct pkey_genprotk) |
141 | 141 | ||
142 | /* | ||
143 | * Verify an (AES) protected key. | ||
144 | */ | ||
145 | struct pkey_verifyprotk { | ||
146 | struct pkey_protkey protkey; /* in: the protected key to verify */ | ||
147 | }; | ||
148 | |||
149 | #define PKEY_VERIFYPROTK _IOW(PKEY_IOCTL_MAGIC, 0x09, struct pkey_verifyprotk) | ||
150 | |||
142 | #endif /* _UAPI_PKEY_H */ | 151 | #endif /* _UAPI_PKEY_H */ |