hwrng: omap - Fix RNG wait loop timeout
authorSumit Garg <sumit.garg@linaro.org>
Mon, 14 Oct 2019 12:02:45 +0000 (17:32 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 17 Dec 2019 19:34:52 +0000 (20:34 +0100)
commit7c07d0267364194aae9786ec0b3d70a65c83329b
treecb3a67f91de228f84e34c8227a9fb34727599933
parentf785f33c23ad6bad78d82d148c3dd9c3600cd2ae
hwrng: omap - Fix RNG wait loop timeout

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>
drivers/char/hw_random/omap-rng.c