]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
3 years agofold(1): Add EXAMPLES section
fernape [Thu, 29 Oct 2020 18:39:04 +0000 (18:39 +0000)]
fold(1): Add EXAMPLES section

A couple of examples covering -s and -w flags.

Approved by: manpages (bcr@)
Differential Revision: https://reviews.freebsd.org/D26948

3 years agofmt(1): Add EXAMPLES section
fernape [Thu, 29 Oct 2020 18:37:20 +0000 (18:37 +0000)]
fmt(1): Add EXAMPLES section

Very small EXAMPLES section.

While here, remove reference to nroff(1).

Approved by: manpages (bcr@)
Differential Revision: https://reviews.freebsd.org/D26947

3 years agofetch(1): Add EXAMPLES section
fernape [Thu, 29 Oct 2020 18:34:47 +0000 (18:34 +0000)]
fetch(1): Add EXAMPLES section

Add a few examples covering flags: 1, R, a, o, q, r, s, v

Approved by: manpages (bcr@)
Differential Revision: https://reviews.freebsd.org/D26946

3 years agoMake linprocfs(4) print a warning when there's not enough room to fill
trasz [Thu, 29 Oct 2020 15:44:44 +0000 (15:44 +0000)]
Make linprocfs(4) print a warning when there's not enough room to fill
/proc/self/maps.

Submitted by: dchagin (earlier version)
Reviewed by: emaste (earlier version)
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D20576

3 years agoOptimize set_syscall_retval for riscv by predicting the return
trasz [Thu, 29 Oct 2020 15:36:20 +0000 (15:36 +0000)]
Optimize set_syscall_retval for riscv by predicting the return
value to be zero.

Reviewed by: mhorne, kp
MFC after: 2 weeks
Sponsored by: EPSRC
Differential Revision: https://reviews.freebsd.org/D26990

3 years agoMake it possible to mount nullfs(5) using plain mount(8)
trasz [Thu, 29 Oct 2020 15:28:15 +0000 (15:28 +0000)]
Make it possible to mount nullfs(5) using plain mount(8)
instead of mount_nullfs(8).

Obviously you'd need to force mount(8) to not call
mount_nullfs(8) to make use of it.

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

3 years agoWhitespace cleanup
lwhsu [Thu, 29 Oct 2020 14:44:09 +0000 (14:44 +0000)]
Whitespace cleanup

MFC after: 3 days

3 years agoFix typo.
trasz [Thu, 29 Oct 2020 14:42:51 +0000 (14:42 +0000)]
Fix typo.

MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation

3 years agoRemove superfluous `this` in comment
lwhsu [Thu, 29 Oct 2020 14:42:02 +0000 (14:42 +0000)]
Remove superfluous `this` in comment

PR: 250721
Submitted by: Hiroya EBINE <hebiyan@protonmail.com>
MFC after: 3 days

3 years agoAdd defines for Linux errno values and use them to make linux_errtbl[]
trasz [Thu, 29 Oct 2020 14:23:52 +0000 (14:23 +0000)]
Add defines for Linux errno values and use them to make linux_errtbl[]
more readable.  While here, add linux_check_errtbl() function to make
sure we don't leave holes.

No objections: emaste (earlier version)
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26972

3 years agoUpdate the due date of the quarterly status report
lwhsu [Thu, 29 Oct 2020 14:21:25 +0000 (14:21 +0000)]
Update the due date of the quarterly status report

While here, move the date to keep 2 weeks ahead notificaion
and fix the part of speech.

Reviewed by: debdrup
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26998

3 years agovfs: add NDREINIT to facilitate repeated namei calls
mjg [Thu, 29 Oct 2020 12:56:02 +0000 (12:56 +0000)]
vfs: add NDREINIT to facilitate repeated namei calls

struct nameidata mixes caller arguments, internal state and output, which
can be quite error prone.

Recent addition of valdiating ni_resflags uncovered a caller which could
repeatedly call namei, effectively operating on partially populated state.

Add bare minimium validation this does not happen. The real fix would
decouple aforementioned state.

Reported by: pho
Tested by: pho (different variant)

3 years agoSimplify test for closing delimiter of #include argument (no functional
se [Thu, 29 Oct 2020 08:31:47 +0000 (08:31 +0000)]
Simplify test for closing delimiter of #include argument (no functional
change).

While here: Fix invalid parameters of a commented-out debug printf() found
when testing with this code enabled.

MFC after: 3 days

3 years agoFix calendar -a processing of files included in the user's home directory
se [Thu, 29 Oct 2020 08:26:38 +0000 (08:26 +0000)]
Fix calendar -a processing of files included in the user's home directory

The existing code performed a chdir() into the home directory, but the
parser fell back to using the invoking user's home directory as the base
directory for the search for an include file.

Since use of the -a option is limited to UID==0, the directory searched
was typically ~root/.calendar, not the .calendar directory of the user
whose file is being processed.

PR: 205580
Reported by: greg.bal4@gmail.com (Greg Balfour)
MFC after: 3 days

3 years agoCI: switch to qemu42 package
emaste [Thu, 29 Oct 2020 02:02:30 +0000 (02:02 +0000)]
CI: switch to qemu42 package

It appears that booting FreeBSD from qemu's synthesized FAT filesystem
broke somehow in a recent qemu-devel update.  qemu42 works so switch to
it for now.

3 years agoSupport hardware rate limiting (pacing) with TLS offload.
jhb [Thu, 29 Oct 2020 00:23:16 +0000 (00:23 +0000)]
Support hardware rate limiting (pacing) with TLS offload.

- Add a new send tag type for a send tag that supports both rate
  limiting (packet pacing) and TLS offload (mostly similar to D22669
  but adds a separate structure when allocating the new tag type).

- When allocating a send tag for TLS offload, check to see if the
  connection already has a pacing rate.  If so, allocate a tag that
  supports both rate limiting and TLS offload rather than a plain TLS
  offload tag.

- When setting an initial rate on an existing ifnet KTLS connection,
  set the rate in the TCP control block inp and then reset the TLS
  send tag (via ktls_output_eagain) to reallocate a TLS + ratelimit
  send tag.  This allocates the TLS send tag asynchronously from a
  task queue, so the TLS rate limit tag alloc is always sleepable.

