Commit Graph

12340 Commits

Author SHA1 Message Date
Warner Losh
ab6145c976 style: tweak tab after #define advice
Once upon a time, #define<tab> was cultural thing. However, even when it
was promulgated, it was a minority usage. 20 years ago the split was
30k/69k (tab/space) and today the split is 80k/546k (tab/space). Update
guidance to allow either with the usual suggestion to be consistent
within a file.

Reviewed by:		sef, allenjude, 0mp (prior rev), jhb
Sponsored by:		Netflix
Differential Revision:	https://reviews.freebsd.org/D30254
2021-06-11 10:54:06 -06:00
Fernando Apesteguía
cedaad9317 mmc(4), mmcsc(4): Remove missing Xref
There is no evidence of at91_mci in the code whatsoever. Most of the at91
drivers where removed in 802baf0ba6

PR: 218970
Reported by: reezer@reezer.org

Approved by: imp@
Differential Revision: https://reviews.freebsd.org/D29193
2021-06-10 15:15:54 +02:00
Fernando Apesteguía
49ddfdec19 ports(7): Add install-missing-packages to target list
It is already used in the EXAMPLES section.

Approved by:	bcr@ (manpages)
Differential Revision: https://reviews.freebsd.org/D30044
2021-06-10 14:58:24 +02:00
Edward Tomasz Napierala
dd869341b1 Install the linux(4) man page also for aarch64
Previously it was only installed on i386 and amd64.

Reviewed By:	emaste, gbe (manpages)
Sponsored By:	EPSRC
Differential Revision: https://reviews.freebsd.org/D30546
2021-06-07 11:50:50 +01:00
Konstantin Belousov
598f6fb49c linuxolator: Add compat.linux.setid_allowed knob
PR:	21463
Reported by:	kris
Reviewed by:	dchagin
Tested by:	trasz
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D28154
2021-06-06 21:43:00 +03:00
Konstantin Belousov
f9b1e711f0 fdescfs: add an option to return underlying file vnode on lookup
The 'nodup' option forces fdescfs to return real vnode behind file
descriptor instead of the fdescfs fd vnode, on lookup. The end result
is that e.g. stat("/dev/fd/3") returns the stat data for the underlying
vnode, if any.  Similarly, fchdir(2) works in the expected way.

For open(2), if applied over file descriptor opened with O_PATH, it
effectively re-open that vnode into normal file descriptor which has the
specified access mode, assuming the current vnode permissions allow it.

If the file descriptor does not reference vnode, the behavior is unchanged.

This is done by a mount option, because permission check on open(2) breaks
established fdescfs open semantic of dup(2)-ing the descriptor.  So it
is not suitable for /dev/fd mount.

Tested by:	Andrew Walker <awalker@ixsystems.com>
Reviewed by:	markj
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D30140
2021-06-04 03:30:12 +03:00
Ceri Davies
774bb1c256 periodic: add support for .xz and .zcat compressed logs
Also improve temporary file usage in 200.accounting, add an xref to
zstd(1) to newsyslog.conf.5, and clarify in periodic.conf that
"daily accounting" means process accounting and "monthly accounting"
is login accounting.

PR:		253868
Reviewed by:	allanjude
Approved by:	blackend (mentor)
Differential Revision:	https://reviews.freebsd.org/D29267
2021-06-02 17:28:28 +01:00
Kyle Evans
2d741f33bd kern: ether_gen_addr: randomize on default hostuuid, too
Currently, this will still hash the default (all zero) hostuuid and
potentially arrive at a MAC address that has a high chance of collision
if another interface of the same name appears in the same broadcast
domain on another host without a hostuuid, e.g., some virtual machine
setups.

Instead of using the default hostuuid, just treat it as a failure and
generate a random LA unicast MAC address.

Reviewed by:	bz, gbe, imp, kbowling, kp
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D29788
2021-06-01 22:59:21 -05:00
Kyle Evans
e58a65ccda man: document ether_gen_addr(9)
This KPI is used to assign a MAC address to an interface that doesn't
already have one assigned.

Reviewed by:	bcr, gnn, imp, kbowling, kp
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D29787
2021-06-01 22:59:10 -05:00
Jason A. Harmening
a4b07a2701 VFS_QUOTACTL(9): allow implementation to indicate busy state changes
Instead of requiring all implementations of vfs_quotactl to unbusy
the mount for Q_QUOTAON and Q_QUOTAOFF, add an "mp_busy" in/out param
to VFS_QUOTACTL(9).  The implementation may then indicate to the caller
whether it needed to unbusy the mount.

Also, add stbool.h to libprocstat modules which #define _KERNEL
before including sys/mount.h.  Otherwise they'll pull in sys/types.h
before defining _KERNEL and therefore won't have the bool definition
they need for mp_busy.

Reviewed By:	kib, markj
Differential Revision: https://reviews.freebsd.org/D30556
2021-05-30 14:53:47 -07:00
Sean Eric Fagan
505dc43562 The zone(9) man page had two entries for uma_reclaim(), one with
an argument (correct), and one without (incorrect).  Pointed out
by Allan Jude.
2021-05-30 13:02:11 -07:00
Gordon Bergling
66e2a5803b iwn(4): Remove duplicate device entry
'Intel Centrino Wireless-N 6250' is listed twice in the description
section of the manual page.

PR:	256257
Reported by:	Daniel Cervus <danielthedeer at outlook dot com>
MFC after:	3 days
2021-05-30 15:40:33 +02:00
Jason A. Harmening
271fcf1c28 Revert commits 6d3e78ad6c and 54256e7954
Parts of libprocstat like to pretend they're kernel components for the
sake of including mount.h, and including sys/types.h in the _KERNEL
case doesn't fix the build for some reason.  Revert both the
VFS_QUOTACTL() change and the follow-up "fix" for now.
2021-05-29 17:48:02 -07:00
Jason A. Harmening
6d3e78ad6c VFS_QUOTACTL(9): allow implementation to indicate busy state changes
Instead of requiring all implementations of vfs_quotactl to unbusy
the mount for Q_QUOTAON and Q_QUOTAOFF, add an "mp_busy" in/out param
to VFS_QUOTACTL(9).  The implementation may then indicate to the caller
whether it needed to unbusy the mount.

