]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
3 years agoMerge commit e09107ab8 from llvm git (by Raul Tambre):
dim [Thu, 17 Sep 2020 19:43:25 +0000 (19:43 +0000)]
Merge commit e09107ab8 from llvm git (by Raul Tambre):

  [Sema] Introduce BuiltinAttr, per-declaration builtin-ness

  Instead of relying on whether a certain identifier is a builtin,
  introduce BuiltinAttr to specify a declaration as having builtin
  semantics.

  This fixes incompatible redeclarations of builtins, as reverting the
  identifier as being builtin due to one incompatible redeclaration
  would have broken rest of the builtin calls.
  Mostly-compatible redeclarations of builtins also no longer have
  builtin semantics. They don't call the builtin nor inherit their
  attributes.
  A long-standing FIXME regarding builtins inside a namespace enclosed
  in extern "C" not being recognized is also addressed.

  Due to the more correct handling attributes for builtin functions are
  added in more places, resulting in more useful warnings.
  Tests are updated to reflect that.

  Intrinsics without an inline definition in intrin.h had `inline` and
  `static` removed as they had no effect and caused them to no longer
  be recognized as builtins otherwise.

  A pthread_create() related test is XFAIL-ed, as it relied on it being
  recognized as a builtin based on its name.
  The builtin declaration syntax is too restrictive and doesn't allow
  custom structs, function pointers, etc.
  It seems to be the only case and fixing this would require reworking
  the current builtin syntax, so this seems acceptable.

  Fixes PR45410.

  Reviewed By: rsmith, yutsumi

  Differential Revision: https://reviews.llvm.org/D77491

This should fix 'Assertion failed: (i < getNumParams() && "Illegal
param #"), function getParamDecl, file
/usr/src/contrib/llvm-project/clang/include/clang/AST/Decl.h, line 2430'
when building the graphics/pgplot port.

Note that there may also have been other ports which triggered this
assertion, if they redeclare standard functions with incompatible
arguments.

Reported by: zeising
MFC after: 6 weeks
X-MFC-With: r364284

3 years agomakefs: connect cd9660 El Torito EFI boot image system type
emaste [Thu, 17 Sep 2020 19:41:10 +0000 (19:41 +0000)]
makefs: connect cd9660 El Torito EFI boot image system type

Sponsored by: The FreeBSD Foundation

3 years agoCirrus-CI: build as an unprivileged user
emaste [Thu, 17 Sep 2020 18:47:23 +0000 (18:47 +0000)]
Cirrus-CI: build as an unprivileged user

The Cirrus-CI-provided working tree is owned by root.  Leave that as is
for simplicity but build as an unprivileged user; this tests building
with an unmodifiable source tree as a side effect.

Continue running the smoke test as root for now, as it failed when run
as an unprivileged user - pkg reported "Fail to chmod
/usr/bin/.pkgtemp.lpq.dUHpEqPGJ9pq:Operation not permitted"

Sponsored by: The FreeBSD Foundation

3 years agoFix additional memory leak in process_mapfile
vangyzen [Thu, 17 Sep 2020 18:24:51 +0000 (18:24 +0000)]
Fix additional memory leak in process_mapfile

Additional Coverity detected memory leak fix.

Submitted by: bret_ketchum@dell.com
Reported by: Coverity
Reviewed by: cem, emaste
MFC after: 2 weeks
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D26462

3 years agoRemove no longer used variable.
jhb [Thu, 17 Sep 2020 18:06:57 +0000 (18:06 +0000)]
Remove no longer used variable.

Pointy hat to: jhb
Reported by: kevans
MFC after: 1 week

3 years agoMove to a more robust and conservative alloation scheme for devctl messages
imp [Thu, 17 Sep 2020 17:29:33 +0000 (17:29 +0000)]
Move to a more robust and conservative alloation scheme for devctl messages

Change the zone setup:
- Allow slabs to be returned to the OS
- Set the number of slots to the max devctl will queue before discarding
- Reserve 2% of the max (capped at 100) for low memory allocations
- Disable per-cpu caching since we don't need it and we avoid some pathologies

Change the alloation strategiy a bit:
- If a normal allocation fails, try to get the reserve
- If a reserve allocation fails, re-use the oldest-queued entry for storage
- If there's a weird race/failure and nothing on the queue to steal, return NULL

This addresses two main issues in the old code:
- If devd had died, and we're generating a lot of messages, we have an
  unbounded leak. This new scheme avoids the issue that lead to this.
- The MPASS that was 'sure' the allocation couldn't have failed turned out
  to be wrong in some rare cases. The new code doesn't make this assumption.

Since we reserve only 2% of the space, we go from about 1MB of
allocation all the time to more like 50kB for the reserve.

Reviewed by: markj@
Differential Revision: https://reviews.freebsd.org/D26448

3 years agoRemove support for setting some obscure fields.
jhb [Thu, 17 Sep 2020 17:07:04 +0000 (17:07 +0000)]
Remove support for setting some obscure fields.

Don't permit setting the exception bitmap or VMCS entry interrupt
information.  These are not generally useful to set.  If it is needed
in the future, dedicated pseudo registers can be added for these that
would be used with vm_set_register().

Discussed with: grehan
MFC after: 1 week

3 years agoIncrease the default vm.max_user_wired value.
markj [Thu, 17 Sep 2020 16:49:28 +0000 (16:49 +0000)]
Increase the default vm.max_user_wired value.

Since r347532 (merged to stable/12) we only count user-wired pages
towards the system limit.  However, we now also treat pages wired by
hypervisors (bhyve and virtualbox) as user-wired, so starting VMs with
large amounts of RAM tends to fail due to the low limit.

The purpose of the limit is to provide a seatbelt, not to impose some
policy on the use of wired memory.  Thus, increase the default limit to
allow reasonable VM configurations to work without tuning.

Reviewed by: kib
Discussed with: dougm
MFC after: 3 days
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26424

3 years agoAdd some basic regression tests for SHM_LARGEPAGE.
markj [Thu, 17 Sep 2020 16:44:12 +0000 (16:44 +0000)]
Add some basic regression tests for SHM_LARGEPAGE.

Discussed with: kib
Sponsored by: Juniper Networks, Inc.
Sponsored by: Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D25900

3 years agoPromote the installworld `certctl rehash` to distributeworld
kevans [Thu, 17 Sep 2020 15:58:42 +0000 (15:58 +0000)]
Promote the installworld `certctl rehash` to distributeworld

