crypto: talitos - add support for sha224
authorKim Phillips <kim.phillips@freescale.com>
Wed, 19 May 2010 09:21:53 +0000 (19:21 +1000)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 19 May 2010 09:21:53 +0000 (19:21 +1000)
commit60f208d7836216885cdcd6f77a02f31dbc66f169
tree03458188b947e1cddf5d0f34b316935e470f7147
parent497f2e6b8b21407625a4fb34bc04b50eff098085
crypto: talitos - add support for sha224

SEC h/w versions 2.1 and above support sha224 via explicit instruction.

Performing sha224 ahashes on earlier versions is still possible because
they support sha256 (sha224 is sha256 with different initial constants
and a different truncation length).  We do this by overriding hardware
context self-initialization, and perform it manually in s/w instead.

Thanks to Lee for his fixes for correct execution on actual sec2.0 h/w.

Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Signed-off by: Lee Nipper <lee.nipper@gmail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/talitos.c
drivers/crypto/talitos.h