diff options
Diffstat (limited to 'debian/patches/0002-Fix-initialization-of-s390-hardware-switches-part-2.patch')
-rw-r--r-- | debian/patches/0002-Fix-initialization-of-s390-hardware-switches-part-2.patch | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/debian/patches/0002-Fix-initialization-of-s390-hardware-switches-part-2.patch b/debian/patches/0002-Fix-initialization-of-s390-hardware-switches-part-2.patch new file mode 100644 index 0000000..5427706 --- /dev/null +++ b/debian/patches/0002-Fix-initialization-of-s390-hardware-switches-part-2.patch @@ -0,0 +1,35 @@ +From 9a0ff895de3756c2e1b0815cf9d96b77278e8282 Mon Sep 17 00:00:00 2001 +From: Ingo Tuchscherer <ingo.tuchscherer@linux.vnet.ibm.com> +Date: Tue, 19 Apr 2016 12:43:35 +0200 +Subject: [PATCH 2/2] Fix initialization of s390 hardware switches (part 2) + +The initialization of the hardware switches was not done correctly. +This could lead to illegal access and segmentation fault. + +Changed declaration of hardware switches to ensure uniqueness +across compile units and thereby proper initialization. + +Signed-off-by: Ingo Tuchscherer <ingo.tuchscherer@linux.vnet.ibm.com> +--- + src/s390_crypto.c | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/src/s390_crypto.c b/src/s390_crypto.c +index 44fb40b..8424480 100644 +--- a/src/s390_crypto.c ++++ b/src/s390_crypto.c +@@ -26,6 +26,11 @@ + #include "s390_crypto.h" + #include "init.h" + ++unsigned int sha1_switch, sha256_switch, sha512_switch, des_switch, ++ tdes_switch, aes128_switch, aes192_switch, aes256_switch, ++ prng_switch, tdea128_switch, tdea192_switch, sha512_drng_switch, ++ msa4_switch, msa5_switch; ++ + s390_supported_function_t s390_kimd_functions[] = { + {SHA_1, S390_CRYPTO_SHA_1, &sha1_switch}, + {SHA_224, S390_CRYPTO_SHA_256, &sha256_switch}, +-- +2.7.4 + |