s390/zcrypt: improve special ap message cmd handling
authorHarald Freudenberger <freude@linux.ibm.com>
Mon, 19 Nov 2018 10:36:13 +0000 (11:36 +0100)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Fri, 30 Nov 2018 06:22:05 +0000 (07:22 +0100)
commitbe534791011100d204602e2e0496e9e6ce8edf63
treedebe169af123ff95c8ab9e03efb62c34bf1d81d3
parent159491f3b509bd8101199944dc7b0673b881c734
s390/zcrypt: improve special ap message cmd handling

There exist very few ap messages which need to have the 'special' flag
enabled. This flag tells the firmware layer to do some pre- and maybe
postprocessing. However, it may happen that this special flag is
enabled but the firmware is unable to deal with this kind of message
and thus returns with reply code 0x41. For example older firmware may
not know the newest messages triggered by the zcrypt device driver and
thus react with reject and the named reply code. Unfortunately this
reply code is not known to the zcrypt error routines and thus default
behavior is to switch the ap queue offline.

This patch now makes the ap error routine aware of the reply code and
so userspace is informed about the bad processing result but the queue
is not switched to offline state any more.

Signed-off-by: Harald Freudenberger <freude@linux.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/include/uapi/asm/zcrypt.h
drivers/s390/crypto/zcrypt_error.h