libsysdecode: Use consistent include path
mkioctls should look at the same set of headers as mktables does.
MFC after: 1 week
Fixes: 139d114acc7b ("libsysdecode use MKTABLES_INCLUDEDIR")
Sponsored by: Klara, Inc.
Sponsored by: NetApp, Inc.
Reviewed by: sjg
Differential Revision: https://reviews.freebsd.org/D54106
(cherry picked from commit c51876a107310984ba3a31b088caebcfd86a9844)
cleanvar: Fix startup order
Instead of having FILESYSTEMS require cleanvar, which doesn't really
make semantic sense, say that cleanvar needs to run before FILESYSTEMS.
MFC after: 3 days
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D54118
(cherry picked from commit 6ce227d6274869a95150746d2f2d8c8c5ed9a266)
noshutdown: Fix startup order
This rc script exists solely to create a file, so have it explicitly
require FILESYSTEMS. In its current form, it was as likely as not to
end up running before cleanvar, which would undo its work.
MFC after: 3 days
Fixes: 384d976725a5 ("rc.d: Add precious_machine rc.conf knob to create /var/run/noshutdown")
Reviewed by: kib
Differential Revision: https://reviews.freebsd.org/D54119
(cherry picked from commit e540e8b2c04f03b4210a3bf2f421c05b918d1b51)
nextboot: Reimplement missing -a option
* Reimplement the -a option which was available in the original shell
script and is still documented.
* Print the correct usage string when invoked as nextboot.
* Add the -D option to the manual page synopsis.
MFC after: 1 week
Fixes: fd6d47375a78 ("rescue,nextboot: Install nextboot as a link to reboot, rm nextboot.sh")
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D54120
(cherry picked from commit de670c611b17939712a81dc56f73a3ff84f6c178)
bus: Return 0 if reading an ivar fails
In the non-INVARIANTS case, return 0 rather than stack garbage if
reading an ivar fails (in the INVARIANTS case, we still panic).
MFC after: 1 week
Sponsored by: Klara, Inc.
Sponsored by: NetApp, Inc.
Reviewed by: jhb
Differential Revision: https://reviews.freebsd.org/D54078
(cherry picked from commit 4c2295c15860e70c8bd3f05f9229d2fc40dfd50d)
pfctl: report ICMP states consistently for IPv4/IPv6
Remove the '#ifndef INET6', which never actually mattered because this
define is never set. This makes us report ICMP states for IPv4 and IPv6
the same way (and also aligns us with OpenBSD).
This means we will now always report state 0:0 rather than
NO_TRAFFIC:NO_TRAFFIC for icmp6 (like we already did for icmp).
Reported by: Lev Prokofev <lev at netgate.com>
Sponsored by: Rubicon Communications, LLC ("Netgate")
bhyvectl: fix build without BHYVE_SNAPSHOT
Build fails without BHYVE_SNAPSHOT due to undeclared identifier
'checkpoint_file'. Wrap that with a proper #ifdef.
Reported by: dhw
bhyvectl: improve options error handling
Currently, it is possible to execute bhyvectl(8) with mutually exclusive
options, such as "--destroy" and "--suspend", and it will print out
obscure errors, e.g.:
bhyvectl --suspend=/var/run/vms/my_vm --destroy --vm my_vm
connect() failed: Connection refused
Address that by failing early if mutually exclusive options were
specified.
Additionally, move the BHYVE_SNAPSHOT block before the errors are
printed, so its errors are also displayed.
Approved by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D54092
bhyve: change suspend exit code
Currently, after suspending, bhyve(8) exits with 0. This code is
also used to indicate that a VM was rebooted. To differentiate
reboot and suspend, use the next available exit code, 5, for suspend.
Approved by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D54087
locale: tools: Make finalize idempotent
The finalize script renames source files with 3 components in their name
into names with two components with an @modifier, in the process.
Running the script for a second time without cleaning will strip the
@modifier from the files, producing invalid Makefiles and unusable
locales.
Prevent this by adding a guard at the beginning of the script.
Also, use a sub-shell for directory changes to avoid working directory
issues.
Reviewed by: bapt
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D53981
(cherry picked from commit 934364da7fc8cd3ba4d030d0478163b41dda1b37)
locale: make posix
Run make posix to generate monetary definition files with the
international parameters missing from localeconv(3)'s lconv struct.
Manually convert the "frozen" non-unicode locales under share/monetdef.
Reviewed by: bapt
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D53917
(cherry picked from commit 9df8243a2e0ab1ef027cbfbcb4105f5f0ce108e1)