crypto: aes-generic - drop alignment requirement
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Thu, 2 Feb 2017 15:58:57 +0000 (15:58 +0000)
committerHerbert Xu <herbert@gondor.apana.org.au>
Sat, 11 Feb 2017 09:50:43 +0000 (17:50 +0800)
commitec38a9376163f9f7cb671e49b7667129c7bb8f8b
tree9a30cfcd8e0cf51b1605f68cc33243f8769cd3c1
parentc459bd7beda0295ea67db0ce2004a49addb2f765
crypto: aes-generic - drop alignment requirement

The generic AES code exposes a 32-bit align mask, which forces all
users of the code to use temporary buffers or take other measures to
ensure the alignment requirement is adhered to, even on architectures
that don't care about alignment for software algorithms such as this
one.

So drop the align mask, and fix the code to use get_unaligned_le32()
where appropriate, which will resolve to whatever is optimal for the
architecture.

Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/aes_generic.c