Commit bbb8ceb5 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'v6.1-p2' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6

Pull crypto fix from Herbert Xu:
 "This fixes an issue exposed by the recent change to feed untrusted
  sources into /dev/random"

* tag 'v6.1-p2' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
  hwrng: bcm2835 - use hwrng_msleep() instead of cpu_relax()
parents 9abf2313 96cb9d05
...@@ -71,7 +71,7 @@ static int bcm2835_rng_read(struct hwrng *rng, void *buf, size_t max, ...@@ -71,7 +71,7 @@ static int bcm2835_rng_read(struct hwrng *rng, void *buf, size_t max,
while ((rng_readl(priv, RNG_STATUS) >> 24) == 0) { while ((rng_readl(priv, RNG_STATUS) >> 24) == 0) {
if (!wait) if (!wait)
return 0; return 0;
cpu_relax(); hwrng_msleep(rng, 1000);
} }
num_words = rng_readl(priv, RNG_STATUS) >> 24; num_words = rng_readl(priv, RNG_STATUS) >> 24;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment