path: root/stand/efi/loader/arch/i386
Commit message (Collapse)AuthorAgeFilesLines
* stand/efi: allow not exiting boot servicesRoger Pau Monné2021-02-161-2/+3
| | | | | | | | | | | | | | | | | | Xen requires that UEFI BootServices are enabled in order to boot, so introduce a new parameter to bi_load in order to select whether BS should be exited. No functional change introduced in this patch, as all current users of bi_load request BS to be exited. Further changes will make use of this functionality. Note the memory map is still appended to the kernel metadata, even when it could be modified by further calls to the Boot Services, as it will be used to detect if the kernel has been booted from UEFI. Sponsored by: Citrix Systems R&D Reviewed by: tsoome, imp Differential revision: https://reviews.freebsd.org/D28495
* veloader use vectx API for kernel and modulesSimon J. Gerraty2020-03-081-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 Notes: svn path=/head/; revision=358744
* loader: use teken teminal emulator for x86 and uefiToomas Soome2019-09-051-1/+1
| | | | | | | | | | | Replace mini cons25 emulator with teken, this does enable us proper console terminal for loader and will make it possible to implement different back end callbacks to draw to screen. At this time we still only "draw" in text mode. Notes: svn path=/head/; revision=351900
* EFI: don't call printf after ExitBootServices, since it uses Boot ServicesRebecca Cran2019-03-021-2/+7
| | | | | | | | | | | | | | | ExitBootServices terminates all boot services including console access. Attempting to call printf afterwards can result in a crash, depending on the implementation. Move any printf statements to before we call bi_load, and remove any that depend on calling bi_load first. Reviewed by: imp, tsoome Differential Revision: https://reviews.freebsd.org/D19374 Notes: svn path=/head/; revision=344718
* stand: Remove unused i386 EFI MD bitsKyle Evans2019-02-263-146/+0
| | | | | | | | | | | | | | | | | | r328169 removed the copy of bootinfo that would've made this somewhat functional. However, this is irrelevant- earlier work in r292338 was done to exit boot services in the MI bi_load() rather than having N copies of the GetMemoryMap/ExitBootServices dance. i386 never quite caught up to that; ldr_enter was still being called but the prereq for that, ldr_bootinfo, was no longer. As a consequence, this ExitBootServices() was being called with a mapkey=0, clearly bogus, and reportedly breaking the boot in some instances. Reported by: bcran MFC after: 1 week Notes: svn path=/head/; revision=344560
* Fix casts between 64-bit physical addresses and pointers in EFI.John Baldwin2018-08-181-6/+6
| | | | | | | | | | | | | | | Compiling FreeBSD/i386 with modern GCC triggers warnings for various places that convert 64-bit EFI_ADDRs to pointers and vice versa. - Cast pointers to uintptr_t rather than to uint64_t when assigning to a 64-bit integer. - Cast 64-bit integers to uintptr_t before a cast to a pointer. Reviewed by: kevans MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D16586 Notes: svn path=/head/; revision=338022
* Remove extra copy of bootinfo.c. It's a bit rotted copy of the one inWarner Losh2018-01-191-275/+0
| | | | | | | | | efi/loader. Differential Review: https://reviews.freebsd.org/D13986 Notes: svn path=/head/; revision=328169
* Move sys/boot to stand. Fix all references to new locationWarner Losh2017-11-148-0/+784
Sponsored by: Netflix Notes: svn path=/head/; revision=325834