Commit dd7aa36e authored by Jason A. Donenfeld's avatar Jason A. Donenfeld

random: re-add removed comment about get_random_{u32,u64} reseeding

The comment about get_random_{u32,u64}() not invoking reseeding got
added in an unrelated commit, that then was recently reverted by
0313bc27 ("Revert "random: block in /dev/urandom""). So this adds
that little comment snippet back, and improves the wording a bit too.
Reviewed-by: default avatarDominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: default avatarJason A. Donenfeld <Jason@zx2c4.com>
parent d97c68d1
...@@ -224,9 +224,10 @@ static void _warn_unseeded_randomness(const char *func_name, void *caller, void ...@@ -224,9 +224,10 @@ static void _warn_unseeded_randomness(const char *func_name, void *caller, void
* *
* These interfaces will return the requested number of random bytes * These interfaces will return the requested number of random bytes
* into the given buffer or as a return value. This is equivalent to * into the given buffer or as a return value. This is equivalent to
* a read from /dev/urandom. The integer family of functions may be * a read from /dev/urandom. The u32, u64, int, and long family of
* higher performance for one-off random integers, because they do a * functions may be higher performance for one-off random integers,
* bit of buffering. * because they do a bit of buffering and do not invoke reseeding
* until the buffer is emptied.
* *
*********************************************************************/ *********************************************************************/
......
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