]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commit
s390/zcrypt: enable card/domain autoselect on ep11 cprbs
authorHarald Freudenberger <freude@linux.ibm.com>
Mon, 17 Feb 2020 17:37:10 +0000 (18:37 +0100)
committerSeth Forshee <seth.forshee@canonical.com>
Thu, 20 Feb 2020 13:58:10 +0000 (07:58 -0600)
commitdb6d177365bf0e4dba87778bcb5f9f8d03505361
tree3ffcf1853f876b0c37ede348f931cd39acfd5e8c
parentddbe4cf495b032849bacb37bbf1a9c2f744acd42
s390/zcrypt: enable card/domain autoselect on ep11 cprbs

BugLink: https://bugs.launchpad.net/bugs/1853303
For EP11 CPRBs there was only to choose between specify
one or more ep11 targets or not give a target at all. Without
any target the zcrypt code assumed AUTOSELECT. For EP11 this
ended up in choosing any EP11 APQN with regards to the weight.

However, CCA CPRBs can have a more fine granular target
addressing. The caller can give 0xFFFF as AUTOSELECT for
the card and/or the domain. So it's possible to address
any card but domain given or any domain but card given.

This patch now introduces the very same for EP11 CPRB handling.
An EP11 target entry now may contain 0xFFFF as card and/or
domain value with the meaning of ANY card or domain. So
now the same behavior as with CCA CPRBs becomes possible:
Address any card with given domain or address any domain within
given card.

For convenience the zcrypt.h header file now has two new
defines AUTOSEL_AP and AUTOSEL_DOM covering the 0xFFFF
value to address card any and domain any.

Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
(cherry picked from commit 8f291ebf327050822d4ebf3812e5cc033ee0a88a)
Signed-off-by: Frank Heimes <frank.heimes@canonical.com>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
arch/s390/include/uapi/asm/zcrypt.h
drivers/s390/crypto/zcrypt_api.c