hwrng: Make explicit that max >= 32 always

As hw_random core calls ->read with max > 32 or more, make it explicit.
Also remove checks involving 'max' being less than 8.

Signed-off-by: PrasannaKumar Muralidharan <prasannatsmkumar@gmail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
PrasannaKumar Muralidharan
2016-11-18 23:00:10 +05:30
committed by Herbert Xu
parent 8ff4c191d1
commit ed424bb368
4 changed files with 3 additions and 12 deletions

View File

@@ -30,8 +30,7 @@
* Must not be NULL. *OBSOLETE*
* @read: New API. drivers can fill up to max bytes of data
* into the buffer. The buffer is aligned for any type
* and max is guaranteed to be >= to that alignment
* (either 4 or 8 depending on architecture).
* and max is a multiple of 4 and >= 32 bytes.
* @priv: Private data, for use by the RNG driver.
* @quality: Estimation of true entropy in RNG's bitstream
* (per mill).