svn commit: r256377 - in head: etc/defaults etc/rc.d share/examples/kld/random_adaptor share/man/man4 sys/boot/forth sys/conf sys/dev/glxsb sys/dev/hifn sys/dev/random sys/dev/rndtest sys/dev/safe ...

Konstantin Belousov kostikbel at gmail.com
Sun Oct 13 15:14:13 UTC 2013


On Sun, Oct 13, 2013 at 10:50:17AM +0100, Mark R V Murray wrote:
> 
> On 13 Oct 2013, at 08:48, Konstantin Belousov <kostikbel at gmail.com> wrote:
> 
> > On Sat, Oct 12, 2013 at 12:57:57PM +0000, Mark Murray wrote:
> >> Author: markm
> >> Date: Sat Oct 12 12:57:57 2013
> >> New Revision: 256377
> >> URL: http://svnweb.freebsd.org/changeset/base/256377
> >> 
> >> Log:
> >>  Merge from project branch. Uninteresting commits are trimmed.
> >> 
> >>  Refactor of /dev/random device. Main points include:
> > 
> > The random.ko is broken.  On boot, I get
> > link_elf_obj: symbol live_entropy_source_deregister undefined
> > KLD file random.ko - could not finalize loading
> > 
> > There are several files from dev/random which are listed as
> > 'optional random' in conf/files but are not added to the SRCS in
> > modules/random/Makefile. I do not know the intent of splitting the
> > dev/random into the module and non-optional part of the kernel, so
> > cannot provide the patch.
> > 
> > Please fix.
> 
> Here's the fix:
> 
> Index: sys/modules/random/Makefile
> ===================================================================
> --- sys/modules/random/Makefile	(revision 256427)
> +++ sys/modules/random/Makefile	(working copy)
> @@ -10,7 +10,8 @@
>  SRCS+=	nehemiah.c
>  SRCS+=	ivy.c
>  .endif
> -SRCS+=	randomdev_soft.c yarrow.c hash.c
> +SRCS+=	randomdev_soft.c random_harvestq.c live_entropy_sources.c
> +SRCS+=	yarrow.c hash.c rwfile.c
>  SRCS+=	rijndael-alg-fst.c rijndael-api-fst.c sha2.c
>  SRCS+=	bus_if.h device_if.h vnode_if.h opt_cpu.h opt_random.h
> 

Surely this works, thank you. The rwfile.c content probably should be
taken under the #ifdef RANDOM_RWFILE.

But I do not see much use for the randomdev_read_file() and
randomdev_write_file() functions. It would be better to directly code
the VFS calls in the random_harvestq_cache(). For one thing, it would
eliminate unneccessary close and open of the entropy file.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 834 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/svn-src-head/attachments/20131013/a374c1ef/attachment.sig>


More information about the svn-src-head mailing list