Merge from CheriBSD:

commit 003649d9622ce252a2794ae5891ee7e7c209caca
Author: Robert N. M. Watson <robert.watson@cl.cam.ac.uk>
Date:   Wed Feb 5 18:32:09 2014 +0000

    Teach the FreeBSD/beri boot to "auto-detect" whether argument 4 (a3) is a
    memory size of pointer to a struct bootinfo * by looking at its value and
    seeing whether it is pointer-like.  If a pointer, assume it's a bootinfo
    and extract memsize from it instead; otherwise, use it as memsize directly.
    This allows kernels to support bootinfo being passed by loader (and boot2)
    while still supporting older Miniboot setups.

commit f7045af9a1e92b6bd92541fe5d25abf66d824e8f
Author: Robert N. M. Watson <robert.watson@cl.cam.ac.uk>
Date:   Thu Feb 6 13:45:34 2014 +0000

    When the module metadata pointer is available from loader, use it in the
    kernel.

commit 52e0e1ff2cba9dfcfab9e1d0a31fb7fdf7317450
Author: Robert N. M. Watson <robert.watson@cl.cam.ac.uk>
Date:   Thu Feb 6 19:57:48 2014 +0000

    In the BERI kernel boot code, extract 'boothowto' (which includes boot flags
    such as '-s') and 'envp' from passed module data.  Booting to single-user
    mode using boot flags now works.

Sponsored by:	DARPA, AFRL