Contrary to my belief, installworld is not sufficient for getting certs
installed into VM images. Promote the rehash to both installworld and
distributeworld (notably: not stageworld) and rehash the base distdir so we
end up with /etc/ssl/certs populated in the base dist archive. A future
commit will remove the rehash from bsdinstall, which doesn't really need to
happen if they're installed into base.txz.

While here, fix a minor typo: s/CERTCLTFLAGS/CERTCTLFLAGS/

MFC after: 1 week

3 years agoStop using lorder and ranlib when building libraries
arichardson [Thu, 17 Sep 2020 15:07:25 +0000 (15:07 +0000)]
Stop using lorder and ranlib when building libraries

Use of ranlib or lorder is no longer necessary with current linkers
(probably anything newer than ~1990) and ar's ability to create an object
index and symbol table in the archive.
Currently the build system uses lorder+tsort to sort the .o files in
dependency order so that a single-pass linker can use them. However,
we can use the -s flag to ar to add an index to the .a file which makes
lorder unnecessary.
Running ar -s is equivalent to running ranlib afterwards, so we can also
skip the ranlib invocation.

Similarly, we don't have to pass the .o files for shared libraries in
dependency order since both ld.bfd and ld.lld will correctly resolve
references between the .o files.

This removes many fork()+execve calls for each library so should speed up
builds a bit. Additionally lorder.sh uses a regular expression that is not
supported by the macOS libc or glibc and results in many warnings when
cross-building (see D25989).

There is one functional change: lorder.sh removed duplicated .o files
from the linker command line which now no longer happens. I fixed the duplicates
in the base system in r364649. I also checked the ports tree for uses of
bsd.lib.mk and found one duplicate source file which I fixed in r548168.
Most ports use CMake/autotools rather than bsd.lib.mk but if this breaks any
ports that I missed in my search please let me know.

Avoiding the shell script actually speeds up the linking step noticeably: I
measured how long it takes to rebuild the .a and .so files for lib/libc using a
basic benchmark: `rm $LIBC_OBJDIR/*.so* $LIBC_OBJDIR/*.a* && /usr/bin/time make -DWITHOUT_TESTS -s > /dev/null`
Without this change ~4.5 seconds and afterwards ~3.1 seconds.
Looking at truss -cf output we can see that the number fork() system
calls goes down from 27 to 12 (and the speedup while tracing is more
noticeable: 81 seconds -> 65 seconds).

See also https://www.gnu.org/software/coreutils/manual/html_node/tsort-background.html
for some more background:
This whole procedure has been obsolete since about 1980, because Unix
archives now contain a symbol table (traditionally built by ranlib, now
generally built by ar itself), and the Unix linker uses the symbol table
to effectively make multiple passes over an archive file.

Or alternatively https://www.unix.com/man-page/osf1/1/lorder/:
The lorder command is essentially obsolete.  Use the following command in
its place: % ar -ts file.a

Reviewed By:  emaste, imp, dim
Differential Revision: https://reviews.freebsd.org/D26044

3 years agoAdd dtb/sifive module
mhorne [Thu, 17 Sep 2020 14:58:30 +0000 (14:58 +0000)]
Add dtb/sifive module

This allows building the HiFive Unleashed device tree blob.

Reviewed by: manu
Differential Revision: https://reviews.freebsd.org/D26459

3 years agoReduce code duplication by introducing linux_copyout_sockaddr()
trasz [Thu, 17 Sep 2020 12:14:24 +0000 (12:14 +0000)]
Reduce code duplication by introducing linux_copyout_sockaddr()
helper function.  No functional changes.

Reviewed by: emaste
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D25804

3 years agoAdd support for SOUND_MIXER_WRITE_MONITOR ioctl. Fixes alsamixer(1)
trasz [Thu, 17 Sep 2020 11:44:45 +0000 (11:44 +0000)]
Add support for SOUND_MIXER_WRITE_MONITOR ioctl.  Fixes alsamixer(1)
on my x220.

Reviewed by: emaste
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D25806

3 years agoGet rid of sv_errtbl and SV_ABI_ERRNO().
trasz [Thu, 17 Sep 2020 11:39:33 +0000 (11:39 +0000)]
Get rid of sv_errtbl and SV_ABI_ERRNO().

Reviewed by: kib
Sponsored by: DARPA
Differential Revision: https://reviews.freebsd.org/D26388

3 years agoRevert r249362, atime update in tmpfs is fixed in r365810
lwhsu [Thu, 17 Sep 2020 07:13:41 +0000 (07:13 +0000)]
Revert r249362, atime update in tmpfs is fixed in r365810

PR: 249362
Sponsored by: The FreeBSD Foundation

3 years agogeom_part: make it possible recovering broken GPT after some LBAs cut off
eugen [Thu, 17 Sep 2020 04:39:39 +0000 (04:39 +0000)]
geom_part: make it possible recovering broken GPT after some LBAs cut off

This is followup to r365477.

If pre-formatted device has GPT and a partition covering
last available LBAs and the device is attached using
a bridge reducing amount of LBAs, then it could be not enough
forcing GEOM to use primary GPT. Also, we should make it possible
to recover GPT and this requires either deleting or resizing the partition.

This change enables "gpart delete" and "gpart resize" commands
on corrupted GPT with following "gpart recover".

It still does not allow modifying corrupted GPT without
preliminary setting sysctl kern.geom.part.check_integrity=0

For example:

# gpart show da0
=>        34  3906963389  da0  GPT  (1.8T) [CORRUPT]
          34      262144    1  ms-reserved  (128M)
      262178        2014       - free -  (1.0M)
      264192  3906764943    2  freebsd-swap  (1.8T)
# gpart resize -i 2 -s 3900000000 da0
# gpart recover da0

Reported by: Alex Korchmar
MFC after: 3 days

3 years agoinstallworld: run `certctl rehash` after installation completes
kevans [Thu, 17 Sep 2020 02:18:21 +0000 (02:18 +0000)]
installworld: run `certctl rehash` after installation completes

This was originally introduced back in r360833, and subsequently reverted
because it was broken for -DNO_ROOT builds and it may not have been the
correct place for it.

While debatably this may still not be 'the correct place,' it's much cleaner
than scattering rehashes all throughout the tree. brooks has fixed the issue
with -DNO_ROOT by properly writing to the METALOG in r361397.

