freebsd-skq/stand
sjg 32ca39b78e veloader use vectx API for kernel and modules
The vectx API, computes the hash for verifying a file as it is read.
This avoids the overhead of reading files twice - once to verify, then
again to load.

For doing an install via loader, avoiding the need to rewind
large files is critical.

This API is only used for modules, kernel and mdimage as these are the
biggest files read by the loader.
The reduction in boot time depends on how expensive the I/O is
on any given platform.  On a fast VM we see 6% improvement.

For install via loader the first file to be verified is likely to be the
kernel, so some of the prep work (finding manifest etc) done by
verify_file() needs to be factored so it can be reused for
vectx_open().

For missing or unrecognized fingerprint entries, we fail
in vectx_open() unless verifying is disabled.

Otherwise fingerprint check happens in vectx_close() and
since this API is only used for files which must be verified
(VE_MUST) we panic if we get an incorrect hash.

Reviewed by:	imp,tsoome
MFC after:	1 week
Sponsored by:	Juniper Networks
Differential Revision:	https://reviews.freebsd.org//D23827
2020-03-09 16:02:54 +00:00
..
arm
arm64
common veloader use vectx API for kernel and modules 2020-03-08 18:48:01 +00:00
defaults
efi veloader use vectx API for kernel and modules 2020-03-08 17:42:42 +00:00
fdt stand/fdt: Scale blob size better as overlays apply 2020-01-09 04:34:42 +00:00
ficl veloader use vectx API for kernel and modules 2020-03-09 16:02:54 +00:00
ficl32
forth loader_4th: menu items need to reset color attribute, not switch to white 2019-09-22 16:10:25 +00:00
i386 veloader use vectx API for kernel and modules 2020-03-09 16:02:54 +00:00
kshim
liblua veloader use vectx API for kernel and modules 2020-03-09 15:48:53 +00:00
liblua32
libofw veloader use vectx API for kernel and modules 2020-03-08 17:42:42 +00:00
libsa loader: replace zfs_alloc/zfs_free with malloc/free 2020-02-26 18:12:12 +00:00
libsa32
lua lua: add modules.loaded hook 2020-01-25 03:52:16 +00:00
man Remove sparc64 support from the boot loader. 2020-02-03 17:34:57 +00:00
mips veloader use vectx API for kernel and modules 2020-03-08 17:42:42 +00:00
powerpc veloader use vectx API for kernel and modules 2020-03-08 17:42:42 +00:00
uboot veloader use vectx API for kernel and modules 2020-03-08 17:42:42 +00:00
usb Fix build of stand/usb . 2020-01-23 10:40:34 +00:00
userboot veloader use vectx API for kernel and modules 2020-03-08 17:42:42 +00:00
defs.mk Move stand/ofw/libofw to stand/libofw. 2020-01-02 04:34:22 +00:00
fdt.mk
ficl.mk
loader.mk veloader use vectx API for kernel and modules 2020-03-08 17:42:42 +00:00
lua.mk
Makefile Move stand/ofw/libofw to stand/libofw. 2020-01-02 04:34:22 +00:00
Makefile.amd64
Makefile.inc
uboot.mk