]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: sa2ul - Check engine status before enabling
authorAndrew Davis <afd@ti.com>
Wed, 6 Jul 2022 19:11:44 +0000 (14:11 -0500)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 15 Jul 2022 08:43:22 +0000 (16:43 +0800)
commitf8f989fe6385ab5af4e36120eaa9e1979f242c33
treebea10ed7a6202c8d48ceec643ec27f0c9b09571c
parent70cf0393e2432e2af9910f9fd5b5e98daf67a6f2
crypto: sa2ul - Check engine status before enabling

There is a engine status register that can be used to check if the
different HW crypto engines are enabled. Check that first and then only
try to enable the engines if they are not already on.

This has a couple benefits. First we don't need to use match_data for
this. Second, this driver can now work on HS devices where the engine
control registers are read-only and writing causes a firewall exception.

Signed-off-by: Andrew Davis <afd@ti.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/sa2ul.c
drivers/crypto/sa2ul.h