From: Bakul Shah <bakul@bitblocks.com>
To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net>
Subject: Re: [9fans] bcm2835 random number generator
Date: Fri, 28 Mar 2014 14:39:59 -0700 [thread overview]
Message-ID: <20140328213959.64BBFB827@mail.bitblocks.com> (raw)
In-Reply-To: Your message of "Fri, 28 Mar 2014 17:09:43 EDT." <51844d0013c4336e5793156d18a91b3e@ladd.quanstro.net>
On Fri, 28 Mar 2014 17:09:43 EDT erik quanstrom <quanstro@quanstro.net> wrote:
> On Fri Mar 28 13:21:35 EDT 2014, bakul@bitblocks.com wrote:
> > I have put an initial version of raspberryPi hardware RNG
> > driver on sources. Supposedly bcm2835 uses a reverse bias
> > transistor as a noise source (though I couldn't find anything
> > a definitive source for this). FWIW, I ran the output through
> > rngtest (does FIPS 140-2 tests) and the failure rate is about
> > the same as FreeBSD's (about 1 out of 1000). rngtest tests at
> > a minimum 2*10^6 bits and plan9's stock /dev/random seems far
> > too slow so I didn't bother testing it.
> >
> > Just copy /n/sources/contrib/bakul/random.c to sys/src/9/bcm
> > and rebuild 9pi.
> >
> > Arguably this should be a new device, /dev/hrng or something,
> > but plan9's /dev/random code is very simple compared to the
> > elaborate versions on *BSD's. I have kept this one simple too.
> > If you are concerned about the quality of RNG or paranoid
> > about bcm2835's unpublic algorithm, feel free to complexify!
>
> i have not had luck with this. i get data aborts when booting
> from flash, and hangs when rebooting via /dev/reboot.
Sorry about that! I forgot to mention that this facility was
added around Jan 30, 2013. See Dom's message on page 12 on
http://www.raspberrypi.org/phpBB3/viewtopic.php?f=29&t=19334&p=273944#p273944
Make sure you have firmware as least as recent as that. Not
sure if Richard's 9pi image on sources has something more
recent. I will check this evening.
next prev parent reply other threads:[~2014-03-28 21:39 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-28 17:19 Bakul Shah
2014-03-28 21:09 ` erik quanstrom
2014-03-28 21:39 ` Bakul Shah [this message]
2014-03-28 23:51 ` erik quanstrom
2014-03-29 0:11 ` Bakul Shah
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140328213959.64BBFB827@mail.bitblocks.com \
--to=bakul@bitblocks.com \
--cc=9fans@9fans.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).