XZ kernel build cleanup
-I${SRCTOP}/sys/contrib/xz-embedded/linux/lib/xz isn't used, and
.PATH: ${SRCTOP}/sys/contrib/xz-embedded/freebsd isn't used either.
Remove them both to simplify things a little.
Sponsored by: Netflix
kldxref: Add -m filag to print info about modules in one file
kldxref -m <file> will print the same data that the '-d' flag produces,
except restrict the output to one file. This should be the full path to
the file, and the directory name to process is omitted.
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D57902
loader: Add two new build knobs for x86 BIOS loaders
We have two sets of BIOS loaders: One that lives in stand/i386 and one
that lives in stand/userboot. Add knows to turn these on/off, with the
default being on. These often aren't needed when creating a minimal UEFI
system, so add knobs to turn them off. Given light-weight VMs have
created a new use cases for these loaders, there's no plans at all to
eliminate them.
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D58072
Revert "loader.efi: Trim ZFS searching for other booting options"
This reverts commit 3e3fd1fde8e168910edc538966111c0b5f03cd5f.
This appears to break chainbooting with boot1.efi and similar scenarios
with Root-on-ZFS scenarios. Revert until it's better understood.
PR: 296309
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D58071
loader.efi: Fix off by one error in size of the virtual disk
The end address is the final byte in the array, not one byte past the
end of the array, so we need to add 1 to get the full length.
Fixes: 59219fc76a4b ("loader.efi: efiblk_memdisk_preload passes the VirtualDisks to FreeBSD")
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D58069
laoder.efi: Fix error in download protcol
The download protocol calls download_data with FileOffset and
BufferLength of 0 first to start the download (no data yet
available). Calls it again with BufferLength == 0 and FileOffset the
size of the download (again, no data). It then starts calling with
BufferLength != 0 and FileOffset == 0 to start the download. The
heuristic I used to detect the start was wrong, so we'd allocate the
buffer twice. Fix that by being more explicit and not using the
heuristic that was bogus.
Fixes: afee781523e4 ("loader.efi: Recognize new memdisk=<url> and memcd=<url> options")
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D58068
loader.efi: Simplify the code for null decompression a little
This code is simpler when we spell it the Unix way. Also, add sanity
checks to make sure the offset is where we think it is.
Fixes: afee781523e4 ("loader.efi: Recognize new memdisk=<url> and memcd=<url> options")
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D58070
MINIMAL: Add device md
This can't be a loadable module, so add it to MINIMAL
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D58067
libcxxrt: Fix diagnostics for derived classes
In terminate_with_diagnostics the cast_to arguments were swapped, so it
always failed. The diagnostic handler produced output like "Terminating
due to uncaught exception 0x24891e08000 of type std::runtime_error".
Now, e->what() will actually be included in the output, e.g.
"Terminating due to uncaught exception 0x2bba49208000 'Model file
doesn't exist' of type std::runtime_error".
Reviewed by: dim
Event: Halifax Hackathon 202606
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D57822
(cherry picked from commit 3a5c2899fc7bd0865b5aacccc3465e46e9bc6df3)
(cherry picked from commit ab1af7bd2f425147e658a32f128a56176b1de059)
vtfontcvt: Return error from write_fnt_source
Previously write_fnt_source always returned 0, silently discarding
errors. Return rv so that errors set vtfontcvt's shell exit
appropriately.
Sponsored by: The FreeBSD Foundation
(cherry picked from commit f05fb5157ba1291ee5019bacece8d1e98ea95b35)
(cherry picked from commit a00f80731213e03bf3d0b9028a93d0be4c0df756)
libcxxrt: Fix diagnostics for derived classes
In terminate_with_diagnostics the cast_to arguments were swapped, so it
always failed. The diagnostic handler produced output like "Terminating
due to uncaught exception 0x24891e08000 of type std::runtime_error".
Now, e->what() will actually be included in the output, e.g.
"Terminating due to uncaught exception 0x2bba49208000 'Model file
doesn't exist' of type std::runtime_error".
Reviewed by: dim
Event: Halifax Hackathon 202606
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D57822
(cherry picked from commit 3a5c2899fc7bd0865b5aacccc3465e46e9bc6df3)