Reviewed By:	kib, markj
Differential Revision: https://reviews.freebsd.org/D30218
2021-05-29 14:05:39 -07:00
Bryan Drewery
55baee8cdb Correct location for KTR masks.
MFC after:	3 days
Sponsored by:	Dell EMC
2021-05-28 16:29:18 -07:00
Dmitry Chagin
434c46c006 rtwn_usb(4): Add a USB ID for the TP-Link Archer T2U v3.
PR:		256203
Submitted by:	Steve Kargl sgk at troutmask.apl.washington.edu
MFC after:	2 weeks
2021-05-27 21:52:10 +03:00
Mark Johnston
27130028a5 ktls.4: Mention mb_use_ext_pgs in the "sysctl nodes" section
Reviewed by:	rmacklem, jhb
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D30403
2021-05-26 10:49:30 -04:00
Dmitry Chagin
399bad7b9a rtwn_usb(4): add Mercusys MW150US (N150 Nano) to the rtwn_usb hardware list.
MFC after:		2 weeks
2021-05-26 10:13:08 +03:00
Dmitry Chagin
17dafdc0de rtwn_usb(4): add revision number for D-Link DWA-121 (N150 Nano).
MFC after:		2 weeks
2021-05-26 09:47:30 +03:00
Dmitry Chagin
962b3a0926 rtwn_usb(4): add D-Link DWA-121 (N150 Nano) to the rtwn_usb hardware list
MFC after:		2 weeks
2021-05-26 08:01:04 +03:00
John Baldwin
beb817edfe crypto: Add crypto_cursor_segment() to fetch both base and length.
This function combines crypto_cursor_segbase() and
crypto_cursor_seglen() into a single function.  This is mostly
beneficial in the unmapped mbuf case where back to back calls of these
two functions have to iterate over the sub-components of unmapped
mbufs twice.

Bump __FreeBSD_version for crypto drivers in ports.

Suggested by:	markj
Reviewed by:	markj
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D30445
2021-05-25 16:59:19 -07:00
John Baldwin
883a0196b6 crypto: Add a new type of crypto buffer for a single mbuf.
This is intended for use in KTLS transmit where each TLS record is
described by a single mbuf that is itself queued in the socket buffer.
Using the existing CRYPTO_BUF_MBUF would result in
bus_dmamap_load_crp() walking additional mbufs in the socket buffer
that are not relevant, but generating a S/G list that potentially
exceeds the limit of the tag (while also wasting CPU cycles).

Reviewed by:	markj
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D30136
2021-05-25 16:59:18 -07:00
John Baldwin
6663f8a23e sglist: Add sglist_append_single_mbuf().
This function appends the contents of a single mbuf to an sglist
rather than an entire mbuf chain.

Reviewed by:	gallatin, markj
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D30135
2021-05-25 16:59:18 -07:00
Ceri Davies
a23b08cf98 man5/{hosts,resolver}.5: note that IPv6 addresses are allowed.
The patch in the PR largely no longer applied due to age, but
thanks to Evgeniy Khramtsov for the patches in the PR.

PR:		120024
Reported by:	bcran
Approved by:	blackend (mentor)
Obtained from:	Evgeniy Khramtsov <evgeniy@khramtsov.org> (partly)
2021-05-25 16:23:20 +01:00
Ceri Davies
2770978d05 man4/inet6.4: use "effect" rather than "affect"
Approved by:	blackend (mentor)
2021-05-25 16:23:20 +01:00
J.R. Oldroyd
3fdd5c1e49 DRIVER_MODULE(9): Correct the SYNOPSIS of EARLY_DRIVER_MODULE()
The man page SYNOPSIS for EARLY_DRIVER_MODULE() shows that it has
an "enum sysinit_elem_order order" argument.

The actual macro in sys/bus.h does not have an order argument.

PR:	256103
Reported by:	J.R. Oldroyd <fbsd at opal dot com>
Reviewed by:	markj
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D30411
2021-05-24 16:54:45 +02:00
Dmitry Chagin
8746bc9187 run(4): add support for DLINK DWA-130 rev F1 wireless adaptor.
PR:		256092
Submitted by:	Francois Briere <purplefiasco at gmail.com>
MFC After:	2 weeks
2021-05-23 21:31:51 +03:00
Dmitry Chagin
b595729ccf rsu(4): add ASUS WL-167G V3 to the list of supported devices.
MFC After:	2 weeks
2021-05-23 18:42:29 +03:00
Dmitry Chagin
43f5d5bf01 run(4): fix manual after d6fd321ef6.
PR:		255759
MFC After:	2 weeks
2021-05-23 16:35:31 +03:00
Mark Johnston
c235059bb7 ktls.4: Remove an obsolete statement
The default mb_use_ext_pgs value was toggled in commit 52cd25eb1a.

Reviewed by:	jhb
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D30393
2021-05-22 12:12:30 -04:00
Allan Jude
73e77cf90b Netmap: fix documentation for NR_REG_NIC_SW mode
The correct character to add to the intername name is *, not +

Reviewed by:	vmaffione, bcr
Sponsored By:	Klara Inc.
Differential Revision:	https://reviews.freebsd.org/D30324
2021-05-22 01:44:23 +00:00
Mitchell Horne
788401188f scsi(4): fix "NMVe" typo 2021-05-21 11:51:45 -03:00
Kristof Provost
0592a4c83d pf: Add DIOCGETSTATESNV
Add DIOCGETSTATESNV, an nvlist-based alternative to DIOCGETSTATES.

MFC after:      1 week
Sponsored by:   Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D30243
2021-05-20 12:49:27 +02:00
Kristof Provost
1732afaa0d pf: Add DIOCGETSTATENV
Add DIOCGETSTATENV, an nvlist-based alternative to DIOCGETSTATE.

