Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Sep 2017 16:52:01 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 222256] RPI random number generator underruns when BCM2835_RNG_USE_CALLOUT is set
Message-ID:  <bug-222256-8-5iVNqAzy82@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-222256-8@https.bugs.freebsd.org/bugzilla/>
References:  <bug-222256-8@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D222256

--- Comment #2 from Stephen J. Kiernan <stevek@freebsd.org> ---
Interesting. The RPi3 must be a bit different than the RPi2 (where the init=
ial
testing using callout was done.) It might make sense to have a sysctl in the
case where one would want to use the callout version to be able to tweak it=
 as
appropriate.

However, it's better to use the default interrupt method rather than the
callout, because, as you saw, there can be cases where the random bit gener=
ator
(RBG) cannot provide enough bits to satisfy a request, if the callout perio=
d is
too short. With the interrupt method, the RBG is programmed to raise an
interrupt when the FIFO is full. When that occurs, the interrupt handler re=
ads
from the FIFO and feeds the bits read into the random_harvest_queue functio=
n.

However, that requires the FDT for the board to have a proper entry for the=
 RBG
with an interrupt attribute, which I don't think the RPi3 FDT has currently.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-222256-8-5iVNqAzy82>