e_os.h: add prandom and hwrng to the list of random devices on s390x.
authorPatrick Steuer <patrick.steuer@de.ibm.com>
Thu, 5 Oct 2017 16:20:30 +0000 (18:20 +0200)
committerAndy Polyakov <appro@openssl.org>
Sun, 22 Oct 2017 20:56:18 +0000 (22:56 +0200)
Signed-off-by: Patrick Steuer <patrick.steuer@de.ibm.com>
Reviewed-by: Rich Salz <rsalz@openssl.org>
Reviewed-by: Andy Polyakov <appro@openssl.org>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/4534)

e_os.h

diff --git a/e_os.h b/e_os.h
index e76fb43..f3b8fb8 100644 (file)
--- a/e_os.h
+++ b/e_os.h
@@ -58,7 +58,11 @@ extern "C" {
  * set this to a comma-separated list of 'random' device files to try out. By
  * default, we will try to read at least one of these files
  */
-#  define DEVRANDOM "/dev/urandom","/dev/random","/dev/srandom"
+#  if defined(__s390__)
+#   define DEVRANDOM "/dev/prandom","/dev/urandom","/dev/hwrng","/dev/random"
+#  else
+#   define DEVRANDOM "/dev/urandom","/dev/random","/dev/srandom"
+#  endif
 # endif
 # if !defined(OPENSSL_NO_EGD) && !defined(DEVRANDOM_EGD)
 /*