Fix seeding from random device w/o getrandom syscall
[openssl.git] / crypto / s390x_arch.h
index 25859851e5d49620060cc8020a6f256d5dfcca53..4a775a927db7627c679cfaae69ac33d8c743a262 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2017 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2017-2018 The OpenSSL Project Authors. All Rights Reserved.
  *
  * Licensed under the OpenSSL license (the "License").  You may not use
  * this file except in compliance with the License.  You can obtain a copy
 
 # ifndef __ASSEMBLER__
 
+void s390x_kimd(const unsigned char *in, size_t len, unsigned int fc,
+                void *param);
+void s390x_klmd(const unsigned char *in, size_t inlen, unsigned char *out,
+                size_t outlen, unsigned int fc, void *param);
+void s390x_km(const unsigned char *in, size_t len, unsigned char *out,
+              unsigned int fc, void *param);
+void s390x_kmac(const unsigned char *in, size_t len, unsigned int fc,
+                void *param);
+void s390x_kmo(const unsigned char *in, size_t len, unsigned char *out,
+               unsigned int fc, void *param);
+void s390x_kmf(const unsigned char *in, size_t len, unsigned char *out,
+               unsigned int fc, void *param);
+void s390x_kma(const unsigned char *aad, size_t alen, const unsigned char *in,
+               size_t len, unsigned char *out, unsigned int fc, void *param);
+
 /*
  * The field elements of OPENSSL_s390xcap_P are the 64-bit words returned by
  * the STFLE instruction followed by the 64-bit word pairs returned by
@@ -79,4 +94,10 @@ extern struct OPENSSL_s390xcap_st OPENSSL_s390xcap_P;
 /* prno */
 # define S390X_TRNG            114
 
+/* Register 0 Flags */
+# define S390X_DECRYPT         0x80
+# define S390X_KMA_LPC         0x100
+# define S390X_KMA_LAAD                0x200
+# define S390X_KMA_HS          0x400
+
 #endif