Make arc4random() depend on less subsystems by decoupling extract_entropy()
authorclaudio <claudio@openbsd.org>
Fri, 14 Jun 2024 10:17:05 +0000 (10:17 +0000)
committerclaudio <claudio@openbsd.org>
Fri, 14 Jun 2024 10:17:05 +0000 (10:17 +0000)
commita7abde85e532ee6411eb327a603de94cfab9f6ec
tree880b365483108e19fed0005eeca8a28153a42a38
parentdfc54264df1e287f7ea83d7741905efb8de33c5f
Make arc4random() depend on less subsystems by decoupling extract_entropy()
from the enqueue_randomness() logic.

Add add_event_data() which just enqueues some data into the event buffer
which can be used by extract_entropy(). On top of this remove the
timeout_del() call in dequeue_randomness() it does serve any meaningful
reason.
OK kettenis@ deraadt@ mpi@
sys/dev/rnd.c