]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
3 years agomrsas: update man page
Alfredo Dal'Ava Junior [Thu, 4 Feb 2021 06:13:13 +0000 (03:13 -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

3 years agorelease: disable the 'reldoc' target after the ASCIIDoctor switch
Glen Barber [Fri, 5 Feb 2021 16:46:49 +0000 (11:46 -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")

3 years agotruss: Decode sendfile(2) arguments
Mark Johnston [Fri, 5 Feb 2021 16:28:09 +0000 (11:28 -0500)]
truss: Decode sendfile(2) arguments

MFC after: 2 weeks

3 years agomrsas: unbreak i386 build
Alfredo Dal'Ava Junior [Fri, 5 Feb 2021 18:43:48 +0000 (15:43 -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

3 years agoImprove ACPI_NFIT_CONTROL_REGION formatting.
Alexander Motin [Fri, 5 Feb 2021 15:07:37 +0000 (10:07 -0500)]
Improve ACPI_NFIT_CONTROL_REGION formatting.

MFC after: 1 week

3 years agotools/git: Add git-arc
Mark Johnston [Fri, 5 Feb 2021 14:44:47 +0000 (09:44 -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

3 years agoAdd support for arm64 nGnRE device memory
Andrew Turner [Fri, 5 Feb 2021 10:50:29 +0000 (10:50 +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

3 years agogrep: turn off -w if -x is specified
Kyle Evans [Thu, 4 Feb 2021 21:35:58 +0000 (15:35 -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.

3 years agogrep: fix null pattern and empty pattern file behavior
Kyle Evans [Thu, 4 Feb 2021 21:26:45 +0000 (15:26 -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

3 years agocpucontrol(8): Fix display.
Konstantin Belousov [Fri, 5 Feb 2021 01:00:27 +0000 (03:00 +0200)]
cpucontrol(8): Fix display.

Sponsored by: The FreeBSD Foundation
MFC after: 3 days

3 years agoamd64 GENERIC: compile in mlx5en(4)
Konstantin Belousov [Wed, 3 Feb 2021 12:19:12 +0000 (14:19 +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

3 years agoEnable pvscsi and vmx in arm64 GENERIC
Ed Maste [Fri, 5 Feb 2021 00:14:12 +0000 (19:14 -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

3 years agoixl(4): Fix VLAN HW filtering
Krzysztof Galazka [Wed, 3 Feb 2021 23:22:55 +0000 (15:22 -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

3 years agoloader.efi: There are systems without ConOut, also use ConOutDev
Toomas Soome [Thu, 4 Feb 2021 20:49:02 +0000 (22:49 +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

3 years agoAdd a comment notifying that "device axp" requires miibus for build.
Muhammad Moinur Rahman [Thu, 4 Feb 2021 21:05:47 +0000 (21:05 +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

3 years agoFix mismerge in OFED update
Ryan Stone [Fri, 29 Jan 2021 20:48:50 +0000 (15:48 -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

3 years agoFix race condition in linuxkpi workqueue
Ryan Stone [Thu, 7 Jan 2021 17:25:56 +0000 (12:25 -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

3 years agotests/sys/vfs/lookup_cap_dotdot: No longer aborts after ATF update
Alex Richardson [Thu, 4 Feb 2021 17:48:29 +0000 (17:48 +0000)]
tests/sys/vfs/lookup_cap_dotdot: No longer aborts after ATF update

It appears this test no longer fails after c203bd70b5957f85616424b6fa374479372d06e3.

PR: 215690

3 years agousr.bin/jail: Fix tests when using kyua -v parallelism=N
Alex Richardson [Thu, 4 Feb 2021 17:56:54 +0000 (17:56 +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

3 years agosbin/pfctl: fix tests after recent output changes
Alex Richardson [Thu, 4 Feb 2021 17:56:26 +0000 (17:56 +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

3 years agoImport atf 0.22 snapshot ca73d08c3fc1ecffc1f1c97458c31ab82c12bb01
Alex Richardson [Thu, 4 Feb 2021 14:48:10 +0000 (14:48 +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.

3 years agoserf: Fix the default return value of the BIO control method.
John Baldwin [Wed, 3 Feb 2021 22:59:32 +0000 (14:59 -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 <mad@madpilot.net>
Reviewed by: emaste
MFC after: 3 days
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D28472

3 years ago[POWERPC64BE] add mrsas driver to GENERIC64
Alfredo Dal'Ava Junior [Thu, 4 Feb 2021 01:02:28 +0000 (22:02 -0300)]
[POWERPC64BE] add mrsas driver to GENERIC64

Submitted by:   Andre Fernando da Silva <andre.silva@eldorado.org.br>
Reviewed by:    luporl, alfredo, kadesai (on email)
Sponsored by:   Eldorado Research Institute (eldorado.org.br)
Differential Revision:  https://reviews.freebsd.org/D26531

3 years ago[POWERPC64BE] mrsas: add big-endian support
Alfredo Dal'Ava Junior [Thu, 4 Feb 2021 00:52:19 +0000 (21:52 -0300)]
[POWERPC64BE] mrsas: add big-endian support

Add endiannes conversions in order to support big-endian platforms

Submitted by: Andre Fernando da Silva <andre.silva@eldorado.org.br>
Reviewed by: luporl, alfredo, kadesai (on email)
Sponsored by: Eldorado Research Institute (eldorado.org.br)
Differential Revision: https://reviews.freebsd.org/D26531

3 years agoreadelf: do not trucate section name with -W
Ed Maste [Tue, 2 Feb 2021 14:35:04 +0000 (09:35 -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

3 years agoreadelf: decode LA48 and ASG_DISABLE feature flags
Ed Maste [Wed, 3 Feb 2021 21:16:45 +0000 (16:16 -0500)]
readelf: decode LA48 and ASG_DISABLE feature flags

MFC after: 1 week
Sponsored by: The FreeBSD Foundation

3 years agoAdd a VM flag to prevent reclaim on a failed contig allocation
Ryan Stone [Fri, 29 Jan 2021 21:13:57 +0000 (16:13 -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

3 years agodwmmc: Multiple busdma fixes.
Michal Meloun [Thu, 21 Jan 2021 14:06:19 +0000 (15:06 +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

3 years agolinux: remove locks around callout_drain in timerfd_close()
shu [Wed, 3 Feb 2021 19:10:58 +0000 (19:10 +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

3 years agoRevert "Reimplement strlen"
Mateusz Guzik [Wed, 3 Feb 2021 19:38:10 +0000 (19:38 +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

3 years agolinux: make timerfd_settime(2) set expirations count to zero
shu [Wed, 3 Feb 2021 16:51:45 +0000 (16:51 +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

3 years agotools/build/make.py: -DNO_CLEAN -> -DWITHOUT_CLEAN
Alex Richardson [Wed, 3 Feb 2021 15:56:03 +0000 (15:56 +0000)]
tools/build/make.py: -DNO_CLEAN -> -DWITHOUT_CLEAN

3 years agodu_test: Skip three tests if sparse files are not supported
Alex Richardson [Wed, 3 Feb 2021 16:07:05 +0000 (16:07 +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

3 years agodiff: Use unprivileged_user with report_identical test
Olivier Cochard [Wed, 3 Feb 2021 16:18:59 +0000 (17:18 +0100)]
diff: Use unprivileged_user with report_identical test

Approved by: bapt
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D28466

3 years agoExpose clang's alignment builtins and use them for roundup2/rounddown2
Alex Richardson [Wed, 3 Feb 2021 15:27:17 +0000 (15:27 +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

3 years agousr.sbin/praudit: Fix tests after 5619d49e07
Alex Richardson [Wed, 3 Feb 2021 15:26:19 +0000 (15:26 +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

3 years agoreadelf: Fix printing NT_FREEBSD_ARCH_TAG
Alex Richardson [Wed, 3 Feb 2021 15:24:28 +0000 (15:24 +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

3 years agoarm64: Initialize VFP control register.
Michal Meloun [Sat, 23 Jan 2021 20:19:07 +0000 (21:19 +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

3 years agowg(4): Add authors of the wg(4) driver to the manual page
Gordon Bergling [Wed, 3 Feb 2021 15:01:32 +0000 (16:01 +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

3 years agoAlways clamp curve25519 keys prior to use.
Peter Grehan [Wed, 3 Feb 2021 09:05:09 +0000 (19:05 +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

3 years agoatf: Fix ATF_BUILD_* values when not using the bootstrap compiler
Alex Richardson [Wed, 3 Feb 2021 09:32:16 +0000 (09:32 +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

3 years agosbin/bectl: Skip tests if sparse files are not supported
Alex Richardson [Wed, 3 Feb 2021 09:31:32 +0000 (09:31 +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

3 years agoFix build with read-only source dir after 83c20b8a2da0
Alex Richardson [Wed, 3 Feb 2021 09:29:08 +0000 (09:29 +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

3 years agoEnable multipath routing by default.
Alexander V. Chernikov [Wed, 3 Feb 2021 08:49:46 +0000 (08:49 +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

3 years agorelease.sh: Skip installing textproc/docproj when NODOC is set
Glen Barber [Wed, 3 Feb 2021 00:04:11 +0000 (19:04 -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")

3 years agoCorrect description for kern.proc.proc_td
Ed Maste [Tue, 2 Feb 2021 21:55:51 +0000 (16:55 -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

3 years agoAllow setting alias port ranges in libalias and ipfw. This will allow a system
Neel Chauhan [Tue, 2 Feb 2021 21:24:17 +0000 (13:24 -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

3 years agowg(4): Fix Copyright statement in man page
Gordon Bergling [Tue, 2 Feb 2021 19:16:52 +0000 (20:16 +0100)]
wg(4): Fix Copyright statement in man page

3 years agoAdd a wg(4) manual page
Gordon Bergling [Tue, 2 Feb 2021 19:13:53 +0000 (20:13 +0100)]
Add a wg(4) manual page

Reviewed by: brueffer, donner, debdrup, ygy
MFC after: 2 days

3 years agoMake DataSN counter of solicited Data-Out local.
Alexander Motin [Tue, 2 Feb 2021 18:37:13 +0000 (13:37 -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

3 years agogit hooks: add "Tested by" to commit message template
Ed Maste [Tue, 2 Feb 2021 18:36:45 +0000 (13:36 -0500)]
git hooks: add "Tested by" to commit message template

Reported by: mjg
Reviewed by: imp
Sponsored by: The FreeBSD Foundation

3 years agocache: fix trailing slash support in face of permission problems
Mateusz Guzik [Tue, 2 Feb 2021 18:06:56 +0000 (18:06 +0000)]
cache: fix trailing slash support in face of permission problems

Reported by: Johan Hendriks <joh.hendriks gmail.com>
Tested by: kevans

3 years agorelease: update workaround during transition to git
Glen Barber [Tue, 2 Feb 2021 17:19:36 +0000 (12:19 -0500)]
release: update workaround during transition to git

PR: 253181
Submitted by: Yasuhiro Kimura
MFC after: 3 days
Sponsored by: Rubicon Communications, LLC ("Netgate")

3 years agosrc.conf.5: regenerate
Konstantin Belousov [Tue, 2 Feb 2021 16:48:08 +0000 (18:48 +0200)]
src.conf.5: regenerate

3 years agoWITH_OFED build option: fix
Konstantin Belousov [Tue, 2 Feb 2021 13:01:26 +0000 (15:01 +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

3 years agoUse compat.linux.emul_path instead of hardcoded path in /etc/rc.d/linux
Edward Tomasz Napierala [Tue, 2 Feb 2021 14:40:38 +0000 (14:40 +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

3 years agortld: Fix null-pointer dereference
David Chisnall [Tue, 2 Feb 2021 14:06:33 +0000 (16:06 +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

3 years agoRegister the bad read before bailing on terminal errors.
Poul-Henning Kamp [Tue, 2 Feb 2021 12:01:38 +0000 (12:01 +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.

3 years agotests/sys/audit: Skip extattr tests if extattrs are not supported
Alex Richardson [Tue, 2 Feb 2021 09:55:18 +0000 (09:55 +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

3 years agotests/sys/kern/crc32: Check for SSE4.2 before using it
Alex Richardson [Tue, 2 Feb 2021 09:52:52 +0000 (09:52 +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

3 years agoRevert "diff: eliminate a useless lseek"
Baptiste Daroussin [Tue, 2 Feb 2021 09:07:57 +0000 (10:07 +0100)]
Revert "diff: eliminate a useless lseek"

This changes breaks when one of the files is stdin

This reverts commit fa977a3b2bb2d0e6c2957b14474c31b58dd3a8e1.

Reported by: olivier

3 years agobhyve/ioapic: improve the tracking of IRR bit
Roger Pau Monné [Tue, 19 Jan 2021 11:52:28 +0000 (12:52 +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

3 years agobhyve/ioapic: only account for asserted line in level mode
Roger Pau Monné [Tue, 19 Jan 2021 12:41:03 +0000 (13:41 +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

3 years agobhyve/vioapic: remove an extra pin masked check
Roger Pau Monné [Tue, 19 Jan 2021 11:52:44 +0000 (12:52 +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

3 years agoReplace the redundant MENTAT macro with SOLARIS.
Cy Schubert [Thu, 28 Jan 2021 05:50:04 +0000 (21:50 -0800)]
Replace the redundant MENTAT macro with SOLARIS.

MENTAT and SOLARIS are synonymous. Remove the extraneous duplicate
macro.

MFC after: 1 week

3 years agoIndentation cleanup resulting from the cleanup of #ifdefs.
Cy Schubert [Wed, 27 Jan 2021 15:25:00 +0000 (07:25 -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

3 years agoRetire the K&R/STD C __P prototype declarations.
Cy Schubert [Tue, 26 Jan 2021 06:24:28 +0000 (22:24 -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

3 years agoBump shared library versions after ncurses bump in 13.
John Baldwin [Tue, 2 Feb 2021 01:09:33 +0000 (17:09 -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

3 years agotail: fix "tail -F" file rotation detection
Chuck Silvers [Tue, 2 Feb 2021 00:21:14 +0000 (16:21 -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

3 years agovt: parse_font_info_static should set refcount, not parse_font_info
Toomas Soome [Sun, 31 Jan 2021 21:04:59 +0000 (23:04 +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

3 years agozfs: update zfs_config.h to match OpenZFS gf11b09dec
Martin Matuska [Mon, 1 Feb 2021 21:08:19 +0000 (22:08 +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

3 years agoconfig: Fix typo in comment.
John Baldwin [Mon, 1 Feb 2021 21:13:36 +0000 (13:13 -0800)]
config: Fix typo in comment.

3 years agoipfw(8) crashes when ext6hdr option is omitted
Evgeniy Khramtsov [Mon, 1 Feb 2021 19:03:57 +0000 (20:03 +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

3 years agoiflib: Free resources in a consistent order during detach
Sai Rajesh Tallamraju [Mon, 1 Feb 2021 16:13:00 +0000 (11:13 -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

3 years agostand/amd64: remove unused addr parameter from bi_load64
Roger Pau Monné [Fri, 29 Jan 2021 11:29:37 +0000 (12:29 +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

3 years agosrc.conf(5): regenerate after MK_ZFS change
Mitchell Horne [Mon, 1 Feb 2021 14:34:11 +0000 (10:34 -0400)]
src.conf(5): regenerate after MK_ZFS change

With e5cc1c474841, this option is also disabled by WITHOUT_OPENSSL and
WITHOUT_CRYPT.

3 years agosrc.opts.mk: set MK_ZFS conditional on MK_OPENSSL
Mitchell Horne [Sat, 30 Jan 2021 19:04:08 +0000 (15:04 -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

3 years agobridge: fix STP roles and protos strings
Jonah Caplan [Sat, 30 Jan 2021 13:54:09 +0000 (14:54 +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

3 years agoarm64: Improve DDB backtrace support
Jessica Clarke [Mon, 1 Feb 2021 14:15:57 +0000 (14:15 +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

3 years agoFix LINT kernel builds after 1a714ff20419 .
Hans Petter Selasky [Mon, 1 Feb 2021 12:23:21 +0000 (13:23 +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

3 years agosctp: small cleanup, no functional change intended.
Michael Tuexen [Mon, 1 Feb 2021 13:03:41 +0000 (14:03 +0100)]
sctp: small cleanup, no functional change intended.

MFC after: 3 days

3 years agozfs: remove incomplete ifdefs for lockless symlink support
Mateusz Guzik [Mon, 1 Feb 2021 12:18:27 +0000 (13:18 +0100)]
zfs: remove incomplete ifdefs for lockless symlink support

This wil be handled differently upstream and merged later.

3 years agocxgbe(4): Fixes to tx coalescing.
Navdeep Parhar [Mon, 1 Feb 2021 11:00:09 +0000 (03:00 -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.

3 years agoRemove the MK_LIBCPLUSPLUS option
Alex Richardson [Sat, 30 Jan 2021 17:56:35 +0000 (17:56 +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

3 years agomips: fix NLM platforms breakage caused by e0a0a3ef
Oleksandr Tymoshenko [Mon, 1 Feb 2021 07:56:22 +0000 (23:56 -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

3 years agox86: use compiler intrinsics for bswap*
Mateusz Guzik [Mon, 1 Feb 2021 03:00:13 +0000 (04:00 +0100)]
x86: use compiler intrinsics for bswap*

3 years agoamd64: use compiler intrinsics for bsf* and bsr*
Mateusz Guzik [Sun, 31 Jan 2021 23:35:30 +0000 (00:35 +0100)]
amd64: use compiler intrinsics for bsf* and bsr*

3 years agocache: add delayed degenerate path handling
Mateusz Guzik [Sun, 31 Jan 2021 20:54:35 +0000 (21:54 +0100)]
cache: add delayed degenerate path handling

3 years agocache: move hash computation into the parsing loop
Mateusz Guzik [Sun, 31 Jan 2021 18:25:18 +0000 (19:25 +0100)]
cache: move hash computation into the parsing loop

3 years agosctp: improve input validation
Michael Tuexen [Sun, 31 Jan 2021 22:43:15 +0000 (23:43 +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

3 years agomips: fix early kernel panic when setting up interrupt counters
Oleksandr Tymoshenko [Sat, 30 Jan 2021 06:11:24 +0000 (22:11 -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

3 years agolibc: fix buffer overrun in getrpcport(3)
Edward Tomasz Napierala [Sun, 31 Jan 2021 21:41:55 +0000 (21:41 +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

3 years agomsdosfs: fix vnode leak with msdosfs_rename()
Edward Tomasz Napierala [Sun, 31 Jan 2021 21:37:41 +0000 (21:37 +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

3 years agomsdosfs: fix double unlock if the source file disappears
Edward Tomasz Napierala [Sun, 31 Jan 2021 21:07:02 +0000 (21:07 +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

3 years agoMerge commit '47a52dc4d48f259ab7d9f9ba6b65f4f2331a22dc'
Stefan Eßer [Sun, 31 Jan 2021 20:07:42 +0000 (21:07 +0100)]
Merge commit '47a52dc4d48f259ab7d9f9ba6b65f4f2331a22dc'

Update to version 3.2.6

MFC after: 3 days

3 years agoVendor import of Gavin Howard's bc version 3.2.6
Stefan Eßer [Sun, 31 Jan 2021 19:56:48 +0000 (20:56 +0100)]
Vendor import of Gavin Howard's bc version 3.2.6

3 years agocxgb(4): Remove assumption of physically contiguous mbufs.
Alexander Motin [Sun, 31 Jan 2021 17:46:57 +0000 (12:46 -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

3 years agotools: boot: use four jobs for building stand
Kyle Evans [Sun, 31 Jan 2021 16:07:31 +0000 (10:07 -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.

3 years agoamd64: move memcmp checks upfront
Mateusz Guzik [Sun, 31 Jan 2021 15:46:18 +0000 (16:46 +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

3 years agoamd64: add a note about simd to libc memset, memmove and memcmp
Mateusz Guzik [Sun, 31 Jan 2021 15:50:34 +0000 (16:50 +0100)]
amd64: add a note about simd to libc memset, memmove and memcmp