Lines Matching defs:cprng_fast
1 /* $NetBSD: cprng_fast.c,v 1.20 2024/10/15 17:34:06 riastradh Exp $ */
33 __KERNEL_RCSID(0, "$NetBSD: cprng_fast.c,v 1.20 2024/10/15 17:34:06 riastradh Exp $");
51 struct cprng_fast {
62 static void cprng_fast_schedule_reseed(struct cprng_fast *);
65 static void cprng_fast_seed(struct cprng_fast *, const void *);
66 static void cprng_fast_buf(struct cprng_fast *, void *, unsigned);
78 cprng_fast_percpu = percpu_create(sizeof(struct cprng_fast),
87 struct cprng_fast *const cprng = p;
98 ci->ci_cpuname, "cprng_fast reseed");
103 cprng_fast_get(struct cprng_fast **cprngp)
105 struct cprng_fast *cprng;
118 cprng_fast_put(struct cprng_fast *cprng, int s)
128 cprng_fast_schedule_reseed(struct cprng_fast *cprng __unused)
138 struct cprng_fast *cprng;
159 cprng_fast_seed(struct cprng_fast *cprng, const void *seed)
169 cprng_fast_buf(struct cprng_fast *cprng, void *buf, unsigned len)
198 struct cprng_fast *cprng;
214 CTASSERT(sizeof(seed) <= sizeof(((struct cprng_fast *)0)->buf));
248 cprng_fast(void *buf, size_t len)
256 if (len <= sizeof(((struct cprng_fast *)0)->buf))