aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* efivar: use bool for booleansWarner Losh2021-04-091-23/+22
| | | | | | | | | Rather than int flags we ++, use booleans for all command line args. No functional change intended. Reviewed by: markj@ Sponsored by: Netflix, Inc Differential Revision: https://reviews.freebsd.org/D29621
* efivar: Attempt to fix setting/printing/deleting EFI vars with '-' in their nameWarner Losh2021-04-091-9/+18
| | | | | | | | | | | | Due to how we're parsing UUIDs, we were disallowing setting, printing or deleting any UEFI variable with a '-' in it when you attempted to do that operation with the exact name (wildcard reporting was unaffected). Fix the parser to loop over all the dashes in the name and only give up when all possible matches are exhausted. Reviewed by: markj@ Sponsored by: Netflix, Inc Differential Revision: https://reviews.freebsd.org/D29620
* efivar: Add --quiet to not report errorsWarner Losh2021-04-092-17/+55
| | | | | | | | | Add -q/--quiet flag to the command line. With it, errors are not reported at all. Instead nothing is printed and the exit code is non-zero. Reviewed by: markj Sponsored by: Netflix, Inc Differential Revision: https://reviews.freebsd.org/D29619
* tcp_hostcache: make THC_LOCK/UNLOCK macros to work with hash head pointer.Gleb Smirnoff2021-04-091-14/+14
| | | | Not a functional change.
* tcp_hostcache: style(9)Gleb Smirnoff2021-04-091-26/+27
| | | | Reviewed by: rscheff
* tcp_hostcache: remove extraneous check.Gleb Smirnoff2021-04-091-6/+0
| | | | | | All paths leading here already checked this setting. Reviewed by: rscheff
* tcp_hostcache: implement tcp_hc_updatemtu() via tcp_hc_update.Gleb Smirnoff2021-04-091-30/+5
| | | | | | | Locking changes are planned here, and without this change too much copy-and-paste would be between these two functions. Reviewed by: rscheff
* rtld: use _get_tp() in __tls_get_addr()Konstantin Belousov2021-04-094-72/+13
| | | | | | | | | | This eliminates some non-trivial amount of code duplication, where done. Only x86 and mips are handled right now. Tested by: bdragon (powerpc), mhorne (riscv) Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* rtld: avoid recursing on rtld_bind_lock for writeKonstantin Belousov2021-04-093-4/+7
| | | | | | | | | | | | This fixes a regression in d36d6816151705907393889, where the call to __tls_get_address() was performed under rtld_bind_lock write-locked. Instead use tls_get_addr_slow() directly, with locked = true. Reported by: jkim, many others Tested by: jkim, bdragon (powerpc), mhorne (riscv) Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* rtld: allow to use tls_get_addr_slow() from context where rtld_bind_lock is ↵Konstantin Belousov2021-04-091-7/+11
| | | | | | | | | | locked Explicit locked parameter is added Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* rtld: style tls_get_addr_slowKonstantin Belousov2021-04-091-27/+27
| | | | | | Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* libc dl_iterate_phdr(): dlpi_tls_data is wrongKonstantin Belousov2021-04-091-2/+4
| | | | | | | | | | | This is the same change as d36d681615170590, but for libc static implementaion of dl_iterate_phdr(). Reported by: emacsray@gmail.com PR: 254774 Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* libc: implement __tls_get_addr() for static binariesKonstantin Belousov2021-04-091-8/+15
| | | | | | Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* libc: add _get_tp() private functionKonstantin Belousov2021-04-0917-6/+441
| | | | | | | | which returns pointer to tcb Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* rtld: define TLS_DTV_OFFSET on all architecturesKonstantin Belousov2021-04-095-0/+10
| | | | | | Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* libc: include rtld.h into static implementations of rtld interfaceKonstantin Belousov2021-04-095-37/+58
| | | | | | | | and resolve naming conficts Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* libc: constify dummy error message string for dlfcnKonstantin Belousov2021-04-091-2/+2
| | | | | | Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* rtld_lock.h: Expand scope for IN_RTLD to avoid some conflicts with libcKonstantin Belousov2021-04-091-0/+4
| | | | | | Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* rtld/x86/reloc.c: styleKonstantin Belousov2021-04-092-3/+6
| | | | | | Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* rtld_lock.h: remove tautological extern'sKonstantin Belousov2021-04-091-3/+3
| | | | | | Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D29623
* Stop arming kqueue timers on knote owner suspend or terminateKonstantin Belousov2021-04-096-7/+61
| | | | | | | | | | | This way, even if the process specified very tight reschedule intervals, it should be stoppable/killable. Reported and reviewed by: markj Tested by: markj, pho Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D29106
* Add helper for kqueue timers callout schedulingKonstantin Belousov2021-04-091-4/+13
| | | | | | | | Reviewed by: markj Tested by: markj, pho Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D29106
* Stop arming realtime posix process timers on suspend or terminateKonstantin Belousov2021-04-092-9/+40
| | | | | | | | Reported and reviewed by: markj Tested by: markj, pho Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D29106
* Stop arming periodic process timers on suspend or terminateKonstantin Belousov2021-04-094-4/+43
| | | | | | | | Reported and reviewed by: markj Tested by: markj, pho Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D29106
* Implement better rebuild-delay fib algo policy.Alexander V. Chernikov2021-04-091-61/+228
| | | | | | | | | | | | | | | | | | | | | The intent is to better handle time intervals with large amount of RIB updates (e.g. BGP peer going up or down), while still keeping low sync delay for the rest scenarios. The implementation is the following: updates are bucketed into the buckets of size 50ms. If the number of updates within a current bucket exceeds the threshold of 500 routes/sec (e.g. 10 updates per bucket interval), the update is delayed for another 50ms. This can be repeated until the maximum update delay (1 sec) is reached. All 3 variables are runtime tunables: * net.route.algo.fib_max_sync_delay_ms: 1000 * net.route.algo.bucket_change_threshold_rate: 500 * net.route.algo.bucket_time_ms: 50 Differential Review: https://reviews.freebsd.org/D29588 MFC after: 2 weeks
* netmap: vtnet: remove unused variableVincenzo Maffione2021-04-091-2/+1
| | | | Reported by: bdragon
* sysctl.conf(5): Mention sysctl.conf.local in the sysctl.conf(5) manual pageGordon Bergling2021-04-091-2/+5
| | | | | | | | | | | | | 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
* Removed the reference to the deprecated splx API from ifnet(9).Dmitry Chagin2021-04-091-9/+0
| | | | | | | Reviewed by: emaste, markj PR: 254880 MFC After: 1 week Differential Revision: https://reviews.freebsd.org/D29666
* lpd(8): Mention the author of a paper in the SEE ALSO sectionGordon Bergling2021-04-091-1/+3
| | | | | Obtained from: OpenBSD MFC after: 1 week
* config(8): Mention the authors of a paper in the SEE ALSO sectionGordon Bergling2021-04-091-1/+5
| | | | | Obtained from: OpenBSD MFC after: 1 week
* ed(1): Add two references in the SEE ALSO sectionGordon Bergling2021-04-091-1/+11
| | | | | Obtained from: OpenBSD MFC after: 1 week
* pci_dw: Trim ATU windows bigger than 4GBWojciech Macek2021-04-091-0/+12
| | | | | | | | | | | | The size of the ATU MEM/IO windows is implicitly casted to uint32_t. Because of that some window sizes were silently demoted to 0 and ignored. Check the size if its too large, trim it to 4GB and print a warning message. Submitted by: Kornel Duleba <mindal@semihalf.com> Reviewed by: mw Obtained from: Semihalf Sponsored by: Marvell Differential revision: https://reviews.freebsd.org/D29625
* UPDATING: dereference portupgrade(8)Glen Barber2021-04-091-1/+2
| | | | | | | | Make the UPDATING file less tool-specific regarding upgrading third-party software. MFC after: 3 weeks Sponsored by: Rubicon Communications, LLC ("Netgate")
* struct mount uppers: correct locking annotationsKonstantin Belousov2021-04-081-2/+3
| | | | | | | | It is all locked by the uppers' interlock. Noted by: Alexander Lochmann <alexander.lochmann@tu-dortmund.de> Sponsored by: The FreeBSD Foundation MFC after: 3 days
* nfsd: fix replies from session cache for retried RPCsRick Macklem2021-04-082-1/+8
| | | | | | | | | | | | | | | | | | | | | | Recent testing of network partitioning a FreeBSD NFSv4.1 server from a Linux NFSv4.1 client identified problems with both the FreeBSD server and Linux client. The FreeBSD server failec to reply using the cached reply in the session slot when an RPC was retried on the session slot, as indicated by same slot sequence#. This patch fixes this. It should also fix a similar failure for NFSv4.0 mounts, when the sequence# in the open/lock_owner requires a reply be done from an entry locked into the DRC. This fix affects the fairly rare case where a NFSv4 client retries a non-idempotent RPC, such as a lock operation. Note that retries only occur after the client has needed to create a new TCP connection. MFC after: 2 weeks
* Enforce check for using the return result for ifa?_try_ref().Alexander V. Chernikov2021-04-051-2/+2
| | | | | | Suggested by: hps MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D29504
* m4(1): Add a SEE ALSO section and reference an AT&T manualGordon Bergling2021-04-081-1/+12
| | | | | Obtained from: OpenBSD MFC after: 1 week
* sed(1): Add a reference for a 4.4BSD manual documentGordon Bergling2021-04-082-2/+20
| | | | | Obtained from: OpenBSD MFC after: 1 week
* tcp: Use jenkins_hash32() in hostcacheRichard Scheffenegger2021-04-082-9/+62
| | | | | | | | | | | | 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
* tcp_hostcache.c: remove unneeded includes.Gleb Smirnoff2021-04-081-14/+0
| | | | Reviewed by: rscheff
* tcp_hostcache: add bool argument for tcp_hc_lookup() to tell are weGleb Smirnoff2021-04-081-25/+20
| | | | | | | | looking to only read from the result, or to update it as well. For now doesn't affect locking, but allows to push stats and expire update into single place. Reviewed by: rscheff
* tcp_hostcache: hide rmx_hits/rmx_updates under ifdef.Gleb Smirnoff2021-04-081-3/+22
| | | | | | | They have little value unless you do some profiling investigations, but they are performance bottleneck. Reviewed by: rscheff
* Remove tcp_hostcache.h. Everything is private.Gleb Smirnoff2021-04-083-85/+45
| | | | Reviewed by: rscheff
* tcp: Prepare PRR to work with NewReno LossRecoveryRichard Scheffenegger2021-04-082-5/+7
| | | | | | | | | | | | | Add proper PRR vnet declarations for consistency. Also add pointer to tcpopt struct to tcp_do_prr_ack, in preparation for it to deal with non-SACK window reduction (after loss). No functional change. MFC after: 2 weeks Reviewed By: tuexen, #transport Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D29440
* Avoid -pedantic warnings about using _Generic in __fp_type_selectDimitry Andric2021-04-081-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | When compiling parts of math.h with clang using a C standard before C11, and using -pedantic, it will result in warnings similar to: bug254714.c:5:11: warning: '_Generic' is a C11 extension [-Wc11-extensions] return !isfinite(1.0); ^ /usr/include/math.h:111:21: note: expanded from macro 'isfinite' ^ /usr/include/math.h:82:39: note: expanded from macro '__fp_type_select' ^ This is because the block that enables use of _Generic is conditional not only on C11, but also on whether the compiler advertises support for C generic selections via __has_extension(c_generic_selections). To work around the warning without having to pessimize the code, use the __extension__ keyword, which is supported by both clang and gcc. While here, remove the check for __clang__, as _Generic has been supported for a long time by gcc too now. Reported by: yuri PR: 254714 MFC after: 1 week
* bhyve: fix regression in legacy virtio-9p config parsingRoman Bogorodskiy2021-04-081-1/+1
| | | | | | | | | | | Commit 621b5090487de9fed1b503769702a9a2a27cc7bb introduced a regression in legacy virtio-9p config parsing by not initializing *sharename to NULL. As a result, "sharename != NULL" check in the first iteration fails and bhyve exits with "virtio-9p: more than one share name given". Fix by adding NULL back. Approved by: grehan
* [tcp] Fix ECN on finalizing sessions.Richard Scheffenegger2021-04-081-1/+1
| | | | | | | | | | | A subtle oversight would subtly change new data packets sent after a shutdown() or close() call, while the send buffer is still draining. MFC after: 3 days Reviewed By: #transport, tuexen Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D29616
* Clean up the style in the arm64 bus.hAndrew Turner2021-04-081-12/+14
| | | | | MFC after: 2 weeks Sponsored by: Innovate UK
* arm64: clear debug register state on forkMitchell Horne2021-04-081-0/+3
| | | | | | | | | | | | Following the analogous change for amd64 and i386 in 8223717ce62c, ensure that new processes start with these registers inactive. PR: 254661 Reported by: Michał Górny Reviewed by: kib, emaste MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D29630
* pf: Remove unused variable rt_listid from struct pf_kruleKristof Provost2021-04-082-3/+0
| | | | | | | Reviewed by: donner MFC after: 4 weeks Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D29639