diff options
author | Michael Shalayeff <mickey@cvs.openbsd.org> | 1997-06-14 21:37:13 +0000 |
---|---|---|
committer | Michael Shalayeff <mickey@cvs.openbsd.org> | 1997-06-14 21:37:13 +0000 |
commit | be9e68b0d9cd84bf7310511b3e146b0895633780 (patch) | |
tree | 1210487499905b6cc8e78ab0d9c917ff6103bf6f /sys/dev/rndvar.h | |
parent | c7a19b401046a531612a627a73ed5aea7310eca9 (diff) |
split the treatment of the random events
event_q by flipk@
spl fix by deraadt@
gother statistics about whole processing
use 'sysctl kern.random' to view what had happened
also fix wrong vm.psstrings description
Diffstat (limited to 'sys/dev/rndvar.h')
-rw-r--r-- | sys/dev/rndvar.h | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/sys/dev/rndvar.h b/sys/dev/rndvar.h index 2a9ffaf87b4..0014dfcffa4 100644 --- a/sys/dev/rndvar.h +++ b/sys/dev/rndvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: rndvar.h,v 1.5 1997/01/05 11:08:59 niklas Exp $ */ +/* $OpenBSD: rndvar.h,v 1.6 1997/06/14 21:37:09 mickey Exp $ */ /* * Copyright (c) 1996 Michael Shalayeff. @@ -46,7 +46,26 @@ #define RND_ARND 4 /* aRC4 based random number generator */ #define RND_NODEV 5 /* First invalid minor device number */ +struct rndstats { + u_long rnd_total; /* total bits of entropy generated */ + u_long rnd_used; /* strong data bits read so far */ + u_long arc4_reads;/* aRC4 data bytes read so far */ + + u_long rnd_timer; /* timer calls */ + u_long rnd_mouse; /* mouse calls */ + u_long rnd_tty; /* tty calls */ + u_long rnd_disk; /* block devices calls */ + u_long rnd_net; /* net calls */ + + u_long rnd_reads; /* strong read calls */ + u_long rnd_waits; /* sleep for data */ + u_long rnd_enqs; /* enqueue calls */ + u_long rnd_deqs; /* dequeue calls */ + u_long rnd_drops; /* queue-full drops */ +}; + #ifdef _KERNEL +extern struct rndstats rndstats; extern void add_mouse_randomness __P((u_int32_t)); extern void add_net_randomness __P((int)); |