d51c59002367 moved the MFC hash matching logic into a lua utility
script but left the output formatting in the shell script. Simplify this
slightly by just printing the formatted output from lua.
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D44836
(cherry picked from commit 793745fad866f65863ab3b16a17bdf18dc779efd)
Previously we obtained the list of MFC candidate hashes (i.e., those
commits only in the mfc-from branch), removed the already-merged
commits based on "cherry picked from" commit message entries, and then
printed the list sorted by commit time. This is usually the correct
order, but it is not when commits have non-monotonically-increasing
commit times. This is unfortunately the case for a number of commits in
our tree. This made it difficult to merge some groups of dependent
commits in the correct order.
Instead, leave the from-list in git rev-parse order, and move the
matching logic to a new lua script.
Reviewed by: imp
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D44808
(cherry picked from commit d51c590023675ca20a7da74d75a3b5a5dcfdfddc)
This test fails after tzsetup was changed to symlink rather than copy
the zoneinfo file (5e16809c953f).
(cherry picked from commit f72b4f7e149d82ef5b8ed7a3aa415fcd7603b350)
Using a symlink means that new timezone data (installed by an errata
update, say) will be usable without having to be copied again.
Reviewed by: bapt, kevans, philip
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D37005
(cherry picked from commit 5e16809c953f4cd19fadb1767469dec319de0353)
UTC is Coordinated Universal Time, not Greenwich Mean Time.
Reviewed by: imp, allanjude
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D45573
(cherry picked from commit a16cb8709de7ddc6dd6ab71918af9fc5fd96f377)
Skipping the UTC question via -s will not create or delete
/etc/wall_cmos_clock.
Reported by: Tomoaki AOKI
Reviewed by: imp, allanjude, jrm
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D45576
(cherry picked from commit 70e3e1bde9bf0ddf7fc18b97487fe2d23d4fc5ed)
Following commit a87651e2ff18 add xrefs to intro(2) and sigaction(2),
and use a consistent form.
Suggested by: kib, arrowd
Reviewed by: kib (earlier)
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D45555
(cherry picked from commit 0277c0c6f72a964bf0439db1f4558551052e4f3b)
namei was mistaken for a typo (see GitHub pull request #1284). Add an
xref to make it clear.
Reviewed by: imp
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D45546
(cherry picked from commit a87651e2ff189cec4c26cb220354f1bc93794f31)
PR: 279201
Fixes: 9a49a37929 ("mptutil: document that disabled/enab...")
Sponsored by: The FreeBSD Foundation
(cherry picked from commit b128bedfb95c1fefe10e3375b07e200eff8c3664)
Fixes: 7504e0e3e517 ("splash(4): Document how to use splash screen ...")
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 004d5af853bfef1eb66394a15ac9e94e6dcebc0a)
When the boot loader version is too old, add a warning to the boot menu
to maybe catch people's attention.
Use the correct loader code that adds an inactive highlighted menu item
indicating that an update is needed.
Sponsored by: Netflix
Reviewed by: jhb
Differential Revision: https://reviews.freebsd.org/D45890
(cherry picked from commit 0eac99f76ec31270f902cc2a0ff5ae4b5b606a65)
(cherry picked from commit 7cb65be96d47cbe0b740266bc633d272fc4c5e6b)
If the loader is < 3.0, print a warning that it's too old and needs to
be upgraded.
Sponsored by: Netflix
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D45889
(cherry picked from commit a2fd7ae87991044ca283974ced8f6ed635d1cb0c)
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
(cherry picked from commit 9f7f90507528aaa9a2f54575c1d4f4010d01c2e5)
This reverts commit 552f3072af54820cf1805f712e2567bc1b7f046d.
loader.command_error was added just after 11.2, but appears to not have
been back ported to 11.x. 11.0 was the first lua loader release, so keep
this compat shim until we sort out what to do.
MFC After: 3 days
Sponsored by: Netflix
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D45883
(cherry picked from commit 809edb3636a5494ad7d3dfff910e0aab89d83442)
This reverts commit ab97d42addae97a389c6f22d6bba62ed954bb8e7.
There's too many people in the field with FreeBSD 12.0 loader.efi that
stubbed their toe on upgrading to 14.1 since they'd not updated
loader.efi. While we sort out that mess, add back this workaround. Can
revisit after 14.2 maybe.
MFC After: 3 days
Sponsored by: Netflix
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D45882
(cherry picked from commit 522a65a8d97a0d6b634266f1b4a89aa8f374279c)
This reverts commit 8b9178cd0d35ff2beafebdd51c8c44ba2b5aeb0f.
Really old loader.efi files persist in the field. Revert this to support
it. We need to support this through at least 14.2 now, alas.
MFC After: 3 days
Sponsored by: Netflix
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D45881
(cherry picked from commit b38a82c77ab90eace53c56151b191efd1f4a8439)
This line is no longer needed as fallback, and should have been deleted
in 7870a52598 instead of commented out, but 26 years later, I have a
high degree of confidence that old change was right and we won't need
this line as a fallback.
Sponsored by: Netflix
Reviewed by: kevans, jhb
Differential Revision: https://reviews.freebsd.org/D45880
(cherry picked from commit 65300ca729452f62c201baedcbb4a67f2afc5ed5)
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
(cherry picked from commit 8165650389ba2d0a68cea6902ac3750055cad9da)
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
(cherry picked from commit 195a96f0b303345818e09ad1d79dc80122804de8)
Its base privileged architecture provides these. Read/write is
toggleable via the SUM bit, so use that as its feature name. Execute is
always-on so has no name.
(cherry picked from commit a5ae2d2ab409834c28e71b1dcde4ebcd0d9b3671)
Stack Smashing Protection (SSP) is a software vulnerability mitigation,
and fits with this page. Add a note to the beginning of security.7
providing a more explicit cross reference to mitigations.7.
Reviewed by: kevans
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D45435
(cherry picked from commit 297bb39b6f0fcfc5d571dc77008eb7acf138d279)
A brief description of supervisor mode memory access protection was
added in 72ece341b427. Uncomment the existing reference to this section
in the table of contents.
Fixes: 72ece341b427 ("mitigations.7: mention supervisor mode memory...")
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 166ec3e86aa4a48bdf2a56ee065f0173bbb8f745)
This is required for the kernel to link after commit 13d00a43cba4.
Fixes: 13d00a43cba4 ("conf: Add usbhid and hidbus to GENERIC* kernel configs")
(cherry picked from commit d68d124817780db5f98f65ae02a7ce286cd426eb)
Add the ability to pre-resolve architecture-specific EABI symbols and
use it on arm for selected EABI functions. These functions can be called
with rtld bind lock write-locked, so they should be resolved in forward.
Reported by: Mark Millard <marklmi@yahoo.com>, John F Carr <jfc@mit.edu>
Reviewed by: kib, imp
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D46104
(cherry picked from commit 5670b8cc3672d5a6bc2c41eb48d7d01343c43ad0)
When creating a state for ICMP (v4 or v6) packets we only used the ID, which
means that we could confuse different ICMP types. For example, if we allowed
neighbour discovery but not ICMPv6 echo requests an ND packet could create a
state that the echo request would match.
Test that this is now fixed.
Reported by: Enrico Bassetti <e.bassetti@tudelft.nl>
MFC after: 1 day
Sponsored by: Rubicon Communications, LLC ("Netgate")
(cherry picked from commit b9f0dbc3d006e0b904ee4275d54459f4edd65bb8)
Change PF behavior to allow MLD Listener Report packets to be sent
without needing a previously created state by MLD Listener Query. It
wasn't working because: (1) you might not have a previous MLD Listener
Query and (2) the addresses of the Query and Report don't match.
ok mikeb@, sashan@
MFC after: 1 day
Obtained From: OpenBSD, rzalamena <rzalamena@openbsd.org>, 5c526dbdb0f2
Sponsored by: Rubicon Communications, LLC ("Netgate")
(cherry picked from commit 1afe4da75d1d2acd33b25eea942af28aa41c82c2)
In pf_icmp_mapping() the ICMP and ICMPv6 types shared the same
number space. In fact they are independent and must be handled
separately. Fix traceroute via pf by splitting pf_icmp_mapping()
into IPv4 and IPv6 sections.
ok henning@ mcbride@; tested mcbride@; sure deraadt@
MFC after: 1 day
Obtained From: OpenBSD, bluhm <bluhm@openbsd.org> ef4bccd7509e
Sponsored by: Rubicon Communications, LLC ("Netgate")
(cherry picked from commit 46755f52247bd34a7f013d6844ed0c673ac0defc)
Include
the ICMP type in one port of the state key, using the type to determine which
side should be the id, and which should be the type.
Also:
- Handle ICMP6 messages which are typically sent to multicast addresses but
recieve unicast replies, by doing fallthrough lookups against the correct
multicast address.
- Clear up some mistaken assumptions in the PF code:
- Not all ICMP packets have an icmp_id, so simulate one based on other
data if we can, otherwise set it to 0.
- Don't modify the icmp id field in NAT unless it's echo
- Use the full range of possible id's when NATing icmp6 echoy
ok henning marco
testing matthieu todd
MFC after: 1 day
Obtained From: OpenBSD, mcbride <mcbride@openbsd.org> 70bf7555ef4c
Sponsored by: Rubicon Communications, LLC ("Netgate")
(cherry picked from commit 534ee17e61ee094ec175703bc50e88ff6587703e)
[CalcSpillWeights] Avoid x87 excess precision influencing weight result
Fixes#99396
The result of `VirtRegAuxInfo::weightCalcHelper` can be influenced by
x87 excess precision, which can result in slightly different register
choices when the compiler is hosted on x86_64 or i386. This leads to
different object file output when cross-compiling to i386, or native.
Similar to 7af3432e22b0, we need to add a `volatile` qualifier to the
local `Weight` variable to force it onto the stack, and avoid the excess
precision. Define `stack_float_t` in `MathExtras.h` for this purpose,
and use it.
This is the version of the fix for PR276961 that landed upstream.
PR: 276961
Reported by: cperciva
MFC after: 3 days
(cherry picked from commit 1a4b8325f6e3a45c77188343da504fe04495cc46)
In preparation for applying the fix that landed upstream, this reverts
commit 397c2693fa66508cb5e6b173650a1f3bc6c4dd4f:
Fix llvm register allocator for native/cross build differences
Work around an issue in LLVM's register allocator, which can cause
slightly different i386 object files, when produced by a native or cross
build of clang.
This adds another volatile qualifier to a float variable declaration in
the weightCalcHelper() function, which otherwise produces slightly
different float results on amd64 and i386 hosts. In turn, this can lead
to different (but equivalent) register choices, and thus non-identical
assembly code.
See https://github.com/llvm/llvm-project/issues/99396 for more details.
Note this is a temporary fix, meant to merge in time for 13.4. As soon
as upstream has a permanent solution we will import that.
PR: 276961
Reported by: cperciva
MFC after: 3 days
(cherry picked from commit 52552d7572a6d3d7d3ce0d6862de9a9d203c5d01)
It relies on being able inspect the dmesg buffer to see whether the
kernel logged certain messages. If it's interleaved with tests that
generate large amounts of console output (e.g., GELI tests), then it can
fail spuriously.
MFC after: 2 weeks
(cherry picked from commit ab27e232b14c07317642a2e4c546c9b71bd9c00b)
Some of these tests make use of test disk devices, but then they can't
run in parallel.
MFC after: 2 weeks
(cherry picked from commit dc8357de606aa65fc1c35a43d4a5f1d706164ddb)
The use of an ifdef here most likely carries over from when the dtrace
port only worked on x86 platforms.
MFC after: 2 weeks
Sponsored by: Innovate UK
(cherry picked from commit 7bbcbd43c53b49360969ca82b152fd6d971e9055)
Load a splash screen that vt(4) can use if the "splash" env variable is defined.
For now only png is supported and decoding is done in loader and not in kernel
compared to splash screen support in sc(4).
For using this add:
boot_mute="YES"
splash="/boot/images/freebsd-logo-rev.png"
in loader.conf
Differential Revision: https://reviews.freebsd.org/D45932
Reviewed by: imp, tsoome
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit 00460cc8c5ad02b628e81eec9e493a1df8393d36)
If loader(8) gives use a splash screen to use using the MODINFOMD_SPLASH
type, use it if RB_MUTE is set to "YES".
By design only argb data will be displayed.
Differential Revision: https://reviews.freebsd.org/D45931
Reviewed by: imp, tsoome
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit f6e8b0e85081681100bf9cd74423be02233204bc)
This mod type and structure holds the splash screen data and metadata.
Differential Revision: https://reviews.freebsd.org/D45930
Reviewed by: tsoome
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit 966e53a4e563da36d62edf57c2b0007921fec8dd)
splash: Add sys/types.h
To fix make test-includes
Fixes: 966e53a4e563 ("linker: Add MODINFOMD_SPLASH type")
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit e4fc2fd62a5e4afebfc466868eb3b17f9ba0ad57)
This blit an ARGB image on the dedicated vd.
This also adds vt_fb_bitblt_argb which will works for most of the vt backends
Differential Revision: https://reviews.freebsd.org/D45929
Reviewed by: tsoome
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit b93028d8cd3aafc883b5f0ecec65a8a2a30af7f3)
The alpha wasn't done properly and some white stripes could be seen.
Differential Revision: https://reviews.freebsd.org/D45933
Reviewed by: imp. tsoome
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit 887062c1da4a4c04a2b3987ec9a4e2a5902122d5)
Include the new unified HID stack by default in generic.
This will allow us to migrate to the multi-stack hkbd and hms instead of
relying on the older ukbd and ums which only work with USB.
To test those drivers just add hw.usb.usbhid.enable=1 in loader.conf
Differential Revision: https://reviews.freebsd.org/D45658
Reviewed by: emaste, imp, wulf (all older version)
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit 13d00a43cba4c35fcc9e0ab567baf530126a6348)
conf: hidmap is always needed for hms
So bring it in when hms is in the kernel config
Fixes: 13d00a43cba4 ("conf: Add usbhid and hidbus to GENERIC* kernel configs")
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit 5ed91e788f0b97c9e6c544671ffef71fad7cad27)
conf: powerpc: Add evdev to some kernel configs
Fixes: 13d00a43cba4 ("conf: Add usbhid and hidbus to GENERIC* kernel configs")
Sponsored by: Beckhoff Automation GmbH & Co. KG
(cherry picked from commit 43a62df0b464e60895084c7f9d9eddf70906fda3)
Sponsored by: The FreeBSD Foundation
MFC after: 2 days
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D46165
(cherry picked from commit f0eceecf5ab51a68d713f9a5a7f360964d0a49ce)
- Remove unnecessary CHN_[UN]LOCKs.
- Improve device_printf() messages.
- Remove redundant checks.
- Remove 0 assignments, since the channel is allocated with M_ZERO.
- Re-organize sections in a more coherent way.
- Remove "out1" label, just return NULL directly.
- Rename "out2" to "fail" and simplify logic.
- Do not check the return value of dsp_unit2name(), as it is guaranteed
not to fail (we pass a valid channel type).
Sponsored by: The FreeBSD Foundation
MFC after: 2 days
Reviewed by: dev_submerge.ch
Differential Revision: https://reviews.freebsd.org/D45985
(cherry picked from commit 5b209e153b58515c0315f5902e18ecd7d75ecd2a)
No functional change intended.
Sponsored by: The FreeBSD Foundation
MFC after: 2 days
Reviewed by: dev_submerge.ch, markj
Differential Revision: https://reviews.freebsd.org/D45984
(cherry picked from commit c55f995502cbaa2d38b7a7003bc27805b28a6a29)