- When modifying a rate on a connection using KTLS, look for a TLS
  send tag.  If the send tag is only a plain TLS send tag, assume we
  failed to allocate a TLS ratelimit tag (either during the
  TCP_TXTLS_ENABLE socket option, or during the send tag reset
  triggered by ktls_output_eagain) and ignore the new rate.  If the
  send tag is a ratelimit TLS send tag, change the rate on the TLS tag
  and leave the inp tag alone.

- Lock the inp lock when setting sb_tls_info for a socket send buffer
  so that the routines in tcp_ratelimit can safely dereference the
  pointer without needing to grab the socket buffer lock.

- Add an IFCAP_TXTLS_RTLMT capability flag and associated
  administrative controls in ifconfig(8).  TLS rate limit tags are
  only allocated if this capability is enabled.  Note that TLS offload
  (whether unlimited or rate limited) always requires IFCAP_TXTLS[46].

Reviewed by: gallatin, hselasky
Relnotes: yes
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D26691

3 years agoSave the current TCP pacing rate in t_pacing_rate.
jhb [Thu, 29 Oct 2020 00:03:19 +0000 (00:03 +0000)]
Save the current TCP pacing rate in t_pacing_rate.

Reviewed by: gallatin, gnn
Sponsored by: Netflix
Differential Revision: https://reviews.freebsd.org/D26875

3 years agoDisable ssp raw test without ASAN
brooks [Wed, 28 Oct 2020 23:10:54 +0000 (23:10 +0000)]
Disable ssp raw test without ASAN

r366981 disabled ASAN when it might not be reliable (with an external
compiler), but this test is broken without ASAN so disable it completely
in that case.

PR: 250706
Reviewed by: emaste, lwhsu
Differential Revision: https://reviews.freebsd.org/D26982

3 years agoCheck for process group change in tty_wait_background().
kib [Wed, 28 Oct 2020 22:12:47 +0000 (22:12 +0000)]
Check for process group change in tty_wait_background().

The calling process's process group can change between PROC_UNLOCK(p)
and PGRP_LOCK(pg) in tty_wait_background(), e.g. by a setpgid() call
from another process. If that happens, the signal is not sent to the
calling process, even if the prior checks determine that one should be
sent.  Re-check that the process group hasn't changed after acquiring
the pgrp lock, and if it has, redo the checks.

PR: 250701
Submitted by: Jakub Piecuch <j.piecuch96@gmail.com>
MFC after: 2 weeks

3 years agoloader: add aarch64 support for zstd
imp [Wed, 28 Oct 2020 21:18:04 +0000 (21:18 +0000)]
loader: add aarch64 support for zstd

We don't have NEON available in the boot loader, so we have to disable
it. OpenZFS included ZSTD which used the wrong symbol to bring in neon
support. Change to use the code that's been submitted upstream as a
pull request to both.

