]> git.karo-electronics.de Git - karo-tx-linux.git/commit
s390/crypto: fix aes_s390 crypto module unload problem
authorIngo Tuchscherer <ingo.tuchscherer@de.ibm.com>
Tue, 15 Oct 2013 09:24:07 +0000 (11:24 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Tue, 22 Oct 2013 07:18:26 +0000 (09:18 +0200)
commit0b060cc9650e90f2b39b256ecddb728d2346e092
tree78df6c562c7885af9add3be50ff86800d3c3a4b7
parentc6b034a9fad908817a502e752ea74855ea83287d
s390/crypto: fix aes_s390 crypto module unload problem

If a machine has no hardware support for the xts-aes or ctr-aes algorithms
they are not registered in aes_s390_init. But aes_s390_fini unconditionally
unregisters the algorithms which causes crypto_remove_alg to crash.
Add two flag variables to remember if xts-aes and ctr-aes have been added.

Signed-off-by: Ingo Tuchscherer <ingo.tuchscherer@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/crypto/aes_s390.c