]> git.baikalelectronics.ru Git - kernel.git/commit
s390/zcrypt: extend cca_findcard function and helper
authorHarald Freudenberger <freude@linux.ibm.com>
Tue, 18 Jun 2019 13:53:12 +0000 (15:53 +0200)
committerVasily Gorbik <gor@linux.ibm.com>
Wed, 21 Aug 2019 10:58:54 +0000 (12:58 +0200)
commit2949f415cd0223a9ee3b14e716f42f0227fe75b4
treedb03651f0faa192a910569d59a0f86d404956522
parentbfc1eaaf96c8bf3ad5535d7ee47b9d7f2aad5095
s390/zcrypt: extend cca_findcard function and helper

Rework and extension of the cca_findcard function to be prepared for
other types of secure key blobs. Split the function and extract an
internal function which has no awareness of key blobs any
more. Improve this function and the helper code around to be able to
check for a minimal crypto card hardware level (Background: the newer
AES cipher keys need to match to the master key verification pattern
and need to have a crypto card CEX6 or higher).

No API change, neither for the in-kernel API nor the ioctl interface.

Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
Reviewed-by: Ingo Franzki <ifranzki@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
drivers/s390/crypto/zcrypt_api.c
drivers/s390/crypto/zcrypt_api.h
drivers/s390/crypto/zcrypt_ccamisc.c
drivers/s390/crypto/zcrypt_ccamisc.h