Do note that this is different than what was originally committed; brooks
had revisions in D24932 that made it actually use the revised unprivileged
mode and write to METALOG, along with being a little more friendly to
foreign crossbuilds and just using the certctl in-tree.

With this change, I believe we should now have a populated /etc/ssl/certs in
the VM images.

MFC after: 1 week

3 years agoPut calls to check_pgrp_jobc() in fixjobc_kill() under INVARIANTS.
kib [Thu, 17 Sep 2020 00:07:15 +0000 (00:07 +0000)]
Put calls to check_pgrp_jobc() in fixjobc_kill() under INVARIANTS.

Reported by: Michael Butler <imb@protected-networks.net>
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

3 years agoAdd check_pgrp_jobc() calls into process exit path.
kib [Wed, 16 Sep 2020 21:49:19 +0000 (21:49 +0000)]
Add check_pgrp_jobc() calls into process exit path.

Both before and after job control adjustments.

Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D26416

3 years agoFix fixjobc+orhpanage.
kib [Wed, 16 Sep 2020 21:46:57 +0000 (21:46 +0000)]
Fix fixjobc+orhpanage.

Orphans affect job control state, we must account for them when
changing pg_jobc.

Instead of p_pptr, use proc_realparent() to get parent relevant for
job control.

Use correct calculation of the parent for exiting process.  For jobc
purposes, we must use realparent, but if it is also exiting, we should
fall to reaper, then recursively find non-exiting reaper.

Reported by: trasz
PR: 249257
Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D26416

3 years agoAssert that P_TREE_GRPEXITED is set only once.
kib [Wed, 16 Sep 2020 21:40:32 +0000 (21:40 +0000)]
Assert that P_TREE_GRPEXITED is set only once.

Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D26416

3 years agoproc_realparent: if p_oppid does not match pid of the current parent
kib [Wed, 16 Sep 2020 21:38:24 +0000 (21:38 +0000)]
proc_realparent: if p_oppid does not match pid of the current parent
for non-orphaned process, return reaper instead of init.

Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D26416

3 years agoImprove ddb 'show pgrpdump' command.
kib [Wed, 16 Sep 2020 21:34:18 +0000 (21:34 +0000)]
Improve ddb 'show pgrpdump' command.

Use ddb pager.
Make lines more compact.
Eliminate unneeded casts.
Print more job-control related info when reporting process group.

Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D26416

3 years agotmpfs: restore atime updates for reads from page cache.
kib [Wed, 16 Sep 2020 21:28:18 +0000 (21:28 +0000)]
tmpfs: restore atime updates for reads from page cache.

Split TMPFS_NODE_ACCCESSED bit into dedicated byte that can be updated
atomically without locks or (locked) atomics.

tn_update_getattr() change also contains unrelated bug fix.

Reported by: lwhsu
PR: 249362
Reviewed by: markj (previous version)
Discussed with: mjg
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D26451

3 years agoStyle.
kib [Wed, 16 Sep 2020 21:24:34 +0000 (21:24 +0000)]
Style.

Sponsored by: The FreeBSD Foundation
MFC after: 3 days

3 years agoMerge llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp
dim [Wed, 16 Sep 2020 16:58:29 +0000 (16:58 +0000)]
Merge llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and openmp
release/11.x llvmorg-11.0.0-rc2-91-g6e042866c30.

MFC after: 6 weeks
X-MFC-With: r364284

3 years agoif_media: definitions for 40GE LM4 ethernet media type
mhorne [Wed, 16 Sep 2020 14:45:16 +0000 (14:45 +0000)]
if_media: definitions for 40GE LM4 ethernet media type

Reviewed by: erj
Sponsored by: NetApp, Inc.
Sponsored by: Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D26276

3 years agoMove PLTs to the beginning of amd64 kernel modules.
markj [Wed, 16 Sep 2020 13:51:47 +0000 (13:51 +0000)]
Move PLTs to the beginning of amd64 kernel modules.

As with .text, the aim is to ensure that executable sections are
segregated from the rest, to avoid creation of writeable and executable
mappings.  Recent versions of LLVM emit a PLT in firmware modules.

Reviewed by: kib
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26444

3 years agoTemporarily skip sys.fs.tmpfs.times_test.{empty,non_empty} in CI
lwhsu [Wed, 16 Sep 2020 09:58:15 +0000 (09:58 +0000)]
Temporarily skip sys.fs.tmpfs.times_test.{empty,non_empty} in CI

PR: 249362
Sponsored by: The FreeBSD Foundation

3 years agoUpdate to 2020.08.19
bapt [Wed, 16 Sep 2020 07:30:18 +0000 (07:30 +0000)]
Update to 2020.08.19

MFC after: 3 days

3 years agoUse standard bool type, instead of non-standard boolean_t
imp [Wed, 16 Sep 2020 06:02:30 +0000 (06:02 +0000)]
Use standard bool type, instead of non-standard boolean_t

3 years agoFix a LOR between the NFS server and server side krpc.
rmacklem [Wed, 16 Sep 2020 02:25:18 +0000 (02:25 +0000)]
Fix a LOR between the NFS server and server side krpc.

Recent testing of the NFS-over-TLS code found a LOR between the mutex lock
used for sessions and the sleep lock used for server side krpc socket
structures.
The code in nfsrv_checksequence() would call SVC_RELEASE() with the mutex
held.  Normally this is ok, since all that happens is SVC_RELEASE()
decrements a reference count.  However, if the socket has just been shut
down, SVC_RELEASE() drops the reference count to 0 and acquires a sleep
lock during destruction of the server side krpc structure.

This patch fixes the problem by moving the SVC_RELEASE() call in
nfsrv_checksequence() down a few lines to below where the mutex is released.

MFC after: 1 week

3 years agoFix locking in uipc_accept().
markj [Tue, 15 Sep 2020 23:03:56 +0000 (23:03 +0000)]
Fix locking in uipc_accept().

Reported by: cy
MFC after: 1 week
Sponsored by: The FreeBSD Foundation

3 years agoAdd tmpfs page cache read support.
kib [Tue, 15 Sep 2020 22:19:16 +0000 (22:19 +0000)]
Add tmpfs page cache read support.

Or it could be explained as lockless (for vnode lock) reads.  Reads
are performed from the node tn_obj object.  Tmpfs regular vnode object
lifecycle is significantly different from the normal OBJT_VNODE: it is
alive as far as ref_count > 0.

