commit 6461715f1ae19d028fcae45768cfa91f88b31f32 Author: Glen Barber Date: Thu Feb 11 19:01:13 2021 -0500 update releng/13.0 to BETA2 Approved by: re (implicit) Sponsored by: Rubicon Communications, LLC ("Netgate") commit 4a3d252cf36e4d7e31be92ff832fe6b59ff872c6 Author: Alexander V. Chernikov Date: Mon Feb 8 20:11:38 2021 +0000 Turn off forgotten multipath debug messages Approved by: re(gjb) Reported by: mike tancsa (cherry picked from commit adc4ea97bd775cb49df5dbfd71dd497c834ae150) (cherry picked from commit 980ce11f30f7587bbb897c3c3bd488a06f5f6b4f) commit 46d3e8cd88fa9d78c47ce2e492ca0b098f4c23a1 Author: Mark Johnston Date: Mon Feb 8 09:19:07 2021 -0500 armv8crypto: Fix some edge cases in the AES-GCM implementation - We were only hashing up to the first 16 bytes of the AAD. - When computing the digest during decryption, handle the case where len == trailer, i.e., len < AES_BLOCK_LEN, properly. While here: - trailer is always smaller than AES_BLOCK_LEN, so remove a pair of unnecessary modulus operations. - Replace some byte-by-byte loops with memcpy() and memset() calls. In particular, zero the full block before copying a partial block into it since we do that elsewhere and it means that the memset() length is known at compile time. Approved by: re (gjb) Reviewed by: jhb Sponsored by: Ampere Computing Submitted by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D28501 (cherry picked from commit 0dc7076037a87100060309f7179ef6a01f32f99e) (cherry picked from commit 860e0c7fb84863580521142825330aa941dee313) commit dc57f212526d25e8ef036e768b816a7fdae5707b Author: Kyle Evans Date: Thu Feb 11 09:11:24 2021 -0600 grep: fix -A handling in conjunction with -m match limitation The basic issue here is that grep, when given -m 1, would stop all line processing once it hit the match count and exit immediately. The problem with exiting immediately is that -A processing only happens when subsequent lines are processed and do not match. The fix here is relatively easy; when bsdgrep matches a line, it resets the 'tail' of the matching context to the value supplied to -A and dumps anything that's been queued up for -B. After the current line has been printed and tail is reset, we check our mcount and do what's needed. Therefore, at the time that we decide we're doing nothing, we know that 'tail' of the context is correct and we can simply continue on if there's still more to pick up. With this change, we still bail out immediately if there's been no -A flag. If -A was supplied, we signal that we should continue on. However, subsequent lines will not even bothere to try and process the line. We have reached the match count, so even if the next line would match then we must process it if it hadn't. Thus, the loop in procfile() can short-circuit and just process the line as a non-match until procmatches() indicates that it's safe to stop. A test has been added to reflect both that we should be picking up the next line and that the next line should be considered a non-match even if it should have been. PR: 253350 Approved by: re (gjb) (cherry picked from commit 3e2d96ac974db823255a6f40b90eeffa6e38d022) (cherry picked from commit 08f25b50dbd332e5c5c9380fd90c516e9af1ab36) commit f28ccd8d95954134cec93db482fb0bd4ce93f36e Author: Kyle Evans Date: Thu Feb 11 09:10:44 2021 -0600 grep: fix null pattern and empty pattern file behavior The null pattern semantics were terrible because I tried to match gnugrep, but I got it wrong. Let's unwind that: - The null pattern should match every line if neither -w nor -x. - The null pattern should match empty lines if -x. - The null pattern should not match any lines if -w. The first two will stop processing (shortcut) even if additional patterns are specified. In any other case, we will continue processing other patterns. If no other patterns are specified beside a null pattern, then we match if neither -w nor -x or set and do not match if either of those are specified. The justification for -w is that it should match on a whole word, but the null pattern does not have a whole word to match on. Empty pattern files should never match anything, and more importantly, -v should cause everything to be written. PR: 253209 Approved by: re (gjb) (cherry picked from commit f823c6dc730b0dd08b54a53be1d8fd587eee7021) (cherry picked from commit 574d0dfae5011a766aa967f1d1675ddf7b535936) commit c511a5ab53ba335dc85f7ac93843872eb5763602 Author: Glen Barber Date: Wed Feb 10 21:23:58 2021 -0500 release: fix overriding UNAME_r Sponsored by: Rubicon Communications, LLC ("Netgate") commit d3338f3355a612cf385632291f46c5777bba8d18 Author: Dimitry Andric Date: Wed Feb 10 23:28:43 2021 +0100 Fix incorrect hypotl(3) result with subnormal numbers This adjusts the factor used to scale the subnormal numbers, so it becomes the right value after adjusting its exponent. Thanks to Steve Kargl for finding the most elegant fix. Also enable the hypot tests, and add a test case for this bug. PR: 253313 MFC after: 1 week commit a6dc68c0e0f8a24ffaf0b4e78e58141ef7897047 Author: Emmanuel Vadot Date: Thu Feb 4 17:07:17 2021 +0100 arm64: if_dwc is also needed by intel stratix10 platform MFC after: 3 days commit 3b721b44955af8f915a6974b1012a5089c6a48ca Author: Emmanuel Vadot Date: Thu Feb 4 15:40:54 2021 +0100 arm64: Add a SOC_BRCM_NS2 option Only compile files needed for this platform if the option is enabled in the kernel config file. Add the option to GENERIC. MFC after: 3 days commit b81439d1eb3a25fd2329a4391597de43b9c52589 Author: Emmanuel Vadot Date: Thu Feb 4 15:31:23 2021 +0100 arm64: Make thunderx vnic file depend on soc_cavm_thunderx MFC after: 3 days commit ea3b6abf3f2fd7db11a95ea10cc4b6d136958f8d Author: Emmanuel Vadot Date: Thu Feb 4 14:54:22 2021 +0100 arm64: Order sys/conf/files.arm64 This is now easier to read and see what's compiled-in No functional changes intended. MFC after: 3 days commit 3c958f5fdfc01b7579ea0fbfc3f15f8a85bebee9 Author: Lutz Donnerhacke Date: Wed Feb 10 11:47:38 2021 +0100 netgraph/ng_bridge: Add counters for the first link, too For broadcast, multicast and unknown unicast, the replication loop sends a copy of the packet to each link, beside the first one. This special path is handled later, but the counters are not updated. Factor out the common send and count actions as a function. Reviewed by: kp MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28537 commit 0b54d2764737cbe0c4cdd0c0aecddbc485653a07 Author: Ed Maste Date: Thu Feb 4 19:14:12 2021 -0500 Enable pvscsi and vmx in arm64 GENERIC FreeBSD pvscsi and vmx work with VMware ESXi Arm "Fling"; provide these in GENERIC for a convenient out-of-the-box experience. PR: 253202 Reported by: Vincent Milum Jr Approved by: re (gjb) Sponsored by: The FreeBSD Foundation (cherry picked from commit 375d797b81916eb3d16927c9dac8c42975784252) (cherry picked from commit 87eac7608343d86f2d33d15139ca467565bd7623) commit bfb217a826bdd920ddeef74f925944b911b69f89 Author: Ed Maste Date: Tue Feb 2 16:55:51 2021 -0500 Correct description for kern.proc.proc_td kern.proc.proc_td returns the process table with an entry for each thread. Previously the description included "no threads", presumably a cut-and-pasteo in 2648efa621748. Description suggested by PauAmma. PR: 253146 Approved by: re (gjb) Sponsored by: The FreeBSD Foundation (cherry picked from commit edc374e7c41d3d9e28e0b3a76bc9ed021d7db571) (cherry picked from commit dbe043d42cda38e7f4186f0c0ed39569b713f05b) commit e6f59be239aa17f80b44ded4779e29f5d5352b28 Author: Mateusz Piotrowski <0mp@FreeBSD.org> Date: Wed Feb 10 18:02:14 2021 +0100 systat.1: Fix synopsis systat does not have a "-display" flag. Use Ar to indicate that "display" is meant to be substituted with an actual display command. MFC after: 1 week commit fcbaf46b763a91bb41fe68afdcf59a7d210bc2f7 Author: Mateusz Piotrowski <0mp@FreeBSD.org> Date: Sat Feb 6 14:14:20 2021 +0100 systat.1: Remove Tn macros They are no longer supported by mdoc(7). MFC after: 1 week commit abfcf9a17dba7151e554cd64dcd4d8a7c3dc2aa0 Author: Ed Maste Date: Wed Feb 3 16:16:45 2021 -0500 readelf: decode LA48 and ASG_DISABLE feature flags Approved by: re (gjb) Sponsored by: The FreeBSD Foundation (cherry picked from commit e79b51e2b2e35d6256a1ef5311ce02ec4032d21f) (cherry picked from commit 5e9e7ad9a2a4bc95326df76c90b9244470fea72e) commit 01d07b03ef2b59e70a25cfc4d9e438a7331c5926 Author: Jessica Clarke Date: Wed Feb 10 16:41:35 2021 +0000 localedef: Fix bootstrapping on Ubuntu 16.04 Glibc's stdlib.h defines various prototypes for GNU extensions that take a locale_t. Newer versions use locale_t directly and include an internal bits/types/locale_t.h in order to get its definition, but older versions include xlocale.h for that, for which our bootstrap version is empty. Moreover it expects to use the glibc-specific __locale_t type. Thus, provide dummy definitions of both types in order to ensure the prototypes don't give any errors, and guard against the header being inadvertently included between the bootstrapping namespace.h and un-namespace.h, where locale_t is #define'd. This header is not used when bootstrapping on FreeBSD and exists solely to stub out glibc's, so this should have no impact on FreeBSD hosts. Reviewed by: arichardson, emaste (comment only) Differential Revision: https://reviews.freebsd.org/D28317 commit 5c18744ea9b94cb6a9a091a900fa4999868736e1 Author: Mark Johnston Date: Wed Feb 10 11:10:27 2021 -0500 vm: Honour the "noreuse" flag to vm_page_unwire_managed() This flag indicates that the page should be enqueued near the head of the inactive queue, skipping the LRU queue. It is used when unwiring pages from the buffer cache following direct I/O or after I/O when POSIX_FADV_NOREUSE or _DONTNEED advice was specified, or when sendfile(SF_NOCACHE) completes. For the direct I/O and sendfile cases we only enqueue the page if we decide not to free it, typically because it's mapped. Pass "noreuse" through to vm_page_release_toq() so that we actually honour the desired LRU policy for these scenarios. Reported by: bdrewery Reviewed by: alc, kib MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28555 commit 7676b388adbc81a2ad46b43852cd9bc7ac7fad7e Author: Alex Richardson Date: Wed Feb 10 15:25:14 2021 +0000 Always build the sanitizer runtimes when compiling with clang This allows instrumenting e.g. test binaries even when compiling with an external clang (e.g. CROSS_TOOLCHAIN=llvm11). I have some upcoming patches that allow building the entire base system with ASan/UBSan/etc. instrumentation and this is required in preparation for this. Reviewed By: dim, emaste Differential Revision: https://reviews.freebsd.org/D28532 commit 12ad8bdb34aa990bcc4f3faa92a6e0557385d2b2 Author: Alex Richardson Date: Wed Feb 10 15:23:23 2021 +0000 usr.sbin/makefs: fix use-after-free in read_mtree_keywords() The st variable is used as a shortcut for &node->inode->st, but in one branch just before the exit we update node->inode without changing st. Reported by: AddressSanitizer Reviewed By: emaste MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28570 commit f44e67d120ad78ef7894241b519ee79fd190a16e Merge: 1e811efbc59 d60fa10fd87 Author: Cy Schubert Date: Tue Feb 9 20:25:05 2021 -0800 MFV d60fa10fd872db7e3d8cb1e161cfdae026c43b14: Update unbound 1.13.0 --> 1.13.1. Includes numerous bugfixes documented at: https://www.nlnetlabs.nl/projects/unbound/download/#unbound-1-13-1 MFC after: 1 month commit c48cbd0254dedd363ab569692ddf3395b6214412 Author: Brandon Bergren Date: Sun Feb 7 16:05:41 2021 -0600 powerpc64: Fix boot on virtual-mode OF (PowerMac G5) In 78599c32efed3247d165302a1fbe8d9203e38974, CFI endproc decoration was added to locore64.S. However, it missed the subtle detail that __restartkernel_virtual() falls through to __restartkernel(). This was causing boot failure on PowerMac G5, as it tried to execute the epilogue as code. Fix this by branching to __restartkernel() instead of intentionally running off the end of the function. While here, add some additional notes on how the virtual mode restart works. Approved by: re (gjb) (cherry picked from commit d26f2a50ff48dacd38ba358d658882d51f7bdbc4) (cherry picked from commit 187492ef639fecde6c122838cfff0a75d8b94608) commit 1e811efbc591699b872bea42b9de419c373199df Author: Cy Schubert Date: Tue Feb 9 17:13:01 2021 -0800 Fix non-IPv6 build post 57785538c6e0d7e8ca0f161ab95bae10fd304047. 57785538c6e0d7e8ca0f161ab95bae10fd304047 change the test for FreeBSD from __FreeBSD_version to __FreeBSD__. However this test was performed before sys/param.h was included, therefore __FreeBSD_version was never defined. As the test was never true opt_random_ip_id.h was never included. Submitted by: bdragon Reported by: bdragon MFC after: 1 week X-MFC with: 57785538c6e0d7e8ca0f161ab95bae10fd304047 commit f25266bee7dafb10f03e06537c8127cc17335bed Author: Michael Tuexen Date: Tue Feb 9 23:35:55 2021 +0100 libsysdecode: fix decoding of TCP_NOPUSH and TCP_MD5SIG TCP_FASTOPEN_MIN_COOKIE_LEN was incorrectly registered as a name of a IPPROTO_TCP level socket option, which overwrote TCP_NOPUSH. TCP_FASTOPEN_PSK_LEN was incorrectly registered as a name of an IPPROTO_TCP level socket option, which overwrote TCP_MD5SIG. MFC after: 3 days Sponsored by: Netflix, Inc. commit 51af03328755c9095e94d20858a8d10acfe412ae Author: Dimitry Andric Date: Tue Feb 9 23:37:08 2021 +0100 Add test case for 93fc67896550 (incorrect powf(3) result) This adds the test case to contrib/netbsd-tests/lib/libm/t_pow.c, as it is currently the only place testing pow(3) and friends. MFC after: 1 week commit 9c6954329a9285547881ddd60e393b7c55ed30c4 Author: Jessica Clarke Date: Tue Feb 9 21:40:24 2021 +0000 bsd.compiler.mk: Detect distribution-provided GCC when executed as cc Clang always prints "clang $VERSION" regardless of the name used to execute it, whereas GCC prints "$progname $VERSION", meaning if CC is set to cc and cc is GCC it will print "cc $VERSION". We are able to detect some of those cases since it then prints "($PKGVERSION)", where the default is "GCC", but many distributions override that to print their name and the package version number (e.g. "Debian 10.2.1-6"), so nothing tells us it's GCC other than the fact that it's not Clang (and that there's an FSF copyright disclaimer). However, GCC's -v option will always print "gcc version $VERSION", so fall back on using that to detect GCC. Whilst Clang also supports this option, we should never get here, so Clang handling is not added. Reviewed by: brooks, emaste, arichardson Differential Revision: https://reviews.freebsd.org/D28315 commit c41fef90a7d06d7a363d1085a53205ba147cd518 Author: Stefan Eßer Date: Fri Feb 5 20:53:34 2021 +0100 bc: Correct mis-merge of contrib/bc on upgrade to version 3.2.6 Revert "bc: Vendor import of Gavin Howard's bc version 3.2.6" This reverts commit 601ac82194693fcae9d7d2a7ec7d66ebaf3fd61e. Vendor import of Gavin Howard's bc version 3.2.6 (cherry picked from commit 47a52dc4d48f259ab7d9f9ba6b65f4f2331a22dc) The files README.md and .gitignore had been lost and are restored by this commit. A lot of files used for fuzzing had been moved to a new place and still existed in their previous location. Delete the now obsolete files from the old location. Approved by: re commit ac76bc1145dd7f4476e5d982ce8f355f71015713 Author: Dimitry Andric Date: Tue Feb 9 22:06:51 2021 +0100 Fix lib/msun's ctrig_test/test_inf_inputs test case with clang >= 10 This sprinkles a few strategic volatiles in an attempt to defeat clang's optimization interfering with the expected floating-point exception flags. Reported by: lwhsu PR: 244732 MFC after: 3 days commit d60fa10fd872db7e3d8cb1e161cfdae026c43b14 Author: Cy Schubert Date: Tue Feb 9 12:59:02 2021 -0800 Vendor import of Unbound 1.13.1. Includes numerous bugfixes documented at: https://www.nlnetlabs.nl/projects/unbound/download/#unbound-1-13-1 commit 011b7317dbb5038a95b9b4fca050325a62f3991e Author: Lutz Donnerhacke Date: Tue Feb 9 12:32:46 2021 +0100 netgraph/ng_bridge: Document staleness in multithreaded operation In the data path of ng_bridge(4), the only value of the host struct, which needs to be modified, is the staleness, which is reset every time a frame is received. It's save to leave the code as it is. This patch is part of a series to make ng_bridge(4) multithreaded. Reviewed by: kp MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28546 commit ccf4cd2e7830394467d5f6cf546ab453f9657b69 Author: Lutz Donnerhacke Date: Mon Feb 8 22:36:46 2021 +0100 netgraph/ng_bridge: Merge internal structures In a earlier version of ng_bridge(4) the exernal visible host entry structure was a strict subset of the internal one. So internal view was a direct annotation of the external structure. This strict inheritance was lost many versions ago. There is no need to encapsulate a part of the internal represntation as a separate structure. This patch is a preparation to make the internal structure read only in the data path in order to make ng_bridge(4) multithreaded. Reviewed by: kp MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28545 commit 7100be11ec2e7a79b65ddb727236f23d885aa8a3 Author: Antonio Russo Date: Mon Feb 8 10:15:05 2021 -0700 Set file mode during zfs_write Apply https://github.com/openzfs/zfs/pull/11576 Direct commit from upstream openzfs. Full commit message below: Set file mode during zfs_write 3d40b65 refactored zfs_vnops.c, which shared much code verbatim between Linux and BSD. After a successful write, the suid/sgid bits are reset, and the mode to be written is stored in newmode. On Linux, this was propagated to both the in-memory inode and znode, which is then updated with sa_update. 3d40b65 accidentally removed the initialization of newmode, which happened to occur on the same line as the inode update (which has been moved out of the function). The uninitialized newmode can be saved to disk, leading to a crash on stat() of that file, in addition to a merely incorrect file mode. Reviewed-by: Ryan Moeller Reviewed-by: Brian Behlendorf Signed-off-by: Antonio Russo Closes #11474 Closes #11576 Approved by: re (gdb) Obtained from: openzfs/zfs@f8ce8aed0 Sponsored by: iXsystems, Inc. (cherry picked from commit e9d419a05357036ea2fd37218d853d2c713d55cc) (cherry picked from commit 618dee602319166c14c6e12971425d175d4630ed) commit f69cd089ccf4bf6afbb61fe84e1df2af2b037ec4 Author: John Baldwin Date: Wed Feb 3 14:59:32 2021 -0800 serf: Fix the default return value of the BIO control method. OpenSSL BIO classes provide an abstraction for dealing with I/O. OpenSSL provides BIO classes for commonly used I/O primitives backed by file descriptors, sockets, etc. as well as permitting consumers of OpenSSL to define custom BIO classes. One of the methods BIO classes implement is a control method invoked by BIO_ctrl() for various ancilliary tasks somewhat analgous to fcntl() and ioctl() on file descriptors. According to the BIO_ctrl(3) manual page, control methods should return 0 for unknown control requests. KTLS support in OpenSSL adds new control requests. Two of those new requests are queries to determine if KTLS is enabled for either reading or writing. These control reuquest return 1 if KTLS is enabled and 0 if it is not. serf includes two custom BIO classes for wrapping I/O requests from files and from a buffer in memory. These BIO classes both use a custom control method. However, this custom control method was returning 1 for unknown or unsupported control requests instead of 0. As a result, OpenSSL with KTLS believed that these BIOs were using KTLS and were thus adding headers and doing encryption/decryption in the BIO. Correcting the return value removes this confusion. PR: 253135 Reported by: Guido Falsi Approved by: re (gjb) Sponsored by: Netflix (cherry picked from commit cb7cc72c546e0f87598961c3860e17391f42866c) (cherry picked from commit b122886de25a51e3587d94ab2988a6ccb1e6a4e7) commit 1f0bc379eb71af6d1cbc857a5b1316a115fbc649 Author: John Baldwin Date: Fri Jan 29 10:53:50 2021 -0800 Fix ldd to work with more ELF files. - Use libelf to parse ELF data structures and remove code duplication for ELF32. - Don't require the OSABI field to be set to the FreeBSD OSABI for shared libraries. Both AArch64 and RISC-V leave it set to "none" and instead depend on the ABI tag note. For ldd, this means falling back to walking the notes in PT_NOTE segments to find the ABI tag note to determine if an ELF shared library without OSABI set in the header file is a FreeBSD shared library. Approved by: re (gjb) (cherry picked from commit 9d4104b214963bb3371ada05cae8006940121634) (cherry picked from commit fa3b2ad265d311191c1c8337bf3aa356f28480cb) commit e9d419a05357036ea2fd37218d853d2c713d55cc Author: Antonio Russo Date: Mon Feb 8 10:15:05 2021 -0700 Set file mode during zfs_write Apply https://github.com/openzfs/zfs/pull/11576 Direct commit from upstream openzfs. Full commit message below: Set file mode during zfs_write 3d40b65 refactored zfs_vnops.c, which shared much code verbatim between Linux and BSD. After a successful write, the suid/sgid bits are reset, and the mode to be written is stored in newmode. On Linux, this was propagated to both the in-memory inode and znode, which is then updated with sa_update. 3d40b65 accidentally removed the initialization of newmode, which happened to occur on the same line as the inode update (which has been moved out of the function). The uninitialized newmode can be saved to disk, leading to a crash on stat() of that file, in addition to a merely incorrect file mode. Reviewed-by: Ryan Moeller Reviewed-by: Brian Behlendorf Signed-off-by: Antonio Russo Closes #11474 Closes #11576 Obtained from: openzfs/zfs@f8ce8aed0 MFC after: 0 days Sponsored by: iXsystems, Inc. commit 81c3f64110bb76e24d6062eafd7206c10f676d6f Author: Alex Richardson Date: Tue Jan 19 11:35:07 2021 +0000 usr.bin/grep: Fix Address OOB read error I found this when compiling all the bootstrap tools with -fsanitize=addres: ==65590==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62d000008400 at pc 0x000000473053 bp 0x7ffc1c7dd910 sp 0x7ffc1c7dd0b8 READ of size 32769 at 0x62d000008400 thread T0 #0 0x473052 in regexec (/local/scratch/alr48/cheri/build/freebsd-amd64-build/local/scratch/alr48/cheri/freebsd/amd64.amd64/tmp/legacy/bin/grep+0x473052) #1 0x4c9cf3 in procline /local/scratch/alr48/cheri/freebsd/usr.bin/grep/util.c:539:8 #2 0x4c8687 in procfile /local/scratch/alr48/cheri/freebsd/usr.bin/grep/util.c:379:18 #3 0x4c6596 in main /local/scratch/alr48/cheri/freebsd/usr.bin/grep/grep.c:714:8 0x62d000008400 is located 0 bytes to the right of 32768-byte region [0x62d000000400,0x62d000008400) allocated by thread T0 here: #0 0x493d5d in malloc (/local/scratch/alr48/cheri/build/freebsd-amd64-build/local/scratch/alr48/cheri/freebsd/amd64.amd64/tmp/legacy/bin/grep+0x493d5d) #1 0x4cad75 in grep_malloc /local/scratch/alr48/cheri/freebsd/usr.bin/grep/util.c:656:13 #2 0x4c8129 in procfile /local/scratch/alr48/cheri/freebsd/usr.bin/grep/util.c #3 0x4c6596 in main /local/scratch/alr48/cheri/freebsd/usr.bin/grep/grep.c:714:8 SUMMARY: AddressSanitizer: heap-buffer-overflow (/local/scratch/alr48/cheri/build/freebsd-amd64-build/local/scratch/alr48/cheri/freebsd/amd64.amd64/tmp/legacy/bin/grep+0x473052) in regexec Reviewed By: kevans MFC after: 1 week commit 39e0c3f686387605591f8f646ceec53613619525 Author: Mateusz Guzik Date: Tue Feb 9 17:06:27 2021 +0100 cache: assorted comment fixups commit b49a0db6628e6f953504ebc8712ed582471ccd05 Author: Mateusz Guzik Date: Tue Feb 9 16:18:58 2021 +0100 Revert "amd64: implement strlen in assembly" This reverts commit af366d353b84bdc4e730f0fc563853abc338271c. Trips over '\xa4' byte and terminates early, as found in lib/libc/gen/setdomainname_test:setdomainname_basic testcase However, keep moving libkern/strlen.c out of conf/files. Reported by: lwhsu commit 07eed38ae2de9b0194c1beef797c05cf57cdcd97 Author: David Chisnall Date: Tue Feb 2 16:06:33 2021 +0200 rtld: Fix null-pointer dereference Approved by: re (gjb) (cherry picked from commit 43d44842aef3972cc86ce673e84e31f372257b15) commit ec090f4a67654fa541e6d97fd5f74d3f66c1c0d0 Author: Michal Meloun Date: Tue Feb 9 11:36:36 2021 +0100 arm32: Align arguments of sync_icache() syscall to cacheline size. Otherwise, we may miss synchronization of the last cacheline. MFC after: 3 days commit a26f7358583174f2fe0df3e979f7b8b02069278c Author: Toomas Soome Date: Tue Feb 9 00:34:47 2021 +0200 loader: do not autoselect smaller font than 8x16 with high res display The VT screen buffer size is calculated based on our default built in (8x16) font. With high-resolution display, we want to use at least 8x16 font, or we will have large unused areas on screen. MFC after: 1 week commit 96bef2053a87c8d01ce08ea88857e4657489c8e7 Author: Toomas Soome Date: Mon Feb 8 20:49:09 2021 +0200 loader: remove BORDER_PIXELS BORDER_PIXELS is left over from picking up the source from illumos port. Since FreeBSD VT does not use border in terminal size calculation, there is no reason why should loader use it. MFC after: 1 week commit 504ebd612ec61165bb949cfce3a348b0d6f37008 Author: Kyle Evans Date: Wed Jan 20 11:53:05 2021 -0600 kern: sonewconn: set so_options before pru_attach() Protocol attachment has historically been able to observe and modify so->so_options as needed, and it still can for newly created sockets. 779f106aa169 moved this to after pru_attach() when we re-acquire the lock on the listening socket. Restore the historical behavior so that pru_attach implementations can consistently use it. Note that some pru_attach() do currently rely on this, though that may change in the future. D28265 contains a change to remove the use in TCP and IB/SDP bits, as resetting the requested linger time on incoming connections seems questionable at best. This does move the assignment out from under the head's listen lock, but glebius notes that head won't be going away and applications cannot assume any specific ordering with a race between a connection coming in and the application changing socket options anyways. Discussed-with: glebius MFC-after: 1 week commit 45c95531c0a2b48a79137555a9cda12137045391 Author: Piotr Kubaj Date: Sat Feb 6 03:21:55 2021 +0100 powerpc64le: readd COMPAT_FREEBSD11 and COMPAT_FREEBSD12 lang/rust needs COMPAT_FREEBSD11 to build, even though powerpc64le itself is supported only since 13.0. I also corrected a comment, because if we ever have lib32 for powerpc64le, it will be for powerpcle. Reviewed by: bdragon (on IRC) Approved by: gjb (re) (cherry picked from commit 8b804ee616b4c8810015b69e37e31ef0c4161511) commit 3bc17248d31794519ba95b2c6b9ff8a0d31dba81 Author: Mateusz Guzik Date: Mon Feb 8 23:10:57 2021 +0100 devfs: fix use count leak when using TIOCSCTTY by matching devfs_ctty_ref Fixes: 3b44443626603f65 ("devfs: rework si_usecount to track opens") commit 57785538c6e0d7e8ca0f161ab95bae10fd304047 Author: Cy Schubert Date: Sat Feb 6 19:22:52 2021 -0800 Simplify the FreeBSD check using __FreeBSD__ compiler macro. Rather than rely on __FreeBSD_version, defined in sys/param.h, use __FreeBSD__ defined by the compiler. Reported by: emaste MFC after: 1 week commit d20f7a5a3da1aa5bccdabb89c181ca0c49385ecd Author: Cy Schubert Date: Sat Feb 6 19:15:27 2021 -0800 Simply FreeBSD check using __FreeBSD__ and remove OpenBSD MFC after: 1 week commit 174a7e578a33c01401e33f9bfcc077fc3155251c Author: Alan Somers Date: Wed Jan 20 08:55:36 2021 -0700 ZFS: fix assertions with INVARIANTS AFAICT, this was an oversight from 9e5787d2284e187abb5b654d924394a65772e004 (svn r364746). That revision inadvertently disabled assertions unconditionally. Reviewed by: freqlabs MFC after: 3 days Sponsored by: Axcient Differential Revision: https://reviews.freebsd.org/D28256 commit 82874dcb3610b1e57fb6b1b9db96ac4996bfa620 Author: Peter Grehan Date: Wed Feb 3 19:05:09 2021 +1000 Always clamp curve25519 keys prior to use. Approved by: re (gjb) (cherry picked from commit 6136a10e355a7a837edecbccbed04c34b4bc32c9) commit 924d1c9a050d7e355d0562fca62bd2bb9b5f53d7 Author: Alexander V. Chernikov Date: Mon Feb 8 22:30:39 2021 +0000 Revert "SO_RERROR indicates that receive buffer overflows should be handled as errors." Wrong version of the change was pushed inadvertenly. This reverts commit 4a01b854ca5c2e5124958363b3326708b913af71. commit db2f512381ac3c0c227f5c0354690bb929dcac17 Author: Warner Losh Date: Mon Feb 8 12:29:20 2021 -0700 hid: bump HID_ITEM_MAXUSAGES to 8 My YOGA requires a minimum of 7 to parse w/o an error. Since the memory savings are trivial and the yoga a popular system, bump the default up to 8. There's no API/ABI issues in doing this. This hid_item struct isn't exported to userland and the one libusbhid has is different and only shares a name... MFC After: 3 days Reviewed by: wulf@ Differential Revision: https://reviews.freebsd.org/D28543 commit 07cac176fba947381c8111b8e02e8067e7fa542a Author: Edward Tomasz Napierala Date: Mon Feb 8 21:52:31 2021 +0000 Don't check compat.linux.emul_path before loading linux(4) Fix e40787f900f to make libexec/rc/rc.d/linux retrieve the sysctl after loading the kernel module which provides it, not before. Reported By: jkim Sponsored By: The FreeBSD Foundation commit 35af933173d516101f4c44af328fbe2d6e587869 Author: Warner Losh Date: Mon Feb 8 14:43:25 2021 -0700 acpi: limit the AMDI0020/AMDI0010 workaround to an option It appears that production versions of EPYC firmware get the _STA method right for these nodes. In fact, this workaround breaks on production hardware by including too many uart nodes. This work around was for pre-release hardware that wound up not having a large deployment. Move this work around to a kernel option since the machines that needed it have been powered off and are difficult to resurrect. Should there be a more significant deployment than is understood, we can restrict it based on smbios strings. Discussed with: mmacy@, seanc@, jhb@ MFC After: 3 days commit adc4ea97bd775cb49df5dbfd71dd497c834ae150 Author: Alexander V. Chernikov Date: Mon Feb 8 20:11:38 2021 +0000 Turn off forgotten multipath debug messages Reported by: mike tancsa MFC after: 3 days commit 4a01b854ca5c2e5124958363b3326708b913af71 Author: Alexander V. Chernikov Date: Sun Feb 7 17:21:18 2021 +0000 SO_RERROR indicates that receive buffer overflows should be handled as errors. Historically receive buffer overflows have been ignored and programs could not tell if they missed messages or messages had been truncated because of overflows. Since programs historically do not expect to get receive overflow errors, this behavior is not the default. This is really really important for programs that use route(4) to keep in sync with the system. If we loose a message then we need to reload the full system state, otherwise the behaviour from that point is undefined and can lead to chasing bogus bug reports. commit d8c6d4c7321d4c969216bda8f792b45ed00afd64 Author: Vladimir Kondratyev Date: Tue Feb 9 00:26:42 2021 +0300 wsp: Add sysctl tunable for Z-Axis inversion This adds a new sysctl to Wellspring Touchpad driver for controlling Z-Axis (2-finger vertical scroll) direction "hw.usb.wsp.z_invert". Submitted by: James Wright Reviewed by: wulf PR: 253321 Differential revision: https://reviews.freebsd.org/D28521 commit dd2516fc078f15633ad5aedaad6de140cb491f80 Author: Warner Losh Date: Mon Feb 8 13:28:18 2021 -0700 nvme: Make nvme_ctrlr_hw_reset static nvme_ctrlr_hw_reset is no longer used outside of nvme_ctrlr.c, so make it static. If we need to change this in the future we can. commit 6c34d8ce11cb73e718fc23d85b6fbfab07ee15b4 Author: Gordon Bergling Date: Mon Feb 8 21:21:26 2021 +0100 ktls(4): Mention WITH_OPENSSL_KTLS in the ktls(4) manual page Since we ship a ktls(4) enabled OpenSSL version, mention the src.conf(5) option WITH_OPENSSL_KTLS in the manual page. Reviewed by: jhb MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28435 commit 9600aa31aa633bbb9e8a56d91a781d5a7ce2bff6 Author: Warner Losh Date: Mon Feb 8 13:08:48 2021 -0700 nvme: use NVME_GONE rather than hard-coded 0xffffffff Make it clearer that the value 0xfffffff is being used to detect the device is gone. We use it other places in the driver for other meanings. commit 93fc67896550548f91b307dbe3053f11db5d4a8a Author: Steve Kargl Date: Mon Feb 8 20:45:30 2021 +0100 Fix incorrect powf(3) result with x near 1 and |y| much larger than 1 This adjusts the check to trigger overflow/underflow to a slightly lower value. Before: powf(9.999995e-01, -1.342177e+08) -> inf After: powf(9.999995e-01, -1.342177e+08) -> 1.858724e+31 MFC after: 1 week commit b5770470276268acef21368b3e77a325df883500 Author: Mark Johnston Date: Mon Feb 8 14:42:54 2021 -0500 mca: Handle inconsistent CMCI capability reporting A BIOS bug may apparently cause the BSP to report that it does not implement CMCI, with some APs reporting that they do. In this scenario, avoid a NULL pointer dereference that occurs in cmci_monitor() because cmc_state was not allocated by the BSP. PR: 253272 Reported by: asomers, mmacy Reviewed by: kib (previous version) MFC after: 1 week commit 7da3bfc20ca8aca8177b677cba37c9f52714605c Author: Mateusz Guzik Date: Mon Feb 8 19:24:26 2021 +0000 amd64: fix up a braino in strlen comment commit d242f782c24980627716613ff8fb5e6078520a5b Author: Daniel Ebdrup Jensen Date: Mon Feb 8 20:15:34 2021 +0100 prepare-commit-msg: Remove blank character Approved by: emaste@ (maintainer) commit af366d353b84bdc4e730f0fc563853abc338271c Author: Mateusz Guzik Date: Mon Feb 8 18:01:48 2021 +0100 amd64: implement strlen in assembly The C variant in libkern performs excessive branching to find the non-zero byte instead of using the bsfq instruction. The same code patched to use it is still slower than the routine implemented here as the compiler keeps neglecting to perform certain optimizations (like using leaq). On top of that the routine can is a starting point for copyinstr which operates on words instead of bytes. Tested with glibc test suite. Sample results (calls/s): Haswell: $(perl -e "print 'A' x 3"): stock: 211198039 patched:338626619 asm: 465609618 $(perl -e "print 'A' x 100"): stock: 83151997 patched: 98285919 asm: 120719888 AMD EPYC 7R32: $(perl -e "print 'A' x 3"): stock: 282523617 asm: 491498172 $(perl -e "print 'A' x 100"): stock: 114857172 asm: 112082057 commit 3acea07c1873b1e4042f4a4fa8668745ee59f15b Author: Mateusz Guzik Date: Sun Feb 7 19:53:34 2021 +0000 Restore the augmented strlen commentary ... lost in revert commit 81e074d57dfcd86f152e2848dc44b77087ee7a2d Author: Mateusz Guzik Date: Sun Feb 7 19:50:25 2021 +0000 libkern: use compiler builtins for strcpy, strcmp and strlen commit 3e2d96ac974db823255a6f40b90eeffa6e38d022 Author: Kyle Evans Date: Mon Feb 8 12:31:17 2021 -0600 grep: fix -A handling in conjunction with -m match limitation The basic issue here is that grep, when given -m 1, would stop all line processing once it hit the match count and exit immediately. The problem with exiting immediately is that -A processing only happens when subsequent lines are processed and do not match. The fix here is relatively easy; when bsdgrep matches a line, it resets the 'tail' of the matching context to the value supplied to -A and dumps anything that's been queued up for -B. After the current line has been printed and tail is reset, we check our mcount and do what's needed. Therefore, at the time that we decide we're doing nothing, we know that 'tail' of the context is correct and we can simply continue on if there's still more to pick up. With this change, we still bail out immediately if there's been no -A flag. If -A was supplied, we signal that we should continue on. However, subsequent lines will not even bothere to try and process the line. We have reached the match count, so even if the next line would match then we must process it if it hadn't. Thus, the loop in procfile() can short-circuit and just process the line as a non-match until procmatches() indicates that it's safe to stop. A test has been added to reflect both that we should be picking up the next line and that the next line should be considered a non-match even if it should have been. PR: 253350 MFC-after: 3 days commit 32bf05ad89aaa93f4dd27e3721f4cb52cf57fa03 Author: Toomas Soome Date: Fri Jan 22 00:18:56 2021 +0200 vt: terminal size can grow too big with small font vt is using static buffers for on screen data, the buffer size is calculated based on maximum supported screen size and 8x16 font. When using hi-res graphics and very smaller than 8x16 font, we need to be careful not to overflow static buffers in vt. Testing: I did test by building smaller buffers than vt currently is using, royger was testing on actual 4k capable hardware. MFC after: 1 week Tested by: royger commit 8cb8d8d998792e9c89516904f4951a060a9f2a49 Author: Hans Petter Selasky Date: Tue Jan 26 16:59:42 2021 +0100 MFC 093e72319089: Add missing decrement of active ratelimit connections. Approved by: re (gjb) Reviewed by: rrs@ Sponsored by: Mellanox Technologies // NVIDIA Networking (cherry picked from commit 093e7231908908b651b91c68ac03fb697c3a8352) commit 20204c4681cb27c52907ff5d3a9bfea03527428e Author: Hans Petter Selasky Date: Tue Jan 26 15:01:38 2021 +0100 MFC 85d8d30f9f70: Don't allow allocating a new send tag on an INP which is being torn down. This fixes a potential send tag leak. Approved by: re (gjb) Reviewed by: rrs@ Sponsored by: Mellanox Technologies // NVIDIA Networking (cherry picked from commit 85d8d30f9f7046f5e89295352ded49135b25fbe3) commit c7fcb36f5670b1d6c1f80c3c29d9d2ba374807f7 Author: Mark Johnston Date: Mon Feb 8 09:20:38 2021 -0500 binmiscctl: Avoid segfault with "binmiscctl add" and no extra params MFC after: 1 week commit db6b56441e3a142e7fe58a5a85d9071e772a943e Author: Mark Johnston Date: Mon Feb 8 09:19:27 2021 -0500 ktls: Avoid wakeups and locking for synchronous callbacks When performing encryption in software, the KTLS crypto callback always locks the session to deliver a wakeup. But, if we're handling the operation synchronously this is wasted effort and can result in sleepqueue lock contention on large systems. Use CRYPTO_SESS_SYNC() to determine whether the operation will be completed asynchronously or not, and select a callback appropriately. Avoid locking the session to check for completion if the session handles requests synchronously. Reviewed by: jhb Sponsored by: Ampere Computing Submitted by: Klara, Inc. MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28195 commit 68f6800ce05c386ff045b4416d8595d09c4d8fdd Author: Mark Johnston Date: Mon Feb 8 09:19:19 2021 -0500 opencrypto: Introduce crypto_dispatch_async() Currently, OpenCrypto consumers can request asynchronous dispatch by setting a flag in the cryptop. (Currently only IPSec may do this.) I think this is a bit confusing: we (conditionally) set cryptop flags to request async dispatch, and then crypto_dispatch() immediately examines those flags to see if the consumer wants async dispatch. The flag names are also confusing since they don't specify what "async" applies to: dispatch or completion. Add a new KPI, crypto_dispatch_async(), rather than encoding the requested dispatch type in each cryptop. crypto_dispatch_async() falls back to crypto_dispatch() if the session's driver provides asynchronous dispatch. Get rid of CRYPTOP_ASYNC() and CRYPTOP_ASYNC_KEEPORDER(). Similarly, add crypto_dispatch_batch() to request processing of a tailq of cryptops, rather than encoding the scheduling policy using cryptop flags. Convert GELI, the only user of this interface (disabled by default) to use the new interface. Add CRYPTO_SESS_SYNC(), which can be used by consumers to determine whether crypto requests will be dispatched synchronously. This is just a helper macro. Use it instead of looking at cap flags directly. Fix style in crypto_done(). Also get rid of CRYPTO_RETW_EMPTY() and just check the relevant queues directly. This could result in some unnecessary wakeups but I think it's very uncommon to be using more than one queue per worker in a given workload, so checking all three queues is a waste of cycles. Reviewed by: jhb Sponsored by: Ampere Computing Submitted by: Klara, Inc. MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28194 commit 7509b677b413b9551c15b483ec2ed9ce655d2455 Author: Mark Johnston Date: Mon Feb 8 09:19:10 2021 -0500 armv8crypto: Extract GCM state into a structure This makes it easier to refactor the GCM code to operate on crypto_buffer_cursors rather than plain contiguous buffers, with the aim of minimizing the amount of copying and zeroing done today. No functional change intended. Reviewed by: jhb MFC after: 1 week Sponsored by: Ampere Computing Submitted by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D28500 commit 0dc7076037a87100060309f7179ef6a01f32f99e Author: Mark Johnston Date: Mon Feb 8 09:19:07 2021 -0500 armv8crypto: Fix some edge cases in the AES-GCM implementation - We were only hashing up to the first 16 bytes of the AAD. - When computing the digest during decryption, handle the case where len == trailer, i.e., len < AES_BLOCK_LEN, properly. While here: - trailer is always smaller than AES_BLOCK_LEN, so remove a pair of unnecessary modulus operations. - Replace some byte-by-byte loops with memcpy() and memset() calls. In particular, zero the full block before copying a partial block into it since we do that elsewhere and it means that the memset() length is known at compile time. Reviewed by: jhb Sponsored by: Ampere Computing Submitted by: Klara, Inc. MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28501 commit b5aa9ad43aead288dca0eb94fb4621991917f4e1 Author: Mark Johnston Date: Mon Feb 8 09:19:02 2021 -0500 ktls: Make configuration sysctls available as tunables Reviewed by: gallatin, jhb Sponsored by: Ampere Computing Submitted by: Klara, Inc. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28499 commit 1755b2b9891bb1bfa7a58383ef5126821f7e46e3 Author: Mark Johnston Date: Mon Feb 8 09:18:51 2021 -0500 ktls: Use COUNTER_U64_DEFINE_EARLY This makes it a bit more straightforward to add new counters when debugging. No functional change intended. Reviewed by: jhb Sponsored by: Ampere Computing Submitted by: Klara, Inc. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28498 commit 45d75e3ac3fb5bf8230ca28dc09b48c6e5ed7a4f Author: Lutz Donnerhacke Date: Sun Feb 7 22:07:34 2021 +0100 netgraph/ng_base: Allow larger BINARY2ASCII conversions Allocate the necessary memory for the conversion dynamically starting with a value which is sufficient for almost all normal cases. PR: 187835 Reviewed by: kp Differential Revision: https://reviews.freebsd.org/D23840 commit fb8c2f743ab695f6004650b58bf96972e2535b20 Author: Edward Tomasz Napierala Date: Mon Feb 8 10:46:29 2021 +0000 arm64: optimize set_syscall_retval() Microoptimize set_syscall_retval() for arm64 by predicting the return value to be zero. This is similar to what has been done for other architectures Reviewed By: emaste, mhorne Differential Revision: https://reviews.freebsd.org/D26991 commit 866c8b8d5ddb982c2b8139153a4ddfdb2aac3364 Author: Daniel Ebdrup Jensen Date: Mon Feb 8 07:49:32 2021 +0100 kldload(8): Add note about using kld_list in rc.conf(5) While here, also recommend that loader.conf(5) should only be used in order to get to mountroot, as rc(8) is less fragile, faster, and is easier to fix by booting to single-user mode instead of having to blacklist modules in the loader. MFH: 2 weeks commit 07e8f560fb53b7a47bc88a94c8aed1333d434686 Author: Glen Barber Date: Fri Feb 5 11:46:49 2021 -0500 release: disable the 'reldoc' target after the ASCIIDoctor switch The 'reldoc' target includes release-related documentation on installation medium. Since the switch from XML to ASCIIDoctor, the file locations have moved, and it will take some time to sort out how this target should work now. Approved by: re (kib) Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit 7b1d1a1658ffb69eff93afc713f9e88ed8b20eac) (cherry picked from commit 606bf913f9a33a47005efcac84a430ffb7ec4778) commit 741627c88bb1d8882a9120ed336d10c855f69e22 Author: Konstantin Belousov Date: Wed Feb 3 14:19:12 2021 +0200 amd64 GENERIC: compile in mlx5en(4) Approved by: re (gjb) (cherry picked from commit 5832a3e398642f721381dc2bdc8e954ae43c17a7) commit bb79ec97e5b6fae5329015135cfc1ff22afe100d Author: Konstantin Belousov Date: Fri Feb 5 03:00:27 2021 +0200 cpucontrol(8): Fix display. Approved by: re (gjb) (cherry picked from commit 856789c123d69de86684c5aa1ad8a53427dd47fc) commit b3c6fe663bb90240f8bda6b5ba9c6a761f09f078 Author: Vladimir Kondratyev Date: Mon Feb 8 02:46:14 2021 +0300 epoll: Store epoll_event udata member in ext member of kevent. Current epoll implementation stores udata fields of epoll_event structure in special dynamically-sized table rather than in udata field of backing kevent structure because of 2 reasons: 1. Kevent's udata size is smaller than epoll's on 32-bit archs. 2. Kevent's udata can be clobbered on execution EPOLL_CTL_ADD as kqueue modifies existing event while epoll returns error in this case. After r320043 has introduced four new 64bit user data members (ext[]), we can store epoll udata in one of them and drop aforementioned table. According to kqueue_register() source code ext members are not updated when existing kevent is modified that fixes p.2. As a side effect the patch fixes PR/252582. Reviewed by: trasz MFC after: 1 month Differential revision: https://reviews.freebsd.org/D28169 commit d26f2a50ff48dacd38ba358d658882d51f7bdbc4 Author: Brandon Bergren Date: Sun Feb 7 16:05:41 2021 -0600 powerpc64: Fix boot on virtual-mode OF (PowerMac G5) In 78599c32efed3247d165302a1fbe8d9203e38974, CFI endproc decoration was added to locore64.S. However, it missed the subtle detail that __restartkernel_virtual() falls through to __restartkernel(). This was causing boot failure on PowerMac G5, as it tried to execute the epilogue as code. Fix this by branching to __restartkernel() instead of intentionally running off the end of the function. While here, add some additional notes on how the virtual mode restart works. MFC after: 3 days commit e44a78ce6f249f1eb7df94cb6953698953ebd88b Author: Edward Tomasz Napierala Date: Sun Feb 7 20:28:35 2021 +0000 linux: add support for SO_PEERSEC getsockopt It returns "unconfined", like Linux without SELinux would. Sponsored By: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D28164 commit 6117aa58fa4f5891badf58b13c759976983f4f04 Author: Lutz Donnerhacke Date: Wed Jan 13 23:18:55 2021 +0100 netgraph/ng_bridge: Make simple internal functions read-only The data path in netgraph is designed to work on an read only state of the whole netgraph network. Currently this is achived by convention, there is no technical enforcment. In the case of NETGRAPH_DEBUG all nodes can be annotated for debugging purposes, so the strict enforcment needs to be lifted for this purpose. This patch is part of a series to make ng_bridge multithreaded, which is done by rewrite the data path to operate on const. Reviewed By: kp MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28141 commit cef689f45b9d5785ede463bcd23fea51bc1143ed Author: Lutz Donnerhacke Date: Sun Feb 7 17:39:35 2021 +0100 Revert "netgraph/ng_bridge: Make simple internal functions read-only" Patch mass breaks LINT kernels. This reverts commit bb67e52db143b699bdac1830717930b26a7b5766. commit bb67e52db143b699bdac1830717930b26a7b5766 Author: Lutz Donnerhacke Date: Wed Jan 13 23:18:55 2021 +0100 netgraph/ng_bridge: Make simple internal functions read-only The data path in netgraph is designed to work on an read only state of the whole netgraph network. Currently this is achived by convetion, there is no technical enforcment. This patch is part of a series to make ng_brigde multithreaded, which is done by rewrite the data path to const handling. Reviewed By: kp MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28141 commit ed0a1527507e916c78e6937bcc4061bb81fd9da8 Author: Lutz Donnerhacke Date: Sat Feb 6 23:09:52 2021 +0100 netgraph/ng_bridge: Remove old table ABI This was announced to happen after the 12 relases. Remove a depeciated ABI. The complete removal is for HEAD only. I'll remove the #define in stable/13 as MFC, so the code will still exist in 13.x, but will not included by default. Earlier versions will not be affected. Reviewed by: kp MFC after: 5 days Differential Revision: https://reviews.freebsd.org/D28518 commit 7b51ac027529b698a1fc07f31963a8754b7117c4 Author: Nuno Eduardo Simões Leal Teixeira Date: Sun Feb 7 13:46:13 2021 +0000 Update Mentor and Mentee Information (eduardo) commit f6e8256a965d5b7a7d43034ea31b2430a3b51066 Author: Edward Tomasz Napierala Date: Fri Feb 5 17:24:23 2021 +0000 linux: fix handling of flags for 32 bit send(2) syscall Previously the flags were passed as-is, which could resulted in spurious EAGAIN returned for non-blocking sockets, which broke some Steam games. PR: 248065 Reported By: Alex S Tested By: Alex S Reviewed By: emaste MFC After: 3 days Sponsored By: The FreeBSD Foundation commit 8af54bdfcaecf922f936a14d1d9efcf84076029f Author: Emmanuel Vadot Date: Sat Feb 6 20:41:39 2021 +0100 lastcomm(1): Only install if MK_ACCT is on MFC after: 3 days commit 66c72859f66dc6c852234589f3508ce5d36d0336 Author: Lutz Donnerhacke Date: Wed Jan 13 07:16:34 2021 +0100 netgraph/ng_bridge: switch stats to counter framework This is the first patch of a series of necessary steps to make ng_bridge(4) multithreaded. Reviewed by: melifaro (network), afedorov MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D28125 commit c869d905baa4e329dfd6793e7487b5985248ddb6 Author: Lutz Donnerhacke Date: Sat Feb 6 11:25:04 2021 +0100 netgraph/ng_bridge: Derive forwarding mode from first attached hook Handling of unknown MACs on an bridge with incomplete learning capabilites (aka uplink ports) can be defined in different ways. The classical approach is to broadcast unicast frames send to an unknown MAC, because the unknown devices can be everywhere. This mode is default for ng_bridge(4). In the case of dedicated uplink ports, which prohibit learning of MAC addresses in order to save memory and CPU cycles, the broadcast approach is dangerous. All traffic to the uplink port is broadcasted to every downlink port, too. In this case, it's better to restrict the distribution of frames to unknown MAC to the uplink ports only. In order to keep the chance small and the handling as natural as possible, the first attached link is used to determine the behaviour of the bridge: If it is an "uplink" port, then the bridge switch from classical mode to restricted mode. Reviewed By: kp Approved by: kp (mentor) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28487 commit 689561d4032233bc171cff30d6756c3cf3b22720 Author: Lutz Donnerhacke Date: Fri Feb 5 22:24:06 2021 +0100 ng_bridge.4: Use more suitable mandoc macros yuripv@ suggested to replace inapprobriate macros by better ones. Reviewed by: philip Approved by: philip (mentor) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28510 commit f961caf2184c94d6f59c8d522207156b3533d977 Author: Lutz Donnerhacke Date: Sat Feb 6 11:08:24 2021 +0100 netgraph/ng_bridge: Introduce "uplink" ports without MAC learning The ng_bridge(4) node is designed to work in moderately small environments. Connecting such a node to a larger network rapidly fills the MAC table for no reason. It even become complicated to obtain data from the gettable message, because the result is too large to transmit. This patch introduces, two new functionality bits on the hooks: - Allow or disallow MAC address learning for incoming patckets. - Allow or disallow sending unknown MACs through this hook. Uplinks are characterized by denied learing while sending out unknowns. Normal links are charaterized by allowed learning and sending out unknowns. Reviewed by: kp Approved by: kp (mentor) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D23963 commit 344f1083e128d8d41ca31853dac513ca3efd9d1f Author: Cy Schubert Date: Fri Feb 5 06:26:04 2021 -0800 ipfilter: Use the softn (NAT softc) host map size in ip_nat6 calculation. The ipfilter NAT table host map size is a tunable that defaults to a macro value defined at build time. HOSTMAP_SIZE is saved in softn (the ipnat softc) at initialization. It can be tuned (changed) at runtime using the ipf -T command. If the hostmap_size tunable is adjusted the calculation to determine where to put new entries in the table was incorrect. Use the tunable in the NAT softc instead of the static build time value. MFC after: 1 week commit 10990cb46027b4cc4339540b1217117863b2cd15 Author: Cy Schubert Date: Tue Feb 2 19:24:05 2021 -0800 Simplify FreeBSD check. MFC after: 1 week commit e673debe7db8ba95e4ee3b549d2570e71d19b596 Author: Cy Schubert Date: Tue Feb 2 19:18:48 2021 -0800 Simplify BSD macro tests. All FreeBSD and NetBSD are BSD >= 199306 and have been for a long time. MFC after: 1 week commit 8b804ee616b4c8810015b69e37e31ef0c4161511 Author: Piotr Kubaj Date: Sat Feb 6 03:21:55 2021 +0100 powerpc64le: readd COMPAT_FREEBSD11 and COMPAT_FREEBSD12 lang/rust needs COMPAT_FREEBSD11 to build, even though powerpc64le itself is supported only since 13.0. I also corrected a comment, because if we ever have lib32 for powerpc64le, it will be for powerpcle. Reviewed by: bdragon (on IRC) commit 9fb4377f4102c02207b4231af76b0e9522fe1230 Author: John Baldwin Date: Thu Feb 4 13:47:26 2021 -0800 Regenerate src.conf(5). Approved by: re (gjb) (cherry picked from commit ab537343065a6925e62001165a4743a17e050118) commit b494fc41b79c9fe1b48a19c28969a7e663a3f86d Author: John Baldwin Date: Thu Feb 4 13:40:25 2021 -0800 Disable MK_OPENSSL_KTLS for stable/13. Due to the pending release of 13.0 and the recent bug in serf exposed by the KTLS changes, disable OpenSSL's KTLS by default. This keeps crypto/openssl in sync with main while lowering the risk of introducing instability into 13.0. Approved by: re (gjb) Discussed with: gjb (re), jkim, emaste (secteam) (cherry picked from commit 3cf25a7802a26ae3be9159c585fda6aea3d0dc08) commit 25a4522f88d2def4e3ef497dad3c491ac9afc9c7 Author: Jung-uk Kim Date: Tue Jan 26 14:26:51 2021 -0800 OpenSSL: Regenerate manual pages. Approved by: re (gjb) (cherry picked from commit bb8acd558e66bd4bae31602fcbe569863f47382c) (cherry picked from commit 3e09120f7984c990530d6e6860941ffb1e281f8b) commit afdbccbf4017c17eed95640bd9daad743388a22b Author: John Baldwin Date: Fri Jan 15 16:17:31 2021 -0800 OpenSSL: Support for kernel TLS offload (KTLS) This merges upstream patches from OpenSSL's master branch to add KTLS infrastructure for TLS 1.0-1.3 including both RX and TX offload and SSL_sendfile support on both Linux and FreeBSD. Note that TLS 1.3 only supports TX offload. A new WITH/WITHOUT_OPENSSL_KTLS determines if OpenSSL is built with KTLS support. It defaults to enabled on amd64 and disabled on all other architectures. Approved by: re (gjb) Sponsored by: Netflix (cherry picked from commit aa906e2a4957db700d9e6cc60857e1afe1aecc85) (cherry picked from commit c1c52cd57e8810ca294d02220dfa72607c9a5567) commit e45bb3902e80da374500a3dc077d7d11cfb3d6ba Author: John Baldwin Date: Mon Feb 1 17:09:33 2021 -0800 Bump shared library versions after ncurses bump in 13. A few shared libraries in the base system link against ncurses. An upgrade from a 12.x host to 13 results in ABI breakage for existing binaries since the newer versions of these libraries link against the newer ncurses while the binary itself links against the older ncurses. For example, dialog4ports built on 12.x sometimes crashes on 13 since it depends on libdialog which links against ncurses internally. Approved by: re (gjb) (cherry picked from commit 0b7f1af804f06a285717b490bef80e24648adcbe) (cherry picked from commit 6e1fe6d26ea2939656c8286ccbd105a89d3349a3) commit 2f8a844635312b0f25028a87459fdd2d2a1cbfd6 Author: Mateusz Guzik Date: Sat Feb 6 00:16:55 2021 +0100 cache: remove the largely obsolete general description Examples of inconsistencies with the current state: - references LRU of all entries, removed years ago - references a non-existent lock (neglist) - claims negative entries have a NULL target It will be replaced with a more accurate and more informative description. In the meantime take it out so it stops misleading. commit 0e1594e60e5e0b1fddc33225171f1d1c6a421ed4 Author: Mateusz Guzik Date: Fri Feb 5 23:58:27 2021 +0100 cache: fix vfs:namecache:lookup:miss probe call sites commit 2e96132a7d8bbb2347a3b4776806324f984aa49f Author: Mateusz Guzik Date: Fri Feb 5 23:49:59 2021 +0100 cache: drop spurious arg from panic in cache_validate vp is already reported when noting mismatch commit b54ed778fe45d482bd1e2009df802fda26f94495 Author: Mateusz Guzik Date: Wed Feb 3 21:44:54 2021 +0100 cache: comment on FNV commit b94f25eb626fadba144e9b9e8d08b83ba22134d7 Author: Alfredo Dal'Ava Junior Date: Fri Feb 5 15:43:48 2021 -0300 mrsas: unbreak i386 build Fix build regression introduced by e34a057ca6ebdf8e30ec8b0dc21d18eb450bf36a Approved by: re (gjb) Reviewed by: jhibbits Sponsored by: Eldorado Research Institute (eldorado.org.br) Differential Revision: https://reviews.freebsd.org/D28494 (cherry picked from commit 59fffbcf46ba6369420e655ff9173571410c643d) (cherry picked from commit 6bf9668d9d02bdf3e0dafc4ba1010ef6a9b12247) commit 92d0d6bb14d24abea0786edf546af316ff4a2afe Author: Alexander Motin Date: Fri Feb 5 16:13:55 2021 -0500 Print DeviceHandle and PhysicalId in hex. The first is actually a bitfield. The second is printed in hex by dmidecode, so uniformidy should be good. MFC after: 1 week commit eaffd270d8729c4d79f6ce268275ef4c0e6f7b04 Author: Alfredo Dal'Ava Junior Date: Thu Feb 4 03:12:38 2021 -0300 [POWERPC64LE] add mrsas to GENERIC64LE Reviewed by: bdragon Sponsored by: Eldorado Research Institute (eldorado.org.br) MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28475 commit 20e1817f9a68abd9a232367e04d2afeaf4a3c2f8 Author: Alfredo Dal'Ava Junior Date: Thu Feb 4 03:13:13 2021 -0300 mrsas: update man page update mrsas(4) since big-endian is supported since e34a057ca6ebdf8e30ec8b0dc21d18eb450bf36a Reviewed by: bdragon, gbe Sponsored by: Eldorado Research Institute (eldorado.org.br) MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28475 commit 7b1d1a1658ffb69eff93afc713f9e88ed8b20eac Author: Glen Barber Date: Fri Feb 5 11:46:49 2021 -0500 release: disable the 'reldoc' target after the ASCIIDoctor switch The 'reldoc' target includes release-related documentation on installation medium. Since the switch from XML to ASCIIDoctor, the file locations have moved, and it will take some time to sort out how this target should work now. MFC after: 3 days Sponsored by: Rubicon Communications, LLC ("Netgate") commit 90da2c797bfa7639005ed46ab9173feb8bd85ecd Author: Mark Johnston Date: Fri Feb 5 11:28:09 2021 -0500 truss: Decode sendfile(2) arguments MFC after: 2 weeks commit 59fffbcf46ba6369420e655ff9173571410c643d Author: Alfredo Dal'Ava Junior Date: Fri Feb 5 15:43:48 2021 -0300 mrsas: unbreak i386 build Fix build regression introduced by e34a057ca6ebdf8e30ec8b0dc21d18eb450bf36a Reviewed by: jhibbits Sponsored by: Eldorado Research Institute (eldorado.org.br) Differential Revision: https://reviews.freebsd.org/D28494 commit 35e39fd95fda64699b638192f3bab955d0f1cf0c Author: Alexander Motin Date: Fri Feb 5 10:07:37 2021 -0500 Improve ACPI_NFIT_CONTROL_REGION formatting. MFC after: 1 week commit 3279329b2dca12b6f882db7a295b9e790c82f968 Author: Mark Johnston Date: Fri Feb 5 09:44:47 2021 -0500 tools/git: Add git-arc This is a handy script for creating and updating Differential revisions from git commits. It tries to avoid forcing the user to manage their git tree in any particular way, but makes two major assumptions: - there is a one-to-one mapping between git commits and Differential revisions, - the title of a Differential revision is the same as the summary line of the corresponding commit. A verbose description of the script's functionality is provided in its usage message, which should probably be converted to a man page. A description of workflows using git-arc is here: https://lists.freebsd.org/pipermail/freebsd-hackers/2021-January/056979.html There are some loose ends but this is functional enough to be useful. Discussed with: jhb Differential Revision: https://reviews.freebsd.org/D28334 commit 13ec5a6da04b14c4d40d3b37335dfaef7469aeb5 Author: Andrew Turner Date: Fri Feb 5 10:50:29 2021 +0000 Add support for arm64 nGnRE device memory On arm64 we can select how strongly we order device memory. Currently we use the strongest type of non-Gathering, non-Reordering, no Early write acknowledgement. This is equivalent to VM_MEMATTR_SO in the 32-bit arm code. Create a new memory type to remove the no Early write acknowledgement option to create a memory attribute that is equivalent to the arm VM_MEMATTR_DEVICE. Keep the the old nGnRnE memory as what we provide for VM_MEMATTR_DEVICE until we can test nGnRE on more hardware. A method for dynamically switching back may be needed as at least one vendor is known to have broken nGnRE memory. Sponsored by: Innovate UK commit 2373acbbb77d694b997d90f3251810c6edf5d6d8 Author: Kyle Evans Date: Thu Feb 4 15:35:58 2021 -0600 grep: turn off -w if -x is specified -x overcomes -w in gnugrep, and it should here as well. Flip it off as needed to avoid confusing other parts of grep. commit f823c6dc730b0dd08b54a53be1d8fd587eee7021 Author: Kyle Evans Date: Thu Feb 4 15:26:45 2021 -0600 grep: fix null pattern and empty pattern file behavior The null pattern semantics were terrible because I tried to match gnugrep, but I got it wrong. Let's unwind that: - The null pattern should match every line if neither -w nor -x. - The null pattern should match empty lines if -x. - The null pattern should not match any lines if -w. The first two will stop processing (shortcut) even if additional patterns are specified. In any other case, we will continue processing other patterns. If no other patterns are specified beside a null pattern, then we match if neither -w nor -x or set and do not match if either of those are specified. The justification for -w is that it should match on a whole word, but the null pattern deos not have a whole word to match on. Empty pattern files should never match anything, and more importantly, -v should cause everything to be written. PR: 253209 MFC-after: 4 days commit 856789c123d69de86684c5aa1ad8a53427dd47fc Author: Konstantin Belousov Date: Fri Feb 5 03:00:27 2021 +0200 cpucontrol(8): Fix display. Sponsored by: The FreeBSD Foundation MFC after: 3 days commit 5832a3e398642f721381dc2bdc8e954ae43c17a7 Author: Konstantin Belousov Date: Wed Feb 3 14:19:12 2021 +0200 amd64 GENERIC: compile in mlx5en(4) Reviewed by: hselasky, manu Sponsored by: NVidia Networking/Mellanox Technologies MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28469 commit 375d797b81916eb3d16927c9dac8c42975784252 Author: Ed Maste Date: Thu Feb 4 19:14:12 2021 -0500 Enable pvscsi and vmx in arm64 GENERIC FreeBSD pvscsi and vmx work with VMware ESXi Arm "Fling"; provide these in GENERIC for a convenient out-of-the-box experience. PR: 253202 Reported by: Vincent Milum Jr MFC after: 3 days Sponsored by: The FreeBSD Foundation commit 638e531019fd360ec43d2662c89d12ae632f168f Author: Glen Barber Date: Thu Feb 4 18:58:51 2021 -0500 Branch releng/13.0 Update releng/13.0 to BETA1 in preparation for the first BETA builds. Approved by: re (implicit) Sponsored by: Rubicon Communications, LLC ("Netgate") commit 7d4dceec103039e2b2fa90793ceeb71a8d6684aa Author: Krzysztof Galazka Date: Wed Feb 3 15:22:55 2021 -0800 ixl(4): Fix VLAN HW filtering X700 family of controllers has limited number of available VLAN HW filters. Driver did not handle properly a case when user assigned more VLANs to the interface which had all filters already in use. Fix that by disabling HW filtering when it is impossible to create filters for all requested VLANs. Keep track of registered VLANs using bitstring to be able to re-enable HW filtering when number of requested VLANs drops below the limit. Also switch all allocations to use M_IXL malloc type to ease detecting memory leaks in the driver. Reviewed by: erj Tested by: gowtham.kumar.ks@intel.com MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28137 commit 4c44dbde5491516eba8725dc51d39c1dcc817472 Author: Jamie Gritton Date: Thu Jan 28 21:51:09 2021 -0800 MFC jail: Handle a parent jail when a child is added to it It's possible when adding a jail that its dying parent comes back to life. Only allow that to happen when JAIL_DYING is specified. And if it does happen, call PR_METHOD_CREATE on it. (cherry picked from commit c050ea803eaa1087313b86628b5d486c0e59e41b) commit 7726fc9940d688af35753a374391de48bad1e1ca Author: Jamie Gritton Date: Fri Jan 22 10:56:24 2021 -0800 MFC jail: fix dangling reference bug from 6754ae2572eb The change to use refcounts for pr_uref was mishandled in prison_proc_free, so killing a jail's last process could add an extra reference, leaving it an unkillable zombie. (cherry picked from commit 195cd6ae2481dd5ad555ed65c226b6f20908d66a) commit 3f3b216c0b4b90e02b5637f5b07cc9446e1bcee7 Author: Jamie Gritton Date: Fri Jan 22 10:50:10 2021 -0800 MFC jail: A jail could be removed without calling OSD methods Fix a long-standing bug where setting nopersist on a process-less jail would remove it without calling the the OSD PR_METHOD_REMOVE methods. (cherry picked from commit 39c8ef90f6d035cd3c3ab40e051b1c0f419c76be) commit 211afd1e2391ba5aa7a7a5af5b4b7d71d404d15e Author: Alexander V. Chernikov Date: Sun Jan 31 10:48:47 2021 +0000 MFC 78c93a172114: Use process fib for inet/inet6 fib_algo sysctls. This allows to set/query fib algo for non-default fibs. commit 6bc5d49aba14c6ce102d4392cd53bcdf8b61c2fc Author: Alexander V. Chernikov Date: Sat Jan 30 22:45:46 2021 +0000 MFC 151ec796a230: Fix the design problem with delayed algorithm sync. Currently, if the immutable algorithm like bsearch or radix_lockless receives rtable update notification, it schedules algorithm rebuild. This rebuild is executed by the callout after ~50 milliseconds. It is possible that a script adding an interface address and than route with the gateway bound to that address will fail. It can happen due to the fact that fib is not updated by the time the route addition request arrives. Fix this by allowing synchronous algorithm rebuilds based on certain conditions. By default, these conditions assume: 1) less than net.route.algo.fib_sync_limit=100 routes 2) routes without gateway. * Move algo instance build entirely under rib WLOCK. Rib lock is only used for control plane (except radix algo, but there are no rebuilds). * Add rib_walk_ext_locked() function to allow RIB iteration with rib lock already held. * Fix rare potential callout use-after-free for fds by binding fd callout to the relevant rib rmlock. In that case, callout_stop() under rib WLOCK guarantees no callout will be executed afterwards. commit 2a3cbb6c8954b71ee5bcd49cd2d05e41b960975d Author: Alexander V. Chernikov Date: Sat Jan 30 21:52:44 2021 +0000 MFC dd9163003cb1: Add rib_subscribe_locked() and rib_unsubsribe_locked() to support subscriptions during RIB modifications. Add new subscriptions to the beginning of the lists instead of the end. This fixes the situation when new subscription is created int the callback for the existing subscription, leading to the subscription notification handler pick it. commit f5f50ec15688d6aab67d3fb8fb0c98b89e4dbce0 Author: Alexander V. Chernikov Date: Sat Jan 30 22:32:42 2021 +0000 MFC ab6d9aaed76e: Move business logic from rebuild_fd_callout() into rebuild_fd(). This simplifies code a bit and allows for future non-callout callers to request rebuild. commit 74216f4caef2a4772c2903a04ac2843278fe00a8 Author: Alexander V. Chernikov Date: Sat Jan 30 22:06:40 2021 +0000 MFC f8b7ebea4905: Improve fib_algo debug messages. * Move per-prefix debug lines under LOG_DEBUG2 * Create fib instance counter to distingush log messages between instances * Add more messages on rebuild reason. MFC after: 3 days commit 10977b9f84352c7312a192e99f03dc155db79c54 Author: Alexander V. Chernikov Date: Sat Jan 30 23:24:26 2021 +0000 MFC 91f2c69ec206: Fix unused-function waring when compiling with FIB_ALGO. commit 88452cb1515550b5a9eb78ed2d88c97d09a57ee4 Author: Alexander V. Chernikov Date: Fri Jan 29 23:10:52 2021 +0000 MFC cb984c62d705: Fix multipath support for rib_lookup_info(). The initial plan was to remove rib_lookup_info() before FreeBSD 13. As several customers are still remaining, fix rib_lookup_info() for the multipath use case. commit 8efe1ef1c7415c17899e6d1b5e1984bb3a95c55b Author: Alexander V. Chernikov Date: Tue Jan 26 07:22:23 2021 +0000 MFC 53729367d388: Fix subinterface vlan creation. D26436 introduced support for stacked vlans that changed the way vlans are configured. In particular, this change broke setups that have same-number vlans as subinterfaces. Vlan support was initially created assuming "vlanX" semantics. In this paradigm, automatic number assignment supported by cloning (ifconfig vlan create) was a natural fit. When "ifaceX.Y" support was added, allowing to have the same vlan number on multiple devices, cloning code became more complex, as the is no unified "vlan" namespace anymore. Such interfaces got the first spare index from "vlan" cloner. This, in turn, led to the following problem: ifconfig ix0.333 create -> index 1 ifconfig ix0.444 create -> index 2 ifconfig vlan2 create -> allocation failure This change fixes such allocations by using cloning indexes only for "vlanX" interfaces. Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D27505 commit 87cefd5c3dc6e52609be1b01087b33511f1d16a8 Author: Alexander V. Chernikov Date: Wed Feb 3 08:49:46 2021 +0000 MFC eb0b1b33: Enable multipath routing by default. ROUTE_MPATH was added to the GENERIC kernel in r368648. According to the plan in D27428, it was enabled with `net.route.multipath` sysctl set to 0. Given enough time has passed, this change enables route multipath by default. The goal is to ship FreeBSD 13 with multipath turned on. Reviewed By: donner, olivier Relnotes: yes Differential Revision: https://reviews.freebsd.org/D28423 commit 0c839497c174e961fc71f7d3329d05b10ec5525b Author: Toomas Soome Date: Thu Feb 4 22:49:02 2021 +0200 loader.efi: There are systems without ConOut, also use ConOutDev Conout does contian the default output device name. ConOutDev does contain all possible output device names, so we can use it as fallback, when there is no ConOut. PR: 253253 (cherry picked from commit 2bd4ff2d8911009283e4e615ca4aad35a845f48b) commit 2bd4ff2d8911009283e4e615ca4aad35a845f48b Author: Toomas Soome Date: Thu Feb 4 22:49:02 2021 +0200 loader.efi: There are systems without ConOut, also use ConOutDev Conout does contian the default output device name. ConOutDev does contain all possible output device names, so we can use it as fallback, when there is no ConOut. PR: 253253 commit aa77662373e378c05dfe9ce328be60bd792b5354 Author: Muhammad Moinur Rahman Date: Thu Feb 4 21:05:47 2021 +0000 Add a comment notifying that "device axp" requires miibus for build. Although if RJ-45 interface is not being used the miibus is not required but miibus is a build time dependency. Reviewed by: imp, manu, rajesh1.kumar@amd.com Approved by: imp, manu, rajesh1.kumar@amd.com Differential Revision: https://reviews.freebsd.org/D28465 commit 6d4bc364ab5ae7559caef8c6e62a8d26694e6bde Author: Vladimir Kondratyev Date: Fri Jan 29 00:35:11 2021 +0300 hsctrl: Fix manpage typo Use hsctrl_load to load the module at boot time. Submitted by: Shunchao Hu Reviewed by: wulf Differential revision: https://reviews.freebsd.org/D28343 (cherry picked from commit 5c689e213614bff65e9789875f839aa05053126b) commit 31026a4677d0bbfc55433ba4f375700ec919e3bf Author: Vladimir Kondratyev Date: Sat Jan 23 22:19:50 2021 +0300 hcons: Fix manpage typo Submitted by: Shunchao Hu Reviewed by: wulf, gbe Differential revision: https://reviews.freebsd.org/D28294 (cherry picked from commit 0d528e6354141dd097f8719e858b3ae3686d2062) commit 06eda1d83cbb80eb05711cfa5509b6b0df580973 Author: Glen Barber Date: Tue Feb 2 12:19:36 2021 -0500 release: update workaround during transition to git PR: 253181 Submitted by: Yasuhiro Kimura Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit 70dfc101b6324b25ba353465f0d6c610399741fc) commit 8a06ca2f734c726799688d65a7dad67284275438 Author: Ryan Stone Date: Fri Jan 29 15:48:50 2021 -0500 Fix mismerge in OFED update When OFED was upgraded to Linux v4.9, a bunch of Linux-specific netlink changes were dropped. Unfortunately, there was a mismerge in this process and as a result ib_sa_cancel_query() would fail to cancel an outstanding MAD. This was causing rdma_destroy_id() to hang indefinitely waiting for the MAD to complete and release the final reference. Sponsored by: Dell Inc. Differential Revision: https://reviews.freebsd.org/D28421 Reviewed by: hselasky, kib MFC after: 2 months commit b58cf1cb35abc095d7fb9773630794b38bbc6b1d Author: Ryan Stone Date: Thu Jan 7 12:25:56 2021 -0500 Fix race condition in linuxkpi workqueue Consider the following scenario: 1. A delayed_work struct in the WORK_ST_TIMER state. 2. Thread A calls mod_delayed_work() 3. Thread B (a callout thread) simultaneously calls linux_delayed_work_timer_fn() The following sequence of events is possible: A: Call linux_cancel_delayed_work() A: Change state from TIMER TO CANCEL B: Change state from CANCEL to TASK B: taskqueue_enqueue() the task A: taskqueue_cancel() the task A: Call linux_queue_delayed_work_on(). This is a no-op because the state is WORK_ST_TASK. As a result, the delayed_work struct will never be invoked. This is causing address resolution in ib_addr.c to stop permanently, as it never tries to reschedule a task that it thinks is already scheduled. Fix this by introducing locking into the cancel path (which corresponds with the lock held while the callout runs). This will prevent the callout from changing the state of the task until the cancel is complete, preventing the race. Differential Revision: https://reviews.freebsd.org/D28420 Reviewed by: hselasky MFC after: 2 months commit 1fb5b2860444ba8954abcf14a4e2f5f1ddd2fcd3 Author: Doug Ambrisko Date: Thu Jan 28 15:12:14 2021 -0800 VMD support for new devices. Add support for some more Intel VMD controllers. Some of the newer controller have a sparce bus space that can be figured out by probing the HW. This gives the starting bus number. When reading the PCI config. space behind the VMD controller, the offset of the starting bus needs to be subtracted from the bus being read. Fixed a bug in which in which not all of the devices directly attached to the VMD controller would be probed. On my initial test HW, a switch was found at bus 0, slot 0 and function 0. All of the NVME drives were behind that switch. Now scan for all slots and functions attached to bus 0. If a something was found then run attach after the scan. On detach also go through all slots and functions on bus 0. Tested with device ID's: 0x201d & 0x9a0b Tested by: nc@ MFC: 5c689e21361 PR: 252253 (cherry picked from commit 0c852bb9b9282b30fd047ac1de398358f33777f4) commit 1a2bc12c4b2563628f329e2e971d1619e0240429 Author: Mateusz Guzik Date: Mon Feb 1 04:00:13 2021 +0100 x86: use compiler intrinsics for bswap* (cherry picked from commit e6ff6154d2034c13f3d0da73c1e00d69fdb36516) commit 6d3ce617f398d4066780555210270b97c30e7c0e Author: Mateusz Guzik Date: Mon Feb 1 00:35:30 2021 +0100 amd64: use compiler intrinsics for bsf* and bsr* (cherry picked from commit aae89f6f09576351cc3a9a54959649e60fdd849b) commit 2edd6140e9a157b5493cb287e30f8a15038eb95e Author: Mateusz Guzik Date: Sun Jan 31 21:54:35 2021 +0100 cache: add delayed degenerate path handling (cherry picked from commit 6f19dc2124a31aadf419743288d2ec1abd895563) commit 55764c48f5f8535d8441764d392bb90dd6a6c9e0 Author: Mateusz Guzik Date: Sun Jan 31 19:25:18 2021 +0100 cache: move hash computation into the parsing loop (cherry picked from commit bbfb1edd70e15241d852d82eb7e1c1049a01b886) commit 88a580ebeea10e7bf9eb823dbbf48349eb8da540 Author: Mateusz Guzik Date: Sun Jan 31 16:46:18 2021 +0100 amd64: move memcmp checks upfront This is a tradeoff which saves jumps for smaller sizes while making the 8-16 range slower (roughly in line with the other cases). Tested with glibc test suite. For example size 3 (most common with vfs namecache) (ops/s): before: 407086026 after: 461391995 The regressed range of 8-16 (with 8 as example): before: 540850489 after: 461671032 (cherry picked from commit f1be262ec11c1c35e6485f432415b5b52adb505d) commit 068f2402d28bf2ddee884c83be1dff3a7631569b Author: Mateusz Guzik Date: Sun Jan 31 16:50:34 2021 +0100 amd64: add a note about simd to libc memset, memmove and memcmp (cherry picked from commit 0db6aef407f30c138982b8cde43189aad098b337) commit 1eec5861d52e074bc20d08aef051af59cc70040e Author: Alex Richardson Date: Thu Feb 4 17:48:29 2021 +0000 tests/sys/vfs/lookup_cap_dotdot: No longer aborts after ATF update It appears this test no longer fails after c203bd70b5957f85616424b6fa374479372d06e3. PR: 215690 commit 72692dfdfe7b4ffd894afd67959651ca1b01a105 Author: Alex Richardson Date: Thu Feb 4 17:56:54 2021 +0000 usr.bin/jail: Fix tests when using kyua -v parallelism=N These tests create jails with the same name, so they cannot be run in parallel. Reviewed By: lwhsu Differential Revision: https://reviews.freebsd.org/D28482 commit 58de61b9967b36f5fbd34e8b51ece7b4b772f104 Author: Alex Richardson Date: Thu Feb 4 17:56:26 2021 +0000 sbin/pfctl: fix tests after recent output changes The output now contains http-alt instead of 8080 and personal-agent instead of 5555. This was probably caused by 228e2087a32847fa51168f3f0c58f931cb2cb0f8. Reviewed By: kp Differential Revision: https://reviews.freebsd.org/D28481 commit 397aaa3bcc78196f5c794ebd1de751568562a7a3 Author: Navdeep Parhar Date: Mon Feb 1 03:00:09 2021 -0800 cxgbe(4): Fixes to tx coalescing. - The behavior implemented in r362905 resulted in delayed transmission of packets in some cases, causing performance issues. Use a different heuristic to predict tx requests. - Add a tunable/sysctl (hw.cxgbe.tx_coalesce) to disable tx coalescing entirely. It can be changed at any time. There is no change in default behavior. (cherry picked from commit 3447df8bc5b342bd88d565641435284ff620ee2a) commit 9c829699aa3cae4fa2b736de489c8aac1da068e6 Author: Martin Matuska Date: Mon Feb 1 22:08:19 2021 +0100 zfs: update zfs_config.h to match OpenZFS gf11b09dec Update zfs_config.h to match latest merge in FreeBSD The version string is declared as 2.0.0-FreeBSD_gf11b09dec to provide more information about the loaded module: - the OpenZFS version in base is 2.0 - we are using the in tree-module ("FreeBSD") - the last merged OpenZFS git revision ("gf11b09dec") With future merges the git revision tag should be updated. As we are merging from OpenZFS master branch and already include features like dRAID, referencing patchlevel releases (2.0.1, 2.0.2) is pointless. Reviewed by: freqlabs Differential Revision: https://reviews.freebsd.org/D28447 (cherry picked from commit 8fb966790e1c87276cc26932efee1b29c046cb8a) commit 15443b4d40489c79576a365f88ecd16f97f58bbd Author: Gordon Bergling Date: Wed Feb 3 16:01:32 2021 +0100 wg(4): Add authors of the wg(4) driver to the manual page Glen (@gjb) noticed that I am haven't mentioned the authors of the WireGuard device driver in the manual page. This is commit addressed this. Reviewed by: gjb, brueffer Differential Revision: https://reviews.freebsd.org/D28464 (cherry picked from commit c1b1354789bb15713944f9e6941266de4cb47772) commit 1cb79e809a0f091660df6bc1bc6ed0332563ab7b Author: Gordon Bergling Date: Tue Feb 2 20:16:52 2021 +0100 wg(4): Fix Copyright statement in man page (cherry picked from commit 064e52c2d874abc83dd2af61644d14dc90e26ec3) commit 4295dd589e05de2d20c97381318efd8cd001a6c5 Author: Gordon Bergling Date: Tue Feb 2 20:13:53 2021 +0100 Add a wg(4) manual page Reviewed by: brueffer, donner, debdrup, ygy MFC after: 2 days Differential Revision: https://reviews.freebsd.org/D27783 (cherry picked from commit e59d9cb412846cb5d2bc4c641d3cc44d243cd52d) commit b680dba47653451aeda9292dd6dcda2f79b905e7 Author: Mitchell Horne Date: Wed Jan 27 17:27:15 2021 -0400 riscv: add SBI system reset extension (cherry picked from commit 9bae4ce661c59be88fec89b2531148e36dd1a23e) (cherry picked from commit a6405133b7e14929f8e8e61cf30d7152b1410e59) commit c203bd70b5957f85616424b6fa374479372d06e3 Merge: cb7cc72c546 a3330ae7366 Author: Alex Richardson Date: Thu Feb 4 14:48:10 2021 +0000 Import atf 0.22 snapshot ca73d08c3fc1ecffc1f1c97458c31ab82c12bb01 This includes improvements to the atf-sh helper functions that significantly reduce the number of spawned processes for each test and therefore speeds up running the testsuite noticeably. commit 620455079f47a9d7361b46b965abf273ac6787de Author: Evgeniy Khramtsov <2khramtsov@gmail.com> Date: Mon Feb 1 20:03:57 2021 +0100 ipfw(8) crashes when ext6hdr option is omitted Verify that the option is passed, error out if it's not. The problem can be trivially triggered with `ipfw add allow ext6hdr`. PR: 253169 Reviewed by: kp@ MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28447 (cherry picked from commit 682c31db4ecfb8fc6cac0e8ad4945c03379ea3d1) commit 683d086626cd41a1c22c7ab5cd1c3c52591c5bf7 Author: Jonah Caplan Date: Sat Jan 30 14:54:09 2021 +0100 bridge: fix STP roles and protos strings Add the missing commas that got lost in e5539fb618cc7. PR: 252532 Reviewd by: kp@, donner@, freqlabs@ MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28425 (cherry picked from commit 88be0e11205e4a2dc77e29f7b4a2e82b8d7c9a5c) commit b6cbf02ad87e2aa088aefb3176b94225890ce1b6 Author: Mitchell Horne Date: Thu Feb 4 10:00:11 2021 -0400 src.conf.5: regenerate Direct commit to stable/13. commit 63a3f59066765c251de8cb80bf841b916b4f4061 Author: Mitchell Horne Date: Sat Jan 30 15:04:08 2021 -0400 src.opts.mk: set MK_ZFS conditional on MK_OPENSSL PR: 252841 Reviewed by: kevans, freqlabs (cherry picked from commit e5cc1c47484160969e0a7c13cdbc71081d7dd60e) commit ca9e7ac2fbbbb393a0221ff96ae03f9cac1745b3 Author: Kyle Evans Date: Thu Jan 28 21:01:12 2021 -0600 du: tests: use dollar-single quotes where appropriate No need for "foo$(printf "\t")", $'\t' is both more readable and still functional. (cherry picked from commit bf59049c27ef86669a94ffd43f7216107b5c57ff) commit 37fed6c860035396c306bffb07f2511c12af3f74 Author: Alfredo Dal'Ava Junior Date: Wed Feb 3 22:02:28 2021 -0300 [POWERPC64BE] add mrsas driver to GENERIC64 Submitted by: Andre Fernando da Silva Reviewed by: luporl, alfredo, kadesai (on email) Sponsored by: Eldorado Research Institute (eldorado.org.br) Differential Revision: https://reviews.freebsd.org/D26531 commit d0982de778a678f4558c9444d585689c254f7850 Author: Alfredo Dal'Ava Junior Date: Wed Feb 3 21:52:19 2021 -0300 [POWERPC64BE] mrsas: add big-endian support Add endiannes conversions in order to support big-endian platforms Submitted by: Andre Fernando da Silva Reviewed by: luporl, alfredo, kadesai (on email) Sponsored by: Eldorado Research Institute (eldorado.org.br) Differential Revision: https://reviews.freebsd.org/D26531 commit d37a305bc52fdb6337c012f869fc54dba9408842 Author: Kyle Evans Date: Sat Jan 30 00:09:10 2021 -0600 build: options: mention ports in the WITH_OPENLDAP description There's a third party dependency on this option; currently, net/openldap24-{,sasl-}client. At least mention that an openldap from ports is needed for this option. PR: 252866 (cherry picked from commit 7587d9823a8257b9a2d5b2e58c707026061058c6) commit f31de79df28a75f0ecbac8fc0cd909c5c78eefd0 Author: Kyle Evans Date: Sat Jan 30 00:07:17 2021 -0600 kerberos5: fix the WITH_OPENLDAP build Restore WARNS to its former glory prior to the global WARNS change to fix the build. (cherry picked from commit e948d980f78dd2789060b46d3d03ba0d96b23b59) commit 1535f6701704ef5bc58768490b05cbf0b0958671 Author: Kyle Evans Date: Fri Jan 29 23:48:28 2021 -0600 ofed: fix the WITH_OFED_EXTRA build This option was not tested when WARNS was globally lifted in the src tree up to 6. Drop WARNS back down to unbreak the build; note that this is still enabling more warnings than it had before the WARNS change, so the gcc build may need to be independently evaluated at this level. PR: 252865 (cherry picked from commit 9ca71db4959f674d75f7b4fd0f72bdc1e2e99abb) commit cb7cc72c546e0f87598961c3860e17391f42866c Author: John Baldwin Date: Wed Feb 3 14:59:32 2021 -0800 serf: Fix the default return value of the BIO control method. OpenSSL BIO classes provide an abstraction for dealing with I/O. OpenSSL provides BIO classes for commonly used I/O primitives backed by file descriptors, sockets, etc. as well as permitting consumers of OpenSSL to define custom BIO classes. One of the methods BIO classes implement is a control method invoked by BIO_ctrl() for various ancilliary tasks somewhat analgous to fcntl() and ioctl() on file descriptors. According to the BIO_ctrl(3) manual page, control methods should return 0 for unknown control requests. KTLS support in OpenSSL adds new control requests. Two of those new requests are queries to determine if KTLS is enabled for either reading or writing. These control reuquest return 1 if KTLS is enabled and 0 if it is not. serf includes two custom BIO classes for wrapping I/O requests from files and from a buffer in memory. These BIO classes both use a custom control method. However, this custom control method was returning 1 for unknown or unsupported control requests instead of 0. As a result, OpenSSL with KTLS believed that these BIOs were using KTLS and were thus adding headers and doing encryption/decryption in the BIO. Correcting the return value removes this confusion. PR: 253135 Reported by: Guido Falsi Reviewed by: emaste MFC after: 3 days Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D28472 commit 9fac05ba79a4ea11c7a1ea45fb928da178e2fe95 Author: Alfredo Dal'Ava Junior Date: Wed Feb 3 22:02:28 2021 -0300 [POWERPC64BE] add mrsas driver to GENERIC64 Submitted by: Andre Fernando da Silva Reviewed by: luporl, alfredo, kadesai (on email) Sponsored by: Eldorado Research Institute (eldorado.org.br) Differential Revision: https://reviews.freebsd.org/D26531 commit e34a057ca6ebdf8e30ec8b0dc21d18eb450bf36a Author: Alfredo Dal'Ava Junior Date: Wed Feb 3 21:52:19 2021 -0300 [POWERPC64BE] mrsas: add big-endian support Add endiannes conversions in order to support big-endian platforms Submitted by: Andre Fernando da Silva Reviewed by: luporl, alfredo, kadesai (on email) Sponsored by: Eldorado Research Institute (eldorado.org.br) Differential Revision: https://reviews.freebsd.org/D26531 commit 847dfd2803f6c8b077e3ebc68e35adff2c79a65f Author: Ed Maste Date: Tue Feb 2 09:35:04 2021 -0500 readelf: do not trucate section name with -W PR: 246015 Reviewed by: cem Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D28461 commit e79b51e2b2e35d6256a1ef5311ce02ec4032d21f Author: Ed Maste Date: Wed Feb 3 16:16:45 2021 -0500 readelf: decode LA48 and ASG_DISABLE feature flags MFC after: 1 week Sponsored by: The FreeBSD Foundation commit 660344ca44c63bfe4a16c3e57d0f6dbcbb5e083e Author: Ryan Stone Date: Fri Jan 29 16:13:57 2021 -0500 Add a VM flag to prevent reclaim on a failed contig allocation If a M_WAITOK contig alloc fails, the VM subsystem will try to reclaim contiguous memory twice before actually failing the request. On a system with 64GB of RAM I've observed this take 400-500ms before it finally gives up, and I believe that this will only be worse on systems with even more memory. In certain contexts this delay is extremely harmful, so add a flag that will skip reclaim for allocation requests to allow those paths to opt-out of doing an expensive reclaim. Sponsored by: Dell Inc Differential Revision: https://reviews.freebsd.org/D28422 Reviewed by: markj, kib commit 8727c174b0fe44766bb7ea765dac6d5f82818103 Author: Michal Meloun Date: Thu Jan 21 15:06:19 2021 +0100 dwmmc: Multiple busdma fixes. - limit maximum segment size to 2048 bytes. Although dwmmc supports a buffer fragment with a maximum length of 4095 bytes, use the nearest lower power of two as the maximum fragment size. Otherwise, busdma create excessive buffer fragments. - fix off by one error in computation of the maximum data transfer length. - in addition, reserve two DMA descriptors that can be used by busdma bouncing. The beginning or end of the buffer can be misaligned. - Don’t ignore errors passed to bus_dmamap_load() callback function. - In theory, a DMA engine may be running at time when next dma descriptor is constructed. Create a full DMA descriptor before OWN bit is set. MFC after: 2 weeks commit 14c40d2c292deff44be5591add7fdad5f9b371aa Author: shu Date: Wed Feb 3 19:10:58 2021 +0000 linux: remove locks around callout_drain in timerfd_close() The lock around callout_drain() is unnecessary and may cause deadlock when one closes a timer descriptor during timer execution. Reviewed By: delphij Submitted By: ankohuu_outlook.com (Shunchao Hu) Differential Revision: https://reviews.freebsd.org/D28148 commit 8a680912a190d619be6194f88917052eed327f7b Author: Mateusz Guzik Date: Wed Feb 3 19:38:10 2021 +0000 Revert "Reimplement strlen" This reverts commit 710e45c4b8539d028877769f1a4ec088c48fb5f1. It breaks for some corner cases on big endian ppc64. Given the stage of the release process it is best to revert for now. Reported by: jhibbits (cherry picked from commit 33f0540b13d949c7cc226a79927ddc2062ff98bf) commit 33f0540b13d949c7cc226a79927ddc2062ff98bf Author: Mateusz Guzik Date: Wed Feb 3 19:38:10 2021 +0000 Revert "Reimplement strlen" This reverts commit 710e45c4b8539d028877769f1a4ec088c48fb5f1. It breaks for some corner cases on big endian ppc64. Given the stage of the release process it is best to revert for now. Reported by: jhibbits commit ae71b794cbed19e5e25effc3438720ad452ab87c Author: shu Date: Wed Feb 3 16:51:45 2021 +0000 linux: make timerfd_settime(2) set expirations count to zero On Linux, read(2) from a timerfd file descriptor returns an unsigned 8-byte integer (uint64_t) containing the number of expirations that have occurred, if the timer has already expired one or more times since its settings were last modified using timerfd_settime(), or since the last successful read(2). That's to say, once we do a read or call timerfd_settime(), timer fd's expiration count should be zero. Some Linux applications create timerfd and add it to epoll with LT mode, when event comes, they do timerfd_settime instead of read to stop event source from trigger. On FreeBSD, timerfd_settime(2) didn't set the count to zero, which caused high CPU utilization. Submitted by: ankohuu_outlook.com (Shunchao Hu) Differential Revision: https://reviews.freebsd.org/D28231 commit 43e083be8103685e65582e002d33e861f7d5c794 Author: Alex Richardson Date: Wed Feb 3 15:56:03 2021 +0000 tools/build/make.py: -DNO_CLEAN -> -DWITHOUT_CLEAN commit 39a1f858ad735ef816a9b1fb7eeade2c6802eb98 Author: Alex Richardson Date: Wed Feb 3 16:07:05 2021 +0000 du_test: Skip three tests if sparse files are not supported This fixes running the du tests with /tmp as tmpfs (which is what we do in the CheriBSD CI). Obtained from: CheriBSD Reviewed By: ngie Differential Revision: https://reviews.freebsd.org/D28398 commit b67df8d7c203a139b5afbe72e1947fbb8c32dc73 Author: Olivier Cochard Date: Wed Feb 3 17:18:59 2021 +0100 diff: Use unprivileged_user with report_identical test Approved by: bapt Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D28466 commit 8fa6abb6f4f64f4f23e2920e2aea7996566851a4 Author: Alex Richardson Date: Wed Feb 3 15:27:17 2021 +0000 Expose clang's alignment builtins and use them for roundup2/rounddown2 This makes roundup2/rounddown2 type- and const-preserving and allows using it on pointer types without casting to uintptr_t first. Not performing pointer-to-integer conversions also helps the compiler's optimization passes and can therefore result in better code generation. When using it with integer values there should be no change other than the compiler checking that the alignment value is a valid power-of-two. I originally implemented these builtins for CHERI a few years ago and they have been very useful for CheriBSD. However, they are also useful for non-CHERI code so I was able to upstream them for Clang 10.0. Rationale from the clang documentation: Clang provides builtins to support checking and adjusting alignment of pointers and integers. These builtins can be used to avoid relying on implementation-defined behavior of arithmetic on integers derived from pointers. Additionally, these builtins retain type information and, unlike bitwise arithmetic, they can perform semantic checking on the alignment value. There is also a feature request for GCC, so GCC may also support it in the future: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98641 Reviewed By: brooks, jhb, imp Differential Revision: https://reviews.freebsd.org/D28332 commit 7791ecf04b48a0c365b003447f479ec890115dfc Author: Alex Richardson Date: Wed Feb 3 15:26:19 2021 +0000 usr.sbin/praudit: Fix tests after 5619d49e07 Commit 5619d49e07 made the getgrgid() call inside bsm work as intended so we now print "wheel" instead of a numeric 0 in the rgid field. Reviewed By: markj Differential Revision: https://reviews.freebsd.org/D28462 commit 2a39919364b5368e026f656ff41861a3fdd56110 Author: Alex Richardson Date: Wed Feb 3 15:24:28 2021 +0000 readelf: Fix printing NT_FREEBSD_ARCH_TAG Looking at lib/csu/arm/crt1_s.S, this should be a string and therefore the restriction to 4 characters seems wrong. Found whle updating https://reviews.llvm.org/D74393. Reviewed By: emaste Differential Revision: https://reviews.freebsd.org/D28470 commit 65618fdda0f272a823e6701966421bdca0efa301 Author: Michal Meloun Date: Sat Jan 23 21:19:07 2021 +0100 arm64: Initialize VFP control register. The RW fields in this register reset to architecturally unknown values, so initialize these to the proper rounding and denormal mode. MFC after: 1 week commit c1b1354789bb15713944f9e6941266de4cb47772 Author: Gordon Bergling Date: Wed Feb 3 16:01:32 2021 +0100 wg(4): Add authors of the wg(4) driver to the manual page Glen (@gjb) noticed that I am haven't mentioned the authors of the WireGuard device driver in the manual page. This is commit addressed this commit. Reviewed by: gjb, brueffer Differential Revision: https://reviews.freebsd.org/D28464 X-MFC-with: e59d9cb412846cb5d2bc4c641d3cc44d243cd52d commit 1996360d7338db8f12b9bda9572d4e2d85c89170 Author: Mark Johnston Date: Wed Jan 27 15:30:58 2021 -0500 qat: Add support for separate AAD and output buffers Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit bd674d8b1fa808dff1afdcb6afc70226077ee78a) commit 18697b446b95722808c65b72d793de5975c5ae4b Author: Kristof Provost Date: Tue Jan 26 08:56:51 2021 +0100 pf: Improve pf_rule input validation Move the validation checks to pf_rule_to_krule() to reduce duplication. This also makes the checks consistent across different ioctls. Reported-by: syzbot+e9632d7ad17398f0bd8f@syzkaller.appspotmail.com Reviewed by: tuexen@, donner@ MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28362 (cherry picked from commit 7a808c5ee3296fdb72d8e8bc6c7ad6f316a520ab) commit 51ab5e0d82c1e9607c060976259bb9ae0d656a80 Author: Roger Pau Monné Date: Wed Jan 27 11:12:07 2021 +0100 stand/multiboot: adjust the protocol between loader and kernel There's a currently ad-hoc protocol to hand off the FreeBSD kernel payload between the loader and the kernel itself when Xen is in the middle of the picture. Such protocol wasn't very resilient to changes to the loader itself, because it relied on moving metadata around to package it using a certain layout. This has proven to be fragile, so replace it with a more robust version. The new protocol requires using a xen_header structure that will be used to pass data between the FreeBSD loader and the FreeBSD kernel when booting in dom0 mode. At the moment the only data conveyed is the offset of the start of the module metadata relative to the start of the module itself. This is a slightly disruptive change since it also requires a change to the kernel which is contained in this patch. In order to update with this change the kernel must be updated before updating the loader, as described in the handbook. Note this is only required when booting a FreeBSD/Xen dom0. This change doesn't affect the normal FreeBSD boot protocol. This fixes booting FreeBSD/Xen in dom0 mode after 3630506b9daec9167a89bc4525638ea45a00769e. (cherry picked from commit b6d85a5f51e4147452b35d76478fb9e191b7734b) commit 601ac82194693fcae9d7d2a7ec7d66ebaf3fd61e Author: Stefan Eßer Date: Sun Jan 31 20:56:48 2021 +0100 bc: Vendor import of Gavin Howard's bc version 3.2.6 (cherry picked from commit 47a52dc4d48f259ab7d9f9ba6b65f4f2331a22dc) commit 5aaea4b99e5cc724e97e24a68876e8768d3d8012 Author: Peter Grehan Date: Wed Feb 3 19:05:09 2021 +1000 Always clamp curve25519 keys prior to use. This fixes an issue where a private key contained bits that should have been cleared by the clamping process, but were passed through to the scalar multiplication routine and resulted in an invalid public key. Issue diagnosed (and an initial fix proposed) by shamaz.mazum in PR 252894. This fix suggested by Jason Donenfeld. PR: 252894 Reported by: shamaz.mazum Reviewed by: dch MFC after: 3 days commit 9b131f1e51a00c8bbbda32672fb5db88010400f6 Author: Alex Richardson Date: Wed Feb 3 09:32:16 2021 +0000 atf: Fix ATF_BUILD_* values when not using the bootstrap compiler Currently, we encode the full path and compile flags for the build compiler in libatf. However, these values are not correct when cross-compiling: For example, when I build on macOS, CC is set to the host path /usr/local/Cellar/llvm/11.0.0_1/bin/clang-11. This path will not exist on the target system. Simplify this logic and use cc/cpp/c++ since those binaries will exist on the target system unless the compiler was explicitly disabled. I'm not convinced ATF needs to encode these values, but this is a minimal fix for these tests when using a non-bootstrapped compiler. Reviewed By: ngie, brooks Differential Revision: https://reviews.freebsd.org/D28414 commit d6f4e1a8973daff2ffe4480b66c973562982ffc7 Author: Alex Richardson Date: Wed Feb 3 09:31:32 2021 +0000 sbin/bectl: Skip tests if sparse files are not supported The tests create a 1GB test file and this causes the tests to fail in the CheriBSD CI setup where we run tests with a tmpfs mount on /tmp. Tmpfs does not support sparse files and it appears that tmpfs default to creating a 1GB mount, so there is not enough space to run these tests. Instead of checking for at least 1GB of free space, this commit skips the tests on file systems that do not support sparse files. Reviewed By: kevans Differential Revision: https://reviews.freebsd.org/D28463 commit 8b820df156e065f48857dca89a89462074659e14 Author: Alex Richardson Date: Wed Feb 3 09:29:08 2021 +0000 Fix build with read-only source dir after 83c20b8a2da0 I changed the Makefile to use SRCS instead of LDADD, but since there is still and absolute path to the source the .o file was created inside the source directory instead of the build directory. It would be nice if this was an error/warning by default, but for now just fix this issue by using .PATH and the base name of the file. Reported by: cy, peterj commit eb0b1b33d5af4e81ee77732dffc77634e57a5879 Author: Alexander V. Chernikov Date: Wed Feb 3 08:49:46 2021 +0000 Enable multipath routing by default. ROUTE_MPATH was added to the GENERIC kernel in r368648. According to the plan in D27428, it was enabled with `net.route.multipath` sysctl set to 0. Given enough time has passed, this change enables route multipath by default. The goal is to ship FreeBSD 13 with multipath turned on. Reviewed By: donner, olivier MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28423 commit e3cd8246c756e568956da1ad8e90e1983d9af89f Author: Kyle Evans Date: Sun Jan 31 09:51:39 2021 -0600 lualoader: position hyphens at the beginning of character classes According to the Lua 5.4 manual section 6.4.1 ("Patterns"), the interaction between ranges and classes is not defined and hyphens must be specified at either the beginning or the end of a set if they are not escaped. Move all such occurrences to the beginning. (cherry picked from commit b24872cf7b13314669ed2136c0262bb2eb007695) commit 13de72571eb2532e253fb8d40edf47ebabb99e92 Author: Kyle Evans Date: Sat Jan 23 19:32:38 2021 -0600 stand: lua: enhance lfs.dir() to speed up kernels_autodetect This eliminates a lot of stat() calls that happen when lualoader renders the menu with the default settings, and greatly speeds up rendering on my laptop. ftype is nil if loader/loader.efi hasn't been updated yet, falling back to lfs.attributes() to test. This is technically incompatible with lfs, but not in a particularly terrible way. (cherry picked from commit e25ee296c919d6567aa76058a7049eac974797fb) commit 10625515ad47b52f38c13f4f1d8f8c848e9df4ee Author: Oleksandr Tymoshenko Date: Sun Jan 31 23:56:22 2021 -0800 MFC: mips: fix early kernel panic when setting up interrupt counters Commit 248f0ca converted intrcnt and intrnames from u_long[] and char[] to u_long* and char* respectively, but for non-INTRNG mips these symbols were defined in .S file as a pre-allocated static arrays, so the problem wasn't cought at compile time. Conversion from an array to a pointer requires pointer initialization and it wasn't done for MIPS, so whatever happenned to be in the begginning of intcnt[] array was used as a pointer value. Move intrcnt/intrnames to C code and allocate them dynamically although with a fixed size at the moment. Reviewed by: emaste PR: 253051 Differential Revision: https://reviews.freebsd.org/D28424 MFC after: 1 day (cherry picked from commit e0a0a3efcb09a10ad1de29aca622ea580b2663d2) mips: fix NLM platforms breakage caused by e0a0a3ef NetLogic platforms have their own implementation of cpu_init_interrupts. Apply the same logic to it as to intr_machdep.c. PR: 253051 (cherry picked from commit d6f9c5a6d2f87865f9714d2b8dfd1a9f3080c71e) commit c738bfc506af1feaff2f138534bb5fc99da7e042 Author: Alexander Motin Date: Sun Jan 31 12:46:57 2021 -0500 cxgb(4): Remove assumption of physically contiguous mbufs. Investigation of iSCSI target data corruption reports brought me to discovery that cxgb(4) expects mbufs to be physically contiguous, that is not true after I've started using m_extaddref() in software iSCSI for large zero-copy transmissions. In case of fragmented memory the driver transmitted garbage from pages following the first one due to simple use of pmap_kextract() for the first pointer instead of proper bus_dmamap_load_mbuf_sg(). Seems like it was done as some optimization many years ago, and at very least it is wrong in a world of IOMMUs. This patch just removes that optimization, plus limits packet coalescing for mbufs crossing page boundary, also depending on assumption of one segment per packet. Sponsored by: iXsystems, Inc. (cherry picked from commit 9dc7c250b8bd2d5e669c7633e189a700a02c0571) commit 805e2876ec20f89e45f0f9f4164f31b6711ff0ea Author: Glen Barber Date: Tue Feb 2 19:04:11 2021 -0500 release.sh: Skip installing textproc/docproj when NODOC is set PR: 253192 Submitted by: Yasuhiro Kimura MFC after: 3 days Sponsored by: Rubicon Communications, LLC ("Netgate") commit edc374e7c41d3d9e28e0b3a76bc9ed021d7db571 Author: Ed Maste Date: Tue Feb 2 16:55:51 2021 -0500 Correct description for kern.proc.proc_td kern.proc.proc_td returns the process table with an entry for each thread. Previously the description included "no threads", presumably a cut-and-pasteo in 2648efa621748. Description suggested by PauAmma. PR: 253146 MFC after: 3 days Sponsored by: The FreeBSD Foundation commit a08cdb6cfb1c84b80b5337d46c574b55d0e15c63 Author: Neel Chauhan Date: Tue Feb 2 13:24:17 2021 -0800 Allow setting alias port ranges in libalias and ipfw. This will allow a system to be a true RFC 6598 NAT444 setup, where each network segment (e.g. user, subnet) can have their own dedicated port aliasing ranges. Reviewed by: donner, kp Approved by: 0mp (mentor), donner, kp Differential Revision: https://reviews.freebsd.org/D23450 commit 064e52c2d874abc83dd2af61644d14dc90e26ec3 Author: Gordon Bergling Date: Tue Feb 2 20:16:52 2021 +0100 wg(4): Fix Copyright statement in man page commit e59d9cb412846cb5d2bc4c641d3cc44d243cd52d Author: Gordon Bergling Date: Tue Feb 2 20:13:53 2021 +0100 Add a wg(4) manual page Reviewed by: brueffer, donner, debdrup, ygy MFC after: 2 days commit 3dd2a7a5ea2f1641c7525f692eed416fa02c28e6 Author: Alexander Motin Date: Tue Feb 2 13:37:13 2021 -0500 Make DataSN counter of solicited Data-Out local. DataSN for solicited Data-Out is per-R2T. Since we handle whole R2T in one go, we don't need to store it anywhere, especially in global per-command structure. This may allow us to handle multiple R2T per command at once, if we decide, or may be relax locking. Rename the second use of that field to io_referenced_task_tag. MFC after: 1 month commit 9d0f1092cf90c8bf161cb946584f703a9998f8cd Author: Ed Maste Date: Tue Feb 2 13:36:45 2021 -0500 git hooks: add "Tested by" to commit message template Reported by: mjg Reviewed by: imp Sponsored by: The FreeBSD Foundation commit 4e29933d0936fd053f7591ee118dc1fc42617514 Author: Mateusz Guzik Date: Tue Feb 2 18:06:56 2021 +0000 cache: fix trailing slash support in face of permission problems Reported by: Johan Hendriks Tested by: kevans (cherry picked from commit 45456abc4ce71053d07cf03ca63bd1ce459fec55) commit 45456abc4ce71053d07cf03ca63bd1ce459fec55 Author: Mateusz Guzik Date: Tue Feb 2 18:06:56 2021 +0000 cache: fix trailing slash support in face of permission problems Reported by: Johan Hendriks Tested by: kevans commit 70dfc101b6324b25ba353465f0d6c610399741fc Author: Glen Barber Date: Tue Feb 2 12:19:36 2021 -0500 release: update workaround during transition to git PR: 253181 Submitted by: Yasuhiro Kimura MFC after: 3 days Sponsored by: Rubicon Communications, LLC ("Netgate") commit d0ca28d7c9c7da80a62e4307fe37b923e32ca1bb Author: Konstantin Belousov Date: Tue Feb 2 18:48:08 2021 +0200 src.conf.5: regenerate commit ff975f15d86001d5b948ab538de1e4aca852d2f5 Author: Konstantin Belousov Date: Tue Feb 2 15:01:26 2021 +0200 WITH_OFED build option: fix Userspace has OFED build enabled for quite some time, but kernel modules were not. This is useless config because any userspace IB code requires kernel support. So enable modules build by default. Move WITH_OFED to WITHOUT_OFED since defaults are now enabled. Reviewed by: emaste, hselasky, kevans MFC after: 3 days Sponsored by: NVidia Networking / Mellanox Technologies Differential Revision: https://reviews.freebsd.org/D28460 commit e40787f900f3c262d5134d342e5a16757dd2193c Author: Edward Tomasz Napierala Date: Tue Feb 2 14:40:38 2021 +0000 Use compat.linux.emul_path instead of hardcoded path in /etc/rc.d/linux In /etc/rc.d/linux the mounting paths of procfs, sysfs and devfs are hardcoded to "/compat/linux". Switching to the content of compat.linux.emul_path sysctl would allow to switch linuxulator to different place. Submitted by: freebsdnewbie_freenet.de Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D27807 commit 43d44842aef3972cc86ce673e84e31f372257b15 Author: David Chisnall Date: Tue Feb 2 16:06:33 2021 +0200 rtld: Fix null-pointer dereference When a library is opened via fdlopen, it has a null pointer for its path and so _rtld_bind can crash as a result of passing the null pointer to basename() (which passes it to strrchr(), which doesn't do a null check). PR: 253081 Submitted by: theraven MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28442 commit d21ce74dcce6f8b69451b3b2dd291d35cbb70609 Author: Poul-Henning Kamp Date: Tue Feb 2 12:01:38 2021 +0000 Register the bad read before bailing on terminal errors. This way running recoverdisk in a loop will not get stuck on a bad block which causes the disk or SD card detach. commit a66467dcfd65bc6d4915a3c2c1b5ab2ca77133d4 Author: Toomas Soome Date: Sat Jan 30 21:16:20 2021 +0200 userboot: provide stub gfx functions Make sure we have needed functions present, to avoi getting undefined symbols error(s). PR: 253088 Reported by: John Kennedy (cherry picked b79f2bc6c5c7431fa1f7c02937ec97a64653ade1) commit b79f2bc6c5c7431fa1f7c02937ec97a64653ade1 Author: Toomas Soome Date: Sun Jan 24 20:59:36 2021 +0200 vt: panic while changing vt font Set refcount for loader provided font to 1 to prevent this font from being released (so we can reset to default). As we get started with no memory allocator, we set up static font data for font passed by loader (if there is any). At this time, we also must set refcount 1, and refcount will get incremented in cnprobe() callback. At some point the memory allocator will be available, and we will set up properly allocated font data, but we should not disturb the refcount. PR: 252833 PR: 253147 (cherry picked and squashed 93ebd6307efeb95a29bc614edd0c67c2af850e98 and 1912d2b15e6d6f4a1d8c3886b03ab30d2f21f3fd) commit 0d381d1b92e5cc0a83f5fd6b4aa7f063d4d4f2c6 Author: Toomas Soome Date: Fri Jan 22 13:06:58 2021 +0200 loader: create built in font from bold font face We did replace full version of default font 8x16v with bold, also use bold version for built in font. (cherry picked from commit 6c789c55c4ba11014bfd1b59942c204615412ba6) commit cd925aaa73e1bde159bb53ea049a45b6bd86bba3 Author: Marcin Wojtas Date: Tue Jan 26 11:49:35 2021 +0100 marvell: ap806_clock: add missing frequency modes In the driver init routine the CPU clock frequency value is obtained from a dedicated register. Until now only part of the values were handled by the mv_ap806_clock driver. Fix that by adding missing cases. Submitted by: Zyta Szpak MFC after: 1 week Obtained from: Semihalf Sponsored by: Marvell (cherry picked from commit a86b0839d7bf3fc06b1ae9c50e055b53c50a9d0b) commit 4d85bfa4120256d7d023bcecb3b5efe7a4bea46d Author: Bjoern A. Zeeb Date: Fri Jan 29 10:57:50 2021 +0000 __FreeBSD_version: update the references to the doc tree Update the reference of which file to update in the doc tree when bumping __FreeBSD_version. (cherry picked from commit abd619045a54c73f41a95b3e038a5ba083391400) commit 91a07ed50ffca4dfada3e7f1f050ea746c1bac66 Author: Bjoern A. Zeeb Date: Tue Feb 2 11:52:50 2021 +0000 Bump __FreeBSD_version for multiple LinuxKPI updates conflicting with DRM. Be sure to update your drm-kmod port to after the update. Sponsored-by: The FreeBSD Foundation commit ff119f7c4a3894e20190cca37ca00c9fef88a6df Author: Bjoern A. Zeeb Date: Thu Jan 28 16:32:43 2021 +0000 LinuxKPI: implement devres() framework parts and two examples This code implements a version of the devres framework found working for various iwlwifi use cases and also providing functions for ttm_page_alloc_dma.c from DRM. Part of the framework replicates the consumed KPI, while others are internal helper functions. In addition the simple devm_k*malloc() consumers were implemented and kvasprintf() was enhanced to also work for the devm_kasprintf() case. Addmittingly lkpi_devm_kmalloc_release() could be avoided but for the overall understanding of the code and possible memory tracing it may still be helpful. Further devsres consumer are implemented for iwlwifi but will follow later as the main reason for this change is to sort out overlap with DRM. Sponsored-by: The FreeBSD Foundation Obtained-from: bz_iwlwifi MFC After: 3 days Reviewed-by: hselasky, manu Differential Revision: https://reviews.freebsd.org/D28189 (cherry picked from commit fa765ca73e553399ffbad382e579e4c2b4d0fc12) commit 3ac9e87b762c711642c870fb7a43b84d812a6e91 Author: Bjoern A. Zeeb Date: Thu Jan 28 16:23:19 2021 +0000 LinuxKPI: enhance PCI bits for DRM In pci_domain_nr() directly return the domain which got set in lkpifill_pci_dev() in all cases. This was missed between D27550 and 105a37cac76b971f7a94409fbdc4f508a7e97fa0 . In order to implement pci_dev_put() harmonize further code (which was started in the aforementioned commit) and add kobj related bits (through the now common lkpifill_pci_dev() code) to the DRM specific calls without adding the DRM allocated pci devices to the pci_devices list. Add a release for the lkpinew_pci_dev() (DRM) case so freeing will work. This allows the DRM created devices to use the normal kobj/refcount logic and work with, e.g., pci_dev_put(). (For a slightly more detailed code walk see the review). Sponsored-by: The FreeBSD Foundation Obtained-from: bz_iwlwifi (partially) MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28188 (cherry picked from commit 1fac2cb4d6e5cfa1b8ff689213011b0fe077ffa7) commit ec06521ee8728a8d3321bc8eb115a425524dd968 Author: Bjoern A. Zeeb Date: Thu Jan 28 16:15:12 2021 +0000 LinuxKPI: upstream a collection of drm-kmod conflicting changes The upcoming in-kernel implementations for LinuxKPI based on work on iwlwifi (and other wireless drivers) conflicts in a few places with the drm-kmod graphics work outside the base system. In order to transition smoothly extract the conflicting bits. This included "unaligned" accessor functions, sg_pcopy_from_buffer(), IS_*() macros (to be further restricted in the future), power management bits (possibly no longer conflicting with DRM), and other minor changes. Obtained-from: bz_iwlwifi Sponsored-by: The FreeBSD Foundation MFC after: 3 days Reviewed by: kib, hselasky, manu, bdragon (looked at earlier versions) Differential Revision: https://reviews.freebsd.org/D26598 (cherry picked from commit 4abbf816bf06aa70200c5d1d976dd61c2752bdaf) commit ffd05df71796ff4cd56c3f8ef109d00165a9c10a Author: Bjoern A. Zeeb Date: Thu Jan 28 16:05:32 2021 +0000 LinuxKPI: add firmware loading support Implement linux firmware KPI compat code. This includes: request_firmware() request_firmware_nowait(), request_firmware_direct(), firmware_request_nowarn(), and release_firmware(). Given we will try to map requested names from natively ported or full-linuxkpi-using drivers to a firmware(9) auto-loading name format (.ko file name and image name matching), we quieten firmware(9) and print success or failure (unless the _nowarn() version was called) in the linuxkpi implementation. At the moment we try up-to 4 different naming combinations, with path stripped, original name, and requested name with '/' or '.' replaced. We do not currently defer loading in the "nowait" case. Sponsored-by: The FreeBSD Foundation Sponsored-by: Rubicon Communications, LLC ("Netgate") (firmware(9) nowarn update from D27413) MFC after: 3 days Reviewed by: kib, manu (looked at older versions) Differential Revision: https://reviews.freebsd.org/D27414 (cherry picked from commit a6c2507d1baedb183268e31bc6b6f659a9529904) (cherry picked from commit 4a26380ba6dc487a7525d909ee29fbc710b558d1) commit 40407d3998d1a12cbe929721f4dbe72b4be478a6 Author: Alex Richardson Date: Tue Feb 2 09:55:18 2021 +0000 tests/sys/audit: Skip extattr tests if extattrs are not supported In the CheriBSD CI, we run the testsuite with /tmp as tmpfs. This causes the extattr audit tests to fail since tmpfs does not (yet) support extattrs. Skip those tests if the target path is on a file system that does not support extended file attributes. While touching these two files also convert the ATF_REQUIRE_EQ(-1, ...) checks to use ATF_REQURIE_ERRNO(). Reviewed By: asomers Differential Revision: https://reviews.freebsd.org/D28392 commit 83c20b8a2da04937cf4af127366b3dc92c855784 Author: Alex Richardson Date: Tue Feb 2 09:52:52 2021 +0000 tests/sys/kern/crc32: Check for SSE4.2 before using it This avoids a SIGILL when running these tests on QEMU (which defaults to a basic amd64 CPU without SSE4.2). This commit also tests the table-based implementations in addition to testing the hw-accelerated crc32 versions. Reviewed By: cem, kib, markj Differential Revision: https://reviews.freebsd.org/D28395 commit c69047ca7526090cc2aa92c57d9f21a77a82fc2e Author: Baptiste Daroussin Date: Tue Feb 2 10:07:57 2021 +0100 Revert "diff: eliminate a useless lseek" This changes breaks when one of the files is stdin This reverts commit fa977a3b2bb2d0e6c2957b14474c31b58dd3a8e1. Reported by: olivier commit 5ea878684f6cfff4ad05186346ff3a4828d980ca Author: Roger Pau Monné Date: Tue Jan 19 12:52:28 2021 +0100 bhyve/ioapic: improve the tracking of IRR bit One common method of EOI'ing an interrupt at the IO-APIC level is to switch the pin to edge triggering mode and then back into level mode. That would cause the IRR bit to be cleared and thus further interrupts to be injected. FreeBSD does indeed use that method if the IO-APIC EOI register is not supported. The bhyve IO-APIC emulation code didn't clear the IRR bit when doing that switch, and was also missing acknowledging the IRR state when trying to inject an interrupt in vioapic_send_intr. Reviewed by: grehan Differential revision: https://reviews.freebsd.org/D28238 commit d7d067698a38a3464a58eb34f68f63e529c45136 Author: Roger Pau Monné Date: Tue Jan 19 13:41:03 2021 +0100 bhyve/ioapic: only account for asserted line in level mode After modifying a redirection entry only try to inject an interrupt if the pin is in level mode, pins in edge mode shouldn't take into account the line assert status as they are triggered by edge changes, not the line status itself. Reviewed by: grehan Differential revision: https://reviews.freebsd.org/D28237 commit 49429cf9be7f43c37723175f90c56b29e29d1680 Author: Roger Pau Monné Date: Tue Jan 19 12:52:44 2021 +0100 bhyve/vioapic: remove an extra pin masked check vioapic_send_intr does already check whether the pin is masked before injecting the interrupt, there's no need to do it in vioapic_write also. No functional change intended. Reviewed by: grehan Differential revision: https://reviews.freebsd.org/D28236 commit 0f34c80f376345b98a972940dd4757e58d7beb06 Author: Cy Schubert Date: Wed Jan 27 21:50:04 2021 -0800 Replace the redundant MENTAT macro with SOLARIS. MENTAT and SOLARIS are synonymous. Remove the extraneous duplicate macro. MFC after: 1 week commit 7071734fae6019d1e3e44daf7deb4478582081cc Author: Cy Schubert Date: Wed Jan 27 07:25:00 2021 -0800 Indentation cleanup resulting from the cleanup of #ifdefs. The conscious decision was made not to perform any indentation or whitespace cleanup while cleaning out old redunant #ifdefs. The reason for this was to avoid confusing future readers of history and diffs with cosmetic changes, making bisection of any possible bugs introduced more difficult. This commit cleans up the whitespace detritus left behind from the previous #ifdef cleanup commits. MFC after: 1 week commit 4cd1807c7d2a67b633dd0c0bfde15091543a2514 Author: Cy Schubert Date: Mon Jan 25 22:24:28 2021 -0800 Retire the K&R/STD C __P prototype declarations. In the old days when K&R C and STD C were each in use a workaround (read hack) was required to allow the same code to work on each without modification. All C compilers support STD C. We can finally put the __P prototype to rest. MFC after: 1 week commit 0b7f1af804f06a285717b490bef80e24648adcbe Author: John Baldwin Date: Mon Feb 1 17:09:33 2021 -0800 Bump shared library versions after ncurses bump in 13. A few shared libraries in the base system link against ncurses. An upgrade from a 12.x host to 13 results in ABI breakage for existing binaries since the newer versions of these libraries link against the newer ncurses while the binary itself links against the older ncurses. For example, dialog4ports built on 12.x sometimes crashes on 13 since it depends on libdialog which links against ncurses internally. MFC after: 3 days Reviewed by: kib, delphij Differential Revision: https://reviews.freebsd.org/D28448 commit 7787e7eed9d2a43fb6eb66666040f1b495995a2f Author: Chuck Silvers Date: Mon Feb 1 16:21:14 2021 -0800 tail: fix "tail -F" file rotation detection When checking if the newly opened file is the same as the old one, we need to fstat() the new file descriptor, not the old one again. Reviewed by: glebius Sponsored by: Netflix commit 1912d2b15e6d6f4a1d8c3886b03ab30d2f21f3fd Author: Toomas Soome Date: Sun Jan 31 23:04:59 2021 +0200 vt: parse_font_info_static should set refcount, not parse_font_info As we get started with no memory allocator, we set up static font data for font passed by loader (if there is any). At this time, we also must set refcount 1, and refcount will get incremented in cnprobe() callback. At some point the memory allocator will be available, and we will set up properly allocated font data, but we should not disturb the refcount. PR: 253147 commit f19a4e97d3b0905dfda5aaebba49f68a1e07fa3e Author: Warner Losh Date: Mon Jan 25 12:53:31 2021 -0700 newvers: tweak uname to be more useful The current uname is branch-cXXXX-gHASH Three changes to make uname more useful. 1. Move from using git rev-list --count to git rev-lis --count --first-parent since that gives a better, incrementing number. 2. Report this count as 'nXXXXX' rather than 'cXXXXX' because c is part of a hash and we've changed the sematnics of XXXXX 3. Remove g to make HASH cut and pastable. Durting review, #1 & #3 had the largest consensus. There was a diversity of opinion on #2, but on the whole it was positive so I'll acknowledge the dissent, but move forward with something seems to have support since the dissent was all about what letter to use where I chose 'n'. MFC After: 3 days Reviewed by: rgrimes, emaste (earlier version) Differential Revision: https://reviews.freebsd.org/D28338 (cherry picked from commit 8a51f14a7833fd14e1f125e63a0af9d260dcd287) commit 8fb966790e1c87276cc26932efee1b29c046cb8a Author: Martin Matuska Date: Mon Feb 1 22:08:19 2021 +0100 zfs: update zfs_config.h to match OpenZFS gf11b09dec Update zfs_config.h to match latest merge in FreeBSD The version string is declared as 2.0.0-FreeBSD_gf11b09dec to provide more information about the loaded module: - the OpenZFS version in base is 2.0 - we are using the in tree-module ("FreeBSD") - the last merged OpenZFS git revision ("gf11b09dec") With future merges the git revision tag should be updated. As we are merging from OpenZFS master branch and already include features like dRAID, referencing patchlevel releases (2.0.1, 2.0.2) is pointless. Reviewed by: freqlabs MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28447 commit bcaa6aa15383cacf5f20179be919bb8dd45cc5f4 Author: John Baldwin Date: Mon Feb 1 13:13:36 2021 -0800 config: Fix typo in comment. commit 682c31db4ecfb8fc6cac0e8ad4945c03379ea3d1 Author: Evgeniy Khramtsov <2khramtsov@gmail.com> Date: Mon Feb 1 20:03:57 2021 +0100 ipfw(8) crashes when ext6hdr option is omitted Verify that the option is passed, error out if it's not. The problem can be trivially triggered with `ipfw add allow ext6hdr`. PR: 253169 Reviewed by: kp@ MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28447 commit 38bfc6dee33bedb290e1ea2540f97a86fe3caee0 Author: Sai Rajesh Tallamraju Date: Mon Feb 1 11:13:00 2021 -0500 iflib: Free resources in a consistent order during detach Memory and PCI resources are freed with no particular order. This could cause use-after-frees when detaching following a failed attach. For instance, iflib_tx_structures_free() frees ctx->ifc_txqs[] but iflib_tqg_detach() attempts to access this array. Similarly, adapter queues gets freed by IFDI_QUEUES_FREE() but IFDI_DETACH() attempts to access adapter queues to free PCI resources. MFC after: 2 weeks Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D27634 commit c415d0df47fc4b144c029263fac47ad4df81a803 Author: Mitchell Horne Date: Fri Jan 15 12:34:54 2021 -0400 bsdinstall: riscv-specific tweaks Make the installer more useful, by allowing it to create a bootable installation. Also, enable the menu option for ZFS-on-root. Like arm64, RISC-V boots by UEFI only, so arm64's partedit implementation is renamed and shared among the two platforms. Reviewed by: gjb (cherry picked from commit 7b08a307e88bb1abe17d13d11288392a8e4739ce) commit 14640ac7897b79d49e97e5c571f05ae563f4a8e2 Author: Mitchell Horne Date: Fri Jan 15 12:14:27 2021 -0400 bsdinstall: create /efi/boot directory in ESP If the installer is creating a new ESP, then this directory will not exist and the subsequent cp will fail silently. This is usually of no consequence if /efi/freebsd/loader.efi is set up correctly. Reviewed by: imp (cherry picked from commit 676b7d077c2c5f548334cea7fccfbfb5d097c9df) commit 45ecda8ebf80bb341aa3b4955810518ae6fab158 Author: Roger Pau Monné Date: Fri Jan 29 12:29:37 2021 +0100 stand/amd64: remove unused addr parameter from bi_load64 All callers of bi_load64 pass 0 as the addr parameter, so just remove it and always calculate the last load address from the module chain. No functional change. Sponsored by: Citrix Systems R&D Reviewed by: tsoome, imp Differential revision: https://reviews.freebsd.org/D28412 commit 243125c81af5a4947a25e5977056c68db0474c42 Author: Mitchell Horne Date: Mon Feb 1 10:34:11 2021 -0400 src.conf(5): regenerate after MK_ZFS change With e5cc1c474841, this option is also disabled by WITHOUT_OPENSSL and WITHOUT_CRYPT. commit e5cc1c47484160969e0a7c13cdbc71081d7dd60e Author: Mitchell Horne Date: Sat Jan 30 15:04:08 2021 -0400 src.opts.mk: set MK_ZFS conditional on MK_OPENSSL libzfs has a dependency on libcrypto. This causes a buildworld link failure when WITHOUT_OPENSSL/WITHOUT_CRYPT is set. This dependency was added implicitly by the switch to OpenZFS, and explicitly in 40d0fd287510 and cd568e2b1b67. PR: 252841 Reviewed by: kevans, freqlabs MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28431 commit 88be0e11205e4a2dc77e29f7b4a2e82b8d7c9a5c Author: Jonah Caplan Date: Sat Jan 30 14:54:09 2021 +0100 bridge: fix STP roles and protos strings Add the missing commas that got lost in e5539fb618cc7. PR: 252532 Reviewd by: kp@, donner@, freqlabs@ MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28425 commit 05985a7f805f7ac4844c1a246a3822250d411655 Author: Jessica Clarke Date: Mon Feb 1 14:15:57 2021 +0000 arm64: Improve DDB backtrace support The existing implementation relies on each trap handler saving a normal stack frame record, which is a waste of time and space when we're already saving a trapframe to the stack. It's also wrong as it currently saves LR not ELR. Instead of patching it up, rewrite it based on the RISC-V implementation with inspiration from the amd64 implementation for how to handle vectored traps to provide an improved implementation. This includes compressing the information down to one line like other architectures rather than the highly-verbose old form that repeats itself by printing LR and FP in one frame only to print them as PC and SP in the next. It also includes printing out actually useful information about the traps that occurred, though FAR is not saved in the trapframe so we cannot print it (in general it can be clobbered between when the trap happened and now), only ESR. The AAPCS also allows the stack frame record to be located anywhere in the frame, not just the top, so the caller's SP is not at a fixed offset from the callee's FP like on almost all other architectures in existence. This means there is no way to derive the caller's SP in the unwinder, and so we have to drop that bit of (unused) state everywhere. Reviewed by: jhb, markj Differential Revision: https://reviews.freebsd.org/D28026 commit db46c0d0cb3da2813727e56df1f2db292065867a Author: Hans Petter Selasky Date: Mon Feb 1 13:23:21 2021 +0100 Fix LINT kernel builds after 1a714ff20419 . MFC after: 1 week Discussed with: rrs@ Differential Revision: https://reviews.freebsd.org/D28357 Sponsored by: Mellanox Technologies // NVIDIA Networking commit 3728c4d3149553967532a97254737bdb2cd92417 Author: Jamie Landeg-Jones Date: Mon Jan 25 18:42:26 2021 +0100 diff: fix incorrectly displaying files as duplicates When diff hits certain access errors, function diffreg() shows the error message, and then returns to the calling function, which calls print_status() with the return value. However, in these cases, the return value isn't changed from the initial default value of D_SAME. Normally, print_status() with a value of D_SAME does nothing, so this works out ok, however, if the "-s" flag is set, a message is displayed showing identicality: case D_SAME: if (sflag) printf("Files %s%s and %s%s are identical\n", path1, entry, path2, entry); break; This then produces such results as: % diff -s /COPYRIGHT /var/run/rpcbind.sock diff: /var/run/rpcbind.sock: Operation not supported Files /COPYRIGHT and /var/run/rpcbind.sock are identical % diff -s /COPYRIGHT /etc/master.passwd diff: /etc/master.passwd: Permission denied Files /COPYRIGHT and /etc/master.passwd are identical Create a D_ERROR status which is returned in such cases, and print_status() then deals with that status seperately from D_SAME PR: 252614 MFC after: 1 week (cherry picked from commit fefb3c46a80fdde6f307e73a2b5b5aed806df1ce) commit 0702bf9c495d517ef30432de1990f9a301598942 Author: Baptiste Daroussin Date: Mon Jan 25 18:40:12 2021 +0100 diff: add a test case for failed -s option (cherry picked from commit 13860e71eb501f498a2263f44ea9244f6830b61c) commit bdd4630c9a9cea64830f981fc897ac953c48892c Author: Michael Tuexen Date: Mon Feb 1 14:03:41 2021 +0100 sctp: small cleanup, no functional change intended. MFC after: 3 days commit 71b460513827a730c4e5dbf0c9a8eb3a18a95112 Author: Mateusz Guzik Date: Sun Jan 31 13:23:42 2021 +0100 Drop temporary compat in setproctitle (cherry picked from commit 46f168bc665a1aee79d91bd102aef7d4754e7917) commit 006ec2ed15650778c36ef956c5058b5b38717de7 Author: Mateusz Guzik Date: Tue Jan 26 01:38:21 2021 +0100 cache: add trailing slash support Tested by: pho (cherry picked from commit e027e24bfac7dd311ddacaec73d6c42102069511) commit 6a3047840dfbbdb59d96a325f295f42755648545 Author: Mateusz Guzik Date: Tue Jan 26 23:14:49 2021 +0100 cache: handle NOFOLLOW requests for symlinks Tested by: pho (cherry picked from commit 8cbd164a179c182e8fd4a71f366bc48fe840eafb) commit be03df57d62f4cc6161349f9127309ea20395c0d Author: Mateusz Guzik Date: Sat Jan 30 00:17:15 2021 +0000 amd64: retire sse2_pagezero All page zeroing is using temporal stores with rep movs*, the routine is unused for several years. Should a need arise for zeroing using non-temporal stores, a more optimized variant can be implemented with a more descriptive name. (cherry picked from commit d1de5698dfe6109308d4e5d6536a2ac93941d23a) commit 3975d4c9e1be53c2a4977acaa314bcdc18c02416 Author: Mateusz Guzik Date: Fri Jan 29 16:09:14 2021 +0100 amd64: add missing ALIGN_TEXT to loops in memset and memmove (cherry picked from commit 164c3b81848bc81dc200b12370999474225447a3) commit e5b674594e64b86a34295a475bb6cdb67469f8da Author: Mateusz Guzik Date: Fri Jan 29 22:48:11 2021 +0100 Reimplement strlen The previous code neglected to use primitives which can find the end of the string without having to branch on every character. While here augment the somewhat misleading commentary -- strlen as implemented here leaves performance on the table, especially so for userspace. Every arch should get a dedicated variant instead. In the meantime this commit lessens the problem. Tested with glibc test suite. Naive test just calling strlen in a loop on Haswell (ops/s): $(perl -e "print 'A' x 3"): before: 211198039 after: 338626619 $(perl -e "print 'A' x 100"): before: 83151997 after: 98285919 (cherry picked from commit 710e45c4b8539d028877769f1a4ec088c48fb5f1) commit 2bf72739da6f54572597369a1b5892a124c6c9ce Author: Mateusz Guzik Date: Fri Jan 29 00:52:08 2021 +0100 poll: use fget_unlocked or fget_only_user when feasible This follows select by eleminating the use of filedesc lock. This is a win for single-threaded processes and a mixed bag for others as at small concurrency it is faster to take the lock instead of refing/unrefing each file descriptor. Nonetheless, removal of shared lock usage is a step towards a mtx-protected fd table. (cherry picked from commit 45e1f8541428c19f63dba65d78a8d138e1bc6915) commit 233225ef7d5604162b6bda47e35fa7a8075bd559 Author: Mateusz Guzik Date: Fri Jan 29 00:33:46 2021 +0100 select: employ fget_only_user Since most select users are single-threaded this avoid a lot of work in the common case. For example select of 16 fds (ops/s): before: 2114536 after: 2991010 (cherry picked from commit 6affe1b71238df7bbbca6e2059e5494d91e68d2d) commit 1077e49657faaae1477a31fd534375e113df2bd4 Author: Mateusz Guzik Date: Fri Jan 29 00:27:44 2021 +0100 fd: add fget_only_user This can be used by single-threaded processes which don't share a file descriptor table to access their file objects without having to reference them. For example select consumers tend to match the requirement and have several file descriptors to inspect. (cherry picked from commit eaad8d1303da500ed691bd774742a4555a05e729) commit 569ac576088bdb44856d5992ecdc647483b0970b Author: Mateusz Guzik Date: Wed Jan 27 15:59:53 2021 +0100 cache: add missing MNT_NOSYMFOLLOW check to symlink traversal (cherry picked from commit 5c325977b1138828367f39a3f2034af24c3654f0) commit e13587448ab1da930640563340b5e492325f2e10 Author: Mateusz Guzik Date: Wed Jan 27 13:52:23 2021 +0100 cache: fallback when encountering a mount point during .. lookup The current abort is overzealous. (cherry picked from commit 5fc384d1810a3a0a0acefc67abe1daf6d6cd09e4) commit dcba4f2b43809023a9ffb25080fb68c21e53e5df Author: Mateusz Guzik Date: Wed Jan 27 13:25:21 2021 +0100 conf/kern.mk: save some work by using realpath instead of cd ; pwd I did not check if the entire ordeal can be avoided in the first place. (cherry picked from commit bcb7f57aa22757dd0206e88894bc003a93d0c351) commit 742285d283012c0022e9acdbe9ed1c7dd5cbb5e6 Author: Mateusz Guzik Date: Tue Jan 26 17:19:12 2021 +0100 cache: tidy up handling of foo/bar lookups where foo is not a directory The code was performing an avoidable check for doomed state to account for foo being a VDIR but turning VBAD. Now that dooming puts a vnode in a permanent "modify" state this is no longer necessary as the final status check will catch it. (cherry picked from commit a098a831a162fcd55b0097c95e6840621d8c720a) commit 82efef21d051796c97796f85ff3fda76104bedb7 Author: Mateusz Guzik Date: Tue Jan 26 21:31:16 2021 +0100 cache: stop referring to removing entries as invalidating them Said use is a remnant from the old code and clashes with the NCF_INVALID flag. (cherry picked from commit a51eca7936db50a57d2324d945c3be715df749cd) commit 51927c36b8a9d789534258bfd94e0018ee96381f Author: Mateusz Guzik Date: Tue Jan 26 01:40:47 2021 +0100 cache: convert cache_fplookup_parse to void now that it always succeeds (cherry picked from commit 6943671b481e571f2f1ffbe407a4d75241d1174e) commit 1f28a3afe4d227e1f401ea37c97a134eeff1b376 Author: Mateusz Guzik Date: Mon Jan 25 21:49:09 2021 +0100 cache: change ->v_cache_dd synchronisation rules Instead of resorting to seqc modification take advantage of immutability of entries and check if the entry still matches after everything got prepared. (cherry picked from commit e7cf562a40fc093df054bd7fa6f34746069a984a) commit 9375a93b6c225d32b24bd141c0033402feebb185 Author: Mateusz Guzik Date: Mon Jan 25 21:29:54 2021 +0100 cache: make ->v_cache_dd accesses atomic-clean for lockless usage (cherry picked from commit 6f0842764946ed57382293cc3361b86955308084) commit 247f652e622d9aebda627ea34ba5af242dbb835e Author: Mateusz Guzik Date: Mon Jan 25 21:58:59 2021 +0100 cache: make ->nc_flag accesses atomic-clean for lockless usage (cherry picked from commit 6ef8fede86f3feed7fb1e15b0e8a32ecfec33c6c) commit 8a44ccd0588966b5687c30644e83ab1eef9683e3 Author: Mateusz Guzik Date: Sat Jan 23 20:41:40 2021 +0100 cache: store vnodes in local vars in cache_zap_locked (cherry picked from commit ffcf8f97f8a8fb92689793003acabc0a2fe97af4) commit 872a0097fd81235cea5730e642daf725e8bf8afc Author: Mateusz Guzik Date: Mon Jan 25 21:17:48 2021 +0100 tmpfs: drop acq fence now that vn_load_v_data_smr has consume semantics (cherry picked from commit c09f7992714559eaa874f13ea4a1d648f199cd08) commit 7ba12ba0a2df573d055c7f088e666d86e4fea898 Author: Mateusz Guzik Date: Mon Jan 25 21:15:19 2021 +0100 zfs: use atomic_load_consume_ptr for z_cached_symlink (cherry picked from commit 7af02ef0b222eebad4827a264454e85134692e94) commit e8d3e38845697ae831a472870d0bddd991e9041b Author: Mateusz Guzik Date: Mon Jan 25 21:19:08 2021 +0100 vfs: use atomic_load_consume_ptr in vn_load_v_data_smr (cherry picked from commit 8d2a230e996c8aec2ec4883d45f7ac38070bd38f) commit fc301c224b272a522bff817e12fcbf99a7a17330 Author: Mateusz Guzik Date: Mon Jan 25 21:09:41 2021 +0100 atomic: add stub atomic_load_consume_ptr (cherry picked from commit 054ce2b0371042c0dbc4b3ab1d7e7795ad75d51e) commit e92ab3adf4f9848933439c9c2fca36df290c0884 Author: Mateusz Guzik Date: Mon Jan 25 20:39:14 2021 +0100 atomic: make atomic_store_ptr type-aware (cherry picked from commit cc96f92a570e05636a20fdd15d4616b127bb9ecc) commit dde453cf7d3a272ee9319ba6d9e27d34e6b6da6f Author: Mateusz Guzik Date: Mon Jan 25 21:28:05 2021 +0000 zfs: fix panics with invariant kernels from zfs_replay_setattr (cherry picked from commit f40d6217f20d69427b58d82ce4e29d88bf4dfbd6) commit aa411f6ba17b91af720129bd7593df4c7093f8a4 Author: Mateusz Guzik Date: Sun Jan 24 21:04:01 2021 +0100 cache: assorted cleanups (cherry picked from commit 868643e7229b7959024880cda396fef87602b948) commit c700b1babaa874dc6327dd62e80c96b34109c6eb Author: Mateusz Guzik Date: Sun Jan 24 21:00:03 2021 +0100 cache: track calls to cache_symlink_alloc with unsupported size While here assert on size passed to free. (cherry picked from commit 1c7a65adb002cf96bda1f72d9a26dd4237368263) commit 3eae6412b50bbcfe1a7affc26202dc896aedd1ab Author: Mateusz Guzik Date: Sun Jan 24 05:34:22 2021 +0100 libc: try to skip memcpy in _gettemp (cherry picked from commit b22fdf45ff8ef1d1f9a6c28f1d7f59ca4b012da6) commit 410994f463351fe2899af77c797dd61c772b02cf Author: Mateusz Guzik Date: Sun Jan 24 05:32:46 2021 +0100 libc: remove open-coded strlen in _gettemp (cherry picked from commit 6fe328ace8f418bab0ab7f78c6fa1f2e757dd8a9) commit 996912046b4d7188636cc4da6a3808010862e93e Author: Mateusz Guzik Date: Sun Jan 24 05:15:13 2021 +0100 libc: skip spurious stat in _gettemp It was only done to catch ENOTDIR, but the kernel already returns the error where appropriate. (cherry picked from commit 97a463120bf99819fcb21a781e410fb43dde2a43) commit ba0689009b712c558f4ec2b28202a4e45c5bab91 Author: Mateusz Guzik Date: Sat Jan 23 18:21:42 2021 +0100 cache: add back target entry on rename (cherry picked from commit 02ec31bdf60fa3a8530544cb3c8c4ec1df6cde0d) commit c5fcd06736f93ab6dd7b93d54dbeae68ae06ed7b Author: Mateusz Guzik Date: Sat Jan 23 13:46:32 2021 +0000 zfs: add support for lockless symlink lookup Reviewed by: kib (previous version) Tested by: pho (previous version) Differential Revision: https://reviews.freebsd.org/D27488 (cherry picked from commit 3110d4ebd6c0848cf5e25890d01791bb407e2a9b) commit 080f149046070dfd4c99ea3639634864b02d0f80 Author: Mateusz Guzik Date: Sat Jan 23 13:45:01 2021 +0000 tmpfs: add support for lockless symlink lookup Reviewed by: kib (previous version) Tested by: pho (previous version) Differential Revision: https://reviews.freebsd.org/D27488 (cherry picked from commit 618029af508be2c01a84162c1bad02bfd000db27) commit afea6cb020db328a3cd8e6abcc58b1a5f0cb4b31 Author: Mateusz Guzik Date: Sat Jan 23 13:42:16 2021 +0000 ufs: denote lack of support for lockless symlink lookup It is unclear without investigating if it can be provided without using extra memory, so for the time being just don't. (cherry picked from commit c892d60a1d3e11c7e0651705bc4167b218a7415c) commit dcee9964238b12a8e55917f292139f074b1a80b2 Author: Mateusz Guzik Date: Sat Jan 23 13:40:48 2021 +0000 cache: add symlink support to lockless lookup Reviewed by: kib (previous version) Tested by: pho (previous version) Differential Revision: https://reviews.freebsd.org/D27488 commit 69c5fa5cd1ec9b09ed88a086607a8a0993818db9 Author: Mateusz Guzik Date: Mon Feb 1 13:18:27 2021 +0100 zfs: remove incomplete ifdefs for lockless symlink support This wil be handled differently upstream and merged later. commit 3447df8bc5b342bd88d565641435284ff620ee2a Author: Navdeep Parhar Date: Mon Feb 1 03:00:09 2021 -0800 cxgbe(4): Fixes to tx coalescing. - The behavior implemented in r362905 resulted in delayed transmission of packets in some cases, causing performance issues. Use a different heuristic to predict tx requests. - Add a tunable/sysctl (hw.cxgbe.tx_coalesce) to disable tx coalescing entirely. It can be changed at any time. There is no change in default behavior. commit 5cf6f1c4bc281ac45ced086bc2e393f732f2fcc2 Author: Alex Richardson Date: Sat Jan 30 17:56:35 2021 +0000 Remove the MK_LIBCPLUSPLUS option This option has been equivalent to any form of C++ support since libstdc++ was removed. Therefore, replace all MK_LIBCPLUSPLUS uses with MK_CXX. Reviewed By: emaste Differential Revision: https://reviews.freebsd.org/D27974 commit 6bc1f8425560fa3e2ebc6ac3367967a083ccf6e0 Author: Hans Petter Selasky Date: Mon Jan 25 11:22:55 2021 +0100 MFC 064009e79462: Add support for enabling and disabling IFCAP_VLAN_HWTSO via ifconfig(8) in mlx5en(4). Sponsored by: Mellanox Technologies // NVIDIA Networking (cherry picked from commit 064009e79462dea517aa7f1a857fb4d5393caa69) commit 22aca672689130e683672e8e9164e24e598fe377 Author: Hans Petter Selasky Date: Tue Jan 26 17:01:34 2021 +0100 MFC b8051298b0a3: Fix missing value in uar_page field for ratelimit in mlx5en(4). This is a regression issue after the new UAR API was introduced by f8f5b459d21e . Sponsored by: Mellanox Technologies // NVIDIA Networking (cherry picked from commit b8051298b0a345ae0bdfcd2ddf89bca1b96c6c2a) commit d6f9c5a6d2f87865f9714d2b8dfd1a9f3080c71e Author: Oleksandr Tymoshenko Date: Sun Jan 31 23:56:22 2021 -0800 mips: fix NLM platforms breakage caused by e0a0a3ef NetLogic platforms have their own implementation of cpu_init_interrupts. Apply the same logic to it as to intr_machdep.c. PR: 253051 commit b760436e1381bc43368db9252a3da1427c5a4885 Author: Bjoern A. Zeeb Date: Mon Jan 25 22:41:50 2021 +0000 firmware(9): extend firmware_get() by a "no warn" flag. With the upcoming usage from LinuxKPI but also from drivers ported natively we are seeing more probing of various firmware (names). Add the ability to firmware(9) to silence the "firmware image loading/registering errors" by adding a new firmware_get_flags() functions extending firmware_get() and taking a flags argument as firmware_put() already does. Requested-by: zeising (for future LinuxKPI/DRM) Sponsored-by: The FreeBSD Foundation Sponsored-by: Rubicon Communications, LLC ("Netgate") MFC after: 3 days Reviewed-by: markj Differential Revision: https://reviews.freebsd.org/D27413 (cherry picked from commit 6f65b505468aa8cedc57235604bd8df540d42735) commit b06fd805cc871cbde03d3ce8310adf09c9d581b4 Author: Kyle Evans Date: Thu Jan 28 08:27:28 2021 -0600 tmpfs: push VEXEC check into tmpfs_lookup() vfs_cache_lookup() has already done the appropriate VEXEC check, therefore we must not re-check in VOP_CACHEDLOOKUP. This fixes O_SEARCH semantics on tmpfs and removes a redundant descent into VOP_ACCESS() in the common case. (cherry picked from commit 0f919ed4ae4df082eefb517afe02752b1790afd3) commit e6ff6154d2034c13f3d0da73c1e00d69fdb36516 Author: Mateusz Guzik Date: Mon Feb 1 04:00:13 2021 +0100 x86: use compiler intrinsics for bswap* commit aae89f6f09576351cc3a9a54959649e60fdd849b Author: Mateusz Guzik Date: Mon Feb 1 00:35:30 2021 +0100 amd64: use compiler intrinsics for bsf* and bsr* commit 6f19dc2124a31aadf419743288d2ec1abd895563 Author: Mateusz Guzik Date: Sun Jan 31 21:54:35 2021 +0100 cache: add delayed degenerate path handling commit bbfb1edd70e15241d852d82eb7e1c1049a01b886 Author: Mateusz Guzik Date: Sun Jan 31 19:25:18 2021 +0100 cache: move hash computation into the parsing loop commit 3f185aacc58bc21fee050c0a5049894ca4967a68 Author: Alexander Motin Date: Mon Jan 25 16:08:06 2021 -0500 Decode NFIT Platform Capabilities. (cherry picked from commit 1b109c69ed625ebf292c1d16f7a3efcab96722e5) commit af885c57d65d33c0306e91d3e090e76772a0d012 Author: Michael Tuexen Date: Sun Jan 31 23:43:15 2021 +0100 sctp: improve input validation Improve the handling of INIT chunks in specific szenarios and report and appropriate error cause. Thanks to Anatoly Korniltsev for reporting the issue for the userland stack. MFC after: 3 days commit e0a0a3efcb09a10ad1de29aca622ea580b2663d2 Author: Oleksandr Tymoshenko Date: Fri Jan 29 22:11:24 2021 -0800 mips: fix early kernel panic when setting up interrupt counters Commit 248f0ca converted intrcnt and intrnames from u_long[] and char[] to u_long* and char* respectively, but for non-INTRNG mips these symbols were defined in .S file as a pre-allocated static arrays, so the problem wasn't cought at compile time. Conversion from an array to a pointer requires pointer initialization and it wasn't done for MIPS, so whatever happenned to be in the begginning of intcnt[] array was used as a pointer value. Move intrcnt/intrnames to C code and allocate them dynamically although with a fixed size at the moment. Reviewed by: emaste PR: 253051 Differential Revision: https://reviews.freebsd.org/D28424 MFC after: 1 day commit 5299d64b2b9f7a25e423ef1785d9402a0ef198d3 Author: Edward Tomasz Napierala Date: Sun Jan 31 21:41:55 2021 +0000 libc: fix buffer overrun in getrpcport(3) Reviewed By: markj Sponsored by: NetApp, Inc. Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D27332 commit b8073b3c74342113398f36a1c68f442ae9e092e6 Author: Edward Tomasz Napierala Date: Sun Jan 31 21:37:41 2021 +0000 msdosfs: fix vnode leak with msdosfs_rename() This could happen when failing due to disappearing source file. Reviewed By: kib Tested by: pho Sponsored by: NetApp, Inc. Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D27338 commit cb696212495995c8374d9fe12fbae340614af45c Author: Edward Tomasz Napierala Date: Sun Jan 31 21:07:02 2021 +0000 msdosfs: fix double unlock if the source file disappears We would unlock fvp here, only to unlock it again below, just before "bad". Reviewed By: kib Tested by: pho Sponsored by: NetApp, Inc. Sponsored by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D27339 commit 10328f8b112381e25e324688c8603caf4cee94ac Merge: 9dc7c250b8b 47a52dc4d48 Author: Stefan Eßer Date: Sun Jan 31 21:07:42 2021 +0100 Merge commit '47a52dc4d48f259ab7d9f9ba6b65f4f2331a22dc' Update to version 3.2.6 MFC after: 3 days commit 47a52dc4d48f259ab7d9f9ba6b65f4f2331a22dc Author: Stefan Eßer Date: Sun Jan 31 20:56:48 2021 +0100 Vendor import of Gavin Howard's bc version 3.2.6 commit 9dc7c250b8bd2d5e669c7633e189a700a02c0571 Author: Alexander Motin Date: Sun Jan 31 12:46:57 2021 -0500 cxgb(4): Remove assumption of physically contiguous mbufs. Investigation of iSCSI target data corruption reports brought me to discovery that cxgb(4) expects mbufs to be physically contiguous, that is not true after I've started using m_extaddref() in software iSCSI for large zero-copy transmissions. In case of fragmented memory the driver transmitted garbage from pages following the first one due to simple use of pmap_kextract() for the first pointer instead of proper bus_dmamap_load_mbuf_sg(). Seems like it was done as some optimization many years ago, and at very least it is wrong in a world of IOMMUs. This patch just removes that optimization, plus limits packet coalescing for mbufs crossing page boundary, also depending on assumption of one segment per packet. MFC after: 3 days Sponsored by: iXsystems, Inc. Reviewed by: mmacy, np Differential revision: https://reviews.freebsd.org/D28428 commit c060c19240ea257fb2560833c5bd86e43830f255 Author: Alexander Motin Date: Thu Jan 28 18:18:53 2021 -0500 Add missing newlines. (cherry picked from commit 8fee65d0c70c99999b2fe5b49b267547b7ed2a49) commit 38da7d23b6c3f2c1261e33645128f64855a469ef Author: Alexander Motin Date: Thu Jan 28 15:53:49 2021 -0500 Make software iSCSI more configurable. Move software iSCSI tunables/sysctls into kern.icl.soft subtree. Replace several hardcoded length constants there with variables. While there, stretch the limits to better match Linux' open-iscsi and our own initiator with new MAXPHYS of 1MB. Our CTL target is also optimized for up to 1MB I/Os, so there is also a match now. For Windows 10 and VMware 6.7 initiators at default settings it should make no change, since previous limits were sufficient there. Tests of QD1 1MB writes from FreeBSD over 10GigE link show throughput increase by 29% on idle connection and 132% with concurrent QD8 reads. Sponsored by: iXsystems, Inc. (cherry picked from commit b75168ed24ca74f65929e5c57d4fed5f0ab08f2a) commit 8eeeee38f4c5b2b48d03f3c5a3fa678962e8c9ed Author: Kyle Evans Date: Sun Jan 31 10:07:31 2021 -0600 tools: boot: use four jobs for building stand Parallel builds of stand should be assumed both possible and safe as of 7012461c9bf6, so let's start using some jobs to speed up lualoader test harness builds. commit f1be262ec11c1c35e6485f432415b5b52adb505d Author: Mateusz Guzik Date: Sun Jan 31 16:46:18 2021 +0100 amd64: move memcmp checks upfront This is a tradeoff which saves jumps for smaller sizes while making the 8-16 range slower (roughly in line with the other cases). Tested with glibc test suite. For example size 3 (most common with vfs namecache) (ops/s): before: 407086026 after: 461391995 The regressed range of 8-16 (with 8 as example): before: 540850489 after: 461671032 commit 0db6aef407f30c138982b8cde43189aad098b337 Author: Mateusz Guzik Date: Sun Jan 31 16:50:34 2021 +0100 amd64: add a note about simd to libc memset, memmove and memcmp commit 46f168bc665a1aee79d91bd102aef7d4754e7917 Author: Mateusz Guzik Date: Sun Jan 31 13:23:42 2021 +0100 Drop temporary compat in setproctitle commit b24872cf7b13314669ed2136c0262bb2eb007695 Author: Kyle Evans Date: Sun Jan 31 09:51:39 2021 -0600 lualoader: position hyphens at the beginning of character classes According to the Lua 5.4 manual section 6.4.1 ("Patterns"), the interaction between ranges and classes is not defined and hyphens must be specified at either the beginning or the end of a set if they are not escaped. Move all such occurrences to the beginning. Reported-by: _parv (twitter) MFC-after: 3 days commit 7ba4d0f82955d5c229bf339a53f07c191b1b675b Author: Emmanuel Vadot Date: Wed Jan 27 23:31:18 2021 +0100 release: ROCKPRO64: Remove the quirk that disable the big cores It's not needed anymore. (cherry picked from commit 183d6cc0e0db8bd4653245abc1ca30b34ed09d9f) commit e027e24bfac7dd311ddacaec73d6c42102069511 Author: Mateusz Guzik Date: Tue Jan 26 01:38:21 2021 +0100 cache: add trailing slash support Tested by: pho commit 8cbd164a179c182e8fd4a71f366bc48fe840eafb Author: Mateusz Guzik Date: Tue Jan 26 23:14:49 2021 +0100 cache: handle NOFOLLOW requests for symlinks Tested by: pho commit 78c93a1721143db656e277f7827ec4d57826044c Author: Alexander V. Chernikov Date: Sun Jan 31 10:48:47 2021 +0000 Use process fib for inet/inet6 fib_algo sysctls. This allows to set/query fib algo for non-default fibs. MFC after: 3 days commit 8dc6a1edca6de0c64f6c082f69097746d1346592 Author: Michael Tuexen Date: Sun Jan 31 10:46:23 2021 +0100 sctp: fix a locking issue for old unordered data Thanks to Anatoly Korniltsev for reporting the issue for the userland stack. MFC after: 3 days commit e4c81e46acc0dc34fa6a680ad06f9b003675f86d Author: Vincenzo Maffione Date: Sun Jan 24 21:59:02 2021 +0000 netmap: simplify parameter passing Changes imported from the netmap github. (cherry picked from commit ee0005f11f2b38a714bc66b7d79832108f6fee77) commit a8ca736bb4edb18848b6a828d946d1ddee419b56 Author: Vincenzo Maffione Date: Sun Jan 24 21:38:59 2021 +0000 iflib: netmap: move per-packet operation out of fragments loop MFC after: 1 week (cherry picked from commit f80efe5016ba01b2948ca1f0eb8fe34adab5b864) commit e0e00874a3c30a8d418417d5901c065f15b5896e Author: Vincenzo Maffione Date: Sun Jan 24 21:12:41 2021 +0000 iflib: netmap: add support for NS_MOREFRAG The NS_MOREFRAG flag can be set in a netmap slot to represent a multi-fragment packet. Only the last fragment of a packet does not have the flag set. On TX rings, the flag may be set by the userspace application. The kernel will look at the flag and use it to properly set up the NIC TX descriptors. On RX rings, the kernel may set the flag if the packet received was split across multiple netmap buffers. The userspace application should look at the flag to know when the packet is complete. Submitted by: rajesh1.kumar_amd.com Reviewed by: vmaffione MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D27799 (cherry picked from commit aceaccab659c9eb846fb21ff99be34434a9616c7) commit 7754ef5a37245271c2a6832ad0a1289e25abff09 Author: Vincenzo Maffione Date: Sat Jan 23 13:44:24 2021 +0000 axgbe: fix some link related issues By default, axgbe driver does a receiver reset after predefined number of retries for the link to come up. However, this receiver reset doesn't always suffice, due to an hardware issue. In that case, as a workaround, a complete phy reset is necessary. This patch introduces a sysctl that can be set to 1 to let the driver reset the phy completely, rather than just doing receiver reset. The workaround will be removed once the issue is fixed by means of firmware update. This patch also fixes the handling of the direct attach cables properly. Submitted by: rajesh1.kumar_amd.com Differential Revision: https://reviews.freebsd.org/D28266 (cherry picked from commit bfd75d45571958398a043517060d8c3d352e7dbd) commit 2ef3f7f5c356496bbfbb71b26d4a9d9415f3b8c5 Author: Cy Schubert Date: Wed Jan 27 21:52:08 2021 -0800 MFC 0e01ea872ee475d7aef11d21588504e2ef4eb32c: Fix a typo. (cherry picked from commit 0e01ea872ee475d7aef11d21588504e2ef4eb32c) commit 514caf57cda8f2b95a7f32575519fdd18f0cae0a Author: Cy Schubert Date: Thu Jan 14 20:32:16 2021 -0800 MFC: 83edbc3cb54fba6b37a68270c232df7b785bd222 ipfilter: Retire pre-standard C support. All C compilers in 2021 support standard C and architectures that did not were retired long ago. Simplify by removing now redundant pre-standard C code. (cherry picked from commit 83edbc3cb54fba6b37a68270c232df7b785bd222) commit 151ec796a23098279531eaebbf30d08a0877ee4e Author: Alexander V. Chernikov Date: Sat Jan 30 22:45:46 2021 +0000 Fix the design problem with delayed algorithm sync. Currently, if the immutable algorithm like bsearch or radix_lockless receives rtable update notification, it schedules algorithm rebuild. This rebuild is executed by the callout after ~50 milliseconds. It is possible that a script adding an interface address and than route with the gateway bound to that address will fail. It can happen due to the fact that fib is not updated by the time the route addition request arrives. Fix this by allowing synchronous algorithm rebuilds based on certain conditions. By default, these conditions assume: 1) less than net.route.algo.fib_sync_limit=100 routes 2) routes without gateway. * Move algo instance build entirely under rib WLOCK. Rib lock is only used for control plane (except radix algo, but there are no rebuilds). * Add rib_walk_ext_locked() function to allow RIB iteration with rib lock already held. * Fix rare potential callout use-after-free for fds by binding fd callout to the relevant rib rmlock. In that case, callout_stop() under rib WLOCK guarantees no callout will be executed afterwards. MFC after: 3 days commit dd9163003cb1be494609d904521e8dae7737caa7 Author: Alexander V. Chernikov Date: Sat Jan 30 21:52:44 2021 +0000 Add rib_subscribe_locked() and rib_unsubsribe_locked() to support subscriptions during RIB modifications. Add new subscriptions to the beginning of the lists instead of the end. This fixes the situation when new subscription is created int the callback for the existing subscription, leading to the subscription notification handler pick it. MFC after: 3 days commit ab6d9aaed76ed9f86fd0d938ebb6ea81f5ad6a82 Author: Alexander V. Chernikov Date: Sat Jan 30 22:32:42 2021 +0000 Move business logic from rebuild_fd_callout() into rebuild_fd(). This simplifies code a bit and allows for future non-callout callers to request rebuild. MFC after: 3 days commit f8b7ebea4905d84032f3195f86f6c27842e7a286 Author: Alexander V. Chernikov Date: Sat Jan 30 22:06:40 2021 +0000 Improve fib_algo debug messages. * Move per-prefix debug lines under LOG_DEBUG2 * Create fib instance counter to distingush log messages between instances * Add more messages on rebuild reason. MFC after: 3 days commit 91f2c69ec206c2993722bfd818a8888f8237fa7e Author: Alexander V. Chernikov Date: Sat Jan 30 23:24:26 2021 +0000 Fix unused-function waring when compiling with FIB_ALGO. MFC after: 3 days commit d51cc252a062411a1656960eb5d47e954c6c835d Author: Toomas Soome Date: Sat Jan 30 21:16:20 2021 +0200 userboot: provide stub gfx functions Make sure we have needed functions present, to avoi getting undefined symbols error(s). PR: 253088 Reported by: John Kennedy commit 4a26380ba6dc487a7525d909ee29fbc710b558d1 Author: Bjoern A. Zeeb Date: Sat Jan 30 17:50:26 2021 +0000 LinuxKPI: add module dependency on firmware(9) In a6c2507d1baedb183268e31bc6b6f659a9529904 support for LinuxKPI firmware loading was added. Record the dependency on firmware(9) as otherwise (if built as module) linuxkpi will no longer load. Reported-by: tijl MFC after: 1 day X-MFC-with: a6c2507d1baedb183268e31bc6b6f659a9529904 Sponsored-by: The FreeBSD Foundation commit 69557375226a4ab26eadd47007c1230ce5ce9077 Author: Ed Maste Date: Sat Jan 30 12:43:42 2021 -0500 Remove unused GNUCXX option descriptions Missed from 57f804675e65 Reported by: arhchardson in D27974 Sponsored by: The FreeBSD Foundation commit 7436a63ba908a52f1a11f202dbacd9f5eb5b9fee Author: Robert Wing Date: Fri Jan 29 14:18:28 2021 -0900 g_provider_by_name(9): argument can be a geom name or fullpath The argument passed to g_provider_by_name(9) can be a geom name or a fullpath. - g_provider_by_name() gained this functionality in 769afdc71ea6b0c09dae883ce49d913cbc8cff5b. Reviewed by: imp, kevans Approved by: kevans (mentor) Differential Revision: https://reviews.freebsd.org/D27566 commit 7587d9823a8257b9a2d5b2e58c707026061058c6 Author: Kyle Evans Date: Sat Jan 30 00:09:10 2021 -0600 build: options: mention ports in the WITH_OPENLDAP description There's a third party dependency on this option; currently, net/openldap24-{,sasl-}client. At least mention that an openldap from ports is needed for this option. PR: 252866 Reported-by: Build Option Survey via Michael Dexter MFC-after: 3 days commit bb8fa72dae42c213d3f822865c0121577243ca18 Author: Jessica Clarke Date: Wed Jan 27 19:19:00 2021 +0000 libllvmminimal: Add missing Support/ABIBreak.cpp When building natively on RISC-V, linking the bootstrap clang-tblgen fails with: ld: error: undefined symbol: llvm::EnableABIBreakingChecks >>> referenced by PrettyStackTrace.cpp >>> PrettyStackTrace.o:(.sdata+0x0) in archive /usr/obj/usr/src/freebsd-src/riscv.riscv64/tmp/obj-tools/lib/clang/libllvmminimal/libllvmminimal.a >>> referenced by Signals.cpp >>> Signals.o:(.sdata+0x8) in archive /usr/obj/usr/src/freebsd-src/riscv.riscv64/tmp/obj-tools/lib/clang/libllvmminimal/libllvmminimal.a >>> referenced by Timer.cpp >>> Timer.o:(.sdata+0x28) in archive /usr/obj/usr/src/freebsd-src/riscv.riscv64/tmp/obj-tools/lib/clang/libllvmminimal/libllvmminimal.a This is likely due to Error.h's inclusion of abi-breaking.h. It's unclear why this only affects RISC-V, but perhaps relates to its more eager use of .sdata due to the ABI's support for linker relaxations. Regardless, this is theoretically an issue for all architectures. Reported by: Dennis Clarke (cherry picked from commit 48397f6c7d2d693602105d8ec24c5741202e264d) commit 1f9ee757d96dfc35e0a2d89ef5fd80f26138a693 Author: Kirk McKusick Date: Tue Jan 26 11:46:38 2021 -0800 MFC: 8c22cf9b Fix fsck_ffs incorrectly reporting "CANNOT READ BLK: NNNN" errors. A long-standing bug in Pass 1 of fsck_ffs in which it is reading in blocks of inodes to check their block pointers. It failed to round up the size of the read to a disk block size. When disks would accept 512-byte aligned reads, the bug rarely manifested itself. But many recent disks will no longer accept 512-byte aligned reads but require 4096-byte aligned reads, so the failure to properly round-up read sizes to multiples of 4096 bytes makes the error much more likely to occur. Reported by: Peter Holm and others Tested by: Peter Holm and Rozhuk Ivan MFC after: 3 days Sponsored by: Netflix (cherry picked from commit 8c22cf9b0997566ff6f576cfc9296b29bb055f65) commit 1aa1ede1fd447a1807f0cdd9ee7227b5741fecea Author: Kirk McKusick Date: Sat Jan 30 00:03:37 2021 -0800 MFC: a63eae6 Revert 2d4422e7991a, Eliminate lock order reversal in UFS ffs_unmount(). After discussion with Chuck Silvers (chs@) we have decided that there is a better way to resolve this lock order reversal which will be committed separately. Sponsored by: Netflix (cherry picked from commit a63eae65ff8789994c40573a0aa65128022c8bf2) commit a63eae65ff8789994c40573a0aa65128022c8bf2 Author: Kirk McKusick Date: Sat Jan 30 00:03:37 2021 -0800 Revert 2d4422e7991a, Eliminate lock order reversal in UFS ffs_unmount(). After discussion with Chuck Silvers (chs@) we have decided that there is a better way to resolve this lock order reversal which will be committed separately. Sponsored by: Netflix commit e948d980f78dd2789060b46d3d03ba0d96b23b59 Author: Kyle Evans Date: Sat Jan 30 00:07:17 2021 -0600 kerberos5: fix the WITH_OPENLDAP build Restore WARNS to its former glory prior to the global WARNS change to fix the build. MFC-after: 3 days commit 9ca71db4959f674d75f7b4fd0f72bdc1e2e99abb Author: Kyle Evans Date: Fri Jan 29 23:48:28 2021 -0600 ofed: fix the WITH_OFED_EXTRA build This option was not tested when WARNS was globally lifted in the src tree up to 6. Drop WARNS back down to unbreak the build; note that this is still enabling more warnings than it had before the WARNS change, so the gcc build may need to be independently evaluated at this level. PR: 252865 Reported-by: Build Option Servey via Michael Dexter MFC-after: 3 days commit 81f3a59c4601883f2b7339fd402fa2f7e8b804b3 Author: Kyle Evans Date: Wed Jan 27 12:54:07 2021 -0600 stand: ensure that the efi directory's dependencies are correct efi, like the various ${MACHINE} directories, should have a dependency on the enabled interpreters. The general rule here is that any top-level directory that has a program at any depth within that includes loader.mk should add ${INTERP_DEPENDS} added to its dependencies so that the appropriate ficl/lua bits are ready before they begin. Note that the only directories in-tree that require it but will not get it in a more appropriate manner are i386 (on amd64), efi, and userboot. i386 and userboot are handled explicitly in Makefile.amd64 where they are added to S.yes. Reported-by: bcran (cherry picked from commit 7012461c9bf6375cd0b14de16b3b4a753c5c1c7a) commit 29f37e9bcc67d5d94c9d6bbbcf2717e16bf25c4e Author: Jung-uk Kim Date: Tue Jan 5 22:13:30 2021 -0500 acpica: Import ACPICA 20210105. (cherry picked from commit a61ec1492c58c40bd0d968794c380668c157e2ef) commit 385fb5d933b55dbfe6f0eaf4d937ee89026c9ef5 Author: Jung-uk Kim Date: Mon Jan 4 17:20:55 2021 -0500 acpica: Import ACPICA 20201217. (cherry picked from commit a4634ed7779f0905e3bfeb781e58d40a5bdf9bb7) commit a455b23cf348885491f83c6a4734bb6fddf0d481 Author: Mark Johnston Date: Wed Jan 27 15:31:10 2021 -0500 qat.4: Minor tweaks - Document a constraint on the AAD size for AES-GCM. - Note that the list of supported platforms and add-on devices is not complete and indicate that QAT devices will show up in pciconf output. [1] PR: 252984 [1] Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit e1b50e8184fca00520774d43bd7bdd0ccbe9a1d2) commit ef6fb23322a62abae67af779d93535ff2051e17e Author: Mark Johnston Date: Wed Jan 27 15:31:10 2021 -0500 safexcel: Disallow unsupported buffer layouts Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit 2fccd4f9b6b96d75de87df4922eb2bf04fb0a67d) commit 19d2d50e431895dc8a476a1b29ea92c033c87b2d Author: Mark Johnston Date: Sat Jan 23 10:55:09 2021 -0500 Revert "Define PNP info after defining driver modules" This reverts commit aa37baf3d7cf51da92fd367476182802e71838ae. The reverted commit was motivated by a problem observed on stable/12, but it turns out that a better solution was committed in r348309 but not MFCed. So, revert this change since it is unnecessary and not really correct: it assumes that the order in which module metadata records is defined determines their order in the output linker set. While this seems to hold in my testing, it is not guaranteed. Reported by: cem Discussed with: imp (cherry picked from commit 519b64e27fddf10c0b7f6a615edbad730b8c6c45) commit d1de5698dfe6109308d4e5d6536a2ac93941d23a Author: Mateusz Guzik Date: Sat Jan 30 00:17:15 2021 +0000 amd64: retire sse2_pagezero All page zeroing is using temporal stores with rep movs*, the routine is unused for several years. Should a need arise for zeroing using non-temporal stores, a more optimized variant can be implemented with a more descriptive name. commit 164c3b81848bc81dc200b12370999474225447a3 Author: Mateusz Guzik Date: Fri Jan 29 16:09:14 2021 +0100 amd64: add missing ALIGN_TEXT to loops in memset and memmove commit 710e45c4b8539d028877769f1a4ec088c48fb5f1 Author: Mateusz Guzik Date: Fri Jan 29 22:48:11 2021 +0100 Reimplement strlen The previous code neglected to use primitives which can find the end of the string without having to branch on every character. While here augment the somewhat misleading commentary -- strlen as implemented here leaves performance on the table, especially so for userspace. Every arch should get a dedicated variant instead. In the meantime this commit lessens the problem. Tested with glibc test suite. Naive test just calling strlen in a loop on Haswell (ops/s): $(perl -e "print 'A' x 3"): before: 211198039 after: 338626619 $(perl -e "print 'A' x 100"): before: 83151997 after: 98285919 commit 010196adcfaf2bb610725394d40691874b4ff2af Author: Dimitry Andric Date: Tue Jan 26 14:07:47 2021 +0100 Fix clang assertion when compiling the devel/onetbb port Merge commit 740a164de from llvm git (by Richard Smith): PR46377: Fix dependence calculation for function types and typedef types. We previously did not treat a function type as dependent if it had a parameter pack with a non-dependent type -- such a function type depends on the arity of the pack so is dependent even though none of the parameter types is dependent. In order to properly handle this, we now treat pack expansion types as always being dependent types (depending on at least the pack arity), and always canonically being pack expansion types, even in the unusual case when the pattern is not a dependent type. This does mean that we can have canonical types that are pack expansions that contain no unexpanded packs, which is unfortunate but not inaccurate. We also previously did not treat a typedef type as instantiation-dependent if its canonical type was not instantiation-dependent. That's wrong because instantiation-dependence is a property of the type sugar, not of the type; an instantiation-dependent type can have a non-instantiation-dependent canonical type. Merge commit 9cf98d26e from llvm git (by Richard Smith): PR46637: Fix handling of placeholder types in trailing-return-types. Only permit a placeholder type in a trailing-return-type if it would also have been permitted in the decl-specifier sequence of a corresponding declaration with no trailing-return-type. The standard doesn't actually say this, but this is the only thing that makes sense. Also fix handling of an 'auto' in a trailing-return-type in a parameter of a generic lambda. We used to crash if we saw such a thing. Merge commit 234f51a65 from llvm git (by Richard Smith): Don't crash if we deserialize a pack expansion type whose pattern contains no packs. Fixes a regression from 740a164dec483225cbd02ab6c82199e2747ffacb. PR: 252892 Reported by: thierry (cherry picked from commit e63539f3059728ff58328ac0ecb2a7bf4e2f08e8) Bump __FreeBSD_version after e63539f3059728ff58328ac0ecb2a7bf4e2f08e8 This is to allow ports to detect the clang fix applied in the above commit. PR: 252892 (cherry picked from commit 2cf84258922f306a3f84866685d2f5346f67db58) commit cb984c62d705e4229998fdb076d012666a2196da Author: Alexander V. Chernikov Date: Fri Jan 29 23:10:52 2021 +0000 Fix multipath support for rib_lookup_info(). The initial plan was to remove rib_lookup_info() before FreeBSD 13. As several customers are still remaining, fix rib_lookup_info() for the multipath use case. commit 53729367d388e4a6d0ff9be9995bcd4957e9c114 Author: Alexander V. Chernikov Date: Tue Jan 26 07:22:23 2021 +0000 Fix subinterface vlan creation. D26436 introduced support for stacked vlans that changed the way vlans are configured. In particular, this change broke setups that have same-number vlans as subinterfaces. Vlan support was initially created assuming "vlanX" semantics. In this paradigm, automatic number assignment supported by cloning (ifconfig vlan create) was a natural fit. When "ifaceX.Y" support was added, allowing to have the same vlan number on multiple devices, cloning code became more complex, as the is no unified "vlan" namespace anymore. Such interfaces got the first spare index from "vlan" cloner. This, in turn, led to the following problem: ifconfig ix0.333 create -> index 1 ifconfig ix0.444 create -> index 2 ifconfig vlan2 create -> allocation failure This change fixes such allocations by using cloning indexes only for "vlanX" interfaces. Reviewed by: hselasky MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D27505 commit 3f43ada98c89bce5ae416e203ba0e81595a5cd88 Author: Gleb Smirnoff Date: Thu Jan 28 13:08:48 2021 -0800 Catch up with 6edfd179c86: mechanically rename IFCAP_NOMAP to IFCAP_MEXTPG. Originally IFCAP_NOMAP meant that the mbuf has external storage pointer that points to unmapped address. Then, this was extended to array of such pointers. Then, such mbufs were augmented with header/trailer. Basically, extended mbufs are extended, and set of features is subject to change. The new name should be generic enough to avoid further renaming. commit cf6ff85fe847225e7b7ca1c3669cab6412076765 Author: Gleb Smirnoff Date: Thu Jan 28 12:56:36 2021 -0800 Catch up with 6edfd179c86: document M_EXTPG. While here sore flags as they are in sys/mbuf.h commit 9d4104b214963bb3371ada05cae8006940121634 Author: John Baldwin Date: Fri Jan 29 10:53:50 2021 -0800 Fix ldd to work with more ELF files. - Use libelf to parse ELF data structures and remove code duplication for ELF32. - Don't require the OSABI field to be set to the FreeBSD OSABI for shared libraries. Both AArch64 and RISC-V leave it set to "none" and instead depend on the ABI tag note. For ldd, this means falling back to walking the notes in PT_NOTE segments to find the ABI tag note to determine if an ELF shared library without OSABI set in the header file is a FreeBSD shared library. Reviewed by: kib MFC after: 5 days Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D28342 commit e25ee296c919d6567aa76058a7049eac974797fb Author: Kyle Evans Date: Sat Jan 23 19:32:38 2021 -0600 stand: lua: enhance lfs.dir() to speed up kernels_autodetect This eliminates a lot of stat() calls that happen when lualoader renders the menu with the default settings, and greatly speeds up rendering on my laptop. ftype is nil if loader/loader.efi hasn't been updated yet, falling back to lfs.attributes() to test. This is technically incompatible with lfs, but not in a particularly terrible way. Reviewed-by: cem MFC-after: 4 days Differential Revision: https://reviews.freebsd.org/D27542 commit 80a840b8ba03bafe299112e2364959d937a87fe1 Author: Ed Maste Date: Fri Jan 29 11:22:03 2021 -0500 Revert "Cirrus-CI: Use the default Git history depth" This reverts commit fcb4797c90f3f62a18b67542ae5b576a1271e6d4. With `CIRRUS_CLONE_DEPTH` unspecified (using the default of 50) the time to clone the repo increased from a little under 2 minutes to over 6 minutes, possibly due to additional processing required by GitHub. We will want to watch out for occasional `Failed to force reset to SHA: object not found!` errors. commit f17fc5439f517d06ac8976f53354789cde5a7427 Author: Ed Maste Date: Fri Jan 29 09:34:27 2021 -0500 Cirrus-CI: remove svn2git remnant Previously Cirrus was skipped on svn_head to avoid running CI on two different branches with identical content. With the transition to git this serves no purpose. Reported by: kevans Sponsored by: The FreeBSD Foundation commit fcb4797c90f3f62a18b67542ae5b576a1271e6d4 Author: Fedor Korotkov Date: Fri Jan 29 09:22:54 2021 -0500 Cirrus-CI: Use the default Git history depth Which is `50`. I saw a few errors like `Failed to force reset to SHA: object not found!` which seems is happening because the SHA is not available because there were two commits pushed almost simultaneously and the second from the top fails with this error because the SHA is not in the history. Pull Request: https://github.com/freebsd/freebsd-src/pull/454 commit b6d85a5f51e4147452b35d76478fb9e191b7734b Author: Roger Pau Monné Date: Wed Jan 27 11:12:07 2021 +0100 stand/multiboot: adjust the protocol between loader and kernel There's a currently ad-hoc protocol to hand off the FreeBSD kernel payload between the loader and the kernel itself when Xen is in the middle of the picture. Such protocol wasn't very resilient to changes to the loader itself, because it relied on moving metadata around to package it using a certain layout. This has proven to be fragile, so replace it with a more robust version. The new protocol requires using a xen_header structure that will be used to pass data between the FreeBSD loader and the FreeBSD kernel when booting in dom0 mode. At the moment the only data conveyed is the offset of the start of the module metadata relative to the start of the module itself. This is a slightly disruptive change since it also requires a change to the kernel which is contained in this patch. In order to update with this change the kernel must be updated before updating the loader, as described in the handbook. Note this is only required when booting a FreeBSD/Xen dom0. This change doesn't affect the normal FreeBSD boot protocol. This fixes booting FreeBSD/Xen in dom0 mode after 3630506b9daec9167a89bc4525638ea45a00769e. Sponsored by: Citrix Systems R&D MFC after: 3 days Reviewed by: tsoome Differential Revision: https://reviews.freebsd.org/D28411 commit ebc61c86b5567f2e5a3c5f452e86879b558b376b Author: Lutz Donnerhacke Date: Fri Jan 29 12:03:17 2021 +0100 netgraph/ng_source: Switch queuing framework Change the queuing framework from ifq to mbufq. Reported by: glebius Reviewed by: glebius, kp Approved by: kp (mentor) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D28407 commit 45e1f8541428c19f63dba65d78a8d138e1bc6915 Author: Mateusz Guzik Date: Fri Jan 29 00:52:08 2021 +0100 poll: use fget_unlocked or fget_only_user when feasible This follows select by eleminating the use of filedesc lock. This is a win for single-threaded processes and a mixed bag for others as at small concurrency it is faster to take the lock instead of refing/unrefing each file descriptor. Nonetheless, removal of shared lock usage is a step towards a mtx-protected fd table. commit 6affe1b71238df7bbbca6e2059e5494d91e68d2d Author: Mateusz Guzik Date: Fri Jan 29 00:33:46 2021 +0100 select: employ fget_only_user Since most select users are single-threaded this avoid a lot of work in the common case. For example select of 16 fds (ops/s): before: 2114536 after: 2991010 commit eaad8d1303da500ed691bd774742a4555a05e729 Author: Mateusz Guzik Date: Fri Jan 29 00:27:44 2021 +0100 fd: add fget_only_user This can be used by single-threaded processes which don't share a file descriptor table to access their file objects without having to reference them. For example select consumers tend to match the requirement and have several file descriptors to inspect. commit abd619045a54c73f41a95b3e038a5ba083391400 Author: Bjoern A. Zeeb Date: Fri Jan 29 10:57:50 2021 +0000 __FreeBSD_version: update the references to the doc tree Update the reference of which file to update in the doc tree when bumping __FreeBSD_version. commit 76dd854f47f4aea703093647a158f280d383ea6d Author: Richard Scheffenegger Date: Tue Jan 26 16:06:32 2021 +0100 TCP PRR: Patch div/0 in tcp_prr_partialack Adding a safety net prior to the division in tcp_prr_partialack function, which was missed in D28114. Reviewed-by: tuexen, mm, @transport MFC: 3 days Differential Revision: https://reviews.freebsd.org/D28326 (cherry picked from commit 6a376af0cd212be4e16d013d35a0e2eec1dbb8ae) commit e6341fd7220e8f5a3c03a7bf1ad91906e709b5ca Author: Richard Scheffenegger Date: Tue Jan 26 14:47:19 2021 +0100 Adjust line length in tcp_prr_partialack No functional changes. Reviewed By: tuexen, mm, #transport MFC: 3 days Subscribers: imp, melifaro Differential Revision: https://reviews.freebsd.org/D28329 (cherry picked from commit 84761f3df508aed50783b60f028af9d98a684b41) commit 1d15bceae63c438e3ff7dc7a0ca8a2c538e357b9 Author: Alex Richardson Date: Fri Jan 29 09:30:25 2021 +0000 tmpfs: implement pathconf(_PC_SYMLINK_MAX) This fixes one of the sys/audit tests when running them on tmpfs. Reviewed By: delphij, kib Differential Revision: https://reviews.freebsd.org/D28387 commit 892a05ee3a6abd8d84f46a1b895b1d2bf805d08a Author: Alex Richardson Date: Fri Jan 29 09:29:26 2021 +0000 Avoid double output in fenv_test This tests fork()s, so if there is still data in the stdout buffer on fork it will print it again in the child process. This was happening in the CheriBSD CI and caused the test to complain about malformed TAP output. Reviewed By: ngie Differential Revision: https://reviews.freebsd.org/D28397 commit 4d2edf3af1dbd8a3e7cf1b22343a1ecfc2dd41ba Author: Alex Richardson Date: Fri Jan 29 09:28:40 2021 +0000 test_inf_inputs: Use atf_tc_expect_fail() instead of atf_tc_skip() Reviewed By: lwhsu Differential Revision: https://reviews.freebsd.org/D28396 commit d4a6843bb1207d71234099ded81cee75d3ae8864 Author: Alex Richardson Date: Fri Jan 29 09:19:27 2021 +0000 Update comment missed in 83ff5d5d98cbcf9b66dccd70022358aec8918a14 Reported by: jrtc27 commit 07d218f70c2fdaf4ad78aaa14355be415ed58bce Author: Xin LI Date: Thu Jan 28 23:25:19 2021 -0800 Now that the portsnap buildbox is generating the raw bits for INDEX-14, add it to the set of INDEX files built by portsnap. Switch to INDEX-14 for main. commit c050ea803eaa1087313b86628b5d486c0e59e41b Author: Jamie Gritton Date: Thu Jan 28 21:51:09 2021 -0800 jail: Handle a parent jail when a child is added to it It's possible when adding a jail that its dying parent comes back to life. Only allow that to happen when JAIL_DYING is specified. And if it does happen, call PR_METHOD_CREATE on it. commit 633f82126b28d6c44beae579a7f71eb85ca1453c Author: Kyle Evans Date: Sun Jan 24 13:25:34 2021 -0600 lualoader: improve loader.conf var processing lualoader was previously not processing \ as escapes; this commit fixes that and does better error checking on the value as well. Additionally, loader.conf had some odd restrictions on values that make little sense. Previously, lines like: kernel=foo Would simply be discarded with a malformed line complaint you might not see unless you disable beastie. lualoader tries to process these as well as it can and manipulates the environment, while forthloader did minimal processing and constructed a `set` command to do the heavy lifting instead. The lua approach was re-envisioned from building a `set` command so that we can appropriately reset the environment when, for example, boot environments change. Lift the previous restrictions to allow unquoted values on the right hand side of an expression. Note that an unquoted value is effectively: [A-Za-z0-9-][A-Za-z0-9-_.]* This commit also stops trying to weirdly limit what it can handle in a quoted value. Previously it only allowed spaces, alphanumeric, and punctuation, which is kind of weird. Change it here to grab as much as it can between two sets of quotes, then let processEnvVar() do the needful and complain if it finds something malformed looking. My extremely sophisticated test suite is as follows: < Date: Thu Jan 28 21:01:12 2021 -0600 du: tests: use dollar-single quotes where appropriate No need for "foo$(printf "\t")", $'\t' is both more readable and still functional. Reported-by: Jamie Landeg-Jones commit 0f919ed4ae4df082eefb517afe02752b1790afd3 Author: Kyle Evans Date: Thu Jan 28 08:27:28 2021 -0600 tmpfs: push VEXEC check into tmpfs_lookup() vfs_cache_lookup() has already done the appropriate VEXEC check, therefore we must not re-check in VOP_CACHEDLOOKUP. This fixes O_SEARCH semantics on tmpfs and removes a redundant descent into VOP_ACCESS() in the common case. Reported-by: arichardson (via CheriBSD Jenkins CI) Reviewed-by: kib MFC-after: 3 days Differential Revision: https://reviews.freebsd.org/D28401 commit 2e814904643242895a99e71233e1f17585d093e3 Author: Kyle Evans Date: Thu Jan 28 19:21:58 2021 -0600 Regenerate src.conf(5) after 03d837b565a9 (direct commit) commit ed05bfceb8191c2d50742203512bb0378d831aba Author: Kyle Evans Date: Wed Jan 20 08:01:25 2021 -0600 build: remove LIBPTHREAD/LIBTHR build options WITHOUT_LIBTHR has been broken for a little over five years now, since the xz 5.2.0 update introduced a hard liblzma dependency on libthr, and building a useful system without threading support is becoming increasingly more difficult. Additionally, in the five plus years that it's been broken more reverse dependencies have cropped up in libzstd, libsqlite3, and libcrypto (among others) that make it more and more difficult to reconcile the effort needed to fix these options. Remove the broken options. PR: 252760 (cherry picked from commit 123ae3045dd21badb93ce52445e18e364b3ac807) (cherry picked from commit 251a6ddfbdcd72e0de922e8320d2f0cc6806a423) commit 8a51f14a7833fd14e1f125e63a0af9d260dcd287 Author: Warner Losh Date: Mon Jan 25 12:53:31 2021 -0700 newvers: tweak uname to be more useful The current uname is branch-cXXXX-gHASH Three changes to make uname more useful. 1. Move from using git rev-list --count to git rev-lis --count --first-parent since that gives a better, incrementing number. 2. Report this count as 'nXXXXX' rather than 'cXXXXX' because c is part of a hash and we've changed the sematnics of XXXXX 3. Remove g to make HASH cut and pastable. Durting review, #1 & #3 had the largest consensus. There was a diversity of opinion on #2, but on the whole it was positive so I'll acknowledge the dissent, but move forward with something seems to have support since the dissent was all about what letter to use where I chose 'n'. MFC After: 3 days Reviewed by: rgrimes, emaste (earlier version) Differential Revision: https://reviews.freebsd.org/D28338 commit 5d58f58b0d612913fd280a6acaf174019bd465ba Author: Ryan Moeller Date: Wed Jan 27 14:27:46 2021 -0500 sbin/sysctl: Fix CTLFLAG_SKIP for adjacent nodes The OID is saved when we encounter CTLFLAG_SKIP so that descendants can be skipped as well. We then must not update the skip OID until we are out of the node. This was achieved by resetting the skip OID once the prefix no longer matches, but the case where the OID we reset on has CTLFLAG_SKIP was not accounted for. Reported by: mav Reviewed by: mav Sponsored by: iXsystems, Inc. Differential Revision: https://reviews.freebsd.org/D28364 (cherry picked from commit 65efb73fbddd44116fd39b03991386a67422ba6d) commit 40cb0344eb27e0bb9a112ff50812a7e77816d6be Author: Glen Barber Date: Thu Jan 28 18:59:57 2021 -0500 release: set stable/13 to ALPHA3 as part of the 13.0 cycle Approved by: re (implicit) Sponsored by: Rubicon Communications, LLC ("Netgate") commit 8fee65d0c70c99999b2fe5b49b267547b7ed2a49 Author: Alexander Motin Date: Thu Jan 28 18:18:53 2021 -0500 Add missing newlines. MFC after: 3 days commit 0c852bb9b9282b30fd047ac1de398358f33777f4 Author: Doug Ambrisko Date: Thu Jan 28 15:12:14 2021 -0800 Add support for some more Intel VMD controllers. Some of the newer controller have a sparce bus space that can be figured out by probing the HW. This gives the starting bus number. When reading the PCI config. space behind the VMD controller, the offset of the starting bus needs to be subtracted from the bus being read. Fixed a bug in which in which not all of the devices directly attached to the VMD controller would be probed. On my initial test HW, a switch was found at bus 0, slot 0 and function 0. All of the NVME drives were behind that switch. Now scan for all slots and functions attached to bus 0. If a something was found then run attach after the scan. On detach also go through all slots and functions on bus 0. Tested with device ID's: 0x201d & 0x9a0b Tested by: nc@ MFC after: 7 days PR: 252253 commit 5c689e213614bff65e9789875f839aa05053126b Author: Vladimir Kondratyev Date: Fri Jan 29 00:35:11 2021 +0300 hsctrl: Fix manpage typo Use hsctrl_load to load the module at boot time. Submitted by: Shunchao Hu Reviewed by: wulf MFC after: 3 days Differential revision: https://reviews.freebsd.org/D28343 commit b1f1917de48b3eda092937c2af159aa5bc116d37 Author: Allan Jude Date: Thu Jan 28 21:31:40 2021 +0000 Regenerate src.conf.5 after enabling MK_OPENSSL_KTLS for arm64 commit e6b7809cdfc4389d2fc1df2c7fdff08a4a110c77 Author: Allan Jude Date: Thu Jan 28 21:28:18 2021 +0000 Flip the default for OPENSSL_KTLS to arm64 This is required to make use of KERN_TLS Reviewed by: jhb Sponsored by: Ampere Computing Submitted by: Klara, Inc. Differential Revision: https://reviews.freebsd.org/D28405 commit b75168ed24ca74f65929e5c57d4fed5f0ab08f2a Author: Alexander Motin Date: Thu Jan 28 15:53:49 2021 -0500 Make software iSCSI more configurable. Move software iSCSI tunables/sysctls into kern.icl.soft subtree. Replace several hardcoded length constants there with variables. While there, stretch the limits to better match Linux' open-iscsi and our own initiator with new MAXPHYS of 1MB. Our CTL target is also optimized for up to 1MB I/Os, so there is also a match now. For Windows 10 and VMware 6.7 initiators at default settings it should make no change, since previous limits were sufficient there. Tests of QD1 1MB writes from FreeBSD over 10GigE link show throughput increase by 29% on idle connection and 132% with concurrent QD8 reads. MFC after: 3 days Sponsored by: iXsystems, Inc. commit d2c9d0a41811344a2a0bf517d96d52d7c350c88e Author: John Baldwin Date: Thu Jan 28 12:18:54 2021 -0800 Bump date after ae257282ae5b. commit f9322ff6efa508df8368e31e3c4880cff11b0e23 Author: Allan Jude Date: Thu Jan 28 20:48:37 2021 +0000 Enable KERN_TLS by default in ARM64 GENERIC Sponsored-by: Ampere Computing Submitted-by: Klara, Inc. commit 4f9548640dd1c7e9602f0d01647b112e51792224 Author: Ed Maste Date: Thu Jan 28 15:02:24 2021 -0500 arch.7: update 11.x to 11.4 as the last FreeBSD 11 release armeb and pc98 were both discontinued after FreeBSD 11. FreeBSD 11.4 is now known to be the final 11.x release, so update to the specific version. commit c926114f2ff20d7c3e5a157f1618b6228f391bf7 Author: Bryan Drewery Date: Wed Jan 27 09:59:50 2021 -0800 Fix getblk() with GB_NOCREAT returning false-negatives. It is possible for a buf to be reassigned between the dirty and clean lists while gbincore_unlocked() looks in each list. Avoid creating a buffer in that case and fallback to a locked lookup. This fixes a regression from r363482. More discussion on potential improvements to the clean and dirty lists handling is in the review. Reviewed by: cem, kib, markj, vangyzen, rlibby Reported by: Suraj.Raju at dell.com Submitted by: Suraj.Raju at dell.com, cem, [based on both] MFC after: 2 weeks Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D28375 commit ae257282ae5b08db94ae46271d0fc3c24f0a0a4b Author: John Baldwin Date: Tue Jan 26 14:33:08 2021 -0800 Regenerate src.conf.5 for MK_OPENSSL_KTLS commit bb8acd558e66bd4bae31602fcbe569863f47382c Author: Jung-uk Kim Date: Tue Jan 26 14:26:51 2021 -0800 OpenSSL: Regenerate manual pages. MFC after: 1 week commit aa906e2a4957db700d9e6cc60857e1afe1aecc85 Author: John Baldwin Date: Fri Jan 15 16:17:31 2021 -0800 OpenSSL: Support for kernel TLS offload (KTLS) This merges upstream patches from OpenSSL's master branch to add KTLS infrastructure for TLS 1.0-1.3 including both RX and TX offload and SSL_sendfile support on both Linux and FreeBSD. Note that TLS 1.3 only supports TX offload. A new WITH/WITHOUT_OPENSSL_KTLS determines if OpenSSL is built with KTLS support. It defaults to enabled on amd64 and disabled on all other architectures. Reviewed by: jkim (earlier version) Approved by: secteam Obtained from: OpenSSL (patches from master) MFC after: 1 week Relnotes: yes Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D28273 commit 9a0a48b12d3d85f0f00b99439e6a8779f5f1abb6 Author: Alex Richardson Date: Thu Jan 28 17:25:50 2021 +0000 usr.sbin/pkg: Don't re-define roundup2 The file already includes sys/param.h and should use that definition. I found this while testing D28332. Reviewed By: bapt Differential Revision: https://reviews.freebsd.org/D28331 commit 869cc06480b75b4caea0d049e0cf7f82bb5aeed1 Author: Alex Richardson Date: Thu Jan 28 17:23:27 2021 +0000 tests/sys/audit: fix timeout calculation This changes the behaviour to a 30s total timeout (needed when running on slow emulated uniprocessor systems) and timing out after 10s without any input. This also uses timespecsub() instead of ignoring the nanoseconds field. After this change the tests runs more reliably on QEMU and time out less frequently. Reviewed By: asomers Differential Revision: https://reviews.freebsd.org/D28391 commit 83ff5d5d98cbcf9b66dccd70022358aec8918a14 Author: Alex Richardson Date: Thu Jan 28 17:17:49 2021 +0000 Un-XFAIL two tests with Clang > 10 SVN r343917 fixed this for in-tree clang, but when building with a newer out-of-tree clang the test was still marked as XFAIL. Reviewed By: dim Differential Revision: https://reviews.freebsd.org/D28390 commit bcc5b2445674e4691853d7533e4873a6712f67ee Author: Alex Richardson Date: Thu Jan 28 17:17:07 2021 +0000 rc.d/auditd: set pidfile auditd creates a pidfile so we should use it for status checks. This also seems to speed up the frequent onestatus checks used in tests/sys/audit. Reviewed By: asomers Differential Revision: https://reviews.freebsd.org/D28389 commit 1a714ff204193b9eb810426048e03f5d76e9730e Author: Randall Stewart Date: Tue Jan 26 11:54:42 2021 -0500 This pulls over all the changes that are in the netflix tree that fix the ratelimit code. There were several bugs in tcp_ratelimit itself and we needed further work to support the multiple tag format coming for the joint TLS and Ratelimit dances. Sponsored by: Netflix Inc. Differential Revision: https://reviews.freebsd.org/D28357 commit a3330ae736606c1812b9e9c4b9dcfdfb1a150dde Author: Alex Richardson Date: Thu Jan 28 15:48:35 2021 +0000 Vendor import of atf commit ca73d08c3fc1ecffc1f1c97458c31ab82c12bb01 Updated from https://github.com/freebsd/atf commit cd579b6fba46b9f5005358d1e82def7b26703224 Author: Kristof Provost Date: Thu Jan 28 11:02:20 2021 +0100 pf tests: Test that dup-to doesn't produce extra duplicate packets commit 0c458752ceee14818034df7bfcdfb04129dceeda Author: Yannis Planus Date: Thu Jan 28 14:59:07 2021 +0100 pf: duplicate frames only once when using dup-to pf rule When using DUP-TO rule, frames are duplicated 3 times on both output interfaces and duplication interface. Add a flag to not duplicate a duplicated frame. Inspired by a patch from Miłosz Kaniewski milosz.kaniewski at gmail.com https://lists.freebsd.org/pipermail/freebsd-pf/2015-November/007886.html Reviewed by: kp@ Differential Revision: https://reviews.freebsd.org/D27018 commit d386f3a3c32f0396aa7995349dd65d6c59711393 Author: Bjoern A. Zeeb Date: Thu Jan 28 16:37:28 2021 +0000 Bump __FreeBSD_version for multiple LinuxKPI updates conflicting with DRM. Be sure to update your drm-kmod port to after the update. commit fa765ca73e553399ffbad382e579e4c2b4d0fc12 Author: Bjoern A. Zeeb Date: Thu Jan 28 16:32:43 2021 +0000 LinuxKPI: implement devres() framework parts and two examples This code implements a version of the devres framework found working for various iwlwifi use cases and also providing functions for ttm_page_alloc_dma.c from DRM. Part of the framework replicates the consumed KPI, while others are internal helper functions. In addition the simple devm_k*malloc() consumers were implemented and kvasprintf() was enhanced to also work for the devm_kasprintf() case. Addmittingly lkpi_devm_kmalloc_release() could be avoided but for the overall understanding of the code and possible memory tracing it may still be helpful. Further devsres consumer are implemented for iwlwifi but will follow later as the main reason for this change is to sort out overlap with DRM. Sponsored-by: The FreeBSD Foundation Obtained-from: bz_iwlwifi MFC After: 3 days Reviewed-by: hselasky, manu Differential Revision: https://reviews.freebsd.org/D28189 commit 1fac2cb4d6e5cfa1b8ff689213011b0fe077ffa7 Author: Bjoern A. Zeeb Date: Thu Jan 28 16:23:19 2021 +0000 LinuxKPI: enhance PCI bits for DRM In pci_domain_nr() directly return the domain which got set in lkpifill_pci_dev() in all cases. This was missed between D27550 and 105a37cac76b971f7a94409fbdc4f508a7e97fa0 . In order to implement pci_dev_put() harmonize further code (which was started in the aforementioned commit) and add kobj related bits (through the now common lkpifill_pci_dev() code) to the DRM specific calls without adding the DRM allocated pci devices to the pci_devices list. Add a release for the lkpinew_pci_dev() (DRM) case so freeing will work. This allows the DRM created devices to use the normal kobj/refcount logic and work with, e.g., pci_dev_put(). (For a slightly more detailed code walk see the review). Sponsored-by: The FreeBSD Foundation Obtained-from: bz_iwlwifi (partially) MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28188 commit 4abbf816bf06aa70200c5d1d976dd61c2752bdaf Author: Bjoern A. Zeeb Date: Thu Jan 28 16:15:12 2021 +0000 LinuxKPI: upstream a collection of drm-kmod conflicting changes The upcoming in-kernel implementations for LinuxKPI based on work on iwlwifi (and other wireless drivers) conflicts in a few places with the drm-kmod graphics work outside the base system. In order to transition smoothly extract the conflicting bits. This included "unaligned" accessor functions, sg_pcopy_from_buffer(), IS_*() macros (to be further restricted in the future), power management bits (possibly no longer conflicting with DRM), and other minor changes. Obtained-from: bz_iwlwifi Sponsored-by: The FreeBSD Foundation MFC after: 3 days Reviewed by: kib, hselasky, manu, bdragon (looked at earlier versions) Differential Revision: https://reviews.freebsd.org/D26598 commit a6c2507d1baedb183268e31bc6b6f659a9529904 Author: Bjoern A. Zeeb Date: Thu Jan 28 16:05:32 2021 +0000 LinuxKPI: add firmware loading support Implement linux firmware KPI compat code. This includes: request_firmware() request_firmware_nowait(), request_firmware_direct(), firmware_request_nowarn(), and release_firmware(). Given we will try to map requested names from natively ported or full-linuxkpi-using drivers to a firmware(9) auto-loading name format (.ko file name and image name matching), we quieten firmware(9) and print success or failure (unless the _nowarn() version was called) in the linuxkpi implementation. At the moment we try up-to 4 different naming combinations, with path stripped, original name, and requested name with '/' or '.' replaced. We do not currently defer loading in the "nowait" case. Sponsored-by: The FreeBSD Foundation Sponsored-by: Rubicon Communications, LLC ("Netgate") (firmware(9) nowarn update from D27413) MFC after: 3 days Reviewed by: kib, manu (looked at older versions) Differential Revision: https://reviews.freebsd.org/D27414 commit b8051298b0a345ae0bdfcd2ddf89bca1b96c6c2a Author: Hans Petter Selasky Date: Tue Jan 26 17:01:34 2021 +0100 Fix missing value in uar_page field for ratelimit in mlx5en(4). This is a regression issue after the new UAR API was introduced by f8f5b459d21e . MFC after: 1 week Sponsored by: Mellanox Technologies // NVIDIA Networking commit 4e76e4c301c72698e111580e278872a8323fba50 Author: Andrew Turner Date: Thu Jan 28 10:41:45 2021 +0000 Remove obsolete code gated on _ARM_ARCH_* This is all code only run on ARMv4 and ARMv5. Support for these have been dropped from FreeBSD. Differential Revision: https://reviews.freebsd.org/D28314 commit 4d2ff2330f515b0a42b83113a201de48c0f38f7a Author: Andrew Turner Date: Thu Jan 28 10:39:38 2021 +0000 Remove the old ARMv4 memcpy This was only used when building for ARMv4 or some ARMv5 or when _STANDALONE is defined. As ARMv4 and ARMv5 support has been removed, and we only define _STANDALONE in the bootloader where we don't use this version of memcpy we can remove it. Differential Revision: https://reviews.freebsd.org/D28313 commit e09c8c9ad90dabe0d627c979e27e4ca3c234d3ab Author: Andrew Turner Date: Thu Jan 28 10:33:40 2021 +0000 Remove leftover big-endian arm support Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D28312 commit f59810e34bae867059163cb9f651e074043fcec8 Author: Baptiste Daroussin Date: Thu Jan 28 09:19:50 2021 +0100 pci_vendors: update to 2021.01.11 commit 9b388ac30375ad4e0259b264a006753edcb2bd3c Author: Toomas Soome Date: Thu Jan 28 09:45:47 2021 +0200 loader: unload command should reset tg_kernel_supported in gfx_state While loading kernel, we check if vt/vbe backend support is included in kernel and set the tg_kernel_supported flag in gfx_state. unload command needs to reset this flag to allow next load to perform this check with new kernel. Reported by: jhb commit 0e01ea872ee475d7aef11d21588504e2ef4eb32c Author: Cy Schubert Date: Wed Jan 27 21:52:08 2021 -0800 Fix a typo. MFC after: 3 days commit 7b08a307e88bb1abe17d13d11288392a8e4739ce Author: Mitchell Horne Date: Fri Jan 15 12:34:54 2021 -0400 bsdinstall: riscv-specific tweaks Make the installer more useful, by allowing it to create a bootable installation. Also, enable the menu option for ZFS-on-root. Like arm64, RISC-V boots by UEFI only, so arm64's partedit implementation is renamed and shared among the two platforms. Reviewed by: gjb MFC after: 5 days Differential Revision: https://reviews.freebsd.org/D28180 commit 676b7d077c2c5f548334cea7fccfbfb5d097c9df Author: Mitchell Horne Date: Fri Jan 15 12:14:27 2021 -0400 bsdinstall: create /efi/boot directory in ESP If the installer is creating a new ESP, then this directory will not exist and the subsequent cp will fail silently. This is usually of no consequence if /efi/freebsd/loader.efi is set up correctly. Reviewed by: imp MFC after: 5 days Differential Revision: https://reviews.freebsd.org/D28176 commit 9bae4ce661c59be88fec89b2531148e36dd1a23e Author: Danjel Qyteza Date: Wed Jan 27 12:28:48 2021 -0400 riscv: add SBI system reset extension The System Reset extension provides functions to shutdown or reboot the system via SBI firmware. This newly defined extension supersedes the functionality of the legacy shutdown extension. Update the SBI code to use the new System Reset extension when available, and fall back to the legacy one. Reviewed By: kp, jhb MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28226 commit a6405133b7e14929f8e8e61cf30d7152b1410e59 Author: Mitchell Horne Date: Wed Jan 27 17:27:15 2021 -0400 riscv: style(9) nits in sbi.c Wrap a few lines at 80 columns, which were overlooked in recent commits. commit 183d6cc0e0db8bd4653245abc1ca30b34ed09d9f Author: Emmanuel Vadot Date: Wed Jan 27 23:31:18 2021 +0100 release: ROCKPRO64: Remove the quirk that disable the big cores It's not needed anymore. commit 6e26189be406a9a3799074b16925e6cd63cc703b Author: Dimitry Andric Date: Wed Jan 27 22:28:43 2021 +0100 Fix loader detection of vbefb support on !amd64 On i386, after 6c7a932d0b8baaaee16eca0ba061bfa6e0e57bfd, the vbefb vt driver was no longer detected by the loader, if any kernel module was loaded after the kernel itself. This was caused by the parse_vt_drv_set() function being called multiple times, resetting the detection flag. (It was called multiple times, becuase i386 .ko files are shared objects like the kernel proper, while this is not the case on amd64.) Fix this by skipping the set_vt_drv_set lookup if vbefb was already detected. Reviewed by: tsoome commit 2fccd4f9b6b96d75de87df4922eb2bf04fb0a67d Author: Mark Johnston Date: Wed Jan 27 15:31:10 2021 -0500 safexcel: Disallow unsupported buffer layouts MFC after: 3 days Sponsored by: Rubicon Communications, LLC ("Netgate") commit e1b50e8184fca00520774d43bd7bdd0ccbe9a1d2 Author: Mark Johnston Date: Wed Jan 27 15:31:10 2021 -0500 qat.4: Minor tweaks - Document a constraint on the AAD size for AES-GCM. - Note that the list of supported platforms and add-on devices is not complete and indicate that QAT devices will show up in pciconf output. [1] PR: 252984 [1] MFC after: 3 days Sponsored by: Rubicon Communications, LLC ("Netgate") commit bd674d8b1fa808dff1afdcb6afc70226077ee78a Author: Mark Johnston Date: Wed Jan 27 15:30:58 2021 -0500 qat: Add support for separate AAD and output buffers MFC after: 1 week Sponsored by: Rubicon Communications, LLC ("Netgate") commit d0d2e523bafb74180f8bebb90788790f0d2f0290 Author: Lutz Donnerhacke Date: Wed Jan 27 21:19:14 2021 +0100 netgraph/ng_car: Add color marking code Chained policing should be able to reuse the classification of traffic. A new mbuf_tag type is defined to handle gereral QoS marking. A new subtype is defined to track the color marking. Reviewed by: manpages (bcr), melifaro, kp Approved by: kp (mentor) Sponsored by: IKS Service GmbH MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D22110 commit 65efb73fbddd44116fd39b03991386a67422ba6d Author: Ryan Moeller Date: Wed Jan 27 14:27:46 2021 -0500 sbin/sysctl: Fix CTLFLAG_SKIP for adjacent nodes The OID is saved when we encounter CTLFLAG_SKIP so that descendants can be skipped as well. We then must not update the skip OID until we are out of the node. This was achieved by resetting the skip OID once the prefix no longer matches, but the case where the OID we reset on has CTLFLAG_SKIP was not accounted for. Reported by: mav Reviewed by: mav MFC after: 2 days Sponsored by: iXsystems, Inc. Differential Revision: https://reviews.freebsd.org/D28364 commit 48397f6c7d2d693602105d8ec24c5741202e264d Author: Jessica Clarke Date: Wed Jan 27 19:19:00 2021 +0000 libllvmminimal: Add missing Support/ABIBreak.cpp When building natively on RISC-V, linking the bootstrap clang-tblgen fails with: ld: error: undefined symbol: llvm::EnableABIBreakingChecks >>> referenced by PrettyStackTrace.cpp >>> PrettyStackTrace.o:(.sdata+0x0) in archive /usr/obj/usr/src/freebsd-src/riscv.riscv64/tmp/obj-tools/lib/clang/libllvmminimal/libllvmminimal.a >>> referenced by Signals.cpp >>> Signals.o:(.sdata+0x8) in archive /usr/obj/usr/src/freebsd-src/riscv.riscv64/tmp/obj-tools/lib/clang/libllvmminimal/libllvmminimal.a >>> referenced by Timer.cpp >>> Timer.o:(.sdata+0x28) in archive /usr/obj/usr/src/freebsd-src/riscv.riscv64/tmp/obj-tools/lib/clang/libllvmminimal/libllvmminimal.a This is likely due to Error.h's inclusion of abi-breaking.h. It's unclear why this only affects RISC-V, but perhaps relates to its more eager use of .sdata due to the ABI's support for linker relaxations. Regardless, this is theoretically an issue for all architectures. Reported by: Dennis Clarke Reviewed by: dim Tested by: mhorne MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28367 commit dd6c1c2a6c0d3ac239b55105b6726a594ba79c60 Author: Andrew Turner Date: Mon Jan 25 20:03:47 2021 +0000 Remove redundantcy from the arm GIC softc A struct recource already contains the bus_space_tag_t and bus_space_handle_t. There is no neec to read them and store them again in the drivers softc. Remove them and use the struct resource directly with bus_read_* and bus_write_*. Reviewed by: mmel Differential Revision: https://reviews.freebsd.org/D28339 commit 7012461c9bf6375cd0b14de16b3b4a753c5c1c7a Author: Kyle Evans Date: Wed Jan 27 12:54:07 2021 -0600 stand: ensure that the efi directory's dependencies are correct efi, like the various ${MACHINE} directories, should have a dependency on the enabled interpreters. The general rule here is that any top-level directory that has a program at any depth within that includes loader.mk should add ${INTERP_DEPENDS} added to its dependencies so that the appropriate ficl/lua bits are ready before they begin. Note that the only directories in-tree that require it but will not get it in a more appropriate manner are i386 (on amd64), efi, and userboot. i386 and userboot are handled explicitly in Makefile.amd64 where they are added to S.yes. Reported-by: bcran MFC-after: 3 days commit 24a8f6d369962f189ad808f538029179b1e7dc2f Author: Randall Stewart Date: Wed Jan 27 13:32:52 2021 -0500 When we are about to send down to the driver layer we need to make sure that the m_nextpkt field is NULL else the lower layers may do unwanted things. Reviewed By: gallatin, melifaro Differential Revision: https://reviews.freebsd.org/D28377 commit 4f009328a2477f5f1c682629fc5708498b7c689f Author: Alex Richardson Date: Wed Jan 27 10:41:57 2021 +0000 kerberos5: Silence compiler warnings Building the kerberos5 subdirectory currently produces lots of warnings. Since there are many instances of these warnings and it's contrib code, this change silences the warnings instead of fixing them. Reviewed By: jhb, cy, bjk Differential Revision: https://reviews.freebsd.org/D28025 commit 8a2f9dff2b9393503f63902c6ba7802efd8d6e49 Author: Gordon Bergling Date: Wed Jan 27 18:20:04 2021 +0100 VOP_BMAP(9): Remove obsolete comma commit 8dba3dd846cf60c9014f81b099058a9023477096 Author: Gordon Bergling Date: Wed Jan 27 18:18:17 2021 +0100 cnv(9): Use a proper manual page section commit 35dabb7b9cff601045b623aeca59ccc68930d520 Author: Kristof Provost Date: Tue Jan 26 16:02:45 2021 +0100 altq: Fix typo in features sysctl description Reported by: Jose Luis Duran commit 7a808c5ee3296fdb72d8e8bc6c7ad6f316a520ab Author: Kristof Provost Date: Tue Jan 26 08:56:51 2021 +0100 pf: Improve pf_rule input validation Move the validation checks to pf_rule_to_krule() to reduce duplication. This also makes the checks consistent across different ioctls. Reported-by: syzbot+e9632d7ad17398f0bd8f@syzkaller.appspotmail.com Reviewed by: tuexen@, donner@ MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D28362 commit 5c325977b1138828367f39a3f2034af24c3654f0 Author: Mateusz Guzik Date: Wed Jan 27 15:59:53 2021 +0100 cache: add missing MNT_NOSYMFOLLOW check to symlink traversal commit 5fc384d1810a3a0a0acefc67abe1daf6d6cd09e4 Author: Mateusz Guzik Date: Wed Jan 27 13:52:23 2021 +0100 cache: fallback when encountering a mount point during .. lookup The current abort is overzealous. commit c262e8e87e7b59b768c717c1779ef1ba28507f44 Author: Marius Strobl Date: Wed Jan 27 15:28:25 2021 +0100 e1000: fix build after c1655b0f commit 6f65b505468aa8cedc57235604bd8df540d42735 Author: Bjoern A. Zeeb Date: Mon Jan 25 22:41:50 2021 +0000 firmware(9): extend firmware_get() by a "no warn" flag. With the upcoming usage from LinuxKPI but also from drivers ported natively we are seeing more probing of various firmware (names). Add the ability to firmware(9) to silence the "firmware image loading/registering errors" by adding a new firmware_get_flags() functions extending firmware_get() and taking a flags argument as firmware_put() already does. Requested-by: zeising (for future LinuxKPI/DRM) Sponsored-by: The FreeBSD Foundation Sponsored-by: Rubicon Communications, LLC ("Netgate") MFC after: 3 days Reviewed-by: markj Differential Revision: https://reviews.freebsd.org/D27413 commit bcb7f57aa22757dd0206e88894bc003a93d0c351 Author: Mateusz Guzik Date: Wed Jan 27 13:25:21 2021 +0100 conf/kern.mk: save some work by using realpath instead of cd ; pwd I did not check if the entire ordeal can be avoided in the first place. commit 7a57c9cb5a4dffb0483beeae6da7cf266ea634be Author: Baptiste Daroussin Date: Wed Jan 27 11:47:17 2021 +0100 diff: eleminitate useless macros The diff_output was not bringing any values but was obfuscating the code. commit e43239f5140e1b80de122458a2ac037172866058 Author: Baptiste Daroussin Date: Tue Jan 26 16:25:00 2021 +0100 diff: simplify the hash functions Instead of 3 different complex case they have all been folded into a simple on based on switch commit e52546a3a75f6e4b327178f4d50a98dd99101c64 Author: Baptiste Daroussin Date: Tue Jan 26 15:20:44 2021 +0100 diff: fix typo in a comment commit 931ad51808a650fd28be27210f25ba05d8e71199 Author: Baptiste Daroussin Date: Wed Jan 27 12:13:47 2021 +0100 diff: remove stalled entries in headers commit 15abb23286541c17ff95bac056cd4979822c4288 Author: Baptiste Daroussin Date: Wed Jan 27 11:46:15 2021 +0100 diff: eliminate space at end of line No functionnal changes commit fa977a3b2bb2d0e6c2957b14474c31b58dd3a8e1 Author: Baptiste Daroussin Date: Tue Jan 26 11:42:20 2021 +0100 diff: eliminate a useless lseek fdopen with the "r" already position the stream at the beginning of the file. commit c440e7870a020546ad241848e2ff8e9cb27a3073 Author: Baptiste Daroussin Date: Tue Jan 26 11:38:36 2021 +0100 diff: add a test case about the non regular file support commit 45b252fc9182b96342b8a598f271e49c20cbfe40 Author: Baptiste Daroussin Date: Tue Jan 26 10:52:22 2021 +0100 cp: fix indentation No functional changes commit 2be9ff2d65e968497e04e3cd66ccbf9178252493 Author: Andrew Turner Date: Tue Jan 26 21:58:16 2021 +0000 Remove old Marvell drivers These have probe functions that can only match device tree files that have been removed because the boards they describe are unsupported. Reviewed by: imp, manu Sponsored by: Innovate UK Differential Revision: https://reviews.freebsd.org/D28366 commit 042ef1f115500e53cba8c1497e5af7ad9d98e9ea Author: Andrew Turner Date: Tue Jan 26 21:13:29 2021 +0000 Remove DTS files for arm boards we don't support These are all FreeBS-specific device tree files. We don't support any of these anymore, remove them. Reviewed by: emaste, manu Sponsored by: Innovate UK Differential Revision: https://reviews.freebsd.org/D28365 commit 03d837b565a96b450d62b904ee108677f23122f8 Author: Ed Maste Date: Sun Jan 24 12:22:01 2021 -0500 Remove Binutils from src.conf(5) option descriptions All binutils remnants have been removed before FreeBSD 13. PR: 252842 MFC after: 3 days Sponsored by: The FreeBSD Foundation (cherry picked from commit b23665f3169b7b0364416060855541b450204d6d) commit 6c7a932d0b8baaaee16eca0ba061bfa6e0e57bfd Author: Toomas Soome Date: Wed Jan 27 00:47:56 2021 +0200 loader: start kernel in text mode when there is no vbefb vt driver If kernel is built without VT vbefb driver, make sure we start kernel in text mode. commit 93ebd6307efeb95a29bc614edd0c67c2af850e98 Author: Toomas Soome Date: Sun Jan 24 20:59:36 2021 +0200 vt: panic while changing vt font Set refcount for loader provided font to 1 to prevent this font from being released (so we can reset to default). PR: 252833 commit 7a731da592fae9a75278b2d4139d03d7ef6ba84a Author: Marius Strobl Date: Tue Jan 26 23:02:39 2021 +0100 rc.conf(5): regenerate after WITHOUT_NDIS removal ndis(4) has been removed in bfc99943b04b46a6c1c885ce7bcc6f235b7422aa and its build option in 84876bf70222c4e10144d034119f7f455f99813c. commit 84876bf70222c4e10144d034119f7f455f99813c Author: Marius Strobl Date: Tue Jan 26 22:59:36 2021 +0100 build: remove NDIS option ndis(4) has been removed in bfc99943b04b46a6c1c885ce7bcc6f235b7422aa. commit 173f6ce152ce1c4ea3e685d28a3c6461cc140513 Author: Marius Strobl Date: Tue Jan 26 22:51:24 2021 +0100 KDB: remove obsolete KDB_WHY_NDIS ndis(4) has been removed in bfc99943b04b46a6c1c885ce7bcc6f235b7422aa. commit f39b49969ac4ba2151c4c8a6ab273e6fe65ce98a Author: Marius Strobl Date: Tue Jan 26 22:46:59 2021 +0100 man: remove stale references to ndis(4) The latter has been removed in bfc99943b04b46a6c1c885ce7bcc6f235b7422aa. commit c1655b0f8998f9e842a004f33e7c9c01c5d9e879 Author: Marius Strobl Date: Sat Jan 23 19:18:28 2021 +0100 e1000: consistently use the hw variables It's rather confusing when adapter->hw and hw are mixed and matched within a particular function. Some of this was missed in cd1cf2fc1d49c509ded05dcd41b7600a5957fb9a and r353778 respectively. commit f1c010d9f9cbc28412d491689e7f594e56085bcb Author: Olivier Cochard Date: Tue Jan 26 22:19:36 2021 +0100 tests: Skip cap_fileargs if build without capsicum capabilities Approved by: oshogbo Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D2834 commit a098a831a162fcd55b0097c95e6840621d8c720a Author: Mateusz Guzik Date: Tue Jan 26 17:19:12 2021 +0100 cache: tidy up handling of foo/bar lookups where foo is not a directory The code was performing an avoidable check for doomed state to account for foo being a VDIR but turning VBAD. Now that dooming puts a vnode in a permanent "modify" state this is no longer necessary as the final status check will catch it. commit a51eca7936db50a57d2324d945c3be715df749cd Author: Mateusz Guzik Date: Tue Jan 26 21:31:16 2021 +0100 cache: stop referring to removing entries as invalidating them Said use is a remnant from the old code and clashes with the NCF_INVALID flag. commit 8c22cf9b0997566ff6f576cfc9296b29bb055f65 Author: Kirk McKusick Date: Tue Jan 26 11:46:38 2021 -0800 Fix fsck_ffs incorrectly reporting "CANNOT READ BLK: NNNN" errors. A long-standing bug in Pass 1 of fsck_ffs in which it is reading in blocks of inodes to check their block pointers. It failed to round up the size of the read to a disk block size. When disks would accept 512-byte aligned reads, the bug rarely manifested itself. But many recent disks will no longer accept 512-byte aligned reads but require 4096-byte aligned reads, so the failure to properly round-up read sizes to multiples of 4096 bytes makes the error much more likely to occur. Reported by: Peter Holm and others Tested by: Peter Holm and Rozhuk Ivan MFC after: 3 days Sponsored by: Netflix commit 2cf84258922f306a3f84866685d2f5346f67db58 Author: Dimitry Andric Date: Tue Jan 26 19:43:55 2021 +0100 Bump __FreeBSD_version after e63539f3059728ff58328ac0ecb2a7bf4e2f08e8 This is to allow ports to detect the clang fix applied in the above commit. PR: 252892 MFC after: 3 days commit d89c1c461ce31bfc789dbb7bc5f4fce5824c595e Author: Brooks Davis Date: Tue Jan 26 18:27:45 2021 +0000 Reserve gaps in syscall numbers for local use It is best for auditing of syscalls.master if we only append to the file. Reserving unimplemented system call numbers for local use makes this policy and provides a large set of syscall numbers FreeBSD derivatives can use without risk of conflict. Reviewed by: jhb, kevans, kib Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D27988 commit 119fa6ee8a8056aab5e4ab1719d3c563cdb4a95a Author: Brooks Davis Date: Tue Jan 26 18:27:44 2021 +0000 syscalls.master: Add a new syscall type: RESERVED RESERVED syscall number are reserved for local/vendor use. RESERVED is identical to UNIMPL except that comments are ignored. Reviewed by: kevans Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D27988 commit 65a524b499aef18bcc4144a0f7c65d95483b9269 Author: Brooks Davis Date: Tue Jan 26 18:27:44 2021 +0000 Remove documentation of unimplemented syscalls We have not been able to run binaries from other BSDs well over a decade. There is no need to document their allocation decisions here. We also don't need to reserve syscall numbers of never-implemented syscalls. Reviewed by: jhb, kib Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D27988 commit ee55e19a79429fe8505ae37d561eccb38d5fa6b8 Author: Konstantin Belousov Date: Sat Jan 23 22:19:06 2021 +0200 vm_map_protect.9: update after code changes Reviewed by: brooks, markj Discussed with: emaste Sponsored by: The FreeBSD Foundation MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28311 commit 093e7231908908b651b91c68ac03fb697c3a8352 Author: Hans Petter Selasky Date: Tue Jan 26 16:59:42 2021 +0100 Add missing decrement of active ratelimit connections. Reviewed by: rrs@ MFC after: 1 week Sponsored by: Mellanox Technologies // NVIDIA Networking commit 85d8d30f9f7046f5e89295352ded49135b25fbe3 Author: Hans Petter Selasky Date: Tue Jan 26 15:01:38 2021 +0100 Don't allow allocating a new send tag on an INP which is being torn down. This fixes a potential send tag leak. Reviewed by: rrs@ MFC after: 1 week Sponsored by: Mellanox Technologies // NVIDIA Networking commit e63539f3059728ff58328ac0ecb2a7bf4e2f08e8 Author: Dimitry Andric Date: Tue Jan 26 14:07:47 2021 +0100 Fix clang assertion when compiling the devel/onetbb port Merge commit 740a164de from llvm git (by Richard Smith): PR46377: Fix dependence calculation for function types and typedef types. We previously did not treat a function type as dependent if it had a parameter pack with a non-dependent type -- such a function type depends on the arity of the pack so is dependent even though none of the parameter types is dependent. In order to properly handle this, we now treat pack expansion types as always being dependent types (depending on at least the pack arity), and always canonically being pack expansion types, even in the unusual case when the pattern is not a dependent type. This does mean that we can have canonical types that are pack expansions that contain no unexpanded packs, which is unfortunate but not inaccurate. We also previously did not treat a typedef type as instantiation-dependent if its canonical type was not instantiation-dependent. That's wrong because instantiation-dependence is a property of the type sugar, not of the type; an instantiation-dependent type can have a non-instantiation-dependent canonical type. Merge commit 9cf98d26e from llvm git (by Richard Smith): PR46637: Fix handling of placeholder types in trailing-return-types. Only permit a placeholder type in a trailing-return-type if it would also have been permitted in the decl-specifier sequence of a corresponding declaration with no trailing-return-type. The standard doesn't actually say this, but this is the only thing that makes sense. Also fix handling of an 'auto' in a trailing-return-type in a parameter of a generic lambda. We used to crash if we saw such a thing. Merge commit 234f51a65 from llvm git (by Richard Smith): Don't crash if we deserialize a pack expansion type whose pattern contains no packs. Fixes a regression from 740a164dec483225cbd02ab6c82199e2747ffacb. PR: 252892 Reported by: thierry MFC after: 3 days commit cfd6422a5217410fbd66f7a7a8a64d9d85e61229 Author: Lutz Donnerhacke Date: Tue Jan 26 16:50:04 2021 +0100 netgraph/ng_vlan_rotate: IEEE 802.1ad VLAN manipulation netgraph type This node is part of an A10-NSP (L2-BSA) development. Carrier networks tend to stack three or more tags for internal purposes and therefore hiding the service tags deep inside of the stack. When decomposing such an access network frame, the processing order is typically reversed: First distinguish by service, than by other means. This new netgragh node allows to bring the relevant VLAN in front (to the out-most position). This way other netgraph nodes (like ng_vlan) can operate on this specific type. Reviewed by: manpages (gbe), brueffer (manpages), kp Approved by: kp (mentor) MFC after: 1 month Relnotes: yes Sponsored by: IKS Service GmbH Differential Revision: https://reviews.freebsd.org/D22076 commit 6a376af0cd212be4e16d013d35a0e2eec1dbb8ae Author: Richard Scheffenegger Date: Tue Jan 26 16:06:32 2021 +0100 TCP PRR: Patch div/0 in tcp_prr_partialack With clearing of recover_fs in bc7ee8e5bc555, div/0 was observed while processing partial_acks. Suspect that rewind of an erraneous RTO may be causing this - with the above change, recover_fs would no longer retained at the last calculated value, and reset. But CC_RTO_ERR can reenable IN_RECOVERY(), without setting this again. Adding a safety net prior to the division in that function, which I missed in D28114. commit f2b5999b2166579a2ebd4b5e117a17574f18d50f Author: Ed Maste Date: Fri Jan 22 12:22:35 2021 -0500 elfctl: allow features to be specified by value This will allow elfctl on older releases to set bits that are not yet known there, so that the binary will have the correct settings applied if run on a later FreeBSD version. PR: 252629 (related) Suggested by: kib Reviewed by: gbe (manpage, earlier), kib Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D28284 (cherry picked from commit 86f33b5fcf6087bf4439881011b920ff99e6e300) elfctl: fix typo from last-minute refactoring Reported by: jkim (cherry picked from commit f302fd1aa6730facd53a3f761e0a57302731b03e) elfctl: Fix type errors. Target value for val has uint32_t type, not uint, adjust used constant. Change val type to unsigned so that left and right sides of comparision operator do not expose different signed types of same range [*]. Switch to unsigned long long and strtoll(3) so that 0x80000000 is accepted by conversion function [**]. Reported by: kargl [*] Noted by: emaste [**] Reviewed by: emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D28301 (cherry picked from commit 9940ac808de7b7d4ed0408c3e739f667dca06d3b) commit 84761f3df508aed50783b60f028af9d98a684b41 Author: Richard Scheffenegger Date: Tue Jan 26 14:47:19 2021 +0100 Adjust line length in tcp_prr_partialack Summary: Wrap lines before column 80 in new prr code checked in recently. No functional changes. Reviewers: tuexen, rrs, jtl, mm, kbowling, #transport Reviewed By: tuexen, mm, #transport Subscribers: imp, melifaro Differential Revision: https://reviews.freebsd.org/D28329 commit a86b0839d7bf3fc06b1ae9c50e055b53c50a9d0b Author: Marcin Wojtas Date: Tue Jan 26 11:49:35 2021 +0100 marvell: ap806_clock: add missing frequency modes In the driver init routine the CPU clock frequency value is obtained from a dedicated register. Until now only part of the values were handled by the mv_ap806_clock driver. Fix that by adding missing cases. Submitted by: Zyta Szpak MFC after: 1 week Obtained from: Semihalf Sponsored by: Marvell commit 6943671b481e571f2f1ffbe407a4d75241d1174e Author: Mateusz Guzik Date: Tue Jan 26 01:40:47 2021 +0100 cache: convert cache_fplookup_parse to void now that it always succeeds commit da2dfec8f752f0ebde7851644d074678cb9470cf Author: Oleksandr Tymoshenko Date: Mon Jan 25 20:50:26 2021 -0800 Add RELNOTES entry for AES-GCM in armv8crypto(4) Reviewed by: gjb, jhb Approved by: re (gjb) Differential Revision: https://reviews.freebsd.org/D28297 commit 25cdacf79b06356c929e59d5074d26c9dac41bdf Author: Cy Schubert Date: Mon Jan 25 09:45:04 2021 -0800 Import sqlite 3.34.1 (3340100). commit b42a2ea5589f86911643b3ce1ebeace5d1e2c1eb Author: Mateusz Guzik Date: Tue Jan 26 00:04:13 2021 +0000 Remove ndis(4) remnants from kernel configs Unbreaks LINT kernels. commit 1fc148624f50cbf93365f6d56c6587a7d268195b Author: Cy Schubert Date: Mon Jan 25 14:34:22 2021 -0800 Fix build following bfc99943b04b46a6c1c885ce7bcc6f235b7422aa. bfc99943b04b46a6c1c885ce7bcc6f235b7422aa removed ndis(4) support however wpa as delivered by the wpa upstream (w1.fi) enables NDIS by default. This commit disables NDIS suppport in the w1.fi delivered build config, circumventing the build failure. commit 83edbc3cb54fba6b37a68270c232df7b785bd222 Author: Cy Schubert Date: Thu Jan 14 20:32:16 2021 -0800 ipfilter: Retire pre-standard C support. All C compilers in 2021 support standard C and architectures that did not were retired long ago. Simplify by removing now redundant pre-standard C code. MFC after: 1 week commit e7cf562a40fc093df054bd7fa6f34746069a984a Author: Mateusz Guzik Date: Mon Jan 25 21:49:09 2021 +0100 cache: change ->v_cache_dd synchronisation rules Instead of resorting to seqc modification take advantage of immutability of entries and check if the entry still matches after everything got prepared. commit 6f0842764946ed57382293cc3361b86955308084 Author: Mateusz Guzik Date: Mon Jan 25 21:29:54 2021 +0100 cache: make ->v_cache_dd accesses atomic-clean for lockless usage commit 6ef8fede86f3feed7fb1e15b0e8a32ecfec33c6c Author: Mateusz Guzik Date: Mon Jan 25 21:58:59 2021 +0100 cache: make ->nc_flag accesses atomic-clean for lockless usage commit ffcf8f97f8a8fb92689793003acabc0a2fe97af4 Author: Mateusz Guzik Date: Sat Jan 23 20:41:40 2021 +0100 cache: store vnodes in local vars in cache_zap_locked commit c09f7992714559eaa874f13ea4a1d648f199cd08 Author: Mateusz Guzik Date: Mon Jan 25 21:17:48 2021 +0100 tmpfs: drop acq fence now that vn_load_v_data_smr has consume semantics commit 7af02ef0b222eebad4827a264454e85134692e94 Author: Mateusz Guzik Date: Mon Jan 25 21:15:19 2021 +0100 zfs: use atomic_load_consume_ptr for z_cached_symlink commit 8d2a230e996c8aec2ec4883d45f7ac38070bd38f Author: Mateusz Guzik Date: Mon Jan 25 21:19:08 2021 +0100 vfs: use atomic_load_consume_ptr in vn_load_v_data_smr commit 054ce2b0371042c0dbc4b3ab1d7e7795ad75d51e Author: Mateusz Guzik Date: Mon Jan 25 21:09:41 2021 +0100 atomic: add stub atomic_load_consume_ptr commit cc96f92a570e05636a20fdd15d4616b127bb9ecc Author: Mateusz Guzik Date: Mon Jan 25 20:39:14 2021 +0100 atomic: make atomic_store_ptr type-aware commit f40d6217f20d69427b58d82ce4e29d88bf4dfbd6 Author: Mateusz Guzik Date: Mon Jan 25 21:28:05 2021 +0000 zfs: fix panics with invariant kernels from zfs_replay_setattr commit 7b49246c89dd3f6a2b780a732424905eca1860c7 Author: Philip Paeps Date: Tue Jan 26 05:52:24 2021 +0800 contrib/tzdata: import tzdata 2021a Merge commit '4cd7e1071de16a7392b0e466287f13e9e6f2081a' Changes: https://github.com/eggert/tz/blob/2021a/NEWS (cherry picked from commit 8c5bef2eb24cb191c87712a56a9860d8c29415a0) commit 7a1591c1b625ef47a9c9954f0143a6f0d78cc05c Author: Brooks Davis Date: Sat Jan 23 00:08:59 2021 +0000 Rename kern_mmap_req to kern_mmap Replace all uses of kern_mmap with kern_mmap_req move the old kern_mmap. Reand rename kern_mmap_req to kern_mmap . The helper saved some code churn initially, but having multiple interfaces is sub-optimal. Obtained from: CheriBSD Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D28292 commit bfc99943b04b46a6c1c885ce7bcc6f235b7422aa Author: Brooks Davis Date: Mon Jan 25 21:45:03 2021 +0000 ndis(4): remove as previous announced nids(4) was a clever idea in the early 2000's when the market was flooded with 10/100 NICs with Windows-only drivers, but that hasn't been the case for ages and the driver has had no meaningful maintenance in ages. It only supports Windows-XP era drivers. Also remove: - ndis support from wpa_supplicant - ndiscvt(8) Reviewed By: emaste, bcr (manpages) Differential Revision: https://reviews.freebsd.org/D27609 commit 1b109c69ed625ebf292c1d16f7a3efcab96722e5 Author: Alexander Motin Date: Mon Jan 25 16:08:06 2021 -0500 Decode NFIT Platform Capabilities. MFC after: 1 week commit dcd1e41f0cbcb8f7ec5f7a891a690be959bc1ea8 Author: Kristof Provost Date: Sat Jan 23 10:37:22 2021 +0100 pfctl: FreeBSD now supports DIOCGIFSPEED There's no need for a special case here to work around the lack of DIOCGIFSPEED. That was introduced in FreeBSD in c1aedfcbd9896401f637bc815ba4e51dca107f6f. Reported by: jmg@ Reviewed by: donner@ Differential Revision: https://reviews.freebsd.org/D28305 commit 27b2aa49385dc39959f772b76abec1601d4b9ab2 Author: Kristof Provost Date: Sat Jan 23 10:37:13 2021 +0100 altq: Remove unused arguments from altq_attach() Minor cleanup, no functional change. Reviewed by: donner@ Differential Revision: https://reviews.freebsd.org/D28304 commit 16b3833344ad04194f10b567bc6fae829a52a850 Author: Kristof Provost Date: Sat Jan 23 10:37:03 2021 +0100 altq tests: Basic ALTQ test Activate ALTQ_HFSC, crudely check if it really limits bandwidth as we'd expect. Reviewed by: donner@ Differential Revision: https://reviews.freebsd.org/D28303 commit e111d79806fe3652bc85593ca77ee1b4ff85498d Author: Kristof Provost Date: Sat Jan 23 10:36:33 2021 +0100 Add FEATURE sysctls for ALTQ disciplines This will allow userspace to more easily figure out if ALTQ is built into the kernel and what disciplines are supported. Reviewed by: donner@ Differential Revision: https://reviews.freebsd.org/D28302 commit 8564660237aec4c679e8b607dbbf861c90fafc4c Author: Ed Maste Date: Mon Jan 25 14:53:47 2021 -0500 newvers.sh: add newline at EOF in generated vers.c Previously we omitted the newline, which did not cause a functional issue for the build but resulted in suboptimal output from e.g. `cat vers.c`. commit 868643e7229b7959024880cda396fef87602b948 Author: Mateusz Guzik Date: Sun Jan 24 21:04:01 2021 +0100 cache: assorted cleanups commit 1c7a65adb002cf96bda1f72d9a26dd4237368263 Author: Mateusz Guzik Date: Sun Jan 24 21:00:03 2021 +0100 cache: track calls to cache_symlink_alloc with unsupported size While here assert on size passed to free. commit fefb3c46a80fdde6f307e73a2b5b5aed806df1ce Author: Jamie Landeg-Jones Date: Mon Jan 25 18:42:26 2021 +0100 diff: fix incorrectly displaying files as duplicates When diff hits certain access errors, function diffreg() shows the error message, and then returns to the calling function, which calls print_status() with the return value. However, in these cases, the return value isn't changed from the initial default value of D_SAME. Normally, print_status() with a value of D_SAME does nothing, so this works out ok, however, if the "-s" flag is set, a message is displayed showing identicality: case D_SAME: if (sflag) printf("Files %s%s and %s%s are identical\n", path1, entry, path2, entry); break; This then produces such results as: % diff -s /COPYRIGHT /var/run/rpcbind.sock diff: /var/run/rpcbind.sock: Operation not supported Files /COPYRIGHT and /var/run/rpcbind.sock are identical % diff -s /COPYRIGHT /etc/master.passwd diff: /etc/master.passwd: Permission denied Files /COPYRIGHT and /etc/master.passwd are identical Create a D_ERROR status which is returned in such cases, and print_status() then deals with that status seperately from D_SAME PR: 252614 MFC after: 1 week commit 13860e71eb501f498a2263f44ea9244f6830b61c Author: Baptiste Daroussin Date: Mon Jan 25 18:40:12 2021 +0100 diff: add a test case for failed -s option commit 94ac312a71683a3a1a928c6adfe927d6bb45044f Author: Alex Richardson Date: Tue Jan 19 11:35:21 2021 +0000 ifconfig: fix UBSan signed shift error Use 1u since UBSan complains about 1 << 31. commit a8b20f4fabbca9bef377009429848d4f9cea18ae Author: Alexander Richardson Date: Mon Jan 25 14:18:16 2021 +0000 Create symlinks to host tools on non-FreeBSD hosts This is unnecessary when cross-building from Linux/macOS. Additionally, cp -p appears to be broken on macOS Big Sur (https://openradar.appspot.com/8957219). For some unknown reason this commit appears to fix freezes when building on macOS Big Sur. This also fixes building in docker with volume mounts with ACLs, since setting the ACL with cp -p fails otherwise. Obtained From: CheriBSD Tested By: gnn (macOS Big Sur), Nathaniel Wesley Filardo (docker) Reviewed By: jrtc27, imp Differential Revision: https://reviews.freebsd.org/D28267 commit 8d55837dc1331a5cdacad539b1788ab1070159b4 Author: Alex Richardson Date: Mon Jan 25 14:11:45 2021 +0000 qeueue.h: Add {SLIST,STAILQ,LIST,TAILQ}_END() We provide these for compat with other queue.h headers since some software assumes it exists (e.g. the libevent contrib code), but we are not encouraging their use (NULL should be used instead). This fixes the following warning (which should arguable be an error since it results in a function call to an undefined function): .../contrib/libevent/buffer.c:495:16: warning: implicit declaration of function 'LIST_END' is invalid in C99 [-Wimplicit-function-declaration] cbent != LIST_END(&buffer->callbacks); ^ .../contrib/libevent/buffer.c:495:13: warning: comparison between pointer and integer ('struct evbuffer_cb_entry *' and 'int') [-Wpointer-integer-compare] cbent != LIST_END(&buffer->callbacks); ~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Reviewed By: jhb Differential Revision: https://reviews.freebsd.org/D27151 commit 3454fa118c41a588e2dad20614325297c989c60b Author: Alex Richardson Date: Mon Jan 25 14:03:17 2021 +0000 Don't include libarchive fuzz tests by default These tests are basic fuzz tests that permute input to trigger crashes rather than regression or unit tests. Additionally, some of them take a rather long time to run and should probably be run on a dedicated fuzzing job instead. Moreover, these simple tests use rand() instead of a real fuzzing tool that generates interesting inputs (e.g. LLVM libFuzzer) so are unlikely to find anything interesting when run in CI. This allows removing one BROKEN_TESTS case due to timeouts and speeds up running tests on emulated platforms such as QEMU. Reviewed By: lwhsu, mm Differential Revision: https://reviews.freebsd.org/D27153 commit 8e0504d1654d92995abeddef2af7241f902675ed Author: Mitchell Horne Date: Fri Jan 22 14:56:56 2021 -0400 gdb: only return signal values for powerpc's gdb_cpu_signal() Reviewed by: alfredo (cherry picked from commit 57a543d8b85065f77e0b68162d09a03335970f90) commit 064009e79462dea517aa7f1a857fb4d5393caa69 Author: Hans Petter Selasky Date: Mon Jan 25 11:22:55 2021 +0100 Add support for enabling and disabling IFCAP_VLAN_HWTSO via ifconfig(8) in mlx5en(4). MFC after: 1 week Sponsored by: Mellanox Technologies // NVIDIA Networking commit 35ebd8d33ad2f7c2038f6bf9aa02eab21252f689 Author: Cyprien Laplace Date: Sat Dec 5 10:47:33 2020 -0500 gic_v3: add message based interrupts support Pull Request: https://github.com/freebsd/freebsd-src/pull/451 commit 46ca0b903cad8955574a2c61bed41c2b92aa2273 Author: Cyprien Laplace Date: Wed Nov 25 20:17:04 2020 -0500 gic_v3: Use 64-bit writes to GICD_IROUTERn While 32-bit accesses to GICD_IROUTERn are allowed, this is a 64-bit register. Pull Request: https://github.com/freebsd/freebsd-src/pull/451 commit 8c5bef2eb24cb191c87712a56a9860d8c29415a0 Merge: bd01a69f483 4cd7e1071de Author: Philip Paeps Date: Mon Jan 25 08:18:14 2021 +0800 contrib/tzdata: import tzdata 2021a Merge commit '4cd7e1071de16a7392b0e466287f13e9e6f2081a' Changes: https://github.com/eggert/tz/blob/2021a/NEWS MFC after: 3 days commit 4cd7e1071de16a7392b0e466287f13e9e6f2081a Author: Philip Paeps Date: Mon Jan 25 08:11:06 2021 +0800 Import tzdata 2021a commit bd01a69f4836994b50b492883fb5367db41fb506 Author: Konstantin Belousov Date: Sat Jan 23 23:40:07 2021 +0200 nfs_write(): do not call ncl_pager_setsize() after clearing TDP2_SBPAGES This might unnecessary truncate file undoing extension done by the write. Reported by: Yasuhiro Kimura Reviewed by: rmacklem Tested by: rmacklem, Yasuhiro Kimura MFC after: 6 days Sponsored by: The FreeBSD Foundation commit ee0005f11f2b38a714bc66b7d79832108f6fee77 Author: Vincenzo Maffione Date: Sun Jan 24 21:59:02 2021 +0000 netmap: simplify parameter passing Changes imported from the netmap github. commit f80efe5016ba01b2948ca1f0eb8fe34adab5b864 Author: Vincenzo Maffione Date: Sun Jan 24 21:38:59 2021 +0000 iflib: netmap: move per-packet operation out of fragments loop MFC after: 1 week commit aceaccab659c9eb846fb21ff99be34434a9616c7 Author: Vincenzo Maffione Date: Sun Jan 24 21:12:41 2021 +0000 iflib: netmap: add support for NS_MOREFRAG The NS_MOREFRAG flag can be set in a netmap slot to represent a multi-fragment packet. Only the last fragment of a packet does not have the flag set. On TX rings, the flag may be set by the userspace application. The kernel will look at the flag and use it to properly set up the NIC TX descriptors. On RX rings, the kernel may set the flag if the packet received was split across multiple netmap buffers. The userspace application should look at the flag to know when the packet is complete. Submitted by: rajesh1.kumar_amd.com Reviewed by: vmaffione MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D27799 commit 576562856efbec31520aca6a1f72f2b11298e9a7 Author: Kyle Evans Date: Sun Jan 24 13:25:34 2021 -0600 lualoader: improve loader.conf var processing lualoader was previously not processing \ as escapes; this commit fixes that and does better error checking on the value as well. Additionally, loader.conf had some odd restrictions on values that make little sense. Previously, lines like: kernel=foo Would simply be discarded with a malformed line complaint you might not see unless you disable beastie. lualoader tries to process these as well as it can and manipulates the environment, while forthloader did minimal processing and constructed a `set` command to do the heavy lifting instead. The lua approach was re-envisioned from building a `set` command so that we can appropriately reset the environment when, for example, boot environments change. Lift the previous restrictions to allow unquoted values on the right hand side of an expression. Note that an unquoted value is effectively: [A-Za-z0-9-][A-Za-z0-9-_.]* This commit also stops trying to weirdly limit what it can handle in a quoted value. Previously it only allowed spaces, alphanumeric, and punctuation, which is kind of weird. Change it here to grab as much as it can between two sets of quotes, then let processEnvVar() do the needful and complain if it finds something malformed looking. My extremely sophisticated test suite is as follows: < Date: Sun Jan 24 20:23:39 2021 +0100 netgraph/ng_nat: Add RFC 6598/Carrier Grade NAT support This extends upon the RFC 6598 support to libalias/ipfw in r357092. Reviewed By: manpages (bcr), donner, adrian, kp Approved by: kp (mentor) MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D23461 commit 9bee9a98ff7f9de093314abaf7c46ca89c4020d9 Author: Alexander Motin Date: Sun Jan 24 14:23:04 2021 -0500 Exclude reserved iSCSI Initiator Task Tag. RFC 7143 (11.2.1.8): An ITT value of 0xffffffff is reserved and MUST NOT be assigned for a task by the initiator. The only instance in which it may be seen on the wire is in a target-initiated NOP-In PDU (Section 11.19) and in the initiator response to that PDU, if necessary. MFC after: 1 month commit b31dae0caa0286820805951842fa871f71b33d75 Author: Alexander Motin Date: Sun Jan 24 13:58:29 2021 -0500 Exclude reserved iSCSI Target Transfer Tag. RFC 7143 (11.7.4): The Target Transfer Tag values are not specified by this protocol, except that the value 0xffffffff is reserved and means that the Target Transfer Tag is not supplied. MFC after: 1 month commit 7680431a38cc2624f7415012fb9d21d7bdb3f8c9 Author: Ed Maste Date: Sun Jan 24 12:25:04 2021 -0500 Regen src.conf.5 after LLD description updates commit b23665f3169b7b0364416060855541b450204d6d Author: Ed Maste Date: Sun Jan 24 12:22:01 2021 -0500 Remove Binutils from src.conf(5) option descriptions All binutils remnants have been removed before FreeBSD 13. PR: 252842 MFC after: 3 days Sponsored by: The FreeBSD Foundation commit 25611bc0abf8a21f90cf3a702d6163b23bb7bed5 Author: Ed Maste Date: Sun Jan 24 10:21:53 2021 -0500 cxgbetool: correct utilties typo commit 1f73236b0302cdf47630c99687c2dfd4e514ab54 Author: Gordon Bergling Date: Sun Jan 24 14:57:16 2021 +0100 Add a manual page for axp(4) / AMD 10G Ethernet driver Submitted by: Rajesh Kumar Reviewed by: bcr, brueffer, rpokala MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D27800 commit b22fdf45ff8ef1d1f9a6c28f1d7f59ca4b012da6 Author: Mateusz Guzik Date: Sun Jan 24 05:34:22 2021 +0100 libc: try to skip memcpy in _gettemp commit 6fe328ace8f418bab0ab7f78c6fa1f2e757dd8a9 Author: Mateusz Guzik Date: Sun Jan 24 05:32:46 2021 +0100 libc: remove open-coded strlen in _gettemp commit 97a463120bf99819fcb21a781e410fb43dde2a43 Author: Mateusz Guzik Date: Sun Jan 24 05:15:13 2021 +0100 libc: skip spurious stat in _gettemp It was only done to catch ENOTDIR, but the kernel already returns the error where appropriate. commit 0f7573ffd6141b19419c9a6238246b9ba0e6dce6 Author: Michael Tuexen Date: Sun Jan 24 00:50:33 2021 +0100 sctp: fix PR-SCTP stats when adding addtional streams MFC after: 1 week commit 7a051c0a7890dc8e490ebe125bfc70a28e89ddaf Author: Michael Tuexen Date: Sat Jan 23 20:56:45 2021 +0100 sctp: improve consistency No functional change intended. MFC: 1 week commit d6327ae8c11b73765f100981baca49166b558b70 Author: Jessica Clarke Date: Sat Jan 23 20:59:15 2021 +0000 Fix cross-build support for Ubuntu 16.04 Older glibc headers did some very nasty things that have since been sanitised. We could also fix this by adding a linux/getopt.h wrapper alongside the existing common/getopt.h that #undef's __need_getopt, but that seems a little more hacky and complicated. Reviewed by: arichardson commit 0d528e6354141dd097f8719e858b3ae3686d2062 Author: Vladimir Kondratyev Date: Sat Jan 23 22:19:50 2021 +0300 hcons: Fix manpage typo Submitted by: Shunchao Hu Reviewed by: wulf, gbe MFC after: 1 week Differential revision: https://reviews.freebsd.org/D28294 commit 02ec31bdf60fa3a8530544cb3c8c4ec1df6cde0d Author: Mateusz Guzik Date: Sat Jan 23 18:21:42 2021 +0100 cache: add back target entry on rename commit d7dd28bb09fa51b9958a5dc288d2aeef56a67491 Author: Lutz Donnerhacke Date: Sat Jan 23 18:54:47 2021 +0100 netgraph/ng_source: If queue is full, don't enqueue Submitted by: nc Reviewed by: donner, kp Approved by: kp (mentor) Differential Revision: https://reviews.freebsd.org/D23477 commit 519b64e27fddf10c0b7f6a615edbad730b8c6c45 Author: Mark Johnston Date: Sat Jan 23 10:55:09 2021 -0500 Revert "Define PNP info after defining driver modules" This reverts commit aa37baf3d7cf51da92fd367476182802e71838ae. The reverted commit was motivated by a problem observed on stable/12, but it turns out that a better solution was committed in r348309 but not MFCed. So, revert this change since it is unnecessary and not really correct: it assumes that the order in which module metadata records is defined determines their order in the output linker set. While this seems to hold in my testing, it is not guaranteed. Reported by: cem Discussed with: imp MFC after: 3 days commit 9940ac808de7b7d4ed0408c3e739f667dca06d3b Author: Konstantin Belousov Date: Sat Jan 23 12:45:51 2021 +0200 elfctl: Fix type errors. Target value for val has uint32_t type, not uint, adjust used constant. Change val type to unsigned so that left and right sides of comparision operator do not expose different signed types of same range [*]. Switch to unsigned long long and strtoll(3) so that 0x80000000 is accepted by conversion function [**]. Reported by: kargl [*] Noted by: emaste [**] Reviewed by: emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D28301 commit aa8c1f8d84d2638a354e71f9593e978d00878243 Author: Konstantin Belousov Date: Fri Jan 22 23:47:06 2021 +0200 nfs client: block vnode_pager_setsize() calls from nfscl_loadattrcache in nfs_write Otherwise writing thread might wait on sbusy state of the pages which were busied by itself, similarly to nfs_read(). But also we need to clear NVNSETSZKSIP flag possibly set by ncl_pager_setsize(), to not undo extension done by write. Reported by: bdrewery Reviewed by: rmacklem Tested by: pho MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D28306 commit 3110d4ebd6c0848cf5e25890d01791bb407e2a9b Author: Mateusz Guzik Date: Sat Jan 23 13:46:32 2021 +0000 zfs: add support for lockless symlink lookup Reviewed by: kib (previous version) Tested by: pho (previous version) Differential Revision: https://reviews.freebsd.org/D27488 commit 618029af508be2c01a84162c1bad02bfd000db27 Author: Mateusz Guzik Date: Sat Jan 23 13:45:01 2021 +0000 tmpfs: add support for lockless symlink lookup Reviewed by: kib (previous version) Tested by: pho (previous version) Differential Revision: https://reviews.freebsd.org/D27488 commit c892d60a1d3e11c7e0651705bc4167b218a7415c Author: Mateusz Guzik Date: Sat Jan 23 13:42:16 2021 +0000 ufs: denote lack of support for lockless symlink lookup It is unclear without investigating if it can be provided without using extra memory, so for the time being just don't. commit 739ecbcf1c4fd22b5f6ee0bb180a67644046a3e0 Author: Mateusz Guzik Date: Sat Jan 23 13:40:48 2021 +0000 cache: add symlink support to lockless lookup Reviewed by: kib (previous version) Tested by: pho (previous version) Differential Revision: https://reviews.freebsd.org/D27488 commit bfd75d45571958398a043517060d8c3d352e7dbd Author: Vincenzo Maffione Date: Sat Jan 23 13:44:24 2021 +0000 axgbe: fix some link related issues By default, axgbe driver does a receiver reset after predefined number of retries for the link to come up. However, this receiver reset doesn't always suffice, due to an hardware issue. In that case, as a workaround, a complete phy reset is necessary. This patch introduces a sysctl that can be set to 1 to let the driver reset the phy completely, rather than just doing receiver reset. The workaround will be removed once the issue is fixed by means of firmware update. This patch also fixes the handling of the direct attach cables properly. Submitted by: rajesh1.kumar_amd.com Differential Revision: https://reviews.freebsd.org/D28266 commit 6c789c55c4ba11014bfd1b59942c204615412ba6 Author: Toomas Soome Date: Fri Jan 22 13:06:58 2021 +0200 loader: create built in font from bold font face We did replace full version of default font 8x16v with bold, also use bold version for built in font. commit f76393a6305b67c0f3439ba684c5d49a2aafe2a0 Author: Oleksandr Tymoshenko Date: Tue Jan 12 22:27:10 2021 -0800 armv8crypto: add AES-GCM support Add support for AES-GCM using OpenSSL's accelerated routines. Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D27454 Sponsored by: Ampere Computing Submitted by: Klara, Inc. Approved by: re (kib) (cherry picked from commit ed9b7f4414663703e0e9581a730c4bdfaca5687f) commit d1c39af0ec332ec3412e92fb4909de2a4bdfbb6c Author: Kyle Evans Date: Fri Jan 22 17:24:28 2021 -0600 Regenerate src.conf(5) commit 1c9891b8df63f146bd9515e11f45384bc40d0ef4 Author: Kyle Evans Date: Fri Jan 22 17:13:42 2021 -0600 jemalloc: restore JEMALLOC_DEBUG when building WITHOUT_MALLOC_PRODUCTION The default for MALLOC_PRODUCTION was switched to ON in 02611ef8ee9f. This effectively reverts the jemalloc header change from bfd15705156b so that the knob behaves exactly as it does on a -CURRENT; that is, we are effectively doing: WITH_MALLOC_PRODUCTION -> -DMALLOC_PRODUCTION (default for stable/* and on) WITHOUT_MALLOC_PRODUCTION -> -DJEMALLOC_DEBUG (default for main) This allows the knob to be used for debugging on stable branches, too, which is believed to be the main reason one would want to twist it off. (direct commit) commit f302fd1aa6730facd53a3f761e0a57302731b03e Author: Ed Maste Date: Fri Jan 22 16:23:12 2021 -0500 elfctl: fix typo from last-minute refactoring Reported by: jkim Fixes: 86f33b5fcf6087bf4439881011b920ff99e6e300 commit 86f33b5fcf6087bf4439881011b920ff99e6e300 Author: Ed Maste Date: Fri Jan 22 12:22:35 2021 -0500 elfctl: allow features to be specified by value This will allow elfctl on older releases to set bits that are not yet known there, so that the binary will have the correct settings applied if run on a later FreeBSD version. PR: 252629 (related) Suggested by: kib Reviewed by: gbe (manpage, earlier), kib MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D28284 commit 57a543d8b85065f77e0b68162d09a03335970f90 Author: Mitchell Horne Date: Fri Jan 22 14:56:56 2021 -0400 gdb: only return signal values for powerpc's gdb_cpu_signal() Summary: The values returned by this function are reported to the gdb client as the reason for the break in execution, a signal value such as SIGTRAP, SIGEMT, or SIGSEGV. As such, exact vector numbers can be misidentified. Return SIGEMT in the default case instead. Reviewed by: alfredo MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D28046 commit 195cd6ae2481dd5ad555ed65c226b6f20908d66a Author: Jamie Gritton Date: Fri Jan 22 10:56:24 2021 -0800 jail: fix dangling reference bug from 6754ae2572eb The change to use refcounts for pr_uref was mishandled in prison_proc_free, so killing a jail's last process could add an extra reference, leaving it an unkillable zombie. commit 39c8ef90f6d035cd3c3ab40e051b1c0f419c76be Author: Jamie Gritton Date: Fri Jan 22 10:50:10 2021 -0800 jail: A jail could be removed without calling OSD methods Fix a long-standing bug where setting nopersist on a process-less jail would remove it without calling the the OSD PR_METHOD_REMOVE methods. commit 251a6ddfbdcd72e0de922e8320d2f0cc6806a423 Author: Kyle Evans Date: Wed Jan 20 08:03:21 2021 -0600 Regen src.conf after MK_{LIBTHR,LIBPTHREAD} removal commit 123ae3045dd21badb93ce52445e18e364b3ac807 Author: Kyle Evans Date: Wed Jan 20 08:01:25 2021 -0600 build: remove LIBPTHREAD/LIBTHR build options WITHOUT_LIBTHR has been broken for a little over five years now, since the xz 5.2.0 update introduced a hard liblzma dependency on libthr, and building a useful system without threading support is becoming increasingly more difficult. Additionally, in the five plus years that it's been broken more reverse dependencies have cropped up in libzstd, libsqlite3, and libcrypto (among others) that make it more and more difficult to reconcile the effort needed to fix these options. Remove the broken options. PR: 252760 Reviewed by: brooks, emaste, kib Differential Revision: https://reviews.freebsd.org/D28263 commit 035f4ea71e6bef713c06e1fece48518f9a47441c Author: Piotr Kubaj Date: Fri Jan 22 17:39:15 2021 +0100 powerpc64le: don't enable COMPAT_* options in GENERIC64LE Support for powerpc64le appeared in 13, so there's no point to enable COMPAT_* for older releases. Also disable COMPAT_FREEBSD32, since there's no powerpcle. Since that may change in the future, leave the option commented out. Approved by: bdragon, jhibbits (on IRC) commit c0a9a0cb1f3745dc6537861d8bdc43750e686794 Author: Piotr Kubaj Date: Fri Jan 22 17:39:15 2021 +0100 powerpc64le: don't enable COMPAT_* options in GENERIC64LE Support for powerpc64le appeared in 13, so there's no point to enable COMPAT_* for older releases. Also disable COMPAT_FREEBSD32, since there's no powerpcle. Since that may change in the future, leave the option commented out. Approved by: bdragon, jhibbits (on IRC) commit 62bcf61ab17062e1e63f55f0e993777552e5a513 Author: Mateusz Guzik Date: Fri Jan 22 14:29:01 2021 +0000 powerpc: fix build without DDB (cherry picked from commit eb61de5b7871e2ee2122b31418d1cd50ae43964e) commit eb61de5b7871e2ee2122b31418d1cd50ae43964e Author: Mateusz Guzik Date: Fri Jan 22 14:29:01 2021 +0000 powerpc: fix build without DDB commit 51d73a3e46cf9118bc0464c9c0aa99dca7aafe9a Author: Mateusz Guzik Date: Fri Jan 22 13:00:24 2021 +0000 newvers.sh: restore reporting branch names It got removed arguably without much discussion in the commit which added gitup support. (cherry picked from commit ace7209ce04d0e4dc0e84d5e2eb27fc762e67a01) commit d5bd29ed505f535b52673604951d018a43d72579 Author: Mateusz Guzik Date: Fri Jan 22 10:17:34 2021 +0000 Revert "[mips] revert r366664 - flip mips back from -O2 to -O" This reverts commit bd72252aace382921840ddbceea712b96f4ad242. The commit at hand breaks the build for all mips targets and does not have a one-liner fix. make[5]: "/usr/src/share/mk/sys.mk" line 169: Malformed conditional (${MACHINE_CPUARCH} == "mips" && ${COMPILER_TYPE} == "gcc") (cherry picked from commit bb3b6995c4d0ced1a87ec57407f216ece69ab674) commit ace7209ce04d0e4dc0e84d5e2eb27fc762e67a01 Author: Mateusz Guzik Date: Fri Jan 22 13:00:24 2021 +0000 newvers.sh: restore reporting branch names It got removed arguably without much discussion in the commit which added gitup support. commit e808c8309cc6ba9c42d68825dc445937a740c9e4 Author: Lewis Cook Date: Fri Jan 22 11:22:56 2021 +0000 Complete Steps 5 and 9 from the Committer's guide Summary: Steps 5 and 9: - Update Mentor and Mentee Information - Update Ports with Personal Information Reviewers: tcberner, fernape Reviewed By: fernape Subscribers: imp Differential Revision: https://reviews.freebsd.org/D28281 commit bb3b6995c4d0ced1a87ec57407f216ece69ab674 Author: Mateusz Guzik Date: Fri Jan 22 10:17:34 2021 +0000 Revert "[mips] revert r366664 - flip mips back from -O2 to -O" This reverts commit bd72252aace382921840ddbceea712b96f4ad242. The commit at hand breaks the build for all mips targets and does not have a one-liner fix. make[5]: "/usr/src/share/mk/sys.mk" line 169: Malformed conditional (${MACHINE_CPUARCH} == "mips" && ${COMPILER_TYPE} == "gcc") commit 64b1230c03c8dcb6f35041a87bad675062a7f7b2 Author: Mateusz Guzik Date: Fri Jan 22 10:16:57 2021 +0000 arm64: fix typo in file name in GENERIC-MMCCAM-NODEBUG commit af3993c9e4d7445caf92b36df2d8bfc6b76d456d Author: Li-Wen Hsu Date: Fri Jan 22 17:53:59 2021 +0800 Catch up another version bump to 14.0 Reported by: rm commit ed9b7f4414663703e0e9581a730c4bdfaca5687f Author: Oleksandr Tymoshenko Date: Tue Jan 12 22:27:10 2021 -0800 armv8crypto: add AES-GCM support Add support for AES-GCM using OpenSSL's accelerated routines. Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D27454 Sponsored by: Ampere Computing Submitted by: Klara, Inc. commit f9a66922c9ec6a82b72a62f5d1c93be1be91865a Author: Glen Barber Date: Thu Jan 21 19:49:30 2021 -0500 fix incorrect LLD_VERSION_STRING from previous commit Reported by: Oliver Pinter Sponsored by: Rubicon Communications, LLC ("Netgate") commit 02611ef8ee9f4572d251383560bd6f264f628fe7 Author: Glen Barber Date: Thu Jan 21 19:28:07 2021 -0500 Turn on MALLOC_PRODUCTION Approved by: re (implicit) Noticed by: kevans Sponsored by: Rubicon Communications, LLC ("Netgate") commit a53ce3fc4938e37d5ec89304846203d2083c61a2 Author: Glen Barber Date: Thu Jan 21 19:10:07 2021 -0500 Bump CURRENT to 14.0 This one goes to 14. Approved by: re (implicit) Sponsored by: Rubicon Communications, LLC ("Netgate") commit bfd15705156b0436cfe79aea11868dcc0c6e078a Author: Glen Barber Date: Thu Jan 21 19:06:26 2021 -0500 Create the stable/13 branch Prune *-NODEBUG kernels. Turn off debug options. Bump to ALPHA2. Approved by: re (implicit) Sponsored by: Rubicon Communications, LLC ("Netgate") commit 7fe0a3f2085758fdef0a705dbc81d72f1f1953c6 Author: Stefan Eßer Date: Sun Dec 27 21:53:09 2020 +0100 Import bc 3.2.4