View Single Post
  #9   (View Single Post)  
Old 25th May 2008
reuteler reuteler is offline
New User
 
Join Date: May 2008
Posts: 7
Default

well, this blurb in /usr/src/sys/arch/i386/i386/via.c before viac3_rnd is interesting

511 /*
512 * Note, the VIA C3 Nehemiah provides 4 internal 8-byte buffers, which
513 * store random data, and can be accessed a lot quicker than waiting
514 * for new data to be generated. As we are using every 8th bit only
515 * due to whitening. Since the RNG generates in excess of 21KB/s at
516 * its worst, collecting 64 bytes worth of entropy should not affect
517 * things significantly.
518 *
519 * Note, due to some weirdness in the RNG, we need at least 7 bytes
520 * extra on the end of our buffer. Also, there is an outside chance
521 * that the VIA RNG can "wedge", as the generated bit-rate is variable.
522 * We could do all sorts of startup testing and things, but
523 * frankly, I don't really see the point. If the RNG wedges, then the
524 * chances of you having a defective CPU are very high. Let it wedge.
525 *
526 * Adding to the whole confusion, in order to access the RNG, we need
527 * to have FXSR support enabled, and the correct FPU enable bits must
528 * be there to enable the FPU in kernel. It would be nice if all this
529 * mumbo-jumbo was not needed in order to use the RNG. Oh well, life
530 * does go on...
531 */
Reply With Quote