right now. new address-of-packed-member and format-overflow
warnings have new GCC_NO_ADDR_OF_PACKED_MEMBER amd
GCC_NO_FORMAT_OVERFLOW variables to remove these warnings.
apply to a bunch of the tree. mostly, these are real bugs that
should be fixed, but in many cases, only by removing the 'packed'
attribute from some structure that doesn't really need it. (i
looked at many different ones, and while perhaps 60-80% were
already properly aligned, it wasn't clear to me that the uses
were always coming from sane data vs network alignment, so it
doesn't seem safe to remove packed without careful research for
each affect struct.) clang already warned (and was not erroring)
for many of these cases, but gcc picked up dozens more.
- The "EFI_DEVICE_PATH **FilePath" parameter can change, so do not free
the output. This was causing crashes on U-Boot when attempting to load
boot.cfg, even if it didn't exist.
- Allocate the SIMPLE_READ_FILE in advance and store a pointer to it in
struct open_file.
loader command line. Add support for specifying device tree overlays
in boot.cfg, with the syntax:
dtoverlay=/path/to/overlay.dtbo
dtoverlay=hd0e:/overlays/example.dtbo
Multiple overlays can be specified, and they are loaded in the order
they appear in boot.cfg.
Remove support for efiboot.plist.
The EFI environment variable `rndseed' specifies the path to the
random seed. It is loaded only for fdt platforms at the moment.
Since the rndseed (an rndsave_t object as defined in <sys/rndio.h>)
is 536 bytes long (for hysterical raisins), and to avoid having to
erase parts of the fdt tree, we load it into a physical page whose
address is passed in the fdt tree, rather than passing the content of
the file as an fdt node directly; the kernel then reserves the page
from uvm, and maps it into kva to call rnd_seed.
For now, the only kernel that does use efiboot with fdt is evbarm,
which knows to handle the rndseed. Any new kernels that use efiboot
with fdt must do the same; otherwise uvm may hand out the page with
the secret key on it for a normal page allocation in the kernel --
which should be OK if there are no kernel memory disclosure bugs, but
would lead to worse consequences than simply loading the seed late in
userland with /etc/rc.d/random_seed otherwise.
ok jmcneill
This allows you to load a kernel from a build directory deep in some file
system after you accidentally boot an old kernel with a new userland and
are otherwise unable to get yourself back to a matching kernel.
- Add support for pre-loading EFI environment variables from efiboot.plist.
- Add support for device tree overlays specified in efiboot.plist.
(Man page for efiboot forthcoming.)