Blob Blame History Raw
From: Harald Freudenberger <freude@linux.ibm.com>
Subject: s390/zcrypt: fix broken zcrypt_send_cprb in-kernel api function
Patch-mainline: v4.20-rc1
Git-commit: 9434f5d3bef97c7212ef6d96d7783e3a3a6c1cb5
References: FATE#326807, LTC#172229, bsc#1113486

Summary:     zcrypt: multiple zcrypt device nodes support
Description: This patch is an extension to the zcrypt device
             driver to provide, support and maintain multiple
             zcrypt device nodes. The individual zcrypt device
             nodes can be restricted in terms of crypto cards,
             domains and available ioctls. Such a device node can
             be used as a base for container solutions like
             docker to control and restrict the access to crypto
             resources.

Upstream-Description:

             s390/zcrypt: fix broken zcrypt_send_cprb in-kernel api function

             With the new multi zcrypt device node support there came
             in a code rework which broke the in-kernel api function
             zcrypt_send_cprb(). This function is used by the pkey kernel
             module and as an effect, transforming a secure key into a
             protected key did not work any more.

             Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
             Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>

Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
Acked-by: Petr Tesarik <ptesarik@suse.com>
---
 drivers/s390/crypto/zcrypt_api.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/s390/crypto/zcrypt_api.c
+++ b/drivers/s390/crypto/zcrypt_api.c
@@ -907,7 +907,7 @@ out:
 
 long zcrypt_send_cprb(struct ica_xcRB *xcRB)
 {
-	return _zcrypt_send_cprb(NULL, xcRB);
+	return _zcrypt_send_cprb(&ap_perms, xcRB);
 }
 EXPORT_SYMBOL(zcrypt_send_cprb);