]> git.baikalelectronics.ru Git - kernel.git/commit
s390/zcrypt: use explicit return code for flushed requests
authorMartin Schwidefsky <schwidefsky@de.ibm.com>
Mon, 14 Sep 2015 14:59:27 +0000 (16:59 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Wed, 14 Oct 2015 12:32:22 +0000 (14:32 +0200)
commit74bd2d2fcfe20588d293123ab194b5ff32d4aa2d
treea374f011ddd2cbf4be42ce386eed982ea70dd195
parenta750835c72724ec43888676362b485bd160a43f4
s390/zcrypt: use explicit return code for flushed requests

If a AP device is removed while messages are still pending, the requests
are cancelled by calling the message receive function with an error pointer
for the reply. The message type receive handler recognize this and create
a fake hardware error TYPE82_RSP_CODE / REP82_ERROR_MACHINE_FAILURE.
The message with the hardware error then causes a printk and a return
code of -EAGAIN.

Replace the intricate scheme with an explicit return code for this sitation
and avoid the error message.

Reviewd-by: Ingo Tuchscherer <ingo.tuchscherer@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
drivers/s390/crypto/ap_bus.c
drivers/s390/crypto/ap_bus.h
drivers/s390/crypto/zcrypt_msgtype50.c
drivers/s390/crypto/zcrypt_msgtype6.c
drivers/s390/crypto/zcrypt_pcica.c
drivers/s390/crypto/zcrypt_pcicc.c