freebsd-skq/sbin/ifconfig
John Baldwin 521eac97f3 Support hardware rate limiting (pacing) with TLS offload.
- Add a new send tag type for a send tag that supports both rate
  limiting (packet pacing) and TLS offload (mostly similar to D22669
  but adds a separate structure when allocating the new tag type).

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

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

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

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

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

Reviewed by:	gallatin, hselasky
Relnotes:	yes
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D26691
2020-10-29 00:23:16 +00:00
..
tests
af_inet6.c Update for IETF draft-ietf-6man-ipv6only-flag. 2019-03-06 23:31:42 +00:00
af_inet.c ifconfig: eliminate trailing whitespace 2019-02-26 03:34:47 +00:00
af_link.c ifconfig(8): optimize -f ether:dash mode 2020-06-26 16:20:34 +00:00
af_nd6.c Update for IETF draft-ietf-6man-ipv6only-flag. 2019-03-06 23:31:42 +00:00
carp.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifbridge.c libifconfig: Add function to get bridge status 2020-07-01 02:32:41 +00:00
ifclone.c Add support for stacked VLANs (IEEE 802.1ad, AKA Q-in-Q). 2020-10-21 21:28:20 +00:00
ifconfig.8 Support hardware rate limiting (pacing) with TLS offload. 2020-10-29 00:23:16 +00:00
ifconfig.c Support hardware rate limiting (pacing) with TLS offload. 2020-10-29 00:23:16 +00:00
ifconfig.h Add support for stacked VLANs (IEEE 802.1ad, AKA Q-in-Q). 2020-10-21 21:28:20 +00:00
iffib.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifgif.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifgre.c Add GRE-in-UDP encapsulation support as defined in RFC8086. 2019-04-24 09:05:45 +00:00
ifgroup.c ifconfig: eliminate trailing whitespace 2019-02-26 03:34:47 +00:00
ifieee80211.c Add support for stacked VLANs (IEEE 802.1ad, AKA Q-in-Q). 2020-10-21 21:28:20 +00:00
ifipsec.c Update ifr_name before invoking IPSECSREQID ioctl, this fixes the case, 2018-09-22 16:30:48 +00:00
iflagg.c Fix for colliding change (r366917). 2020-10-22 10:36:16 +00:00
ifmac.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifmedia.c ifconfig: add report of the string from SIOCGIFDOWNREASON. 2019-09-17 18:51:10 +00:00
ifpfsync.c ifconfig: fix endianness bug displaying pfsync interfaces 2019-01-28 18:34:04 +00:00
ifvlan.c Add support for stacked VLANs (IEEE 802.1ad, AKA Q-in-Q). 2020-10-21 21:28:20 +00:00
ifvxlan.c Add support for stacked VLANs (IEEE 802.1ad, AKA Q-in-Q). 2020-10-21 21:28:20 +00:00
Makefile Move ifconfig SFP status functionality into libifconfig 2020-08-09 16:27:28 +00:00
Makefile.depend Update Makefile.depend files 2019-12-11 17:37:53 +00:00
Makefile.depend.options Add Makefile.depend.options 2019-12-11 17:37:37 +00:00
sfp.c Move ifconfig SFP status functionality into libifconfig 2020-08-09 16:27:28 +00:00