Lines Matching refs:rng

118 fxrng_rng_genrandom_internal(struct fxrng_basic_rng *rng, void *buf,  in fxrng_rng_genrandom_internal()  argument
125 FXRNG_RNG_ASSERT(rng); in fxrng_rng_genrandom_internal()
128 fxrng_rng_keystream_internal(&rng->rng_prf, newkey, sizeof(newkey)); in fxrng_rng_genrandom_internal()
131 memcpy(&ctx_copy, &rng->rng_prf, sizeof(ctx_copy)); in fxrng_rng_genrandom_internal()
139 fxrng_chacha_nonce_add64(&rng->rng_prf, blockcount); in fxrng_rng_genrandom_internal()
142 chacha_keysetup(&rng->rng_prf, newkey, sizeof(newkey) * 8); in fxrng_rng_genrandom_internal()
145 FXRNG_RNG_UNLOCK(rng); in fxrng_rng_genrandom_internal()
147 p_ctx = &rng->rng_prf; in fxrng_rng_genrandom_internal()
154 FXRNG_RNG_ASSERT_NOT(rng); in fxrng_rng_genrandom_internal()
157 chacha_keysetup(&rng->rng_prf, newkey, sizeof(newkey) * 8); in fxrng_rng_genrandom_internal()
159 FXRNG_RNG_ASSERT(rng); in fxrng_rng_genrandom_internal()
169 fxrng_rng_reseed_internal(struct fxrng_basic_rng *rng, bool seeded, in fxrng_rng_reseed_internal() argument
181 FXRNG_RNG_ASSERT(rng); in fxrng_rng_reseed_internal()
185 fxrng_rng_keystream_internal(&rng->rng_prf, u.root_state, in fxrng_rng_reseed_internal()
212 chacha_keysetup(&rng->rng_prf, u.hash_out, FX_CHACHA20_KEYSIZE * 8); in fxrng_rng_reseed_internal()
217 FXRNG_RNG_ASSERT(rng); in fxrng_rng_reseed_internal()
227 fxrng_rng_src_reseed(struct fxrng_basic_rng *rng, in fxrng_rng_src_reseed() argument
230 fxrng_rng_reseed_internal(rng, true, &event->he_somecounter, in fxrng_rng_src_reseed()
242 fxrng_rng_reseed(struct fxrng_basic_rng *rng, bool seeded, const void *entr, in fxrng_rng_reseed() argument
245 fxrng_rng_reseed_internal(rng, seeded, entr, sz, NULL); in fxrng_rng_reseed()