summaryrefslogtreecommitdiff
path: root/sys/netinet
Commit message (Collapse)AuthorAgeFilesLines
...
* Remove now-unused rt_ifp,rt_ifa,rt_gateway,rt_mtu rte fields.Alexander V. Chernikov2020-05-041-58/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | After converting routing subsystem customers to use nexthop objects defined in r359823, some fields in struct rtentry became unused. This commit removes rt_ifp, rt_ifa, rt_gateway and rt_mtu from struct rtentry along with the code initializing and updating these fields. Cleanup of the remaining fields will be addressed by D24669. This commit also changes the implementation of the RTM_CHANGE handling. Old implementation tried to perform the whole operation under radix WLOCK, resulting in slow performance and hacks like using RTF_RNH_LOCKED flag. New implementation looks up the route nexthop under radix RLOCK, creates new nexthop and tries to update rte nhop pointer. Only last part is done under WLOCK. In the hypothetical scenarious where multiple rtsock clients repeatedly issue RTM_CHANGE requests for the same route, route may get updated between read and update operation. This is addressed by retrying the operation multiple (3) times before returning failure back to the caller. Differential Revision: https://reviews.freebsd.org/D24666 Notes: svn path=/head/; revision=360629
* Step 4.2: start divorce of M_EXT and M_EXTPGGleb Smirnoff2020-05-032-6/+9
| | | | | | | | | | | | | They have more differencies than similarities. For now there is lots of code that would check for M_EXT only and work correctly on M_EXTPG buffers, so still carry M_EXT bit together with M_EXTPG. However, prepare some code for explicit check for M_EXTPG. Reviewed by: gallatin Differential Revision: https://reviews.freebsd.org/D24598 Notes: svn path=/head/; revision=360583
* Step 4.1: mechanically rename M_NOMAP to M_EXTPGGleb Smirnoff2020-05-032-5/+5
| | | | | | | | Reviewed by: gallatin Differential Revision: https://reviews.freebsd.org/D24598 Notes: svn path=/head/; revision=360581
* Step 3: anonymize struct mbuf_ext_pgs and move all its fields into mbufGleb Smirnoff2020-05-032-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | within m_epg namespace. All edits except the 'struct mbuf' declaration and mb_dupcl() were done mechanically with sed: s/->m_ext_pgs.nrdy/->m_epg_nrdy/g s/->m_ext_pgs.hdr_len/->m_epg_hdrlen/g s/->m_ext_pgs.trail_len/->m_epg_trllen/g s/->m_ext_pgs.first_pg_off/->m_epg_1st_off/g s/->m_ext_pgs.last_pg_len/->m_epg_last_len/g s/->m_ext_pgs.flags/->m_epg_flags/g s/->m_ext_pgs.record_type/->m_epg_record_type/g s/->m_ext_pgs.enc_cnt/->m_epg_enc_cnt/g s/->m_ext_pgs.tls/->m_epg_tls/g s/->m_ext_pgs.so/->m_epg_so/g s/->m_ext_pgs.seqno/->m_epg_seqno/g s/->m_ext_pgs.stailq/->m_epg_stailq/g Reviewed by: gallatin Differential Revision: https://reviews.freebsd.org/D24598 Notes: svn path=/head/; revision=360579
* Introduce a lower bound of 2 MSS to TCP Cubic.Richard Scheffenegger2020-04-301-4/+7
| | | | | | | | | | | | | | | | | | | Running TCP Cubic together with ECN could end up reducing cwnd down to 1 byte, if the receiver continously sets the ECE flag, resulting in very poor transmission speeds. In line with RFC6582 App. B, a lower bound of 2 MSS is introduced, as well as a typecast to prevent any potential integer overflows during intermediate calculation steps of the adjusted cwnd. Reported by: Cheng Cui Reviewed by: tuexen (mentor) Approved by: tuexen (mentor) MFC after: 2 weeks Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D23353 Notes: svn path=/head/; revision=360491
* Prevent premature shrinking of the scaled receive windowRichard Scheffenegger2020-04-293-3/+12
| | | | | | | | | | | | | | | | | which can cause a TCP client to use invalid or stale TCP sequence numbers for ACK packets. Packets with old sequence numbers are ignored and not used to update the send window size. This might cause the TCP session to hang indefinitely under some circumstances. Reported by: Cui Cheng Reviewed by: tuexen (mentor), rgrimes (mentor) Approved by: tuexen (mentor), rgrimes (mentor) MFC after: 3 weeks Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D24515 Notes: svn path=/head/; revision=360479
* Correctly set up the initial TCP congestion window in all cases,Richard Scheffenegger2020-04-293-18/+31
| | | | | | | | | | | | | | | | | | | by not including the SYN bit sequence space in cwnd related calculations. Snd_und is adjusted explicitly in all cases, outside the cwnd update, instead. This fixes an off-by-one conformance issue with regular TCP sessions not using Appropriate Byte Counting (RFC3465), sending one more packet during the initial window than expected. PR: 235256 Reviewed by: tuexen (mentor), rgrimes (mentor) Approved by: tuexen (mentor), rgrimes (mentor) MFC after: 3 weeks Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D19000 Notes: svn path=/head/; revision=360477
* Move route_temporal.c and route_var.h to net/route.Alexander V. Chernikov2020-04-282-2/+2
| | | | | | | | | | | | Nexthop objects implementation, defined in r359823, introduced sys/net/route directory intended to hold all routing-related code. Move recently-introduced route_temporal.c and private route_var.h header there. Differential Revision: https://reviews.freebsd.org/D24597 Notes: svn path=/head/; revision=360449
* Convert rtalloc_mpath_fib() users to the new KPI.Alexander V. Chernikov2020-04-282-13/+10
| | | | | | | | | | | | | | | New fib[46]_lookup() functions support multipath transparently. Given that, switch the last rtalloc_mpath_fib() calls to dib4_lookup() and eliminate the function itself. Note: proper flowid generation (especially for the outbound traffic) is a bigger topic and will be handled in a separate review. This change leaves flowid generation intact. Differential Revision: https://reviews.freebsd.org/D24595 Notes: svn path=/head/; revision=360431
* Eliminate now-unused parts of old routing KPI.Alexander V. Chernikov2020-04-282-14/+0
| | | | | | | | | | | | r360292 switched most of the remaining routing customers to a new KPI, leaving a bunch of wrappers for old routing lookup functions unused. Remove them from the tree as a part of routing cleanup. Differential Revision: https://reviews.freebsd.org/D24569 Notes: svn path=/head/; revision=360430
* Initial support for kernel offload of TLS receive.John Baldwin2020-04-276-5/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | - Add a new TCP_RXTLS_ENABLE socket option to set the encryption and authentication algorithms and keys as well as the initial sequence number. - When reading from a socket using KTLS receive, applications must use recvmsg(). Each successful call to recvmsg() will return a single TLS record. A new TCP control message, TLS_GET_RECORD, will contain the TLS record header of the decrypted record. The regular message buffer passed to recvmsg() will receive the decrypted payload. This is similar to the interface used by Linux's KTLS RX except that Linux does not return the full TLS header in the control message. - Add plumbing to the TOE KTLS interface to request either transmit or receive KTLS sessions. - When a socket is using receive KTLS, redirect reads from soreceive_stream() into soreceive_generic(). - Note that this interface is currently only defined for TLS 1.1 and 1.2, though I believe we will be able to reuse the same interface and structures for 1.3. Notes: svn path=/head/; revision=360408
* Add the initial sequence number to the TLS enable socket option.John Baldwin2020-04-271-2/+32
| | | | | | | | | | | This will be needed for KTLS RX. Reviewed by: gallatin Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D24451 Notes: svn path=/head/; revision=360402
* This change does a small prepratory step in getting theRandall Stewart2020-04-274-4/+101
| | | | | | | | | | latest rack and bbr in from the NF repo. When those come in the OOB data handling will be fixed where Skyzaller crashes. Differential Revision: https://reviews.freebsd.org/D24575 Notes: svn path=/head/; revision=360385
* Convert debugnet to the new routing KPI.Alexander V. Chernikov2020-04-262-0/+44
| | | | | | | | | | | | | | | | Introduce new fib[46]_lookup_debugnet() functions serving as a special interface for the crash-time operations. Underlying implementation will try to return lookup result if datastructures are not corrupted, avoding locking. Convert debugnet to use fib4_lookup_debugnet() and switch it to use nexthops instead of rtentries. Reviewed by: cem Differential Revision: https://reviews.freebsd.org/D24555 Notes: svn path=/head/; revision=360349
* Fix order of arguments in fib[46]_lookup calls in SCTP.Alexander V. Chernikov2020-04-261-2/+2
| | | | | | | | | | | | | | r360292 introduced the wrong order, resulting in returned nhops not being referenced, despite the fact that references were requested. That lead to random GPF after using SCTP sockets. Special defined macro like IPV[46]_SCOPE_GLOBAL will be introduced soon to reduce the chance of putting arguments in wrong order. Reported-by: syzbot+5c813c01096363174684@syzkaller.appspotmail.com Notes: svn path=/head/; revision=360337
* Fix LINT build #2 after r360292.Alexander V. Chernikov2020-04-252-5/+6
| | | | | | | Pointyhat to: melifaro Notes: svn path=/head/; revision=360296
* Fix LINT build broken by r360292.Alexander V. Chernikov2020-04-251-0/+1
| | | | Notes: svn path=/head/; revision=360295
* Convert route caching to nexthop caching.Alexander V. Chernikov2020-04-2515-152/+157
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This change is build on top of nexthop objects introduced in r359823. Nexthops are separate datastructures, containing all necessary information to perform packet forwarding such as gateway interface and mtu. Nexthops are shared among the routes, providing more pre-computed cache-efficient data while requiring less memory. Splitting the LPM code and the attached data solves multiple long-standing problems in the routing layer, drastically reduces the coupling with outher parts of the stack and allows to transparently introduce faster lookup algorithms. Route caching was (re)introduced to minimise (slow) routing lookups, allowing for notably better performance for large TCP senders. Caching works by acquiring rtentry reference, which is protected by per-rtentry mutex. If the routing table is changed (checked by comparing the rtable generation id) or link goes down, cache record gets withdrawn. Nexthops have the same reference counting interface, backed by refcount(9). This change merely replaces rtentry with the actual forwarding nextop as a cached object, which is mostly mechanical. Other moving parts like cache cleanup on rtable change remains the same. Differential Revision: https://reviews.freebsd.org/D24340 Notes: svn path=/head/; revision=360292
* Unbreak LINT-NOINET[6] builds broken in r360191.Alexander V. Chernikov2020-04-231-1/+9
| | | | | | | Reported by: np Notes: svn path=/head/; revision=360217
* Improve input validation when processing AUTH chunks.Michael Tuexen2020-04-221-7/+9
| | | | | | | | | | | Thanks to Natalie Silvanovich from Google for finding and reporting the issue found by her in the SCTP userland stack. MFC after: 3 days X-MFC with: https://svnweb.freebsd.org/changeset/base/360193 Notes: svn path=/head/; revision=360209
* Improve input validation when processing AUTH chunks.Michael Tuexen2020-04-221-2/+5
| | | | | | | | | | Thanks to Natalie Silvanovich from Google for finding and reporting the issue found by her in the SCTP userland stack. MFC after: 3 days Notes: svn path=/head/; revision=360193
* Convert TOE routing lookups to the new routing KPI.Alexander V. Chernikov2020-04-223-12/+24
| | | | | | | | Reviewed by: np Differential Revision: https://reviews.freebsd.org/D24388 Notes: svn path=/head/; revision=360191
* revert rS360143 - Correctly set up initial cwndRichard Scheffenegger2020-04-223-18/+17
| | | | | | | | | | | due to syzkaller panics found Reported by: tuexen Approved by: tuexen (mentor) Sponsored by: NetApp, Inc. Notes: svn path=/head/; revision=360180
* Correctly set up the initial TCP congestion windowRichard Scheffenegger2020-04-213-17/+18
| | | | | | | | | | | | | | | | | | | in all cases, by adjust snd_una right after the connection initialization, to include the one byte in sequence space occupied by the SYN bit. This does not change the regular ACK processing, while making the BYTES_THIS_ACK macro to work properly. PR: 235256 Reviewed by: tuexen (mentor), rgrimes (mentor) Approved by: tuexen (mentor), rgrimes (mentor) MFC after: 2 weeks Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D19000 Notes: svn path=/head/; revision=360143
* Avoid calling protocol drain routines more than once per reclamation event.Jonathan T. Looney2020-04-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | mb_reclaim() calls the protocol drain routines for each protocol in each domain. Some protocols exist in more than one domain and share drain routines. In the case of SCTP, it also uses the same drain routine for its SOCK_SEQPACKET and SOCK_STREAM entries in the same domain. On systems with INET, INET6, and SCTP all defined, mb_reclaim() calls sctp_drain() four times. On systems with INET and INET6 defined, mb_reclaim() calls tcp_drain() twice. mb_reclaim() is the only in-tree caller of the pr_drain protocol entry. Eliminate this duplication by ensuring that each pr_drain routine is only specified for one protocol entry in one domain. Reviewed by: tuexen MFC after: 2 weeks Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D24418 Notes: svn path=/head/; revision=360020
* Add nhop parameter to rti_filter callback.Alexander V. Chernikov2020-04-161-3/+4
| | | | | | | | | | | | | | | | | | | | One of the goals of the new routing KPI defined in r359823 is to entirely hide`struct rtentry` from the consumers. It will allow to improve routing subsystem internals and deliver more features much faster. This change is one of the ongoing changes to eliminate direct struct rtentry field accesses. Additionally, with the followup multipath changes, single rtentry can point to multiple nexthops. With that in mind, convert rti_filter callback used when traversing the routing table to accept pair (rt, nhop) instead of nexthop. Reviewed by: ae Differential Revision: https://reviews.freebsd.org/D24440 Notes: svn path=/head/; revision=360014
* Reduce default TCP delayed ACK timeout to 40ms.Richard Scheffenegger2020-04-161-1/+1
| | | | | | | | | | | Reviewed by: kbowling, tuexen Approved by: tuexen (mentor) MFC after: 2 weeks Sponsored by: NetApp, Inc. Differential Revision: https://reviews.freebsd.org/D23281 Notes: svn path=/head/; revision=360010
* Convert IP/IPv6 forwarding, ICMP processing and IP PCB laddr selection toAlexander V. Chernikov2020-04-144-58/+53
| | | | | | | | | | the new routing KPI. Reviewed by: ae Differential Revision: https://reviews.freebsd.org/D24245 Notes: svn path=/head/; revision=359942
* Improve the TCP blackhole detection. The principle is to reduce theMichael Tuexen2020-04-142-13/+39
| | | | | | | | | | | | | | | | MSS in two steps and try each candidate two times. However, if two candidates are the same (which is the case in TCP/IPv6), this candidate was tested four times. This patch ensures that each candidate actually reduced the MSS and is only tested 2 times. This reduces the time window of missclassifying a temporary outage as an MTU issue. Reviewed by: jtl MFC after: 1 week Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D24308 Notes: svn path=/head/; revision=359926
* KTLS: Re-work unmapped mbufs to carry ext_pgs in the mbuf itself.Andrew Gallatin2020-04-142-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While the original implementation of unmapped mbufs was a large step forward in terms of reducing cache misses by enabling mbufs to carry more than a single page for sendfile, they are rather cache unfriendly when accessing the ext_pgs metadata and data. This is because the ext_pgs part of the mbuf is allocated separately, and almost guaranteed to be cold in cache. This change takes advantage of the fact that unmapped mbufs are never used at the same time as pkthdr mbufs. Given this fact, we can overlap the ext_pgs metadata with the mbuf pkthdr, and carry the ext_pgs meta directly in the mbuf itself. Similarly, we can carry the ext_pgs data (TLS hdr/trailer/array of pages) directly after the existing m_ext. In order to be able to carry 5 pages (which is the minimum required for a 16K TLS record which is not perfectly aligned) on LP64, I've had to steal ext_arg2. The only user of this in the xmit path is sendfile, and I've adjusted it to use arg1 when using unmapped mbufs. This change is almost entirely mechanical, except that we change mb_alloc_ext_pgs() to no longer allow allocating pkthdrs, the change to avoid ext_arg2 as mentioned above, and the removal of the ext_pgs zone, This change saves roughly 2% "raw" CPU (~59% -> 57%), or over 3% "scaled" CPU on a Netflix 100% software kTLS workload at 90+ Gb/s on Broadwell Xeons. In a follow-on commit, I plan to remove some hacks to avoid access ext_pgs fields of mbufs, since they will now be in cache. Many thanks to glebius for helping to make this better in the Netflix tree. Reviewed by: hselasky, jhb, rrs, glebius (early version) Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D24213 Notes: svn path=/head/; revision=359919
* Plug netmask NULL check during route addition causing kernel panic.Alexander V. Chernikov2020-04-141-1/+2
| | | | | | | | | This bug was introduced by the r359823. Reported by: hselasky Notes: svn path=/head/; revision=359917
* carp: Widen epoch coverageKristof Provost2020-04-121-5/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix panics related to calling code which expects to be running inside the NET_EPOCH from outside that epoch. This leads to panics (with INVARIANTS) such as this one: panic: Assertion in_epoch(net_epoch_preempt) failed at /usr/src/sys/netinet/if_ether.c:373 cpuid = 7 time = 1586095719 KDB: stack backtrace: db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xfffffe0090819700 vpanic() at vpanic+0x182/frame 0xfffffe0090819750 panic() at panic+0x43/frame 0xfffffe00908197b0 arprequest_internal() at arprequest_internal+0x59e/frame 0xfffffe00908198c0 arp_announce_ifaddr() at arp_announce_ifaddr+0x20/frame 0xfffffe00908198e0 carp_master_down_locked() at carp_master_down_locked+0x10d/frame 0xfffffe0090819910 carp_master_down() at carp_master_down+0x79/frame 0xfffffe0090819940 softclock_call_cc() at softclock_call_cc+0x13f/frame 0xfffffe00908199f0 softclock() at softclock+0x7c/frame 0xfffffe0090819a20 ithread_loop() at ithread_loop+0x279/frame 0xfffffe0090819ab0 fork_exit() at fork_exit+0x80/frame 0xfffffe0090819af0 fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe0090819af0 --- trap 0, rip = 0, rsp = 0, rbp = 0 --- Widen the NET_EPOCH to cover the relevant (callback / task) code. Differential Revision: https://reviews.freebsd.org/D24302 Notes: svn path=/head/; revision=359827
* Introduce nexthop objects and new routing KPI.Alexander V. Chernikov2020-04-123-35/+231
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the foundational change for the routing subsytem rearchitecture. More details and goals are available in https://reviews.freebsd.org/D24141 . This patch introduces concept of nexthop objects and new nexthop-based routing KPI. Nexthops are objects, containing all necessary information for performing the packet output decision. Output interface, mtu, flags, gw address goes there. For most of the cases, these objects will serve the same role as the struct rtentry is currently serving. Typically there will be low tens of such objects for the router even with multiple BGP full-views, as these objects will be shared between routing entries. This allows to store more information in the nexthop. New KPI: struct nhop_object *fib4_lookup(uint32_t fibnum, struct in_addr dst, uint32_t scopeid, uint32_t flags, uint32_t flowid); struct nhop_object *fib6_lookup(uint32_t fibnum, const struct in6_addr *dst6, uint32_t scopeid, uint32_t flags, uint32_t flowid); These 2 function are intended to replace all all flavours of <in_|in6_>rtalloc[1]<_ign><_fib>, mpath functions and the previous fib[46]-generation functions. Upon successful lookup, they return nexthop object which is guaranteed to exist within current NET_EPOCH. If longer lifetime is desired, one can specify NHR_REF as a flag and get a referenced version of the nexthop. Reference semantic closely resembles rtentry one, allowing sed-style conversion. Additionally, another 2 functions are introduced to support uRPF functionality inside variety of our firewalls. Their primary goal is to hide the multipath implementation details inside the routing subsystem, greatly simplifying firewalls implementation: int fib4_lookup_urpf(uint32_t fibnum, struct in_addr dst, uint32_t scopeid, uint32_t flags, const struct ifnet *src_if); int fib6_lookup_urpf(uint32_t fibnum, const struct in6_addr *dst6, uint32_t scopeid, uint32_t flags, const struct ifnet *src_if); All functions have a separate scopeid argument, paving way to eliminating IPv6 scope embedding and allowing to support IPv4 link-locals in the future. Structure changes: * rtentry gets new 'rt_nhop' pointer, slightly growing the overall size. * rib_head gets new 'rnh_preadd' callback pointer, slightly growing overall sz. Old KPI: During the transition state old and new KPI will coexists. As there are another 4-5 decent-sized conversion patches, it will probably take a couple of weeks. To support both KPIs, fields not required by the new KPI (most of rtentry) has to be kept, resulting in the temporary size increase. Once conversion is finished, rtentry will notably shrink. More details: * architectural overview: https://reviews.freebsd.org/D24141 * list of the next changes: https://reviews.freebsd.org/D24232 Reviewed by: ae,glebius(initial version) Differential Revision: https://reviews.freebsd.org/D24232 Notes: svn path=/head/; revision=359823
* Revert https://svnweb.freebsd.org/changeset/base/359809Michael Tuexen2020-04-121-2/+0
| | | | | | | | | | | | | | | The intended change was sp->next.tqe_next = NULL; sp->next.tqe_prev = NULL; which doesn't fix the issue I'm seeing and the committed fix is not the intended fix due to copy-and-paste. Thanks a lot to Conrad Meyer for making me aware of the problem. Reported by: cem Notes: svn path=/head/; revision=359822
* Zero out pointers for consistency.Michael Tuexen2020-04-111-0/+2
| | | | | | | | | This was found by running syzkaller on an INVARIANTS kernel. MFC after: 3 days Notes: svn path=/head/; revision=359809
* Remove per-AF radix_mpath initializtion functions.Alexander V. Chernikov2020-04-112-7/+5
| | | | | | | | | | | Split their functionality by moving random seed allocation to SYSINIT and calling (new) generic multipath function from standard IPv4/IPv5 RIB init handlers. Differential Revision: https://reviews.freebsd.org/D24356 Notes: svn path=/head/; revision=359797
* Fix copyright year and eliminate the obsolete all rights reserved line.Warner Losh2020-04-082-4/+2
| | | | | | | Reviewed by: rrs@ Notes: svn path=/head/; revision=359729
* Do more argument validation under INVARIANTS when starting/stoppingMichael Tuexen2020-04-061-2/+13
| | | | | | | | | an SCTP timer. MFC after: 1 week Notes: svn path=/head/; revision=359657
* Use interface fib for proxyarp checks.Alexander V. Chernikov2020-04-021-5/+9
| | | | | | | | | | | | | Before the change, proxyarp checks for src and dst addresses were performed using default fib, breaking multi-fib scenario. PR: 245181 Submitted by: Scott Aitken (original version) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D24244 Notes: svn path=/head/; revision=359580
* Allow the TCP backhole detection to be disabled at all, enabled onlyMichael Tuexen2020-03-313-12/+27
| | | | | | | | | | | | | | | for IPv4, enabled only for IPv6, and enabled for IPv4 and IPv6. The current blackhole detection might classify a temporary outage as an MTU issue and reduces permanently the MSS. Since the consequences of such a reduction due to a misclassification are much more drastically for IPv4 than for IPv6, allow the administrator to enable it for IPv6 only. Reviewed by: bcr@ (man page), Richard Scheffenegger Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D24219 Notes: svn path=/head/; revision=359487
* Remove the "config" taskqgroup and its KPIs.Mark Johnston2020-03-301-18/+10
| | | | | | | | | | | Equivalent functionality is already provided by taskqueue(9), just use that instead. MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=359438
* Small cleanup by using a variable just assigned.Michael Tuexen2020-03-281-2/+2
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=359410
* Handle integer overflows correctly when converting msecs and secs toMichael Tuexen2020-03-288-59/+134
| | | | | | | | | | | | | ticks and vice versa. These issues were caught by recently added panic() calls on INVARIANTS systems. Reported by: syzbot+b44787b4be7096cd1590@syzkaller.appspotmail.com Reported by: syzbot+35f82d22805c1e899685@syzkaller.appspotmail.com MFC after: 1 week Notes: svn path=/head/; revision=359405
* sys/netinet: remove spurious doubled ;sEd Maste2020-03-272-2/+2
| | | | Notes: svn path=/head/; revision=359381
* Some more uint32_t cleanups, no functional change.Michael Tuexen2020-03-273-12/+11
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=359379
* Use uint32_t where it is expected to be used. No functional change.Michael Tuexen2020-03-272-7/+7
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=359357
* Remove an optimization, which was incorrect a couple of times andMichael Tuexen2020-03-251-21/+3
| | | | | | | | | | | therefore doesn't seem worth to be there. In this case COOKIE where not retransmitted anymore, when the socket was already closed. MFC after: 1 week Notes: svn path=/head/; revision=359306
* Improve consistency in debug output.Michael Tuexen2020-03-251-13/+13
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=359305
* Revert https://svnweb.freebsd.org/changeset/base/357829Michael Tuexen2020-03-251-25/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces a regression reported by koobs@ when running a pyhton test suite on a loaded system. This patch resulted in a failing accept() call, when the association was setup and gracefully shutdown by the peer before accept was called. So the following packetdrill script would fail: +0.0 socket(..., SOCK_STREAM, IPPROTO_SCTP) = 3 +0.0 bind(3, ..., ...) = 0 +0.0 listen(3, 1) = 0 +0.0 < sctp: INIT[flgs=0, tag=1, a_rwnd=15000, os=1, is=1, tsn=1] +0.0 > sctp: INIT_ACK[flgs=0, tag=2, a_rwnd=..., os=..., is=..., tsn=1, ...] +0.1 < sctp: COOKIE_ECHO[flgs=0, len=..., val=...] +0.0 > sctp: COOKIE_ACK[flgs=0] +0.0 < sctp: DATA[flgs=BE, len=116, tsn=1, sid=0, ssn=0, ppid=0] +0.0 > sctp: SACK[flgs=0, cum_tsn=1, a_rwnd=..., gaps=[], dups=[]] +0.0 < sctp: SHUTDOWN[flgs=0, cum_tsn=0] +0.0 > sctp: SHUTDOWN_ACK[flgs=0] +0.0 < sctp: SHUTDOWN_COMPLETE[flgs=0] +0.0 accept(3, ..., ...) = 4 +0.0 close(3) = 0 +0.0 recv(4, ..., 4096, 0) = 100 +0.0 recv(4, ..., 4096, 0) = 0 +0.0 close(4) = 0 Reported by: koops@ Notes: svn path=/head/; revision=359302
* Use consistent debug output.Michael Tuexen2020-03-251-5/+5
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=359301