| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
So this is a gross hack to fix the 'noclean' build since we changed to
text-only loader. We have to fix it in a better way, but for the moment,
this will fix non-meta no-clean builds. A better hack is to fix this so
we build either vidconsole.c or textvidc.c, but some minor refactoring
and variable renaming is needed.
Fixes: 23dee252daf2
Sponsored by: Netflix
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
After talking with a number of people about the removal of some things
to make the loader fit, readjust things a little.
Add back GZIP and BZIP2 compression support. Many of the downstream MFC
packaging systems depend on this. This adds back 20k to the size of the
loader.
Make the boot loader text-only by default. This saves 40k in size. Net,
we're 20k smaller. The graphics loader for BIOS is less useful than the
zip functionality: You can still boot w/a text only one it and you can
build a custom one if you really want it. It's also the default we use
for dual console.
This should be merged back into stable/14 and stable/13 so it's in the
next release for each of these. That way we have only one release (13.4)
with the other defaults.
MFC After: 3 days
Sponsored by: Netflix
Reviewed by: olce, rgrimes, emaste
Differential Revision: https://reviews.freebsd.org/D47203
|
|
|
|
|
|
|
| |
To fit within in the same space, drop the newline before the PXE
prompt to make room for the additional space character.
PR: 281494
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Have a separate PXEBOOTSIZE variable that acts much like LOADERSIZE
variable to limit the size of the loader used for pxeldr. This allows
people to override it independently of LOADERSIZE, which they may need
to set larger for other reasons. Combined with PXEBOOT_DEFAULT_INTERP,
you can build a larger lua loader, while still being able to build pxeldr
with the 4th one, for example.
MFC After: 3 days
Sponsored by: Netflix
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D46214
|
|
|
|
|
|
|
|
|
|
| |
Sometimes you need / want a different boot loader than loader_lua for
pkeldr. Provide an option to get either the 4th one or the simp one.
MFC After: 3 days
Sponsored by: Netflix
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D46213
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Make it possible to disable pxeboot. This loader will fail to build when
it's too large. When /boot/loader needs to be larger like that, this
options will disable a component whose build will fail. It is an explicit
option rather than implicit when things are too large to force the user to
make the explicit tradeoffs rather than wonder why they have a stale pxeboot
or other odd failure mode.
MFC After: 3 days
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D46212
|
|
|
|
|
|
| |
Reword slightly to cleanup awkward constructs.
Sponsored by: Netflix
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The largest loader that works for PXE boot is about 500k. PXE needs low
memory for packets and other driver state, so the largest safe size for
the loader is about 500k. Reduce the size from 560k to 500k so we don't
accidentally break PXE in the future.
Add a comment for people with special needs. If you control the
hardware, it can be safe to have boot loaders as large as 580k or 600k
in some cases. Since the BIOS loader is becoming more and more of a
legacy item, the build variable LOADERSIZE isn't documented. This change
doesn't change that: there's been little demand for this documentation
and in general, users shouldn't change it lightly.
PR: 257018
Sponsored by: Netflix
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Each incompatible change we make, we bump the major version. We've not
done the bump in a while, so sync everybody to 3.0. Anything older than
3.0 will be given a warning that their boot loader is too old. We check
only the major version, though, so minor versions can still be bumped
for individual loaders (though I honestly doubt we'll ever need to do
that again).
Sponsored by: Netflix
Reviewed by: jhb
Differential Revision: https://reviews.freebsd.org/D45888
|
|
|
|
|
|
|
|
|
|
| |
We long ago changed newvers.sh to make these comments bogus. Remove
them since every single one of them is broken after the $FreeBSD$
removal.
Sponsored by: Netflix
Reviewed by: kevans, jhb
Differential Revision: https://reviews.freebsd.org/D45879
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This saves space to allow pxeboot to work again. Users desiring these
features can turn them on for their custom build. While these are useful
for some specialized applications, they aren't needed to boot the
typical system, and we're low on space.
text data bss dec hex filename
Before: 465866 20740 31612 518218 0x7e84a loader_lua.bin
After: 441535 17484 31092 490111 0x77a7f loader_lua.bin
Savings: 28,107 bytes
Sponsored by: Netflix
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D42416
|
|
|
|
|
|
|
| |
This is a residual of the $FreeBSD$ removal.
MFC After: 3 days (though I'll just run the command on the branches)
Sponsored by: Netflix
|
|
|
|
|
|
|
| |
Since this is now 'new code' go ahead and reindent for modern project
preferences.
Sponsored by: Netflix
|
|
|
|
| |
Sponsored by: Netflix
|
|
|
|
|
|
| |
c_init returns 0 (success) or 1 (failure). Don't return other values.
Sponsored by: Netflix
|
|
|
|
| |
Sponsored by: Netflix
|
|
|
|
| |
Sponsored by: Netflix
|
|
|
|
| |
Sponsored by: Netflix
|
|
|
|
|
|
|
|
| |
fdisk is obsolete and there is no need to mention a specific tool used
to update the partition table. Just refer to it as the MBR partition
table.
Sponsored by: The FreeBSD Foundation
|
|
|
|
| |
Sponsored by: Netflix
|
|
|
|
|
|
|
|
|
| |
The project is moving away from CTASSERT in favor of
_Static_assert. Cleanup the few instances in the loader proactively.
Sponsored by: Netflix
Reviewed by: manu, tsoome
Differential Revision: https://reviews.freebsd.org/D44006
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Select between text-only and graphical frame buffer consoles for the
BIOS boot loader. Pull one or the other in with #ifdef in conf.c. Add
gfx_bios.c for the few routines that are needed for the BIOS support of
gfx. These are stubbed out for text-only mode. Move bi_load_vbe_data
here since it's only used for the graphical frame buffer.
Note: This setup also allows us to build multiple BIOS loaders if we
have to, some with text-only and some graphical. We don't do this today.
We may be forced to turn this on in the future if ZFS keeps growing.
The size savings is 41k, which helps a lot with some of our users that
want to enable more options in the BIOS boot loader than are normally
safe to do, and they don't need graphics.
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D43917
|
|
|
|
|
|
|
| |
Add textvidc to the build. And use -DTERM_EMU to build it.
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D43915
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Bring back vidconsole.c as textvidc.c from 2a0e2c88db20. This console
does no graphics stuff at all, supports no fancy logos, has known bugs
in the terminal emulation, etc. However, it is small. It will be a
build-time option to select between the two. The BIOS loader is running
out of space when too many options are selected, so this allows people
to select the smaller one to spend the space elsewhere. This is only the
verbatim copy of the old vidconsole.c. It's not yet connected to the
build.
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D43911
|
|
|
|
|
|
|
| |
Further experience suggests we do not need as much margin. This was
mistakenly bumped to 570,000 in a prior commit, so this undoes that.
Sponsored by: Netflix
|
|
|
|
|
| |
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D43913
|
|
|
|
|
|
|
|
|
|
|
| |
Confine -DDISK_DEBUG to biosdisc.c, the only file it affects.
Use modern variable arrays instead of alloca and add a sanity
size minimum for biospnp nodes. These nodes are tiny enough that
we needn't do a malloc/free pair: the stack is fine.
Sponsored by: Netflix
Reviewed by: tsoome
Differential Revision: https://reviews.freebsd.org/D43914
|
|
|
|
|
|
|
|
| |
Create a small wrapper around the new flua hash module so we can use it
here too. There's no 4th bindings, nor will they be created.
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D43874
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It's currently unused outside of vidconsole.c. Gerald Hicks' fix to the
beep code from de37e4a6d2333/1998 introduced the funciton as
static. Maxim Sobolev (sobomax) made it non-static since his spinconsole
called it in c4c3b35172d67/2009. When sobomax dropped the direct call
after making spinconsole console independent in b35172d67/2017,
vidc_biosputchar remained a harmless unreferenced global. Make it static
once again.
Fixes: c7e10205ae0d
Sponsored by: Netflix
|
|
|
|
|
|
| |
MFC after: 1 week
Reviewed by: manu, kevans, imp
Differential Revision: https://reviews.freebsd.org/D43391
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
While we're here, enable the feature in the places we detect ACPI. This
lets us side-step the existing issues and provide a path forward for
folks upgrading from previous releases that haven't updated their ESP
yet.
Let's also fix core.setACPI: the hint already indicates that the
user's disabled it more consistently than loader.acpi_disabled_by_user.
Even more, the latter is wrong because we set it by default if we did
not detect ACPI. The ACPI hint remains even when we're setting defaults
because ACPI loaded into the kernel will make some noise if it's not
hinted off, even when we didn't detect it.
imp notes that this will result in some relatively harmless noise on
platforms that don't support ACPI but aren't using the UEFI loader, as
we would enable the ACPI module for loading on them and then loader
would not be able to find it. These are non-fatal, but should probably
be fixed by just declaring support for EARLY_ACPI in those loaders since
we know they won't have ACPI early on -- punting on this for the time
being, though, in favor of providing a safer upgrade path sooner.
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D42727
|
|
|
|
|
|
|
|
|
|
|
|
| |
It would be nice to have larger boot partitions for ESPs to live in one
day. It's trivial to carve out 5M 10M or 200M when provisioning, but
logistical issues may make it hard to do it after the fact. So only warn
when the partition is > 545k. If we ever grow the boot loader larger
than that, then it will be responsible for loading the rest anyway.
Sponsored by: Netflix
Reviewed by: tsoome
Differential Revision: https://reviews.freebsd.org/D42774
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Apply the following automated changes to try to eliminate
no-longer-needed sys/cdefs.h includes as well as now-empty
blank lines in a row.
Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/
Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/
Remove /\n+#if.*\n#endif.*\n+/
Remove /^#if.*\n#endif.*\n/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/
Sponsored by: Netflix
|
|
|
|
|
|
|
|
| |
Update dependencies for the loader variations used for each
architecture.
Reviewed by: sjg
Differential Revision: https://reviews.freebsd.org/D39741
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
9600 was a standard baud rate decades ago, but 115200 is now more common
so choose defaults that are useful to the largest number of users.
Note that boot0sio does not support rates above 9600 so it remains
unchanged.
Reviewed by: bz, imp, manu
Relnotes: Yes
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D36295
|
|
|
|
| |
Remove /^\\[\s*]*\$FreeBSD\$.*$\n/
|
|
|
|
| |
Remove /^\s*\$FreeBSD\$$\n/
|
|
|
|
| |
Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/
|
|
|
|
| |
Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
|
|
|
|
| |
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
|
|
|
| |
Remove /^/[*/]\s*\$FreeBSD\$.*\n/
|
|
|
|
| |
Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/
|
|
|
|
| |
Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
|
|
|
|
|
|
|
|
|
| |
We plan to increase the default serial rate to 115200 (see review
D36295) but early boot components that use BIOS interfaces do not
support higher rates. Add a note to that effect.
Reported by: imp
Sponsored by: The FreeBSD Foundation
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix the 'renaming kludge' that we absolutely cannot do going forward
(it's cost us days of engineering time).
console=comconsole talks to the hardware directly. This is available
only on amd64. It is not available anywhere else (and so requires
changes for people doing comconsole on aarch64)
console=eficom talks to the console via EFI protocols. It's available
on amd64, aarch64 and riscv64. It's the first port that we find, though
it can be overriden by efi_com_port (which should be set to the UID of
the serial port, not the I/O port, despite the name). devinfo -v
will give the UID to uartX mapping.
This is an incompatible change for HYPER-V on amd64. It only works with
eficom console, so you'll need to change your configuration in
loader.conf. No compatibility hack will ever be provided for this (since
it requires renamig, which the loader cannot reliably do).
It's also an incompatible change for aarch64. comconsole will need to
change to eficom. There might be a comconsole "shim" for this.
All the interlock to keep only eficom and comconsole from both attaching
have been removed.
RelNotes: Yes
Sponsored by: Netflix
Discussed with: kevans
Differential Revision: https://reviews.freebsd.org/D39982
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Every file should be installed exactly once by `make installworld`.
This is especially important for pkgbase.
Loader help files were being installed by each loader variant (e.g.,
the simp, lua, and 4th EFI loaders). Add a (slightly hacky) mechanism
to skip installing help files for all but one variant.
PR: 271178
Reviewed by: imp
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D40021
|
|
|
|
|
|
|
|
| |
SEGDESC_t needs to be PACKED
there is no status in t_PXENV_UNDI_MCAST_ADDRESS
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D39799
|
| |
|
|
|
|
|
|
|
|
| |
This shouldn't be an option (and I added it in the first place back in
4ae4202e705cf6a12aa3cbb49efb153879a6bc2f and
83f4b92050cbf8913d5c0aac16726c783d8b2d9c). However, unlike the other
knobs I added back then, this really shouldn't be a knob since it is
hardcoded in the source.
|
|
|
|
|
|
| |
This really shouldn't even be an option given it is hardcoded as a
constant named ORIGIN in the assembly. mbr.S also uses 0x600 and
hardcodes it in both the assembly and the Makefile.
|