Ensure liveness of the tmpfs VREG node and consequently v_object
inside VOP_READ_PGCACHE by referencing tmpfs node in tmpfs_open().
Provide custom tmpfs fo_close() method on file, to ensure that close
is paired with open.

Add tmpfs VOP_READ_PGCACHE that takes advantage of all tmpfs quirks.
It is quite cheap in code size sense to support page-ins for read for
tmpfs even if we do not own tmpfs vnode lock.  Also, we can handle
holes in tmpfs node without additional efforts, and do not have
limitation of the transfer size.

Reviewed by: markj
Discussed with and benchmarked by: mjg (previous version)
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D26346

3 years agoMicrooptimize tmpfs node ref/unref by using atomics.
kib [Tue, 15 Sep 2020 22:13:21 +0000 (22:13 +0000)]
Microoptimize tmpfs node ref/unref by using atomics.

Avoid tmpfs mount and node locks when ref count is greater than zero,
which is the case until node is being destroyed by unlink or unmount.

Reviewed by: markj
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D26346

3 years agoConvert page cache read to VOP.
kib [Tue, 15 Sep 2020 22:06:36 +0000 (22:06 +0000)]
Convert page cache read to VOP.

There are several negative side-effects of not calling into VOP layer
at all for page cache reads.  The biggest is the missed activation of
EVFILT_READ knotes.

Also, it allows filesystem to make more fine grained decision to
refuse read from page cache.

Keep VIRF_PGREAD flag around, it is still useful for nullfs, and for
asserts.

Reviewed by: markj
Tested by: pho
Discussed with: mjg
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D26346

3 years agovfs_subr.c: export io_hold_cnt and vn_read_from_obj().
kib [Tue, 15 Sep 2020 22:00:58 +0000 (22:00 +0000)]
vfs_subr.c: export io_hold_cnt and vn_read_from_obj().

Reviewed by: markj
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D26346

3 years agoDo not copy vp into f_data for DTYPE_VNODE files.
kib [Tue, 15 Sep 2020 21:55:21 +0000 (21:55 +0000)]
Do not copy vp into f_data for DTYPE_VNODE files.

The pointer to vnode is already stored into f_vnode, so f_data can be
reused.  Fix all found users of f_data for DTYPE_VNODE.

Provide finit_vnode() helper to initialize file of DTYPE_VNODE type.

Reviewed by: markj (previous version)
Discussed with: freqlabs (openzfs chunk)
Tested by: pho (previous version)
Sponsored by: The FreeBSD Foundation
Differential revision: https://reviews.freebsd.org/D26346

3 years agoe1000: Properly retain promisc flag
erj [Tue, 15 Sep 2020 21:07:30 +0000 (21:07 +0000)]
e1000: Properly retain promisc flag

From Franco:
The iflib rewrite forced the promisc flag but it was not reported
to the system.  Noticed on a stock VM that went into unsolicited
promisc mode when dhclient was started during bootup.

PR: 248869
Submitted by: Franco Fichtner <franco@opnsense.org>
Reviewed by: erj@
MFC after: 3 days

3 years agobhyve: do not permit write access to VMCB / VMCS
emaste [Tue, 15 Sep 2020 21:04:27 +0000 (21:04 +0000)]
bhyve: do not permit write access to VMCB / VMCS

Reported by: Patrick Mooney
Submitted by: jhb
Security: CVE-2020-24718

3 years agoigb(4): Fix define and includes with RSS option enabled
erj [Tue, 15 Sep 2020 21:00:25 +0000 (21:00 +0000)]
igb(4): Fix define and includes with RSS option enabled

This re-adds the opt_rss.h header to the driver and includes some
RSS-specific headers when RSS is defined.

PR: 249191
Submitted by: Milosz Kaniewski <milosz.kaniewski@gmail.com>
MFC after: 3 days

3 years agoftpd: Exit during authentication if an error occurs after chroot().
markj [Tue, 15 Sep 2020 20:54:18 +0000 (20:54 +0000)]
ftpd: Exit during authentication if an error occurs after chroot().

admbug: 969
Security: CVE-2020-7468

3 years ago[PowerPC64LE] Use correct in_masks table on LE to fix checksumming
bdragon [Tue, 15 Sep 2020 20:47:33 +0000 (20:47 +0000)]
[PowerPC64LE] Use correct in_masks table on LE to fix checksumming

Due to a check that should have been an endian check being an #if 0,
the wrong checksum mask table was being used on LE, which was causing
extreme strangeness in DNS resolution -- *some* hosts would be resolvable,
but most would not.

This fixes DNS resolution.

(I am committing some parts of the LE patchset ahead of time to reduce the
amount of work I have to do while committing the main patchset.)

Sponsored by: Tag1 Consulting, Inc.

3 years ago[PowerPC64LE] Set up the powernv partition table correctly.
bdragon [Tue, 15 Sep 2020 20:25:38 +0000 (20:25 +0000)]
[PowerPC64LE] Set up the powernv partition table correctly.

The partition table is always big endian.

Sponsored by: Tag1 Consulting, Inc.

3 years agobhyve: intercept AMD SVM instructions.
kib [Tue, 15 Sep 2020 20:22:50 +0000 (20:22 +0000)]
bhyve: intercept AMD SVM instructions.

Intercept and report #UD to VM on SVM/AMD in case VM tried to execute an
SVM instruction.  Otherwise, SVM allows execution of them, and instructions
operate on host physical addresses despite being executed in guest mode.

Reported by: Maxime Villard <max@m00nbsd.net>
admbug: 972
CVE: CVE-2020-7467
Reviewed by: grehan, markj
Differential revision: https://reviews.freebsd.org/D26313

3 years agoFix locking in uipc_accept().
markj [Tue, 15 Sep 2020 19:23:42 +0000 (19:23 +0000)]
Fix locking in uipc_accept().

This function wasn't converted to use the new locking protocol in
r333744.  Make it use the PCB lock for synchronizing connection state.

Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26300

3 years agoSimplify unix socket connection peer locking.
markj [Tue, 15 Sep 2020 19:23:22 +0000 (19:23 +0000)]
Simplify unix socket connection peer locking.

unp_pcb_owned_lock2() has some sharp edges and forces callers to deal
with a bunch of cases.  Simplify it:

- Rename to unp_pcb_lock_peer().
- Return the connected peer instead of forcing callers to load it
  beforehand.