MFC after:	1 week
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D30242
2021-05-20 12:49:26 +02:00
Ceri Davies
c1a148873d sys/*/conf/*, docs: fix links to handbook
While here, fix all links to older en_US.ISO8859-1 documentation
in the src/ tree.

PR:             255026
Reported by:    Michael Büker <freebsd@michael-bueker.de>
Reviewed by:    dbaio
Approved by:    blackend (mentor), re (gjb)
MFC after:      10 days
Differential Revision: https://reviews.freebsd.org/D30265
2021-05-20 09:27:10 +01:00
Goran Mekić
c232fd4b41 sndstat.4: Improve manpage wording
Reviewed by:    bcr, khng
Differential Revision:	https://reviews.freebsd.org/D30027
2021-05-18 15:40:28 +08:00
Mitchell Horne
7fbc0c98a8 build(7): use a more relevant example for PORTS_MODULES
emulators/kqemu-kmod no longer exists in the ports tree.

Reviewed by:	imp, bcr
Differential Revision:	https://reviews.freebsd.org/D30261
2021-05-15 11:15:25 -03:00
Hans Petter Selasky
c65e2d7092 Update ugen(4) manual page.
Fix description of generic USB character devices.

PR:		244842
MFC after:	1 week
Sponsored by:	Mellanox Technologies // NVIDIA Networking
2021-05-14 17:14:18 +02:00
Lutz Donnerhacke
f6e0c47169 netgraph/ng_bridge: move MACs via control message
Use the new control message to move ethernet addresses from a link to
a new link in ng_bridge(4).  Send this message instead of doing the
work directly requires to move the loop detection into the control
message processing.  This will delay the loop detection by a few
frames.

This decouples the read-only activity from the modification under a
more strict writer lock.

Reviewed by:	manpages (gbe)
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D28559
2021-05-13 17:27:01 +02:00
Michael Tuexen
8ea5eeb913 mod_cc: cross reference CC modules consistently
Reviewed by:		bcr, gbe
MFC after:		3 days
Sponsored by:		Netflix, Inc.
Differential Revision:	https://reviews.freebsd.org/D30240
2021-05-13 11:29:35 +02:00
Ceri Davies
1760799b4c Remove references to timed(8)
There are still references to timed(8) and timedc(8) in the base system,
which were removed in 2018.

PR: 255425
Reported by:	Ceri Davies <ceri at submonkey dot net>
Reviewed by:	ygy, gbe
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D30232
2021-05-13 09:53:08 +02:00
Andrew Fengler
30659d1dcb Add support for adding default routes for other FIBs
Make rc.d/routing read defaultrouter_fibN and ipv6_defaultrouter_fibN, and
set it as the default gateway for FIB N, where N is from 1 to (net.fibs - 1)
This allows adding gateways for multiple FIBs in the same format as the main
gateway. (FIB 0)

Reviewed by:	olivier, rgrimes, bcr (man page)
Sponsored by:	ScaleEngine Inc.
Differential Revision:	https://reviews.freebsd.org/D22706
2021-05-12 01:59:10 +00:00
Richard Scheffenegger
0471a8c734 tcp: SACK Lost Retransmission Detection (LRD)
Recover from excessive losses without reverting to a
retransmission timeout (RTO). Disabled by default, enable
with sysctl net.inet.tcp.do_lrd=1

Reviewed By: #transport, rrs, tuexen, #manpages
Sponsored by: Netapp, Inc.
Differential Revision: https://reviews.freebsd.org/D28931
2021-05-10 19:06:20 +02:00
Gordon Bergling
416051f581 full(4): Use correct section name for AUTHORS
PR:	255715
Reported by:	Christos Margiolis <christos at christosmarg dot xyz>
MFC after:	3 days
2021-05-09 17:31:52 +02:00
Kristof Provost
abbcba9cf5 pf: Allow states to by killed per 'gateway'
This allows us to kill states created from a rule with route-to/reply-to
set.  This is particularly useful in multi-wan setups, where one of the
WAN links goes down.

Submitted by:	Steven Brown
Obtained from:	https://github.com/pfsense/FreeBSD-src/pull/11/
MFC after:	1 week
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D30058
2021-05-07 22:13:31 +02:00
Maxim Konovalov
34abb05be7 qat.4: the Authors section prettification
Rewording the Authors section in way that allows to
remove a hard break before Mark's name.

Reviewed by:	markj
2021-05-07 15:33:01 +00:00
John Baldwin
1b2806931a src.conf.5: Regen.
Reviewed by:	emaste
MFC after:	1 month
Differential Revision:	https://reviews.freebsd.org/D30107
2021-05-05 14:11:33 -07:00
Warner Losh
a512d0ab00 kern: clarify boot time
In FreeBSD, the current time is computed from uptime + boottime. Uptime
is a continuous, smooth function that's monotonically increasing. To
effect changes to the current time, boottime is adjusted.  boottime is
mutable and shouldn't be cached against future need. Document the
current implementation, with the caveat that we may stop stepping
boottime on resume in the future and will step uptime instead (noted in
the commit message, but not in the code).

Sponsored by:		Netflix
Reviewed by:		phk, rpokala
Differential Revision:	https://reviews.freebsd.org/D30116
2021-05-05 12:32:13 -06:00
Lutz Donnerhacke
b1bd44732d netgraph/ng_bridge: learn MACs via control message
Add a new control message to move ethernet addresses to a given link
in ng_bridge(4). Send this message instead of doing the work directly.
This decouples the read-only activity from the modification under a
more strict writer lock.

Decoupling the work is a prerequisite for multithreaded operation.

Approved by:	manpages (bcr), kp (earlier version)
MFC:		3 weeks
Differential Revision:	https://reviews.freebsd.org/D28516
2021-05-04 22:14:59 +02:00
Andrew Turner
2abd4f8581 Add a way to map arm64 non-posted device memory
On arm64 we currently use a non-posted write for device memory, however
we should move to use posted writes. This is expected to work on most
hardware, however we will need to support a non-posted option for some
broken hardware.

Reviewed by:	imp, manu, bcr (manpage)
Differential Revision:	https://reviews.freebsd.org/D29722
2021-05-01 06:01:20 +00:00
Mark Johnston
420d30f5bd kasan.9: A couple of fixups
- Mention GENERIC-KASAN.
- Note that the runtime was ported from NetBSD.

Sponsored by:	The FreeBSD Foundation
2021-04-29 12:26:37 -04:00
Li-Wen Hsu
164d49a584
Correct the link of external mirrors
Reported by:	0mp
Fixes:		8ef03ce6db
MFC after:	1 day
2021-04-29 03:39:18 +08:00
Fernando Apesteguía
e444a4c677 build(7): fix references to svn(1) and svnlite(1)
Replace them with references to Git.

PR:	254937
Reported by:	m.bueker@berlin.de
Approved by:	0mp (mentor)
Differential Revision:	https://reviews.freebsd.org/D29949
2021-04-28 16:38:27 +02:00
Ceri Davies
f33f2365ee geom_uzip(4): fix a typo
While I was there, also fixed a whitespace issue reported by mandoc
-Tlint.

PR:		254338
MFC after:	3 days
2021-04-28 00:59:03 -04:00
Michael Tuexen
6096814d31 tcp: fix man page
Reviewed by:		gbe, rscheff
MFC after:		1 week
Sponsored by:		Netflix, Inc.
Differential Revision:	https://reviews.freebsd.org/D29963
2021-04-24 22:40:34 +02:00
Fernando Apesteguía
2e5929a756 stats.7: Add dwatch(1) to the list
PR:	255303
Approved by: 0mp (mentor)
Differential Revision: https://reviews.freebsd.org/D29924
2021-04-22 19:33:12 +02:00
Ka Ho Ng
4ce1ba6523 sndstat: nvlist schema and API definition changes
- SNDSTAT_LABEL_* are renamed to SNDST_DSPS_*, and SNDSTAT_LABEL_DSPS
  becomes SNDST_DSPS.
- Centralize channel number/rate/formats into a single nvlist
  The above nvlist is named "info_play" and "info_rec"
- Expose only encoding format in pfmts/rfmts. Userland has no direct
  access to AFMT_ENCODING/CHANNEL/EXTCHANNEL macros, thus it serves no
  meaning to expose too much information through this pair of labels.
  However pminrate/rminrate, pmaxrate/rmaxrate, pfmts/rfmts are
  deprecated and will be removed in future.

This commit keeps ioctls ABI compatibility with __FreeBSD_version
1400006 for now. In future the compat ABI with 1400006 will be removed
once audio/virtual_oss is rebuilt.

Sponsored by:	The FreeBSD Foundation
Reviewed by:	hselasky
Approved by:	philip (mentor)
Differential Revision:	https://reviews.freebsd.org/D29770
2021-04-21 16:19:15 +08:00
Faraz Vahedi
33f8d79d76 assert.3: Document static_assert and _Static_assert
Reviewed by:	imp, 0mp
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D29833
2021-04-20 11:17:44 +02:00
Mateusz Piotrowski
ef0ba6bcce c.7: Fix some typos
Those misspellings were not picked up by igor because they are not
present in its list of common spelling errors.

Reported by:	rpokala
2021-04-20 10:33:34 +02:00
Kristof Provost
42ec75f83a pf: Optionally attempt to preserve rule counter values across ruleset updates
Usually rule counters are reset to zero on every update of the ruleset.
With keepcounters set pf will attempt to find matching rules between old
and new rulesets and preserve the rule counters.

MFC after:	4 weeks
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D29780
2021-04-19 14:31:47 +02:00
Michael Tuexen
9e644c2300 tcp: add support for TCP over UDP
Adding support for TCP over UDP allows communication with
TCP stacks which can be implemented in userspace without
requiring special priviledges or specific support by the OS.
This is joint work with rrs.

Reviewed by:		rrs
Sponsored by:		Netflix, Inc.
MFC after:		1 week
Differential Revision:	https://reviews.freebsd.org/D29469
2021-04-18 16:16:42 +02:00
Faraz Vahedi
136f6b6c0c c.7: Describe more recent C standards
Also, add some MLINKS and fix some typos.

Reviewed by:	bcr
Differential Revision:	https://reviews.freebsd.org/D28441
2021-04-18 16:36:13 +02:00
Mateusz Piotrowski
40277af7f2 spigen.4: Fix typos
MFC after:	3 days
2021-04-18 10:20:10 +02:00
Mateusz Piotrowski
d25f7d324a ports.7: Document DEBUG_FLAGS and the process of debugging ports
Loosely based on https://wiki.freebsd.org/BenWoods/DebuggingPorts.

Reviewed by:	crees
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D27296
2021-04-17 22:53:39 +02:00
Mateusz Piotrowski
c0e41dff70 ports.7: Add an example of setting variables for selected ports
Reviewed by:	crees
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D28202
2021-04-17 22:17:38 +02:00
Richard Scheffenegger
d1de2b05a0 tcp: Rename rfc6675_pipe to sack.revised, and enable by default
As full support of RFC6675 is in place, deprecating
net.inet.tcp.rfc6675_pipe and enabling by default
net.inet.tcp.sack.revised.

Reviewed By: #transport, kbowling, rrs
Sponsored by: NetApp, Inc.
Differential Revision: https://reviews.freebsd.org/D28702
2021-04-17 14:59:45 +02:00
Gleb Smirnoff
77a84a305e syncache.4: fix mandoc in cb8d7c44d6
Noticed by:	brueffer
2021-04-15 15:50:01 -07:00
Gleb Smirnoff
cb8d7c44d6 tcp_syncache: add net.inet.tcp.syncache.see_other sysctl
A security feature from c06f087ccb appeared to be a huge bottleneck
under SYN flood. To mitigate that add a sysctl that would make
syncache(4) globally visible, ignoring UID/GID, jail(2) and mac(4)
checks. When turned on, we won't need to call crhold() on the listening
socket credential for every incoming SYN packet.

Reviewed by:	bz
2021-04-15 15:26:48 -07:00
Mark Johnston
aabe13f145 uma: Introduce per-domain reclamation functions
Make it possible to reclaim items from a specific NUMA domain.

- Add uma_zone_reclaim_domain() and uma_reclaim_domain().
- Permit parallel reclamations.  Use a counter instead of a flag to
  synchronize with zone_dtor().
- Use the zone lock to protect cache_shrink() now that parallel reclaims
  can happen.
- Add a sysctl that can be used to trigger reclamation from a specific
  domain.

Currently the new KPIs are unused, so there should be no functional
change.

Reviewed by:	mav
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D29685
2021-04-14 13:03:34 -04:00
Mark Johnston
29bb6c19f0 domainset: Define additional global policies
Add global definitions for first-touch and interleave policies.  The
former may be useful for UMA, which implements a similar policy without
using domainset iterators.

No functional change intended.

Reviewed by:	mav
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D29104
2021-04-14 13:03:33 -04:00
Gordon Bergling
b1ab802ce4 ossl(4): Install the man page also for arm64
In 22bd0c9731 ossl(4) was ported to arm64. The manual page was
adapted, but never installed since the ossl(4) manual page was
i386 / amd64 only.

Reviewed by:	mhorne
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D29762
2021-04-14 18:32:56 +02:00
Mark Johnston
38da497a4d Add the KASAN runtime
KASAN enables the use of LLVM's AddressSanitizer in the kernel.  This
feature makes use of compiler instrumentation to validate memory
accesses in the kernel and detect several types of bugs, including
use-after-frees and out-of-bounds accesses.  It is particularly
effective when combined with test suites or syzkaller.  KASAN has high
CPU and memory usage overhead and so is not suited for production
environments.

The runtime and pmap maintain a shadow of the kernel map to store
information about the validity of memory mapped at a given kernel
address.

The runtime implements a number of functions defined by the compiler
ABI.  These are prefixed by __asan.  The compiler emits calls to
__asan_load*() and __asan_store*() around memory accesses, and the
runtime consults the shadow map to determine whether a given access is
valid.

kasan_mark() is called by various kernel allocators to update state in
the shadow map.  Updates to those allocators will come in subsequent
commits.

The runtime also defines various interceptors.  Some low-level routines
are implemented in assembly and are thus not amenable to compiler
instrumentation.  To handle this, the runtime implements these routines
on behalf of the rest of the kernel.  The sanitizer implementation
validates memory accesses manually before handing off to the real
implementation.

The sanitizer in a KASAN-configured kernel can be disabled by setting
the loader tunable debug.kasan.disable=1.

Obtained from:	NetBSD
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D29416
2021-04-13 17:42:20 -04:00
Dmitry Chagin
86887853c3 Remove reference to the pfctlinput2() from domain(9) after 237c1f932b.
Reviewed by:		glebius
MFC After:		1 week
Differential Revision:	https://reviews.freebsd.org/D29751
2021-04-14 00:40:20 +03:00
Kurosawa Takahiro
2aa21096c7 pf: Implement the NAT source port selection of MAP-E Customer Edge
MAP-E (RFC 7597) requires special care for selecting source ports
in NAT operation on the Customer Edge because a part of bits of the port
numbers are used by the Border Relay to distinguish another side of the
IPv4-over-IPv6 tunnel.

PR:		254577
Reviewed by:	kp
Differential Revision:	https://reviews.freebsd.org/D29468
2021-04-13 10:53:18 +02:00
John Baldwin
76681661be OCF: Remove support for asymmetric cryptographic operations.
There haven't been any non-obscure drivers that supported this
functionality and it has been impossible to test to ensure that it
still works.  The only known consumer of this interface was the engine
in OpenSSL < 1.1.  Modern OpenSSL versions do not include support for
this interface as it was not well-documented.

Reviewed by:	cem
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D29736
2021-04-12 14:28:43 -07:00
Mitchell Horne
2816bd8442 rmlock(9): add an RM_DUPOK flag
Allows for duplicate locks to be acquired without witness complaining.
Similar flags exists already for rwlock(9) and sx(9).

Reviewed by:	markj
MFC after:	3 days
Sponsored by:	NetApp, Inc.
Sponsored by:	Klara, Inc.
NetApp PR:	52
Differential Revision:	https://reviews.freebsd.org/D29683n
2021-04-12 11:42:21 -03:00
Mark Johnston
dfff37765c Rename struct device to struct _device
types.h defines device_t as a typedef of struct device *.  struct device
is defined in subr_bus.c and almost all of the kernel uses device_t.
The LinuxKPI also defines a struct device, so type confusion can occur.

This causes bugs and ambiguity for debugging tools.  Rename the FreeBSD
struct device to struct _device.

Reviewed by:	gbe (man pages)
Reviewed by:	rpokala, imp, jhb
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D29676
2021-04-12 09:32:30 -04:00
Yuri Pankov
970ffdcefe acpi(4): mention NONE as possible setting for hw.acpi.power_button_state
Reviewed by:	manpages (gbe)
Differential Revision:	https://reviews.freebsd.org/D29577
2021-04-11 23:17:06 +03:00
Ka Ho Ng
b77f5f5553 vnode_pager_setsize.9: Some clarifications on the manpage
A number of changes:
- Clarifies the locking rules when calling the routine.
- Correct the description regarding the content range to be purged.
- Document the effects on page fault handler.

MFC after:	3 days
MFC with:	86a52e262a
Sponsored by:	The FreeBSD Foundation
Reviewed by:	bcr, kib
Approved by:	philip (mentor)
Differential Revision:	https://reviews.freebsd.org/D29637
2021-04-11 14:47:40 +08:00
Ed Maste
041c504942 Regen src.conf.5 after 9d178c925f 2021-04-09 22:24:08 -04:00
Gordon Bergling
46c9952807 sysctl.conf(5): Mention sysctl.conf.local in the sysctl.conf(5) manual page
The possibility of using a sysctl.conf.local on a machine that has a shared
sysctl.conf(5) isn't documented. So mention the sysctl.conf.local in the
manual page.

PR:	254901
Submitted by:	Jose Luis Duran <jlduran at gmail dot com>
Reported by:	Jose Luis Duran <jlduran at gmail dot com>
Reviewed by:	markj
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D29673
2021-04-09 17:28:18 +02:00
Dmitry Chagin
f2400e6e83 Removed the reference to the deprecated splx API from ifnet(9).
Reviewed by:		emaste, markj
PR:			254880
MFC After:		1 week
Differential Revision:	https://reviews.freebsd.org/D29666
2021-04-09 17:22:12 +03:00
Gordon Bergling
9048d9a933 sed(1): Add a reference for a 4.4BSD manual document
Obtained from:	OpenBSD
MFC after:	1 week
2021-04-08 21:07:31 +02:00
Richard Scheffenegger
b878ec024b tcp: Use jenkins_hash32() in hostcache
As other parts of the base tcp stack (eg.
tcp fastopen) already use jenkins_hash32,
and the properties appear reasonably good,
switching to use that.

Reviewed By: tuexen, #transport, ae
MFC after: 2 weeks
Sponsored by: NetApp, Inc.
Differential Revision: https://reviews.freebsd.org/D29515
2021-04-08 20:29:19 +02:00
Ka Ho Ng
86a52e262a Document vnode_pager_setsize(9)
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
Reviewed by:	bcr
Approved by:	philip (mentor)
Differential Revision:	https://reviews.freebsd.org/D29408
2021-04-07 19:11:26 +08:00
Rene Ladan
11f47f17e1 ports(7): update instructions for git
Reviewed by:	gjb, imp, lwhsu, mat
Differential Revision:	https://reviews.freebsd.org/D29502
2021-04-06 22:26:03 +02:00
Konstantin Belousov
2d223ccdae Remove kgmon(8)
Follow-up to the removal of the mcov from kernel.

Noted by:	mckusick
Reviewed by:	mckusick
Sponsored by:	The FreeBSD Foundation
Differential revision:	https://reviews.freebsd.org/D29563
2021-04-04 00:50:28 +03:00
Cy Schubert
e2b247fac2 Remove bt.4 man page.
r339568 (a1db7455b7) removed bt(4).
This revision removes the man page

Reviewed by:		emaste (previous version)
Differential Revision:	https://reviews.freebsd.org/D29480
2021-04-01 19:09:54 -07:00
Konstantin Belousov
baacf70137 vxlan: correct interface MTU when using hw offloads
Otherwise it breaks when offloading like checksum or TSO are used,
because second (encapsulated) ip_output() processing passes fragments of
the encapsulated packet down to the hardware interface.

Diagnosed by:	hselasky
Reviewed by:	np
Sponsored by:	Nvidia Networking / Mellanox Technologies
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D29501
2021-03-31 14:38:26 +03:00
Piotr Pawel Stefaniak
4233882f4e security.7: fix typo in sysctl name
It is machdep.syscall_ret_flush_l1d.
2021-03-26 22:24:31 +01:00
Warner Losh
29dd5e7a87 build.7: Use proper .Dd date from this year 2021-03-25 01:48:12 -06:00
Warner Losh
def657b825 build.7: Document SYSDIR variable
Add a description of the SYSDIR variable.
2021-03-25 01:45:21 -06:00
Lawrence Stewart
dbbf3e3f37 random(9): Restore historical [0,2^31-1] output range and related man
documention.

Commit SVN r364219 / Git 8a0edc914f changed random(9) to be a shim around
prng32(9) and inadvertently caused random(9) to begin returning numbers in the
range [0,2^32-1] instead of [0,2^31-1], where the latter has been the documented
range for decades.

The increased output range has been identified as the source of numerous bugs in
code written against the historical output range e.g. ipfw "prob" rules and
stats(3) are known to be affected, and a non-exhaustive audit of the tree
identified other random(9) consumers which are also likely affected.

As random(9) is deprecated and slated for eventual removal in 14.0, consumers
should gradually be audited and migrated to prng(9).

Submitted by:		Loic Prylli <lprylli@netflix.com>
Obtained from:		Netflix
Reviewed by:		cem, delphij, imp
MFC after:		1 day
MFC to:			stable/13, releng/13.0
Differential Revision:	https://reviews.freebsd.org/D29385
2021-03-24 16:14:58 +11:00
Ed Maste
0cff00ae68 retire obsolete mn(4) sync serial driver
Approved by:	phk
Relnotes:	yes
2021-03-22 15:06:51 -04:00
Tobias Rehbein
815209920f rc.conf(5): Remove left-over variables
ipv6_ipfilter_rules was obsoleted because of ipfilter was updated, and
rc_parallel_start was reverted to undergo further refinement.

PR:		254398
Fixes:		e2ad10e847, f61831d2e8
2021-03-21 01:08:36 +01:00
Evgeniy Khramtsov
8ef03ce6db
development(7): mention the Git mirror list in the manual page
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D29234
2021-03-19 20:52:21 +08:00
Daniel Ebdrup Jensen
794f9f43c8 rc.conf(5): Bump date on .Dd
Pointy hat to:	me
Reported by:	lwhsu
2021-03-19 04:52:26 +01:00
John Baldwin
c853c53d02 Add Chacha20+Poly1035 to the list of AEAD algorithms.
Sponsored by:	Netflix
2021-03-18 13:33:11 -07:00
Tobias Rehbein
c39dda8192 rc.conf(5): Document the 'workstation' firewall_type
Document the workstation ACL ruleset, which uses stateful rules.

While here, add a note about where some of the undocumented variables
can be found. This is not a perfect solution for bug 127359, but it at
at least gives a place to go look, and can be used as a reference for
when bug 127359 gets fixed properly.

PR:		254358, 127359
2021-03-18 18:39:24 +01:00
Li-Wen Hsu
53844d3ea4
Clarify that the new STABLE branch is branched off CURRENT, not renamed
Reviewed by:	emaste
Differential Revision:	https://reviews.freebsd.org/D29317
2021-03-18 17:16:16 +08:00
Kyle Evans
f187d6dfbf base: remove if_wg(4) and associated utilities, manpage
After length decisions, we've decided that the if_wg(4) driver and
related work is not yet ready to live in the tree.  This driver has
larger security implications than many, and thus will be held to
more scrutiny than other drivers.

Please also see the related message sent to the freebsd-hackers@
and freebsd-arch@ lists by Kyle Evans <kevans@FreeBSD.org> on
2021/03/16, with the subject line "Removing WireGuard Support From Base"
for additional context.
2021-03-17 09:14:48 -05:00
Ka Ho Ng
c96151d335 Implement sndstat nvlist-based enumeration ioctls.
These ioctl commands aim to provide easier ways for user space
applications to enumerate existing audio devices and the node they can
potentially use.

The exchange of device lists between user space and kernel is done on
nv(9). Some ioctl commands are added to /dev/sndstat node:
  - SNDSTAT_REFRESH_DEVS
  - SNDSTAT_GET_DEVS
  - SNDSTAT_ADD_USER_DEVS
  - SNDSTAT_FLUSH_USER_DEVS

Bump __FreeBSD_version to reflect the addition of the ioctls.

Sponsored by:	The FreeBSD Foundation
Reviewed by:	hselasky
Approved by:	philip (mentor)
Differential Revision:	https://reviews.freebsd.org/D26884
2021-03-17 19:05:43 +08:00
Emmanuel Vadot
c7e6cb9e08 pkgbase: Add an src.conf option for splitting man pages
Man pages can be big in total, add an options to split man pages
in -man packages so we produce smaller packages.
This is useful for small jails or mfsroot produced of pkgbase.
The option is off by default.

Reviewed by:	bapt, Mina Galić <me@igalic.co>
Differential Revision:	https://reviews.freebsd.org/D29169
MFC after:      2 weeks
2021-03-16 07:13:09 +01:00
Kyle Evans
74ae3f3e33 if_wg: import latest fixup work from the wireguard-freebsd project
This is the culmination of about a week of work from three developers to
fix a number of functional and security issues.  This patch consists of
work done by the following folks:

- Jason A. Donenfeld <Jason@zx2c4.com>
- Matt Dunwoodie <ncon@noconroy.net>
- Kyle Evans <kevans@FreeBSD.org>

Notable changes include:
- Packets are now correctly staged for processing once the handshake has
  completed, resulting in less packet loss in the interim.
- Various race conditions have been resolved, particularly w.r.t. socket
  and packet lifetime (panics)
- Various tests have been added to assure correct functionality and
  tooling conformance
- Many security issues have been addressed
- if_wg now maintains jail-friendly semantics: sockets are created in
  the interface's home vnet so that it can act as the sole network
  connection for a jail
- if_wg no longer fails to remove peer allowed-ips of 0.0.0.0/0
- if_wg now exports via ioctl a format that is future proof and
  complete.  It is additionally supported by the upstream
  wireguard-tools (which we plan to merge in to base soon)
- if_wg now conforms to the WireGuard protocol and is more closely
  aligned with security auditing guidelines

Note that the driver has been rebased away from using iflib.  iflib
poses a number of challenges for a cloned device trying to operate in a
vnet that are non-trivial to solve and adds complexity to the
implementation for little gain.

The crypto implementation that was previously added to the tree was a
super complex integration of what previously appeared in an old out of
tree Linux module, which has been reduced to crypto.c containing simple
boring reference implementations.  This is part of a near-to-mid term
goal to work with FreeBSD kernel crypto folks and take advantage of or
improve accelerated crypto already offered elsewhere.

There's additional test suite effort underway out-of-tree taking
advantage of the aforementioned jail-friendly semantics to test a number
of real-world topologies, based on netns.sh.

Also note that this is still a work in progress; work going further will
be much smaller in nature.

MFC after:	1 month (maybe)
2021-03-14 23:52:04 -05:00
Ryan Libby
3e5e9939cd ddb: enable the use of ^C and ^S/^Q
This lets one interrupt DDB's output, which is useful if paging is
disabled and the output device is slow.

This follows a previous implementation in svn r311952 / git
5fddef7999 which was reverted because it
broke DDB type-ahead.

Now, try this again, but with a 512-byte type-ahead buffer.  While there
is buffer space, control input is handled and non-control input is
buffered.  When the buffer is exhausted, the default is to print a
warning and drop further non-control input in order to continue handling
control input.  sysctl debug.ddb.prioritize_control_input can be set to
0 to instead preserve all input but lose immediate handling of control
input.  This could for example effect pasting of a large script into the
ddb console.

Suggested by:	Anton Rang <rang@acm.org>
Reviewed by:	markj
Discussed with:	imp
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D28676
2021-03-14 16:04:27 -07:00
Gordon Bergling
183502d162 Fix a few typos in comments
- trough -> through

MFC after:	1 week
2021-03-13 16:37:28 +01:00
Kristof Provost
51dc8e7f68 Document that uma_zfree_pcpu() allows NULL now
While here also document that for counter_u64_free().

Reviewed by:	rpokala@
MFC after:	1 week
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D29215
2021-03-12 12:12:35 +01:00
Edward Tomasz Napierala
d28cbb7944 development(7): update to reflect Git transition
Reviewed By:	debdrup, imp (earlier version)
Sponsored By:	EPSRC
Differential Revision:	https://reviews.freebsd.org/D28939
2021-03-11 20:07:53 +00:00
Warner Losh
c22076b528 man: Remove obsolete info from hosts man page
The NIC no longer provides a host database, and hasn't for quite some
time. Remove that paragraph, it's not been relevant for many years. Also, hosts
appeared in 4.1c, not 4.2, so correct that too.

Noticed by: Henry Bent
2021-03-11 11:46:10 -07:00
Warner Losh
e52368365d config_intrhook: provide config_intrhook_drain
config_intrhook_drain will remove the hook from the list as
config_intrhook_disestablish does if the hook hasn't been called.  If it has,
config_intrhook_drain will wait for the hook to be disestablished in the normal
course (or expedited, it's up to the driver to decide how and when
to call config_intrhook_disestablish).

This is intended for removable devices that use config_intrhook and might be
attached early in boot, but that may be removed before the kernel can call the
config_intrhook or before it ends. To prevent all races, the detach routine will
need to call config_intrhook_train.

Sponsored by:		Netflix, Inc
Reviewed by:		jhb, mav, gde (in D29006 for man page)
Differential Revision:	https://reviews.freebsd.org/D29005
2021-03-11 09:45:10 -07:00
Oskar Holmund
7d4a5de84d share/man/man9/pwmbus.9 fix types in arguments
Fix the types of period and duty in share/man/man9/pwmbus.9 to match the one in sys/dev/pmw/pwmbus.c.

Reviewed By: rpokala
Differential Revision: https://reviews.freebsd.org/D29139
MFC after:   3 days
2021-03-11 09:57:04 +01:00
Kyle Evans
ce53f92e6c wg(4): note the persistent-keepalive ifconfig(8) option
MFC after:	3 days
Fixes:	b3dac3913d
2021-03-09 14:21:35 -06:00
John Baldwin
c5a365623f Correct the name of the structure used for TCP socket options.
The structure was renamed while refactoring Netflix's KTLS changes for
upstreaming, but the original name remained in tcp.4 and was
subsequently copied to ktls.4.

PR:		254141
Reported by:	asomers
MFC after:	3 days
2021-03-08 10:46:40 -08:00
Gordon Bergling
f7bfe31019 wg(4): Fix an example in the manual page
The example in the manual page of wg(4) for connecting to a
peer was missing the 'public-key' ifconfig(8) keyword and for the
addressed peer the port must be specified.

PR:	253866
Reported by:	Sergey Akhmatov <sergey at akhmatov dot ru>
Reviewed by:	debdrup
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D29115
2021-03-07 20:27:59 +01:00
Mark Murray
fbf8e32452 Remove references to the now-removed bktr(4) driver. 2021-03-07 00:09:22 +00:00
Hans Petter Selasky
c743a6bd4f Implement mallocarray_domainset(9) variant of mallocarray(9).
Reviewed by:	kib @
MFC after:	1 week
Sponsored by:	Mellanox Technologies // NVIDIA Networking
2021-03-06 11:38:55 +01:00
Kristof Provost
b4e3f3c2de pfctl: Add missing 'va' code point name
Add the 'va' (voice-admit, RFC5865) symbolic name.

Reviewed by:	rgrimes, gbe (man page)
MFC after:	2 weeks
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D29069
2021-03-06 10:07:55 +01:00
Konstantin Belousov
f5e930b369 atomic(9): note that atomic_interrupt_fence first appeared in 13.0
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2021-03-06 07:24:18 +02:00
Glen Barber
fa04db4762 release: fix VMSIZE following 1ca8842f3a
truncate(1) is not case-sensitive with regard to setting the size
of a file.  makefs(8), however, does not honor upper-case values.
Update release-specific files and the release(7) manual page to
reflect this.

MFC with:	1ca8842f3a
Submitted by:	ehem_freebsd_m5p.com (original)
Differential Review:	https://reviews.freebsd.org/D28979
Sponsored by:	Rubicon Communications, LLC ("Netgate")
2021-03-04 08:43:02 -05:00
John Baldwin
78991a93eb ossl: Add support for the ChaCha20 + Poly1305 AEAD cipher from RFC 8439
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D28757
2021-03-03 15:20:57 -08:00
John Baldwin
92aecd1e6f ossl: Add ChaCha20 cipher support.
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D28756
2021-03-03 15:20:57 -08:00
John Baldwin
a899ce4ba4 The ChaCha20 counter is little endian, not big endian.
Reviewed by:	cem
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D28755
2021-03-03 15:20:57 -08:00
John Baldwin
a079e38b08 ossl: Add Poly1305 digest support.
Reviewed by:	cem
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D28754
2021-03-03 15:20:57 -08:00
Mark Johnston
3adf72a36b qat.4: Fix some firmware module names
PR:		252984
MFC after:	1 week
2021-03-03 09:07:53 -05:00
Alan Somers
de415e663c release.7: describe the NOGIT option
It was added in 91ce469984 (svn r365638)

MFC after:	7 days
Sponsored by:	Axcient
Reviewed by:	gjb
Differential Revision:	https://reviews.freebsd.org/D29027
2021-03-02 19:39:57 -07:00
Kyle Evans
13686dffbb Regenerate src.conf(5) after FMTREE removal 2021-03-02 15:22:06 -06:00
Kyle Evans
ca4e1ea19f Regenerate src.conf(5) after PIE default change 2021-03-02 15:22:05 -06:00
Evgeniy Khramtsov
907023b454 security(7): mention new W^X sysctls in the manual page
Reviewed by:	emaste, gbe
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D28986
2021-03-02 19:52:22 +01:00
Ka Ho Ng
43afeee2fb share/man/man9: document zero_region(9)
The zero_region() kernel interface was previously undocumented.
Add a new zero_region(9) manual page to document it.

Submitted by:	Ka Ho Ng <khng@freebsdfoundation.org>
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D28914
2021-03-02 17:14:06 +08:00
Konstantin Belousov
55eb51ab66 Add VOP_READ_PGCACHE(9)
PR:	253894
Reviewed by:	gbe, rwatson
Sponsored by:	The FreeBSD Foundation
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D28980
2021-03-01 01:38:33 +02:00
Robert Watson
a9f1135503 Add Xrefs to the new VOP_SETLABEL(9) from mac(9) and vnode(9).
MFC after:	3 days
2021-02-27 16:53:53 +00:00
Robert Watson
7bfd84444e Provide a man page for VOP_SETLABEL(9).
MFC after:	3 days
2021-02-27 16:51:13 +00:00
Li-Wen Hsu
655fa04406
Add if_wg.4 MLINK 2021-02-26 00:43:15 +08:00
Konstantin Belousov
e2494f7561 atomic: add atomic_interrupt_fence()
with the semantic following C11 signal_fence, that is, it establishes
ordering between its place and any interrupt handler executing on the
same CPU.

Reviewed by:	markj, mjg, rlibby
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D28909
2021-02-24 22:45:24 +02:00
Rajesh Kumar M A
ec78688666 Update manpage for AMD 10GbE driver
Approved by: vmaffione, gallatin

Differential Revision: https://reviews.freebsd.org/D28724

MFC after:	1 week
2021-02-24 05:01:10 +00:00
Daniel Ebdrup Jensen
408edcca07 rc.conf(5): Add note about parallel startup variable
The commit below added parallel service startup, and it needs to be
documented, so people know about it.

PR:		249192
MFC with:	77e1ccbee3

Reviewed by:	yuripv
Differential Revision:	https://reviews.freebsd.org/D28898
2021-02-23 22:26:31 +01:00
Daniel Ebdrup Jensen
ef1a1fc7e8 release(7) Fix mistake noted in review
I missed this when doing the final pass.

Fixes: f695e960 release(7): Remove stray references to DOC* variables
2021-02-23 19:11:54 +01:00
Daniel Ebdrup Jensen
f695e96067 release(7): Remove stray references to DOC* variables
We now live in the world of git, and release(7) should reflect that.

As of the commit referenced below, release images also no longer
include (stale) documentation, as the documentation has moved to
AsciiDoctor. This means that a few environment variables no longer
make sense, so remove them from their sections and mention them in
the compatibility section instead.

While here, also pet mandoc.

PR: 253615
MFC after: 3 days
MFC with: f61e92ca5a release: permanently remove the 'reldoc'
target and associates

Reviewed by:	gjb, lwhsu, yuripv
Differential Revision:	https://reviews.freebsd.org/D28881
2021-02-23 19:06:36 +01:00
Jessica Clarke
963cf6cb0f uefi: Add riscv to historical details 2021-02-22 22:27:00 +00:00
Warner Losh
f11e9f325a Restore missing word
"in" got dropped when I shuffled things around.

Noticed by: rpokala@
MFC After: 3 days
2021-02-22 14:39:04 -07:00
Warner Losh
8c09ecb2e2 uefi: add historical details
Add details about when armv6 and armv7 support was added.
2021-02-22 14:20:44 -07:00
Robert Wing
5ce2d4a1c2 bhyve/snapshot: drop mkdir when creating the unix domain socket
Add /var/run/bhyve/ to BSD.var.dist so we don't have to call mkdir when
creating the unix domain socket for a given bhyve vm.

The path to the unix domain socket for a bhyve vm will now be
/var/run/bhyve/vmname instead of /var/run/bhyve/checkpoint/vmname

Move BHYVE_RUN_DIR from snapshot.c to snapshot.h so it can be shared
to bhyvectl(8).

Reviewed by: jhb
Differential Revision: https://reviews.freebsd.org/D28783
2021-02-22 11:31:07 -09:00
Warner Losh
ab77cc9e7b Remove incorrect statement about EFI environment variables being unsupported.
Our uefi support has included environment variable support for several years
now. Remove the bogus blanket statement saying we don't support them.

MFC After: 3 days
2021-02-22 13:20:58 -07:00
Daniel Ebdrup Jensen
248a47a4c2 ports(7): Update instructions for package target
Packages default to ending up in a different location compared to the
documentation, so catch up to the implementation by referring to the
location where packages can usually be found if no environment variables
have been set.

While here, also update the mention of the file extension to match the
txz format that packages use.

PR:		253179, 224370
Reported by:	rwatson, jeromer at fastmail dotnet
2021-02-19 13:42:16 +01:00
John Baldwin
fc8fc743d8 Add an OCF algorithm for ChaCha20-Poly1305 AEAD.
Note that this algorithm implements the mode defined in RFC 8439.

Reviewed by:	cem
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D27836
2021-02-18 09:26:00 -08:00
Mitchell Horne
bd012c7159 arm64: handle watchpoint exceptions from EL0
This is a prerequisite to allowing the use of hardware watchpoints for
userspace debuggers.

This is also a slight departure from the x86 behaviour, since `si_addr`
returns the data address that triggered the watchpoint, not the
address of the instruction that was executed. Otherwise, there is no
straightforward way for the application to determine which watchpoint
was triggered. Make a note of this in the siginfo(3) man page.

Reviewed by:	jhb, markj (earlier version)
Tested by:	Michał Górny (mgorny@gentoo.org)
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D28561
2021-02-17 12:05:00 -04:00
Richard Scheffenegger
3c40e1d52c update the SACK loss recovery to RFC6675, with the following new features:
- improved pipe calculation which does not degrade under heavy loss
- engaging in Loss Recovery earlier under adverse conditions
- Rescue Retransmission in case some of the trailing packets of a request got lost

All above changes are toggled with the sysctl "rfc6675_pipe" (disabled by default).

Reviewers:	#transport, tuexen, lstewart, slavash, jtl, hselasky, kib, rgrimes, chengc_netapp.com, thj, #manpages, kbowling, #netapp, rscheff
Reviewed By:	#transport
Subscribers:	imp, melifaro
MFC after:	2 weeks
Sponsored by:	NetApp, Inc.
Differential Revision:	https://reviews.freebsd.org/D18985
2021-02-16 13:08:37 +01:00
Kyle Evans
95138d09d2 Regenerate src.conf(5) after FMTREE default change 2021-02-12 23:16:06 -06:00
Richard Scheffenegger
a78fee8182 Adding PRR sysctls to tcp(4) man page
Summary:
Documenting the newly added, and enabled by default,
Proportional Rate Reduction algorithm's governing sysctls.

MFC: 3 days

Reviewed By: kbowling, rgrimes

Differential Revision: https://reviews.freebsd.org/D28568
2021-02-12 12:33:27 +01:00
Guangyuan Yang
c03ccb991d VOP_ADVLOCK(9): fix a typo
Submitted by:	Ka Ho Ng <khng300@gmail.com>
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D28575
2021-02-11 14:02:43 +00:00