]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: tegra - use kernel entropy instead of ad-hoc
authorLinus Walleij <linus.walleij@linaro.org>
Mon, 9 Sep 2013 07:35:54 +0000 (09:35 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 13 Sep 2013 11:43:53 +0000 (21:43 +1000)
commitc5ca65052d438de3ae3b5ac41db1589c7969a192
tree6ed73974a4a8cec70834be01514c8af2852dfaf4
parentc970693a98bfa410e7884b3461d8fc714f5ec183
crypto: tegra - use kernel entropy instead of ad-hoc

The way I read the Tegra AES RNG is that it has a homebrew
algorithm for initializing the 128bit RNG using timespec and
the unique chip ID. This looks like reinventing the (square)
wheel, instead just grab 128bits from the kernel entropy pool
where the time and (after another patch) chip unique ID is
already mixed in.

Incidentally this also gets rid of a rather ugly
cross-dependence on the machine using an extern declaration.

Cc: Varun Wadekar <vwadekar@nvidia.com>
Cc: Neil Horman <nhorman@tuxdriver.com>
Cc: linux-tegra@vger.kernel.org
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/tegra-aes.c