- Handle self-connected sockets.
- In unp_connectat(), just lock the accept socket directly.  It should
  not be possible for the nascent socket to participate in any other
  lock orders.
- Get rid of connect_internal().  It does not provide any useful
  checking anymore.
- Block in unp_connectat() when a different thread is concurrently
  attempting to lock both sides of a connection.  This provides simpler
  semantics for callers of unp_pcb_lock_peer().
- Make unp_connectat() return EISCONN if the socket is already
  connected.  This fixes a race[1] when multiple threads attempt to
  connect() to different addresses using the same datagram socket.
  Upper layers will disconnect a connected datagram socket before
  calling the protocol connect's method, but there is no synchronization
  between this and protocol-layer code.

Reported by: syzkaller [1]
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26299

3 years agoAvoid an unnecessary malloc() when connecting dgram sockets.
markj [Tue, 15 Sep 2020 19:23:01 +0000 (19:23 +0000)]
Avoid an unnecessary malloc() when connecting dgram sockets.

The allocated memory is only required for SOCK_STREAM and SOCK_SEQPACKET
sockets.

Reviewed by: kevans
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26298

3 years agoSimplify unp_disconnect() callers.
markj [Tue, 15 Sep 2020 19:22:37 +0000 (19:22 +0000)]
Simplify unp_disconnect() callers.

In all cases, PCBs are unlocked after unp_disconnect() returns.  Since
unp_disconnect() may release the last PCB reference, callers may have to
bump the refcount before the call just so that they can release them
again.

Change unp_disconnect() to release PCB locks as well as connection
references; this lets us remove several refcount manipulations.  Tighten
assertions.

Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26297

3 years agoRename unp_pcb_lock2().
markj [Tue, 15 Sep 2020 19:22:16 +0000 (19:22 +0000)]
Rename unp_pcb_lock2().

unp_pcb_lock_pair() seems like a better name.  Also make it handle the
case where the two sockets are the same instead of making callers do it.
No functional change intended.

Reviewed by: glebius, kevans, kib
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26296

3 years agoImprove unix socket PCB refcounting.
markj [Tue, 15 Sep 2020 19:21:58 +0000 (19:21 +0000)]
Improve unix socket PCB refcounting.

- Use refcount_init().
- Define an INVARIANTS-only zone destructor to assert that various
  bits of PCB state aren't left dangling.
- Annotate unp_pcb_rele() with __result_use_check.
- Simplify control flow.

Reviewed by: glebius, kevans, kib
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26295

3 years agoUpdate unix domain socket locking comments.
markj [Tue, 15 Sep 2020 19:21:33 +0000 (19:21 +0000)]
Update unix domain socket locking comments.

- Define a locking key for unpcb members.
- Rewrite some of the locking protocol description to make it less
  verbose and avoid referencing some subroutines which will be renamed.
- Reorder includes.

Reviewed by: glebius, kevans, kib
Tested by: pho
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26294

3 years agocertctl: fix unprivileged mode
kevans [Tue, 15 Sep 2020 17:13:29 +0000 (17:13 +0000)]
certctl: fix unprivileged mode

The first issue was lack of quoting around INSTALLFLAGS, which set it
incorrectly and produced an error on -M.

The second issue was that we weren't actually doing the install in
unprivileged mode, making it effectively useless. This was designed to pass
through the proper metalog/unpriv flags to install(1), so just let it
happen.

MFC after: 3 days

3 years agoMove SV_ABI_ERRNO translation into linux-specific code, to simplify
trasz [Tue, 15 Sep 2020 16:41:21 +0000 (16:41 +0000)]
Move SV_ABI_ERRNO translation into linux-specific code, to simplify
the syscall path and declutter it a bit.  No functional changes intended.

Reviewed by: kib (earlier version)
MFC after: 2 weeks
Sponsored by: DARPA
Differential Revision: https://reviews.freebsd.org/D26378

3 years agosrc.conf.5: regen after r365753
se [Tue, 15 Sep 2020 16:38:44 +0000 (16:38 +0000)]
src.conf.5: regen after r365753

3 years agoAdd descriptions of the WITH_(OUT)_GH_BC options that exist in -CURRENT
se [Tue, 15 Sep 2020 16:22:05 +0000 (16:22 +0000)]
Add descriptions of the WITH_(OUT)_GH_BC options that exist in -CURRENT
(default: WITH_GH_BC) and 12-STABLE (default: WITHOUT_GH_BC).

Since the new implementation of bc and dc is optionally available in
12-STABLE, I intend to MFC these descriptions for inclusion in 12.2.

MFC after: 3 days

3 years agoInclude sys/types.h here
imp [Tue, 15 Sep 2020 15:21:29 +0000 (15:21 +0000)]
Include sys/types.h here

It's included by header pollution in most of the compile
environments. However, in the standalone envirnment, it's not
included. Go ahead and include it always since the overhead is low and
it is simpler that way.

MFC After: 3 days

3 years agoUse ATTR_DEFAULT in the arm64 locore.S
andrew [Tue, 15 Sep 2020 14:15:04 +0000 (14:15 +0000)]
Use ATTR_DEFAULT in the arm64 locore.S

We can use ATTR_DEFAULT directly in locore.S as it fits within an orr
instruction operand.

Sponsored by: Innovate UK

3 years agoFix some posixshmcontrol nits.
markj [Tue, 15 Sep 2020 13:36:19 +0000 (13:36 +0000)]
Fix some posixshmcontrol nits.

- Exit with an error if no path is specified.
- Man page typo.
- Error message typo.

Reviewed by: kib
Sponsored by: Juniper Networks, Inc.
Sponsored by: Klara, Inc.
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D26376

3 years ago[PowerPC] Remove obsolete MK_LOADER_FORCE_LE
bdragon [Tue, 15 Sep 2020 04:22:28 +0000 (04:22 +0000)]
[PowerPC] Remove obsolete MK_LOADER_FORCE_LE

In D12421, the ability to compile stand/ in little-endian was added, with the
intention to extend loader.kboot to run in Petitboot.

However, no further work was done, as the kernel then gained self-execution
capabilities as Petitboot was taught to load FreeBSD kernels directly.

The FreeBSD installer on powerpc64 (on POWER8 and POWER9) uses
/boot/etc/kboot.conf instead of loader.

As this option does nothing but cause stand/ to be miscompiled and actively
causes confusion, remove it.