__ARM_NEON is the proper symbol, defined in ARM C Language Extensions
Release 2.1 (https://developer.arm.com/documentation/ihi0053/d/). Some
sources suggest __ARM_NEON__, but that's the obsolete spelling from
prior versions of the standard.

OpenZFS Pull Request: https://github.com/openzfs/zfs/pull/11055
ZSTD Pull Request: https://github.com/facebook/zstd/pull/2356

3 years agoNote that sys/systm.h is special too
imp [Wed, 28 Oct 2020 21:09:56 +0000 (21:09 +0000)]
Note that sys/systm.h is special too

If you need / want to includerd sys/systm.h, it has to be just after
param.h/types.h. Document this existing practice. Not all kernel files
include systm.h, but when you do, it should be done out of order.

Reviewed by: vangyzen, kib, emaste
Differential Review: https://reviews.freebsd.org/D26981

3 years agoiflib: fix typo bug introduced by r367093
vmaffione [Wed, 28 Oct 2020 21:06:17 +0000 (21:06 +0000)]
iflib: fix typo bug introduced by r367093

Code was supposed to call callout_reset_sbt_on() rather than
callout_reset_sbt(). This resulted into passing a "cpu" value
to a "flag" argument. A recipe for subtle errors.

PR: 248652
Reported by: sg@efficientip.com
MFC with: r367093

3 years agoFix use-after-free in icmp6_notify_error().
melifaro [Wed, 28 Oct 2020 20:22:20 +0000 (20:22 +0000)]
Fix use-after-free in icmp6_notify_error().

Reported by: Maxime Villard <max at m00nbsd.net>
Reviewed by: markj
MFC after: 3 days

3 years agoFix unintentional constant rename in r367109.
mav [Wed, 28 Oct 2020 18:22:25 +0000 (18:22 +0000)]
Fix unintentional constant rename in r367109.

MFC after: 1 week

3 years agoUse proper variable for device path.
mav [Wed, 28 Oct 2020 17:28:48 +0000 (17:28 +0000)]
Use proper variable for device path.

It seems *-passthru commands were broken from the day one, since the
device path is fetched into opt.dev variable and not left in argv[optind].
The other three wrong argv[optind] instances are just in error messages.

MFC after: 1 week
Sponsored by: iXsystems, Inc.

3 years agoUpdate the list of searched manual sections after r367013
0mp [Wed, 28 Oct 2020 16:54:37 +0000 (16:54 +0000)]
Update the list of searched manual sections after r367013

3 years agoPrint NVMe controller capabilities in verbose dmesg.
mav [Wed, 28 Oct 2020 15:43:29 +0000 (15:43 +0000)]
Print NVMe controller capabilities in verbose dmesg.

Those values are not reported in controller identification, while sometimes
interesting for development and debugging.

MFC after: 1 week

3 years agoAdd support for nested conditionals
se [Wed, 28 Oct 2020 14:48:58 +0000 (14:48 +0000)]
Add support for nested conditionals

The previous behavior was to support nested #ifdef and #ifndef, but to
return to unconditional parsing after the next #endif, independently of
the number of previously parsed conditions.

E.g. after "#ifdef A / #ifdef B / #endif" the following lines were
unconditially parsed again, independently of A and/or B being defined.

The new behavior is to count the level of false conditions and to only
restart parsing of calendar entries when the corresponding number of
#endif tokens have been seen.

In addition to the above, an #else directive has been added, to toggle
between parsing and ignoring of the following lines.

No validation of the correct use of the condition directives is made.
#endif without prior #define or #ifndef is ignored and #else toggles
between parsing and skipping of entries.

The MFC period has been set to 1 month to allow for a review of the
changes and for a discussion, whether these modifications should not
be merged at all.

No correct input file is parsed differently than before, but if calendar
data files are published that use these new features, those data files
will not parse correctly on prior versions of this program.

MFC after: 1 month

3 years agoAdd local variable to store the sysent pointer. Just a cleanup,
trasz [Wed, 28 Oct 2020 14:43:38 +0000 (14:43 +0000)]
Add local variable to store the sysent pointer.  Just a cleanup,
no functional changes.

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

3 years agoMake linux_errtbl a bit more readable by using named initializers.
trasz [Wed, 28 Oct 2020 14:16:08 +0000 (14:16 +0000)]
Make linux_errtbl a bit more readable by using named initializers.

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

3 years agoDrop "All rights reserved" from all my stuff. This includes
trasz [Wed, 28 Oct 2020 13:46:11 +0000 (13:46 +0000)]
Drop "All rights reserved" from all my stuff.  This includes
Foundation copyrights, approved by emaste@.  It does not include
files which carry other people's copyrights; if you're one
of those people, feel free to make similar change.

Reviewed by: emaste, imp, gbe (manpages)
Differential Revision: https://reviews.freebsd.org/D26980

3 years agoFix off-by-one error in processing of #ifdef lines
se [Wed, 28 Oct 2020 13:30:24 +0000 (13:30 +0000)]
Fix off-by-one error in processing of #ifdef lines

The convention in this program is to parse the line immediately starting
after the token (e.g. #defineA and #ifdefA define respectively look-up "A"),
and this commit restores this behavior instead of skipping an assumed
white-space character following #ifdef.

Reported by: kevans
MFC after: 3 days

3 years agoFix parsing of #ifdef in calendar files
se [Wed, 28 Oct 2020 13:06:39 +0000 (13:06 +0000)]
Fix parsing of #ifdef in calendar files

There was code to process an #ifndef tokens, but none for #ifdef.
The #ifdef token was mentioned as unsupported in the BUGS section,
but no reason was given and I do not see why it should stay omitted.

Misleading information in The BUGS section of the man-page regarding
the maximum number of #define and #include statements supported has
been removed. These limits might have applied to a prior version of
this program, but do not seem to apply to the current implementation.

I have not tried to test for the existence of the limits, but the
include file processing just recursively calls the parser (without
counting the recursion depth) and the stringlist functions do not
impose a limit on the number of entries.

Reported by: jhs@berklix.com
MFC after: 3 days

3 years agoSpeed up Cirrus CI by using CROSS_TOOLCHAIN
arichardson [Wed, 28 Oct 2020 11:54:09 +0000 (11:54 +0000)]
Speed up Cirrus CI by using CROSS_TOOLCHAIN

Installing the llvm11 package instead of bootstrapping it from the source
tree reduces the build time by about 20 minutes.

The last freebsd/freebsd build that was tested (r366629) took 1h 21m 22s,
whereas my GitHub fork with this .cirrus.yml took 58m 6s.
We could probably further reduce time by using images that have LLVM
pre-installed: the pkg install step took 4 minutes 30s.

Since the bootstrap toolchain is still tested by Jenkins, this should not
reduce test coverage of the CI testing.

Reviewed By: emaste
Differential Revision: https://reviews.freebsd.org/D26747

3 years agoSignificantly reduce compile time for googletest internal tests
arichardson [Wed, 28 Oct 2020 11:54:04 +0000 (11:54 +0000)]
Significantly reduce compile time for googletest internal tests

Clang's optimizer spends a really long time on these tests at -O2, so we now
use -O0 instead. This reduces the -j32 time for lib/googletest/test from 131s
to 29s. Using -O0 also reduces the disk usage from 144MB (at -O2) / 92MB (at
-O1) to 82MB.

Reviewed By: ngie, dim
Differential Revision: https://reviews.freebsd.org/D26751

3 years agoclang-format: Avoid breaking after the opening paren of function definitions
arichardson [Wed, 28 Oct 2020 11:54:00 +0000 (11:54 +0000)]
clang-format: Avoid breaking after the opening paren of function definitions

This depends on https://reviews.llvm.org/D90246 to have any effect, but once
that has landed clang-format will no longer format code like this:

```
int
myfunction(
    int param1, int param2, int param2)
{
   ...
}
```

and instead create the following:

```
int
myfunction(int param1, int param2,
    int param2)
{
   ...
}
```

Reviewed By: emaste, cem
Differential Revision: https://reviews.freebsd.org/D26978

3 years agoclang-format: place sys/systm.h immediately after sys/param.h
arichardson [Wed, 28 Oct 2020 11:53:55 +0000 (11:53 +0000)]
clang-format: place sys/systm.h immediately after sys/param.h

Should fix one of the objections to r366993.
See also https://reviews.freebsd.org/D26981.

Reviewed By: emaste
Differential Revision: https://reviews.freebsd.org/D26979

3 years agoCorrect USB HID item in examples
0mp [Wed, 28 Oct 2020 08:29:31 +0000 (08:29 +0000)]
Correct USB HID item in examples

It turns out that examples were incorrectly referring to Volume_Up
and Volume_Down, which are not defined at all.

PR: 250683
Reported by: corvid%openmailbox.org
MFC after: 2 weeks

3 years agoAdd new USB IDs.
hselasky [Wed, 28 Oct 2020 08:22:38 +0000 (08:22 +0000)]
Add new USB IDs.

Submitted by: aleksi.kaalinpaa@kapsi.fi
PR: 250675
MFC after: 1 week
Sponsored by: Mellanox Technologies // NVIDIA Networking

3 years agoAdd FreeBSD 12.2
lwhsu [Wed, 28 Oct 2020 02:30:44 +0000 (02:30 +0000)]
Add FreeBSD 12.2

3 years agoMFV r367082:
cy [Tue, 27 Oct 2020 23:03:15 +0000 (23:03 +0000)]
MFV r367082:

Update unbound 1.11.0 --> 1.12.0.

MFC after: 1 month.

3 years agoiflib: add per-tx-queue netmap timer
vmaffione [Tue, 27 Oct 2020 21:53:33 +0000 (21:53 +0000)]
iflib: add per-tx-queue netmap timer

The way netmap TX is handled in iflib when TX interrupts are not
used (IFC_NETMAP_TX_IRQ not set) has some issues:
  - The netmap_tx_irq() function gets called by iflib_timer(), which
    gets scheduled with tick granularity (hz). This is not frequent
    enough for 10Gbps NICs and beyond (e.g., ixgbe or ixl). The end
    result is that the transmitting netmap application is not woken
    up fast enough to saturate the link with small packets.
  - The iflib_timer() functions also calls isc_txd_credits_update()
    to ask for more TX completion updates. However, this violates
    the netmap requirement that only txsync can access the TX queue
    for datapath operations. Only netmap_tx_irq() may be called out
    of the txsync context.

This change introduces per-tx-queue netmap timers, using microsecond
granularity to ensure that netmap_tx_irq() can be called often enough
to allow for maximum packet rate. The timer routine simply calls
netmap_tx_irq() to wake up the netmap application. The latter will
wake up and call txsync to collect TX completion updates.

This change brings back line rate speed with small packets for ixgbe.
For the time being, timer expiration is hardcoded to 90 microseconds,
in order to avoid introducing a new sysctl.
We may eventually implement an adaptive expiration period or use another
deferred work mechanism in place of timers.

Also, fix the timers usage to make sure that each queue is serviced
by a different CPU.

PR: 248652
Reported by: sg@efficientip.com
MFC after: 2 weeks

3 years agoUse my FreeBSD.org mail address in man pages I have written
gbe [Tue, 27 Oct 2020 18:30:43 +0000 (18:30 +0000)]
Use my FreeBSD.org mail address in man pages I have written

MFC after: 3 days

3 years agovfs: tidy up vnlru_free
mjg [Tue, 27 Oct 2020 18:13:09 +0000 (18:13 +0000)]
vfs: tidy up vnlru_free

Apart from cosmeatic changes make sure to only decrease the recycled counter
if vtryrecycle succeeded.

Tested by: pho

3 years agovfs: fix vnode reclaim races against getnwevnode
mjg [Tue, 27 Oct 2020 18:12:07 +0000 (18:12 +0000)]
vfs: fix vnode reclaim races against getnwevnode

All vnodes allocated by UMA are present on the global list used by
vnlru. getnewvnode modifies the state of the vnode (most notably
altering v_holdcnt) but never locks it. Moreover filesystems also
modify it in arbitrary manners sometimes before taking the vnode
lock or adding any other indicator that the vnode can be used.

Picking up such a vnode by vnlru would be problematic.

To that end there are 2 fixes:
- vlrureclaim, not recycling v_holdcnt == 0 vnodes, takes the
interlock and verifies that v_mount has been set. It is an
invariant that the vnode lock is held by that point, providing
the necessary serialisation against locking after vhold.
- vnlru_free_locked, only wanting to free v_holdcnt == 0 vnodes,
now makes sure to only transition the count 0->1 and newly allocated
vnodes start with v_holdcnt == VHOLD_NO_SMR. getnewvnode will only
transition VHOLD_NO_SMR->1 once more making the hold fail

Tested by: pho

3 years agorefcount: make it atomic-clean
mjg [Tue, 27 Oct 2020 18:11:11 +0000 (18:11 +0000)]
refcount: make it atomic-clean

While here consistently use 'old' in all places.

Tested by: pho

3 years agoRevise the description of MAP_STACK. In particular, describe the guard
alc [Tue, 27 Oct 2020 18:08:33 +0000 (18:08 +0000)]
Revise the description of MAP_STACK.  In particular, describe the guard
in more detail.

Reviewed by: bcr, kib, markj
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D26908

3 years agoo Add the domain member to the struct bus_dma_tag_common as required by
br [Tue, 27 Oct 2020 15:29:53 +0000 (15:29 +0000)]
o Add the domain member to the struct bus_dma_tag_common as required by
  busdma_iommu.c.
o Add tag_set_domain() pointer to the struct bus_dma_impl as well.

Sponsored by: Innovate DSbD

3 years agoTake the ITS device lock around gicv3_its_release_irqsrc() since that
br [Tue, 27 Oct 2020 15:18:10 +0000 (15:18 +0000)]
Take the ITS device lock around gicv3_its_release_irqsrc() since that
function checks that the mutex lock is owned.

This fixes 'devctl disable re0' operation.

Sponsored by: Innovate DSbD
Differential Revision: https://reviews.freebsd.org/D26904

3 years agoarm64: Remove a racy KASSERT from pmap_remove_pages()
markj [Tue, 27 Oct 2020 13:27:47 +0000 (13:27 +0000)]
arm64: Remove a racy KASSERT from pmap_remove_pages()

PCPU_GET(curpmap) expands to multiple instructions on arm64, and if the
current thread is migrated in between execution of those instructions, a
stale value may be used in the assertion condition.

Diagnosed by: mmel
Reported by: mmel, Bob Prohaska <fbsd@www.zefox.net>
Submitted by: alc
MFC after: 1 week

3 years agoFix misnomer - linux_to_bsd_errno() does the exact opposite.
trasz [Tue, 27 Oct 2020 12:49:40 +0000 (12:49 +0000)]
Fix misnomer - linux_to_bsd_errno() does the exact opposite.

Reported by: arichardson
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D26965

3 years agoriscv: Minor cleanup in startup code
kp [Tue, 27 Oct 2020 12:44:49 +0000 (12:44 +0000)]
riscv: Minor cleanup in startup code

 - remove setting of register value which is not used until the next value is
   set
 - Use the L2_SHIFT constant when setting up L2 superpages

Submitted by: Antonin Houska <ah AT melesmeles DOT cz>

3 years agorenice(8): Clarify "who" parameters.
fernape [Tue, 27 Oct 2020 12:32:17 +0000 (12:32 +0000)]
renice(8): Clarify "who" parameters.

There was a question raised in freebsd-questions@ mail list[1] about the
"who" parameters in this man page. It seems OpenBSD[2] amd NetBSD[3]
both have more legible descriptions so I borrowed some of their ideas to try
and make this page clearer.

[1] https://lists.freebsd.org/pipermail/freebsd-questions/2020-October/291914.html
[2] https://man.bsd.lv/renice
[3] https://man.netbsd.org/renice.8

Approved by: manpages (bcr@)
Differential Revision: https://reviews.freebsd.org/D26950

3 years agodiff: don't force the format to 'context' with -p immediately
kevans [Tue, 27 Oct 2020 12:27:26 +0000 (12:27 +0000)]
diff: don't force the format to 'context' with -p immediately

Instead, leave the fomat as unspecified (if it hasn't been) and use the
-p flag as a hint to 'context' if no other formatting option is specified.

This fixes `diff -purw`, used frequently by emaste, and matches the behavior
of its GNU counterpart.

PR: 250015
Reviewed by: emaste
MFC after: 1 week

3 years agoReplace literal uses of /usr/local in C sources with _PATH_LOCALBASE
se [Tue, 27 Oct 2020 11:29:11 +0000 (11:29 +0000)]
Replace literal uses of /usr/local in C sources with _PATH_LOCALBASE

Literal references to /usr/local exist in a large number of files in
the FreeBSD base system. Many are in contributed software, in configuration
files, or in the documentation, but 19 uses have been identified in C
source files or headers outside the contrib and sys/contrib directories.

This commit makes it possible to set _PATH_LOCALBASE in paths.h to use
a different prefix for locally installed software.

In order to avoid changes to openssh source files, LOCALBASE is passed to
the build via Makefiles under src/secure. While _PATH_LOCALBASE could have
been used here, there is precedent in the construction of the path used to
a xauth program which depends on the LOCALBASE value passed on the compiler
command line to select a non-default directory.

This could be changed in a later commit to make the openssh build
consistently use _PATH_LOCALBASE. It is considered out-of-scope for this
commit.

Reviewed by: imp
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D26942

3 years agoDo not recommend to install kyua with pkg in the tests README
0mp [Tue, 27 Oct 2020 09:53:49 +0000 (09:53 +0000)]
Do not recommend to install kyua with pkg in the tests README

Kyua is now available in the base system.

While here, reword the usage section a bit.

3 years agoClean up backlight.8
0mp [Tue, 27 Oct 2020 09:41:01 +0000 (09:41 +0000)]
Clean up backlight.8

- Sort flags
- Stylize incr|+ and decr|- properly
- Add a missing period at the end of the description
- Use the standard layout for the EXAMPLES section (remove the list macro
  and add indentation to the code block)

3 years agoMount devfs inside a beinstall(8) chroot
0mp [Tue, 27 Oct 2020 09:32:06 +0000 (09:32 +0000)]
Mount devfs inside a beinstall(8) chroot

It turns out that without /dev/null beinstall is not able to complete and
instead exits with messages similar to these:

  --------------------------------------------------------------
  >>> Installing kernel GENERIC completed on Sun Oct 25 17:47:37 CET 2020
  --------------------------------------------------------------
  /tmp/beinstall.JleGoP/mnt: Inspecting dirs /usr/src /usr/obj/usr/src/amd64.amd64
  --- installworld ---
  make[1]: "/usr/obj/usr/src/amd64.amd64/toolchain-metadata.mk" line 1: Using cached toolchain metadata from build at t480 on Sun Oct 25 15:53:28 CET 2020
  make[2]: "/dev/null" line 2: Need an operator
  make[2]: Fatal errors encountered -- cannot continuemake[1]: "/usr/src/Makefile.inc1" line 593: CPUTYPE global should be set with ?=.
  Cleaning up ...
  umount -f /tmp/beinstall.JleGoP/mnt/usr/src /tmp/beinstall.JleGoP/mnt/usr/obj/usr/src/amd64.amd64 /tmp/beinstall.JleGoP/mnt
  Destroyed successfully
  error: Installworld failed!

Upon a bit of debugging, it turns out that /dev/null inside the chroot
environment is full random bytes, which cause "make -f /dev/null" to
misbehave. Mounting a proper devfs inside the chroot seems to be the most
appropriate way to fix it.

will@ also noted that this change requires that whatever is needed in devfs
must exist in the old kernel.

Approved by: will
MFC after: 2 week
Differential Revision: https://reviews.freebsd.org/D26944

3 years agoRemove frontstuff
imp [Tue, 27 Oct 2020 06:43:24 +0000 (06:43 +0000)]
Remove frontstuff

Nothing implements this in the tree. Remove the ioctl and the
conversion to the geom atttribute stuff.

This was introduced in r94287 in 2002 and was retired in r113390
2003. It appeared in FreeBSD 5.0, but no other releases. This is a
vestige that was missed at the time and overlooked until now. No
compat is provided for this reason.  And there's no implementation of
it today. And it was never part of a release from a stable branch.

Reviewed by: phk@
Differential Revision: https://reviews.freebsd.org/D26967

3 years agoRemove a random equal sign from the example. It should not be there.
cy [Tue, 27 Oct 2020 04:35:47 +0000 (04:35 +0000)]
Remove a random equal sign from the example. It should not be there.
It's a syntax error.

PR: 210303
Reported by: leventelist at gmail.com
MFC after: 3 days

3 years agoContinued ipfilter #ifdef cleanup. The r343701 log entry contains a
cy [Tue, 27 Oct 2020 04:35:36 +0000 (04:35 +0000)]
Continued ipfilter #ifdef cleanup. The r343701 log entry contains a
complete description.

MFC after: 3 days

3 years agoriscv: make use of SBI legacy replacement extensions
mhorne [Mon, 26 Oct 2020 19:13:22 +0000 (19:13 +0000)]
riscv: make use of SBI legacy replacement extensions

Version 0.2 of the SBI specification [1] marked the existing SBI
functions as "legacy" in order to move to a newer calling convention. It
also introduced a set of replacement extensions for some of the legacy
functionality. In particular, the TIME, IPI, and RFENCE extensions
implement and extend the semantics of their legacy counterparts, while
conforming to the newer version of the spec.

Update our SBI code to use the new replacement extensions when
available, and fall back to the legacy ones. These will eventually be
dropped, when support for version 0.2 is ubiquitous.

[1] https://github.com/riscv/riscv-sbi-doc/blob/master/riscv-sbi.adoc

Submitted by: Danjel Q. <danq1222@gmail.com>
Reviewed by: kp
Differential Revision: https://reviews.freebsd.org/D26953

3 years agoriscv: remove sbi_clear_ipi()
mhorne [Mon, 26 Oct 2020 19:06:30 +0000 (19:06 +0000)]
riscv: remove sbi_clear_ipi()

S-mode software has write access to the SIP.SSIP bit, so instead of
making a second round-trip through the SBI we can clear it ourselves.
The SBI spec has deprecated this function for this exactly this reason.

Submitted by: Danjel Q. <danq1222@gmail.com
Reviewed by: kp
Differential Revision: https://reviews.freebsd.org/D26952

3 years agolinux: silence renameat2 flags warning
mjg [Mon, 26 Oct 2020 18:03:50 +0000 (18:03 +0000)]
linux: silence renameat2 flags warning

Hogs the console while building the Linux kernel in a Ubuntu Focal jail.

3 years agolinux: add missing conversions for compat.linux.use_emul_path handling
mjg [Mon, 26 Oct 2020 18:02:52 +0000 (18:02 +0000)]
linux: add missing conversions for compat.linux.use_emul_path handling

3 years agocache: add missing NIRES_ABS handling
mjg [Mon, 26 Oct 2020 18:01:18 +0000 (18:01 +0000)]
cache: add missing NIRES_ABS handling

3 years agoKey decleration of union semun on src version
brooks [Mon, 26 Oct 2020 17:52:28 +0000 (17:52 +0000)]
Key decleration of union semun on src version

__FreeBSD__ is defined by the compiler derived from the triple. When
building FreeBSD 11 on a FreeBSD 12 with a CROSS_TOOLCHAIN=llvm10,
__FreeBSD__ was set to 12 when building lib32 (for some reason no triple
is being passed which seems to mean that we're taking default values
from the build system).  This in turn meant we end up with a double
decleration of union semun which is a build error.

Reviewed by: gshapiro, dim
Differential Revision: https://reviews.freebsd.org/D26902

3 years agoaudit: also correctly audit linux_execve()
kevans [Mon, 26 Oct 2020 17:30:17 +0000 (17:30 +0000)]
audit: also correctly audit linux_execve()

Linux execve() gets audited as AUE_EXECVE as well, we should also interpret
the return from this correctly for the same reasoning as in r367002.

MFC with: r367002

3 years agodb_search_symbol: prevent pollution from bogus symbols
vangyzen [Mon, 26 Oct 2020 16:42:53 +0000 (16:42 +0000)]
db_search_symbol: prevent pollution from bogus symbols

The kernel will never map the first page, so any symbols in that
range cannot refer to addresses.  Some third-party assembly files
define internal constants which appear in their symbol table.
Avoiding the lookup for those symbols avoids replacing small offsets
with those symbols during disassembly.

Reported by: Anton Rang <rang%acm.org>
Reviewed by: Anton Rang <rang%acm.org>, markj
MFC after: 2 weeks
Sponsored by: Dell EMC Isilon
Differential Revision: https://reviews.freebsd.org/D26895

3 years agozfs: remove unused support for zfs_znode_move
mjg [Mon, 26 Oct 2020 08:17:41 +0000 (08:17 +0000)]
zfs: remove unused support for zfs_znode_move

3 years agoCorrect calendar entry for myself
scottl [Mon, 26 Oct 2020 05:22:52 +0000 (05:22 +0000)]
Correct calendar entry for myself

3 years agoEnable bioq 'car limit' added at r335066 at 128 bios.
mav [Mon, 26 Oct 2020 04:04:06 +0000 (04:04 +0000)]
Enable bioq 'car limit' added at r335066 at 128 bios.

Without the 'car limit' enabled (before this), running sequential ZFS scrub
on HDD without command queuing support, I've measured latency on concurrent
random reads reaching 4 seconds (surprised that not more).  Enabling this
reduced the latency to 65 milliseconds, while scrub still doing ~180MB/s.

For disks with command queuing this does not make much difference (if any),
since most time all the requests are queued down to the disk or HBA, leaving
nothing in the queue to sort.  And even if something does not fit, staying on
the queue, it is likely not for long.  To not limit sorting in such bursty
scenarios I've added batched counter zeroing when the queue is getting empty.

The internal scheduler of the SAS HDD I was testing seems to be even more
loyal to random I/O, reducing the scrub speed to ~120MB/s.  So in case
somebody worried this is limit is too strict -- it actually looks relaxed.

MFC after: 2 weeks
Sponsored by: iXsystems, Inc.

3 years agocalendar: remove all datafiles except freebsd one
imp [Mon, 26 Oct 2020 03:26:18 +0000 (03:26 +0000)]
calendar: remove all datafiles except freebsd one

Move all the data files for the calendar(1) program, except
calendar.freebsd to the calendar-data package. When a file
can't be found, and /usr/local/share/calendar doesn't exist
provide a helpful hint to install this package.

Reviewed by: se@
Differential Revision:  https://reviews.freebsd.org/D26926

3 years agoupdate write(2)'s iovec limit w/ info about the iosize_max_clamp sysctl...
jmg [Mon, 26 Oct 2020 00:37:31 +0000 (00:37 +0000)]
update write(2)'s iovec limit w/ info about the iosize_max_clamp sysctl...

3 years agoUse proper type (ino_t) for inode numbers to avoid improper sign extention
mckusick [Sun, 25 Oct 2020 21:04:07 +0000 (21:04 +0000)]
Use proper type (ino_t) for inode numbers to avoid improper sign extention
in the Pass 5 checks. The manifestation was fsck_ffs exiting with this error:

  ** Phase 5 - Check Cyl groups
  fsck_ffs: inoinfo: inumber 18446744071562087424 out of range

The error only manifests itself for filesystems bigger than about 100Tb.

Reported by:  Nikita Grechikhin <ngrechikhin at yandex.ru>
MFC after:    2 weeks
Sponsored by: Netflix

3 years agoIntroduce support of SCSI Command Priority.
mav [Sun, 25 Oct 2020 19:34:02 +0000 (19:34 +0000)]
Introduce support of SCSI Command Priority.

SAM-3 specification introduced concept of Task Priority, that was renamed
to Command Priority in SAM-4, and supported by all modern SCSI transports.
It provides 15 levels of relative priorities: 1 - highest, 15 - lowest and
0 - default.  SAT specification for SATA devices translates priorities 1-3
into NCQ high priority.

This change adds new "priority" field into empty spots of struct ccb_scsiio
and struct ccb_accept_tio of CAM and struct ctl_scsiio of CTL.  Respective
support is added into iscsi(4), isp(4), mpr(4), mps(4) and ocs_fc(4) drivers
for both initiator and where applicable target roles.  Minimal support was
added to CTL to receive the priority value from different frontends, pass it
between HA controllers and report in few places.

This patch does not add consumers of this functionality, so nothing should
really change yet, since the field is still set to 0 (default) on initiator
and not actively used on target.  Those are to be implemented separately.

I've confirmed priority working on WD Red SATA disks connected via mpr(4)
and properly transferred to CTL target via iscsi(4), isp(4) and ocs_fc(4).

While there, added missing tag_action support to ocs_fc(4) initiator role.

MFC after: 1 month
Relnotes: yes
Sponsored by: iXsystems, Inc.

3 years agorc.d/syscons: remove spaces before tab
emaste [Sun, 25 Oct 2020 18:27:21 +0000 (18:27 +0000)]
rc.d/syscons: remove spaces before tab

3 years agomergemaster: Clarify installed and updated versions
emaste [Sun, 25 Oct 2020 18:06:45 +0000 (18:06 +0000)]
mergemaster: Clarify installed and updated versions

Describe "diff installed new" as "Displaying differences between
installed and new."  Previously mergemaster described them in the
opposite order.

PR: 249214
Reported by: Yuri Victorovich
MFC after: 2 weeks

3 years agoFix incorrect constants of target tag action.
mav [Sun, 25 Oct 2020 16:58:48 +0000 (16:58 +0000)]
Fix incorrect constants of target tag action.

ocs_scsi_recv_cmd() receives the flags after ocs_get_flags_fcp_cmd(),
which translates them from FCP_TASK_ATTR_* to OCS_SCSI_CMD_*.  As result
non-SIMPLE requests turned into HEAD or ORDERED depending on direction.

MFC after: 2 weeks

3 years agocalendar.1: Fix locale of the month in Dd ;)
0mp [Sun, 25 Oct 2020 16:01:03 +0000 (16:01 +0000)]
calendar.1: Fix locale of the month in Dd ;)

3 years agoifconfig.8: Remove spurious commas
0mp [Sun, 25 Oct 2020 15:01:01 +0000 (15:01 +0000)]
ifconfig.8: Remove spurious commas

Correct misuse of commas/parentheses in an enumeration that makes the
number of actual parameters more important than expected.

PR: 250526
Submitted by: Samy Mahmoudi <samy.mahmoudi__gmail_com>
MFC after: 1 week

3 years agoRemove the check that prevents creating "loops" from mount_nullfs(8).
trasz [Sun, 25 Oct 2020 14:09:00 +0000 (14:09 +0000)]
Remove the check that prevents creating "loops" from mount_nullfs(8).

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

3 years agoAdd IOMMU support to GICv3 Interrupt Translation Service (ITS) driver.
br [Sun, 25 Oct 2020 10:08:46 +0000 (10:08 +0000)]
Add IOMMU support to GICv3 Interrupt Translation Service (ITS) driver.

Submitted by: andrew
Sponsored by: Innovate DSbD
Differential Revision: https://reviews.freebsd.org/D26878

3 years agoFilesystem utilities that modify the filesystem (growfs(8), tunefs(8),
mckusick [Sun, 25 Oct 2020 01:36:33 +0000 (01:36 +0000)]
Filesystem utilities that modify the filesystem (growfs(8), tunefs(8),
and fsirand(8)) should check the filesystem status and require that
fsck(8) be run if it is unclean. This requirement is not imposed on
fsdb(8) or clri(8) since they may be used to clean up a filesystem.

MFC after:    2 weeks
Sponsored by: Netflix

3 years agoVarious new check-hash checks have been added to the UFS filesystem
mckusick [Sun, 25 Oct 2020 00:43:48 +0000 (00:43 +0000)]
Various new check-hash checks have been added to the UFS filesystem
over various major releases. Superblock check hashes were added for
the 12 release and cylinder-group and inode check hashes will appear
in the 13 release.

When a disk with a UFS filesystem is writably mounted, the kernel
clears the feature flags for anything that it does not support. For
example, if a UFS disk from a 12-stable kernel is mounted on an
11-stable system, the 11-stable kernel will clear the flag in the
filesystem superblock that indicates that superblock check-hashs
are being maintained. Thus if the disk is later moved back to a
12-stable system, the 12-stable system will know to ignore its
incorrect check-hash.

If the only filesystem modification done on the earlier kernel is
to run a utility such as growfs(8) that modifies the superblock but
neither updates the check-hash nor clears the feature flag indicating
that it does not support the check-hash, the disk will fail to mount
if it is moved back to its original newer kernel.

This patch moves the code that clears the filesystem feature flags
from the mount code (ffs_mountfs()) to the code that reads the
superblock (ffs_sbget()). As ffs_sbget() is used by the kernel mount
code and is imported into libufs(3), all the filesystem utilities
will now also clear these flags when they make modifications to the
filesystem.

As suggested by John Baldwin, fsck_ffs(8) has been changed to accept
and repair bad superblock check-hashes rather than refusing to run.
This change allows fsck to recover filesystems that have been impacted
by utilities older than those created after this change and is a
sensible thing to do in any event.

Reported by:  John Baldwin (jhb@)
MFC after:    2 weeks
Sponsored by: Netflix

3 years agoFix build after r367020
mhorne [Sat, 24 Oct 2020 23:21:51 +0000 (23:21 +0000)]
Fix build after r367020

DTrace also relies on these definitions.

Reported by: jenkins

3 years agocdefs.h: remove intel_compiler support
imp [Sat, 24 Oct 2020 23:21:31 +0000 (23:21 +0000)]
cdefs.h: remove intel_compiler support

The  age  of   the  intel  compiler  support  is  so   old  as  to  be
uninteresting. No recent recports of  intel compiler support have been
received.  Remove  all the  special  case  workarounds for  the  Intel
compiler. Should there be interest in supporting the compiler, contact
me and I'll work with people to make it happen, though I suspect these
instances are more likely to be in the way than to be helpful.

Reviewed by: cem, emaste, vangyzen, dim
Differential Revision: https://reviews.freebsd.org/D26817

3 years agoRemove support for intel compiler from i386 in_cksum
imp [Sat, 24 Oct 2020 23:21:27 +0000 (23:21 +0000)]
Remove support for intel compiler from i386 in_cksum

We no longer support building the kernel with the old intel
compiler. Remove support for it from in_cksum. Should there be
interest in reviving it, this is as likely to get in the way as to
help anyway.

3 years agoRemove intel compiler support from math.h
imp [Sat, 24 Oct 2020 23:21:22 +0000 (23:21 +0000)]
Remove intel compiler support from math.h

The intel compiler support has badly decayed over the years. Stop
pretending that we support it. Note, I've stopped short of requiring
gcc builtin support with this commit since other compilers may be used
to build non-base software and we need to support those so more
investigation is needed before simplifying further.

3 years agoRemove support for ancient compilers
imp [Sat, 24 Oct 2020 23:21:18 +0000 (23:21 +0000)]
Remove support for ancient compilers

We don't support building the kernel from such old compilers, nor with
the Intel Compiler specifically. Remove support for this old construct
that was copied from stdbool.h and not relevant here.

3 years agoRemove obsolete check for GCC < 3 and support for Intel Compiler
imp [Sat, 24 Oct 2020 23:21:06 +0000 (23:21 +0000)]
Remove obsolete check for GCC < 3 and support for Intel Compiler

We no longer support old versions of GCC. Remove this check by
assuming it's false. That will make the entire expression false.  Also
remove support for Intel compiler, it's badly bitrotted.  Technically,
this removes support for C89 and K&R from compilers that don't define
_Bool in those compilation environments as well. I'm unaware of any
working compiler today for which that would be relevant (pcc has it
and tcc sadly isn't working for other reasons), though if one
pops up in ports, I'll work to resolve the issue.

3 years agoUpdate man page for -R option added by r376026.
rmacklem [Sat, 24 Oct 2020 22:52:29 +0000 (22:52 +0000)]
Update man page for -R option added by r376026.

This is a content change.

Reviewed by: bcr
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D26746

3 years agoAdd "-R" option to tell mountd to not register with rpcbind.
rmacklem [Sat, 24 Oct 2020 22:48:28 +0000 (22:48 +0000)]
Add "-R" option to tell mountd to not register with rpcbind.

rpcbind is now considered a security risk for some sites.
Since an NFSv4 only NFS server does not need rpcbind,
it makes sense to have an option that implements this.

This patch adds a "-R" option that disables the Mount
protocol (not used by NFSv4) and does not register
with rpcbind.

Changes are required to /etc/rc.d/mountd and /etc/rc.d/nfsd.
Those will be in a separate commit.

Reviewed by: freqlabs, asomers
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D26746

3 years agosockstat: Fix error message when jail_attach fails
freqlabs [Sat, 24 Oct 2020 22:36:20 +0000 (22:36 +0000)]
sockstat: Fix error message when jail_attach fails

jail_errmsg is for libjail, jail_attach() is a system call.

3 years agoAdd network QoS support for PCP to iscsi target.
rscheff [Sat, 24 Oct 2020 21:10:53 +0000 (21:10 +0000)]
Add network QoS support for PCP to iscsi target.

Mak the Ethernet PCP codepoint configurable
for L2 local traffic, to allow lower latency for
iSCSI block IO. This addresses the target
side only.

Reviewed by: mav, trasz, bcr
Sponsored by: NetApp, Inc.
Differential Revision: https://reviews.freebsd.org/D26740

3 years agoAdd network QoS support for PCP to iscsi initiator.
rscheff [Sat, 24 Oct 2020 21:07:13 +0000 (21:07 +0000)]
Add network QoS support for PCP to iscsi initiator.

Make the Ethernet PCP codepoint configurable
for L2 local traffic, to allow lower latency for
iSCSI block IO. This addresses the initiator
side only.

Reviewed by: mav, trasz, bcr
Sponsored by: NetApp, Inc.
Differential Revision: https://reviews.freebsd.org/D26739

3 years agoFix asymmetry in devstat(9) calls by GEOM.
mav [Sat, 24 Oct 2020 21:07:10 +0000 (21:07 +0000)]
Fix asymmetry in devstat(9) calls by GEOM.

Before this GEOM passed bio pointer to transaction start, but not end.
It was irrelevant until devstat(9) got DTrace hooks, that appeared to
provide bio pointer on I/O completion, but not on submission.

MFC after: 2 weeks
Sponsored by: iXsystems, Inc.

3 years agoMake use of IP_VLAN_PCP setsockopt in ping and ping6.
rscheff [Sat, 24 Oct 2020 21:01:18 +0000 (21:01 +0000)]
Make use of IP_VLAN_PCP setsockopt in ping and ping6.

In order to validate the proper marking and use of a different
ethernet priority class, add the new session-specific PCP
feature to the ping/ping6 utilities.

Reviewed by: mav, bcr
Sponsored by: NetApp, Inc.
Differential Revision: https://reviews.freebsd.org/D26627

3 years agoriscv: improve exception code naming
mhorne [Sat, 24 Oct 2020 20:57:13 +0000 (20:57 +0000)]
riscv: improve exception code naming

The existing names were inherited from arm64, but we should prefer
RISC-V terminology. Change the prefix to SCAUSE, and further change the
names to better match the RISC-V spec and be more consistent with one
another. Also, remove two codes that are not defined for S-mode (machine
and hypervisor ecall).

While here, apply style(9) to some condition checks.

Reviewed by: kp
Discussed with: jrtc27
Differential Revision: https://reviews.freebsd.org/D26918

3 years agoo Add iommu de-initialization method for MSI interface.
br [Sat, 24 Oct 2020 20:09:27 +0000 (20:09 +0000)]
o Add iommu de-initialization method for MSI interface.
o Add iommu_unmap_msi() to release the msi GAS entry.
o Provide default implementations for iommu init/deinit methods.

Reviewed by: kib
Sponsored by: Innovate DSbD
Differential Revision: https://reviews.freebsd.org/D26906