ure: improve receive checksum offloading
Let the receive checksum offload for TCP/IPv6 and UDP/IPv6 be
controlled by ifconfig rxcsum6 and not by ifconfig rxcsum.
While there, make the code more compact and improve stlye.9
conformity.
Reviewed by: Timo Völker
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D55188
vtgpu: Support virtio gpu on Parallels Desktop
The Parallels Desktop Virtio GPU implementation doesn't handle
enqueuing the VIRTIO_GPU_CMD_RESOURCE_ATTACH_BACKING request and
memory list together.
Work around this by splitting them before sending them to be enqueued.
Sponsored by: Arm Ltd
Differential Revision: https://reviews.freebsd.org/D55147
kernel dump: dumpsys_gen_pa_next(): Fix "no more chunks" condition detection
In the (improbable) cases where either:
- All entries in dump_map[] are used, so there is no guard entry filled with zeros.
- Some dump region has size 0.
We would respectively access dump_map[] out-of-bounds or omit further
dump regions when iterating.
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
arm64: Add MOPS implementation of pagezero()
Reimplement pagezero() as ifunc. As pagezero() is only used in pmap.c,
move ifunc to that file.
Reviewed by: andrew
Sponsored by: Arm Ltd
Differential Revision: https://reviews.freebsd.org/D54946
arm64: Add MOPS implementations of memset(), memcpy() and memmove()
Enable the use of MOPS implementations of memset, memcpy and memmove within
the kernel. Fix pre-ifunc resolution uses of these functions.
Reported by: andrew
Sponsored by: Arm Ltd
Differential Revision: https://reviews.freebsd.org/D55051
arm64: Enable MOPS usage in the kernel
Support handling kernel-side MOE exceptions.
Reported by: andrew
Sponsored by: Arm Ltd
Differential Revision: https://reviews.freebsd.org/D54943
diff: Correctly declare tests
Sponsored by: Klara, Inc.
Fixes: 5fc739eb5949 ("diff: Fix integer overflows in Stone algorithm")
Fixes: 270492602b9b ("diff: Add test case for pagination resource leak")
Fixes: 590126789c84 ("diff: Don't compare a file or directory to itself")
(cherry picked from commit 157d6664aeb815db3b758bd3038fd1512a0f4e2c)
diff: Don't compare a file or directory to itself
While here, stop abusing struct dirent for something we don't even need
to store.
PR: 254455
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: thj, kevans
Differential Revision: https://reviews.freebsd.org/D55113
(cherry picked from commit 590126789c841d80655869bc075c8980c173dd1c)
diff: Fix build
rc must be defined first.
Fixes: 590126789c84
MFC after: 1 week
[3 lines not shown]
diff: Fix pagination leak
* Drop an unnecessary variable and rename pidfd to procd.
* Rewinding stdout serves no purpose, so stop doing it.
* Don't bother freeing memory or setting the global status right
before erroring out.
* Error out if dup(2) or dup2(2) fail.
* In the unlikely case that our pipe is equal to stdout, we need to
record that information so we don't close it when cleaning up.
* Don't bother closing a descriptor before dup2(2)ing to it.
* Don't forget to close the the process descriptor after reaping the
child process.
[7 lines not shown]
diff: Add test case for pagination resource leak
The pagination code leaks either processes or descriptors or both,
depending on the exact version of the code you have. Add a test case
which exercises this leak to facilitate fixing it.
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: thj, kevans
Differential Revision: https://reviews.freebsd.org/D55111
(cherry picked from commit 270492602b9bd8b8fce4f021f055804978bf3f23)
ath10k: update Atheros/QCA's ath10k driver
This version is based on
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
05f7e89ab9731565d8a62e3b5d1ec206485eeb0b ( tag: v6.19 ).
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
asan: Use memset_early() to fill shadow memory
__builtin_memset() calls are replaced with calls to memset(), but that
can't be used before ifunc relocations are processed if the
implementation is selected at boot time. Meanwhile, the sanitizer may
emit calls to __asan_set_shadow_*() as soon as locore jumps into C code,
before ifuncs are selected.
Just unconditionally use memset_early() to work around this.
Reported by: andrew
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D55079
iwlwifi: update Intel's mvm/mld drivers
This version is based on
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
05f7e89ab9731565d8a62e3b5d1ec206485eeb0b ( tag: v6.19 ).
Sponsored by: The FreeBSD Foundation
ath12k: update Atheros/QCA's ath12k driver
This version is based on
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
05f7e89ab9731565d8a62e3b5d1ec206485eeb0b ( tag: v6.19 ).
Sponsored by: The FreeBSD Foundation
ath10k: update Atheros/QCA's ath10k driver
This version is based on
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
05f7e89ab9731565d8a62e3b5d1ec206485eeb0b ( tag: v6.19 ).
Sponsored by: The FreeBSD Foundation
mtree: stop creating /usr/share/doc/ncurses
In base 68ad2b0d7af2a the ncurses html documentation was removed, and
entries added to ObsoleteFiles.inc to get rid of /usr/share/doc/ncurses,
but the directory was still being re-created via BSD.usr.dist. Remove it
from there too.
Fixes: 68ad2b0d7af2a
MFC after: 1 month
pwd: Clean up and adopt POSIX semantics
According to POSIX, the default should be -L. Based on code history,
whoever first wrote BSD pwd(1) could not figure out how to implement
-L and therefore made -P the default (and only) option. Support for -L
was later added, but the default was never changed.
Clean up the code, make -L the default, and rewrite getcwd_logical() to
reject paths that contain dot or dot-dot, as required by POSIX.
MFC after: 1 week
Reviewed by: olce
Differential Revision: https://reviews.freebsd.org/D55146
diff: Report I/O errors in Stone algorithm
In the legacy Stone algorithm, we do a first pass over the files to
check if they're identical before we start diffing them. That code
would correctly set the exit status if an I/O error was encountered,
but would not emit an error message. Do so.
PR: 292198
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: thj
Differential Revision: https://reviews.freebsd.org/D55125
(cherry picked from commit f8c12e6e3874cdd353fb16785da6f4e7eb134cd9)
diff: Fix integer overflows in Stone algorithm
Fix integer overflows that may occur when the context window is very
large and add tests to exercise those conditions.
PR: 267032
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: thj, kevans
Differential Revision: https://reviews.freebsd.org/D55110
(cherry picked from commit 5fc739eb5949620da911db2f87ca8faedc549d3a)
include/stdckdint.h: make the header compatible with C++
by removing the cast to _Bool. The _Bool type is not defined for C++,
and the specification from the gcc info doc states that the return
type of the __builtin_{add,sub,mul}_overflow() is bool already.
This is done instead of including stdbool.h to avoid namespace
pollution, since defining bool from stdckdint.h simingly is not
sanctioned by ISO/IEC 9899:2024.
PR: 290299
Reviewed by: des
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D53149
(cherry picked from commit 3c052bec12fcf09f81ba0760ebecec38e196d332)
include: Implement N2867.
This adds macros for checked addition, subtraction, and multiplication with semantics similar to the builtins gcc and clang have had for years.
Reviewed by: kib, emaste
Differential Revision: https://reviews.freebsd.org/D41734
(cherry picked from commit e6615b10347caf67f5bc12c9a8e30b8ddd9860ae)
diff: Report I/O errors in Stone algorithm
In the legacy Stone algorithm, we do a first pass over the files to
check if they're identical before we start diffing them. That code
would correctly set the exit status if an I/O error was encountered,
but would not emit an error message. Do so.
PR: 292198
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: thj
Differential Revision: https://reviews.freebsd.org/D55125
(cherry picked from commit f8c12e6e3874cdd353fb16785da6f4e7eb134cd9)
diff: Don't compare a file or directory to itself
While here, stop abusing struct dirent for something we don't even need
to store.
PR: 254455
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: thj, kevans
Differential Revision: https://reviews.freebsd.org/D55113
(cherry picked from commit 590126789c841d80655869bc075c8980c173dd1c)
diff: Fix build
rc must be defined first.
Fixes: 590126789c84
MFC after: 1 week
[3 lines not shown]
diff: Fix integer overflows in Stone algorithm
Fix integer overflows that may occur when the context window is very
large and add tests to exercise those conditions.
PR: 267032
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: thj, kevans
Differential Revision: https://reviews.freebsd.org/D55110
(cherry picked from commit 5fc739eb5949620da911db2f87ca8faedc549d3a)
diff: Correctly declare tests
Sponsored by: Klara, Inc.
Fixes: 5fc739eb5949 ("diff: Fix integer overflows in Stone algorithm")
Fixes: 270492602b9b ("diff: Add test case for pagination resource leak")
Fixes: 590126789c84 ("diff: Don't compare a file or directory to itself")
(cherry picked from commit 157d6664aeb815db3b758bd3038fd1512a0f4e2c)