(I have a functioning petitboot loader in my local tree, however, it turned
out to be quite inconvient to use due to the current petitboot plugin design
so I put it on hold.)

Reviewed by: emaste, imp, jhibbits
Sponsored by: Tag1 Consulting, Inc.
Differential Revision: https://reviews.freebsd.org/D26430

3 years agoWe don't need the sc_ekeys_lock in standalone environment.
imp [Mon, 14 Sep 2020 23:51:14 +0000 (23:51 +0000)]
We don't need the sc_ekeys_lock in standalone environment.

When we bring in geli into the boot loader, we are single threaded so
we don't have to worry about locking. We have no mutexes, and don't need
to use them, so comment it out.

MFC After: 3 days

3 years agoDon't do the busy dance in icee_open/close
imp [Mon, 14 Sep 2020 23:30:04 +0000 (23:30 +0000)]
Don't do the busy dance in icee_open/close

We don't need to do the busy dance for this driver. It's handled by
destroy_dev() entirely. Since all we did was busy/unbusy in
open/close, just delete them. We therefore don't need to track closes
either.

Reviewed by: ian@
Differential Revision: https://reviews.freebsd.org/D26431

3 years agoTweak what's visible in the standalone environment. We define offsetof
imp [Mon, 14 Sep 2020 23:27:51 +0000 (23:27 +0000)]
Tweak what's visible in the standalone environment. We define offsetof
in stand.h typically, but when this is included we can define it
multiple times. However, we don't define bool in stand.h at the
moment, so allow it to be defined inside types.h when we're building
for the standalone environment.

MFC After: 3 days

3 years agocxgbe(4): Get the count of FCS errors from the MAC and not MPS for T6 ports.
np [Mon, 14 Sep 2020 22:15:54 +0000 (22:15 +0000)]
cxgbe(4): Get the count of FCS errors from the MAC and not MPS for T6 ports.

The MPS register on the T6 counts something other than FCS errors despite its
name.

MFC after: 3 days
Sponsored by: Chelsio Communications

3 years agoAdd product ID strings for a couple Microchip usb hubs. Also, update the
ian [Mon, 14 Sep 2020 17:33:28 +0000 (17:33 +0000)]
Add product ID strings for a couple Microchip usb hubs.  Also, update the
vendor ID string to say just "Microchip Technology" -- the buyout of
Standard Microsystems happened in 2012 and the SMC/SMSC names are pretty
much retired at this point.

PR: 241406

3 years agoCleanups for gprof:
andrew [Mon, 14 Sep 2020 16:18:53 +0000 (16:18 +0000)]
Cleanups for gprof:

 * Remove identical or almost identical headers
 * Only build aout.c on amd64 and i386. None of the the other current
   architectures ever supported running a.out binaries
 * Enable on all architectures

Sponsored by: Innovate UK
Differential Revision: https://reviews.freebsd.org/D26369

3 years agoUse MACHINE_CPUARCH when checking for arm64
andrew [Mon, 14 Sep 2020 16:12:28 +0000 (16:12 +0000)]
Use MACHINE_CPUARCH when checking for arm64

Use MACHINE_CPUARCH with arm64 (aarch64) when we build code that could run
on any 64-bit Arm instruction set. This will simplify checks in downstream
consumers targeting prototype instruction sets.

The only place we check for MACHINE_ARCH == aarch64 is when building the
device tree blobs. As these are targeting current generation ISAs.

Sponsored by: Innovate UK
Differential Revision: https://reviews.freebsd.org/D26370

3 years agoFix setting RELENGDIR when release.sh is called from an external
gjb [Mon, 14 Sep 2020 15:58:10 +0000 (15:58 +0000)]
Fix setting RELENGDIR when release.sh is called from an external
script.

Sponsored by: Rubicon Communications, LLC (netgate.com)

3 years agostand/ficl 64-bit compatibility
bdragon [Mon, 14 Sep 2020 15:48:30 +0000 (15:48 +0000)]
stand/ficl 64-bit compatibility

Currently, the only thing that prevents a functioning 64-bit FICL build is
a few integer types that were intended to be fixed-width.

Changing them to C99 integer types allows building a functioning 64-bit
FICL.

While this isn't applicable to the default settings of any in-tree loaders,
it is necessary for a future Petitboot loader, due to the requirement that
it be compiled as a 64-bit program.

Reviewed by: tsoome, imp (earlier revision)
Sponsored by: Tag1 Consulting, Inc.
Differential Revision: https://reviews.freebsd.org/D26364

3 years ago[PowerPC] Make cpu frequency detection endian-independent
bdragon [Mon, 14 Sep 2020 15:20:37 +0000 (15:20 +0000)]
[PowerPC] Make cpu frequency detection endian-independent

On ibm,extended-clock-frequency, ensure we be64toh() the value.

On clock-frequency, remove the right-shifting hack (which was needed due to
reading a 32 bit value into a 64 bit variable) and switch to OF_getencprop()
for reading (which will handle endian conversion internally.)

Reviewed by: jhibbits (in irc)
Sponsored by: Tag1 Consulting, Inc.

3 years agoPartially revert r346018 and use the if/then construct instead of shell.
gordon [Mon, 14 Sep 2020 14:45:30 +0000 (14:45 +0000)]
Partially revert r346018 and use the if/then construct instead of shell.

There are a couple of places in the tree that directly parse the newvers.sh
script looking for the BRANCH variable. I found two locations, one in
release/Makefile and the other in bin/freebsd-version/Makefile.

While there is a good argument that BRANCH_OVERRIDE should properly
propagate in those circumstances and the new behavior is thus better, the
reality is this change broke freebsd-update's ability to find timestamps in
binaries and resulted in a large number of gratuitous changes.

Reported by: freebsd-update
Discussed with: cperciva
MFC after: 1 day

3 years agoPoll statistics more frequently in mlx5en(4).
hselasky [Mon, 14 Sep 2020 14:24:54 +0000 (14:24 +0000)]
Poll statistics more frequently in mlx5en(4).

This makes traffic steering algorithms more accurate.

MFC after: 1 week
Submitted by: gallatin @
Sponsored by: Mellanox Technologies // NVIDIA Networking

