]> www.infradead.org Git - users/jedix/linux-maple.git/commit
crypto: ccp - Add hash state import and export support
authorTom Lendacky <thomas.lendacky@amd.com>
Tue, 12 Jan 2016 17:17:38 +0000 (11:17 -0600)
committerChuck Anderson <chuck.anderson@oracle.com>
Thu, 26 May 2016 22:46:02 +0000 (15:46 -0700)
commit640ae23a60677f364f516f81dd761a7f3c6109f6
tree2ffc93fe50231345a23b467f04d1445f5de8b812
parentc29c8abac29ceea13fe58bace2b510d6a9089016
crypto: ccp - Add hash state import and export support

Orabug: 23331048

[ Upstream commit 952bce9792e6bf36fda09c2e5718abb5d9327369 ]

Commit 8996eafdcbad ("crypto: ahash - ensure statesize is non-zero")
added a check to prevent ahash algorithms from successfully registering
if the import and export functions were not implemented. This prevents
an oops in the hash_accept function of algif_hash. This commit causes
the ccp-crypto module SHA support and AES CMAC support from successfully
registering and causing the ccp-crypto module load to fail because the
ahash import and export functions are not implemented.

Update the CCP Crypto API support to provide import and export support
for ahash algorithms.

Cc: <stable@vger.kernel.org> # 3.14.x-
Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
(cherry picked from commit 1ad241d40ef8d9a50ced5c35bf55e9a21a997516)

Signed-off-by: Dan Duval <dan.duval@oracle.com>
drivers/crypto/ccp/ccp-crypto-aes-cmac.c
drivers/crypto/ccp/ccp-crypto-sha.c