]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
hwrng: omap - Fix RNG wait loop timeout
authorSumit Garg <sumit.garg@linaro.org>
Mon, 14 Oct 2019 12:02:45 +0000 (17:32 +0530)
committerMarcelo Henrique Cerri <marcelo.cerri@canonical.com>
Fri, 17 Jan 2020 17:22:40 +0000 (14:22 -0300)
commit3fef059578819faab31d2d0f60c335029c9d0248
tree324cbe512d304738e5d44042a4601ba6e47a70ff
parent02e9607950f106871097eee235547e1e36c1667a
hwrng: omap - Fix RNG wait loop timeout

BugLink: https://bugs.launchpad.net/bugs/1857158
commit be867f987a4e1222114dd07a01838a17c26f3fff upstream.

Existing RNG data read timeout is 200us but it doesn't cover EIP76 RNG
data rate which takes approx. 700us to produce 16 bytes of output data
as per testing results. So configure the timeout as 1000us to also take
account of lack of udelay()'s reliability.

Fixes: 383212425c92 ("hwrng: omap - Add device variant for SafeXcel IP-76 found in Armada 8K")
Cc: <stable@vger.kernel.org>
Signed-off-by: Sumit Garg <sumit.garg@linaro.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
drivers/char/hw_random/omap-rng.c