3 years agoSkip armv7 bectl tests on CI; they deadlock (""KSTACK_PAGES is 2").
trasz [Mon, 14 Sep 2020 10:35:39 +0000 (10:35 +0000)]
Skip armv7 bectl tests on CI; they deadlock (""KSTACK_PAGES is 2").

PR: 249229
Sponsored by: DARPA

3 years agoMove td_softdep_cleanup() from userret() to ast(); it's infrequent
trasz [Mon, 14 Sep 2020 10:17:07 +0000 (10:17 +0000)]
Move td_softdep_cleanup() from userret() to ast(); it's infrequent
at best.  The schedule_cleanup() function already sets TDF_ASTPENDING.

Reviewed by: kib, mckusick
Tested by: pho
MFC after: 2 weeks
Sponsored by: DARPA
Differential Revision: https://reviews.freebsd.org/D26375

3 years agoMove TDP_GEOM check from userret() to ast(); this code path is quite
trasz [Mon, 14 Sep 2020 10:14:03 +0000 (10:14 +0000)]
Move TDP_GEOM check from userret() to ast(); this code path is quite
infrequent.

Reviewed by: kib
No objections: mav
Tested by: pho
MFC after: 2 weeks
Sponsored by: DARPA
Differential Revision: https://reviews.freebsd.org/D26374

3 years agoMove racct/rctl throttling from userret() to ast(). There's no reason
trasz [Mon, 14 Sep 2020 09:44:24 +0000 (09:44 +0000)]
Move racct/rctl throttling from userret() to ast().  There's no reason
for it to sit in the syscall fast path.

Reviewed by: kib
MFC after: 2 weeks
Sponsored by: DARPA
Differential Revision: https://reviews.freebsd.org/D26368

3 years agoAllow for interrupts on pl061 children
andrew [Mon, 14 Sep 2020 08:59:16 +0000 (08:59 +0000)]
Allow for interrupts on pl061 children

Add enough infrastructure for interrupts on children of the pl061 GPIO
controller. As gpiobus already provided these the pl061 driver also needs
to pass requests up the newbus hierarchy.

Currently there are no children that expect to configure interrupts, however
this is expected to change to support the ACPI Event Information interface.

Sponsored by: Innovate UK

3 years agopfctl_test: avoid 200 calls to atf_get_srcdir
arichardson [Mon, 14 Sep 2020 08:51:18 +0000 (08:51 +0000)]
pfctl_test: avoid 200 calls to atf_get_srcdir

I have been trying to reduce the time that testsuite runs take for CheriBSD
on QEMU (currently about 22 hours). One of the slowest tests is pfctl_test:
Just listing the available test cases currently takes 98 seconds on a
CheriBSD RISC-V system due to all the processes being spawned. This trivial
patch reduces the time to 92 seconds. The better solution would be to
rewrite the test in C/C++ which I may do as a follow-up change.

Reviewed By: kp
Differential Revision: https://reviews.freebsd.org/D26417

3 years agoUpdate bus_dma.9 for the expanded template API. Add some
scottl [Mon, 14 Sep 2020 06:26:36 +0000 (06:26 +0000)]
Update bus_dma.9 for the expanded template API.  Add some
clarifying language about the operation of parent tags in templates.

3 years agoRefine the busdma template interface. Provide tools for filling in fields
scottl [Mon, 14 Sep 2020 05:58:12 +0000 (05:58 +0000)]
Refine the busdma template interface.  Provide tools for filling in fields
that can be extended, but also ensure compile-time type checking.  Refactor
common code out of arch-specific implementations.  Move the mpr and mps
drivers to this new API.  The template type remains visible to the consumer
so that it can be allocated on the stack, but should be considered opaque.

3 years ago__FreeBSD_version bump for r365605 (crunchgen producing WARNS-clean)
kevans [Mon, 14 Sep 2020 01:56:29 +0000 (01:56 +0000)]
__FreeBSD_version bump for r365605 (crunchgen producing WARNS-clean)

The change in D26397 will need a __FreeBSD_version to base off of for
bootstrapping crunchgen, to avoid avoidable build failures just because the
host has an outdated crunchgen.

3 years agoFix a case where the NFSv4.0 server might crash if delegations are enabled.
rmacklem [Mon, 14 Sep 2020 00:44:50 +0000 (00:44 +0000)]
Fix a case where the NFSv4.0 server might crash if delegations are enabled.

asomers@ reported a crash on an NFSv4.0 server with a backtrace of:
kdb_backtrace
vpanic
panic
nfsrv_docallback
nfsrv_checkgetattr
nfsrvd_getattr
nfsrvd_dorpc
nfssvc_program
svc_run_internal
svc_thread_start
fork_exit
fork_trampoline
where the panic message was "docallb", which indicates that a callback
was attempted when the ClientID is unconfirmed.
This would not normally occur, but it is possible to have an unconfirmed
ClientID structure with delegation structure(s) chained off it if the
client were to issue a SetClientID with the same "id" but different
"verifier" after acquiring delegations on the previously confirmed ClientID.

The bug appears to be that nfsrv_checkgetattr() failed to check for
this uncommon case of an unconfirmed ClientID with a delegation structure
that no longer refers to a delegation the client knows about.

This patch adds a check for this case, handling it as if no delegation
exists, which is the case when the above occurs.
Although difficult to reproduce, this change should avoid the panic().

PR: 249127
Reported by: asomers
Reviewed by: asomers
MFC after: 1 week
Differential Revision: https://reviews.freebbsd.org/D26342

3 years agoMakefile.inc1: remove more old stale depend hacks
emaste [Sun, 13 Sep 2020 23:05:19 +0000 (23:05 +0000)]
Makefile.inc1: remove more old stale depend hacks

Current stale dependency hacks are in tools/build/depend-cleanup.sh.
These ones were almost a year old; remove them from Makefile.inc1.

3 years agoIn the newfs(8) utility, use the more appropriate sbwrite() and cgwrite()
mckusick [Sun, 13 Sep 2020 22:57:50 +0000 (22:57 +0000)]
In the newfs(8) utility, use the more appropriate sbwrite() and cgwrite()
libufs interfaces rather than sbput() and cgput().

No functional change.

MFC after:    7 days
Sponsored by: Netflix

3 years ago[PowerPC] bus_space cleanup part 2: Convert to c99 initializers.
bdragon [Sun, 13 Sep 2020 21:34:32 +0000 (21:34 +0000)]
[PowerPC] bus_space cleanup part 2: Convert to c99 initializers.

To make it easier to work with this in the future, convert to c99
designated initializer syntax.

Tested on powerpc, powerpc64, and powerpc64le. No functional change.

Sponsored by: Tag1 Consulting, Inc.

3 years ago[PowerPC] bus_space cleanup part 1 - rename bs_be / bs_le functions
bdragon [Sun, 13 Sep 2020 21:27:30 +0000 (21:27 +0000)]
[PowerPC] bus_space cleanup part 1 - rename bs_be / bs_le functions

The intention of the bus_be naming was for those to be the no-endian-swapping
and for the bus_le to be endian-swapping in all the functions.

This naming breaks down when we're actually are running in LE and need to
use the opposite sense.

As such, rename bs_be_* to native_bs_* and rename bs_le_* to swapped_bs_*.

No functional change.

Sponsored by: Tag1 Consulting, Inc.

3 years ago[PowerPC64LE] Bus space prep for LE
bdragon [Sun, 13 Sep 2020 21:22:39 +0000 (21:22 +0000)]
[PowerPC64LE] Bus space prep for LE

Swap the BE and LE bus_space tags when on LE, and adjust the nexus tag
to match.

This is prep for a a followup that makes the powerpc bus_space macros easier
to maintain in the future.

Sponsored by: Tag1 Consulting, Inc.

3 years agoSpawn the DHCPv6 client in EC2 instances via rtsold.
cperciva [Sun, 13 Sep 2020 19:56:53 +0000 (19:56 +0000)]
Spawn the DHCPv6 client in EC2 instances via rtsold.

Prior to this commit, EC2 AMIs used a "dual-dhclient" tool which was
launched in place of dhclient and spawned both the base system dhclient
for IPv4 and the ISC dhclient from ports for IPv6.

Now that rtsold supports the "M bit" (managed configuration), we can go
back to having the base system dhclient spawned normally, and provide a
script to rtsold which spawns the ISC dhclient from ports when rtsold
decides that it is appropriate.

Thanks to: bz
MFC after: 1 week
Sponsored by: https://www.patreon.com/cperciva

3 years agoBump the size of EC2 AMIs up to 5 GB.
cperciva [Sun, 13 Sep 2020 19:11:45 +0000 (19:11 +0000)]
Bump the size of EC2 AMIs up to 5 GB.

The FreeBSD base system continues to expand.  4GB is now insufficient;
we passed 3 GB in May 2019; we passed 2 GB in August 2017.  Over half
of the disk space used is in /usr/lib/debug/.

Without this change, instances boot but are unusable, since the first
thing which breaks when VM filesystems are too small is the "pkg install"
in the VM building process.

3 years ago[PowerPC64LE] Ensure nvram is built on powerpc64le.
bdragon [Sun, 13 Sep 2020 18:24:15 +0000 (18:24 +0000)]
[PowerPC64LE] Ensure nvram is built on powerpc64le.

Fix some cases where conditionals that were trying to exclude powerpcspe
were also excluding powerpc64le.

Sponsored by: Tag1 Consulting, Inc.

3 years ago[PowerPC64LE] Adjust ELF definitions for LE.
bdragon [Sun, 13 Sep 2020 17:36:43 +0000 (17:36 +0000)]
[PowerPC64LE] Adjust ELF definitions for LE.

Set ELF_TARG_DATA correctly on PowerPC64LE.

Sponsored by: Tag1 Consulting, Inc.

3 years agoRemove WITHOUT_BMAKE description
emaste [Sun, 13 Sep 2020 17:13:32 +0000 (17:13 +0000)]
Remove WITHOUT_BMAKE description

The option was retired in r265423 and bmake is the only make in tree.

3 years ago[PowerPC] Implement pmap_mincore() for moea
bdragon [Sun, 13 Sep 2020 16:46:03 +0000 (16:46 +0000)]
[PowerPC] Implement pmap_mincore() for moea

Do the same as previous for moea.

Tested on G4.

3 years ago[PowerPC64] Implement pmap_mincore() for moea64
bdragon [Sun, 13 Sep 2020 16:42:49 +0000 (16:42 +0000)]
[PowerPC64] Implement pmap_mincore() for moea64

Implement pmap_mincore() for moea64.

This will need some slight tweaks when large page support in HPT lands.

Submitted by: Fernando Eckhardt Valle <fernando.valle@eldorado.org.br>
Reviewed by: bdragon
Differential Revision: https://reviews.freebsd.org/D26314

3 years agoAdd a -C option to netstat to display the congestion control for
tuexen [Sun, 13 Sep 2020 09:14:32 +0000 (09:14 +0000)]
Add a -C option to netstat to display the congestion control for
TCP connections.

Reviewed by: rscheff
MFC after: 1 week
Sponsored by: Netflix, Inc.
Differential Revision: https://reviews.freebsd.org/D26414

3 years agoAdd a -C option to sockstat to display the congestion control for TCP
tuexen [Sun, 13 Sep 2020 09:12:25 +0000 (09:12 +0000)]
Add a -C option to sockstat to display the congestion control for TCP
connections.

Reviewed by: rscheff
MFC after: 1 week
Sponsored by: Netflix, Inc.
Differential Revision: https://reviews.freebsd.org/D26413

3 years agoExport the name of the congestion control. This will be used by sockstat
tuexen [Sun, 13 Sep 2020 09:06:50 +0000 (09:06 +0000)]
Export the name of the congestion control. This will be used by sockstat
and netstat.

Reviewed by: rscheff
MFC after: 1 week
Sponsored by: Netflix, Inc.
Differential Revision: https://reviews.freebsd.org/D26412

3 years agoAdd a -t option to traceroute6 to control the traffic class used when
tuexen [Sun, 13 Sep 2020 09:00:00 +0000 (09:00 +0000)]
Add a -t option to traceroute6 to control the traffic class used when
sending probe packets.

Reviewed by: rscheff
MFC after: 1 week
Sponsored by: Netflix, Inc.
Differential Revision: https://reviews.freebsd.org/D26410

3 years ago[PowerPC] Add PVO_PADDR macro to mmu_oea.c to match mmu_oea64.c changes
bdragon [Sat, 12 Sep 2020 23:54:57 +0000 (23:54 +0000)]
[PowerPC] Add PVO_PADDR macro to mmu_oea.c to match mmu_oea64.c changes

Use a PVO_PADDR macro on 32 bit as well, to reduce the difference between
mmu_oea.c and mmu_oea64.c.

Equivilent to the changes in r363222.