Jason A. Donenfeld 68c9c8b192 random: move initialization out of reseeding hot path
Initialization happens once -- by way of credit_init_bits() -- and then
it never happens again. Therefore, it doesn't need to be in
crng_reseed(), which is a hot path that is called multiple times. It
also doesn't make sense to have there, as initialization activity is
better associated with initialization routines.

After the prior commit, crng_reseed() now won't be called by multiple
concurrent callers, which means that we can safely move the
"finialize_init" logic into crng_init_bits() unconditionally.

Reviewed-by: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2022-05-18 15:53:53 +02:00
..
2022-03-29 08:50:14 -07:00
2022-03-23 18:23:13 -07:00
2022-03-28 14:32:39 -07:00
2021-06-04 15:35:03 +02:00
2022-03-22 09:17:20 -07:00
2021-07-27 12:17:21 +02:00