freebsd-dev/stand
Ian Lepore df108aafe9 Eliminate duplicated code and struct member definitions in the handoff
of args data between gptboot/zfsboot and loader(8).

Despite what seems like a lot of changes here, there are no actual
changes in behavior, or in the data layout in the structures involved.
This is just eliminating identical code pasted into multiple locations.

In detail, the changes are...

- Move struct zfs_boot_args definition from libsa/zfs/libzfs.h to
  i386/common/bootargs.h because it is specific to x86 booting and the
  handoff between zfsboot and loader, and has no relation to the zfs
  library code in general.

- The geli_boot_args and zfs_boot_args structs both contain an identical
  set of member variables containing geli information.  Extract this out
  to a new geli_boot_data struct, and embed it in the arg-passing structs.

- Provide new routines geli_import_boot_data() and geli_export_boot_data()
  that can be shared between gptboot, zfsboot, and loader instead of
  pasting identical code into several different .c files.

- Remove some checks for a NULL pointer that can never be true because the
  pointer being tested was set using pointer math (kargs + 1) and that can
  never result in NULL in this code.
2018-12-03 03:58:30 +00:00
..
arm Go back to one loader.conf 2018-02-26 03:16:47 +00:00
arm64 No need to make objects here. 2018-04-27 22:15:18 +00:00
common When handling CMD_CRIT error set command_errmsg to NULL after we dump it out, 2018-11-30 02:14:41 +00:00
defaults Enable lualoader's kernel autodetection, disabled on install media 2018-10-11 17:17:54 +00:00
efi loader.efi: fix EFI getchar() for multiple consoles 2018-11-30 08:42:14 +00:00
fdt stand: fdt: Drop some write-only assignments/variables and leaked bits 2018-08-23 18:01:34 +00:00
ficl Prefer uintXX_t to u_intXX_t 2018-03-13 16:33:00 +00:00
ficl32
forth Restore the ability to prevent the user from interrupting the boot process 2018-10-21 00:15:51 +00:00
i386 Eliminate duplicated code and struct member definitions in the handoff 2018-12-03 03:58:30 +00:00
kshim A more definitions to kernel emulation shim in order to build stand/usb. 2018-02-07 18:50:36 +00:00
liblua Move LUA_ROOT to /boot/lua 2018-10-28 02:57:50 +00:00
liblua32 Add Lua as a scripting langauge to /boot/loader 2018-02-12 15:31:53 +00:00
libsa Eliminate duplicated code and struct member definitions in the handoff 2018-12-03 03:58:30 +00:00
libsa32
lua lualoader: Add chainload menu entry 2018-11-05 16:20:07 +00:00
man Improve formatting. 2018-08-15 11:39:13 +00:00
mips Don't use CCACHE for linking. 2018-06-27 19:29:15 +00:00
ofw Stop using ../zfs/libzfs.h but instead use libzfs.h. 2018-07-08 07:42:58 +00:00
powerpc bootprog_info is generated in vers.c. Move it's definition to 2018-06-14 06:41:33 +00:00
sparc64 Increase the size of the heap size available on sparc64 during 2018-08-22 14:33:57 +00:00
uboot ubldr: Force 'usefdt' variable to 1 for powerpc 2018-12-02 02:20:35 +00:00
usb Move the stand/usb test loader into its own directory. 2018-02-07 19:20:59 +00:00
userboot userboot: handle guest interpreter mismatches more intelligently 2018-09-01 02:23:45 +00:00
defs.mk powerpcspe: Don't crash the loader on ubldr with SPE instructions. 2018-11-28 01:47:01 +00:00
fdt.mk
ficl.mk Remove redundant defs.mk includes. They aren't needed. 2018-06-14 06:14:48 +00:00
loader.mk Create a loader for each interpreter for x86 BIOS and all EFI 2018-08-14 18:44:41 +00:00
lua.mk Do not include float interfaces when using libsa. 2018-02-23 04:04:25 +00:00
Makefile Move ZFS files into libsa 2018-07-08 07:42:49 +00:00
Makefile.amd64 Create LOADER_UBOOT, and LOADER_OFW. Move these options out of 2018-03-01 19:50:55 +00:00
Makefile.inc Minor flags cleanup 2017-12-02 00:06:58 +00:00
uboot.mk Unify metadata load files for arm, mips, powerpc, sparc64 2018-02-13 03:44:50 +00:00