]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commit
crypto: omap-sham - fix digcnt register handling with export/import
authorTero Kristo <t-kristo@ti.com>
Mon, 7 Sep 2020 07:56:24 +0000 (10:56 +0300)
committerStefan Bader <stefan.bader@canonical.com>
Mon, 9 Nov 2020 13:48:40 +0000 (14:48 +0100)
commitc5449a37ed8fb7aaaddbd3a93a2e4009b64fcb79
tree4f912c6192fee15b4d596714c09bb1dcd9a87265
parent6a3f3d68b31e8a9e2f1e66ed4c4e823d051a5a9a
crypto: omap-sham - fix digcnt register handling with export/import

BugLink: https://bugs.launchpad.net/bugs/1902115
[ Upstream commit 3faf757bad75f3fc1b2736f0431e295a073a7423 ]

Running export/import for hashes in peculiar order (mostly done by
openssl) can mess up the internal book keeping of the OMAP SHA core.
Fix by forcibly writing the correct DIGCNT back to hardware. This issue
was noticed while transitioning to openssl 1.1 support.

Fixes: 0d373d603202 ("crypto: omap-sham - Add OMAP4/AM33XX SHAM Support")
Signed-off-by: Tero Kristo <t-kristo@ti.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Ian May <ian.may@canonical.com>
drivers/crypto/omap-sham.c