[G/master-next] net/mlx5e: backport kTLS RX support from Linux 5.9

Paolo Pisati paolo.pisati at canonical.com
Mon Sep 28 09:40:08 UTC 2020


BugLink: https://bugs.launchpad.net/bugs/1895947

All patches come from linux-next and apply cleanly on top of
groovy/master-next / v5.8.11 (except for "4517c79f8895 net/mlx5e: kTLS, Add kTLS
RX HW offload support" that required some context change in one hunk).

The code changes are limited to the mellanox/mlx5 driver except for these 2 commits
that apply to net/tls code (in reverse order):

1) 0ffec9d5375c 'Revert "net/tls: Add force_resync for driver resync"'

This commit reverts some opt-in code specifically written for net/mlx5e (quoting
the commit msg of the reverted commit):

    This patch adds a field to the tls rx offload context which enables
    drivers to force a send_resync call.
    
    This field can be used by drivers to request a resync at the next
    possible tls record.
    ...
    A following series for mlx5e ConnectX-6DX TLS RX offload support will
    use this mechanism.

but since it was never really used, it was reverted upstream and replaced by the
following commit:

2) e4c708607522 'net/tls: Add asynchronous resync'

that adds a driver asynchronous mechanism to request a resync and is only
exploited by net/mlx5e - unless a driver is patched to use it, it won't be be
exercised.

Proposing for inclusion in Groovy/master-next.

The following changes since commit 2af8f501bbca48f112bd9255efb97579b582cd19:

  Linux 5.8.11 (2020-09-23 17:49:24 +0200)

are available in the Git repository at:

  git://git.launchpad.net/~p-pisati/ubuntu/+source/linux master-lp1895947

for you to fetch changes up to 6f7094bb29c598ff5cb39aedf2555f34a4479ed9:

  net/mlx5e: kTLS, Avoid kzalloc(GFP_KERNEL) under spinlock (2020-09-24 17:35:11 +0200)

----------------------------------------------------------------
Boris Pismenny (3):
      net/mlx5e: Receive flow steering framework for accelerated TCP flows
      Revert "net/tls: Add force_resync for driver resync"
      net/tls: Add asynchronous resync

Colin Ian King (1):
      net/mlx5e: fix memory leak of tls

Maxim Mikityanskiy (2):
      net/mlx5e: Use RCU to protect rq->xdp_prog
      net/mlx5e: Use synchronize_rcu to sync with NAPI

Saeed Mahameed (5):
      net/mlx5e: API to manipulate TTC rules destinations
      net/mlx5e: Fix build break when CONFIG_XPS is not set
      net/mlx5e: kTLS, Add missing dma_unmap in RX resync
      net/mlx5e: kTLS, Fix leak on resync error flow
      net/mlx5e: kTLS, Avoid kzalloc(GFP_KERNEL) under spinlock

Tariq Toukan (14):
      net/mlx5: kTLS, Improve TLS params layout structures
      net/mlx5e: Turn XSK ICOSQ into a general asynchronous one
      net/mlx5e: Refactor build channel params
      net/mlx5e: Accel, Expose flow steering API for rules add/del
      net/mlx5e: kTLS, Improve TLS feature modularity
      net/mlx5e: kTLS, Use kernel API to extract private offload context
      net/mlx5e: kTLS, Add kTLS RX HW offload support
      net/mlx5e: kTLS, Add kTLS RX resync support
      net/mlx5e: kTLS, Add kTLS RX stats
      net/mlx5e: Increase Async ICO SQ size
      net/mlx5e: kTLS, Cleanup redundant capability check
      net/mlx5e: kTLS, Improve rx handler function call
      net/mlx5e: kTLS, Fix napi sync and possible use-after-free
      net/mlx5e: TLS, Do not expose FPGA TLS counter if not supported

 Documentation/networking/tls-offload.rst           |  18 +
 drivers/net/ethernet/mellanox/mlx5/core/Kconfig    |   1 +
 drivers/net/ethernet/mellanox/mlx5/core/Makefile   |   3 +-
 .../net/ethernet/mellanox/mlx5/core/accel/tls.h    |  19 +-
 drivers/net/ethernet/mellanox/mlx5/core/en.h       |  25 +-
 drivers/net/ethernet/mellanox/mlx5/core/en/fs.h    |  26 +-
 .../net/ethernet/mellanox/mlx5/core/en/params.h    |  22 +-
 drivers/net/ethernet/mellanox/mlx5/core/en/txrx.h  |  17 +-
 drivers/net/ethernet/mellanox/mlx5/core/en/xdp.c   |   2 +-
 .../net/ethernet/mellanox/mlx5/core/en/xsk/rx.c    |  14 +-
 .../net/ethernet/mellanox/mlx5/core/en/xsk/setup.c |  56 +-
 .../net/ethernet/mellanox/mlx5/core/en/xsk/tx.c    |  12 +-
 .../mellanox/mlx5/core/en_accel/en_accel.h         |  10 +
 .../ethernet/mellanox/mlx5/core/en_accel/fs_tcp.c  | 400 ++++++++++++
 .../ethernet/mellanox/mlx5/core/en_accel/fs_tcp.h  |  27 +
 .../ethernet/mellanox/mlx5/core/en_accel/ktls.c    | 123 ++--
 .../ethernet/mellanox/mlx5/core/en_accel/ktls.h    | 114 +---
 .../ethernet/mellanox/mlx5/core/en_accel/ktls_rx.c | 681 +++++++++++++++++++++
 .../ethernet/mellanox/mlx5/core/en_accel/ktls_tx.c | 206 ++++---
 .../mellanox/mlx5/core/en_accel/ktls_txrx.c        | 119 ++++
 .../mellanox/mlx5/core/en_accel/ktls_txrx.h        |  42 ++
 .../mellanox/mlx5/core/en_accel/ktls_utils.h       |  86 +++
 .../net/ethernet/mellanox/mlx5/core/en_accel/tls.c |  28 +-
 .../net/ethernet/mellanox/mlx5/core/en_accel/tls.h |  14 +-
 .../mellanox/mlx5/core/en_accel/tls_rxtx.c         |  34 +-
 .../mellanox/mlx5/core/en_accel/tls_rxtx.h         |  34 +-
 .../mellanox/mlx5/core/en_accel/tls_stats.c        |  12 +-
 drivers/net/ethernet/mellanox/mlx5/core/en_arfs.c  |  34 +-
 drivers/net/ethernet/mellanox/mlx5/core/en_fs.c    |  84 ++-
 drivers/net/ethernet/mellanox/mlx5/core/en_main.c  | 133 ++--
 drivers/net/ethernet/mellanox/mlx5/core/en_rx.c    |  53 +-
 drivers/net/ethernet/mellanox/mlx5/core/en_stats.c |  39 ++
 drivers/net/ethernet/mellanox/mlx5/core/en_stats.h |  25 +
 drivers/net/ethernet/mellanox/mlx5/core/en_tx.c    |   1 -
 drivers/net/ethernet/mellanox/mlx5/core/en_txrx.c  |  29 +-
 drivers/net/ethernet/mellanox/mlx5/core/fs_core.c  |   4 +-
 drivers/net/ethernet/mellanox/mlx5/core/fw.c       |   3 +-
 include/linux/mlx5/device.h                        |   9 +
 include/linux/mlx5/mlx5_ifc.h                      |   5 +-
 include/linux/mlx5/qp.h                            |   2 +-
 include/net/tls.h                                  |  34 +-
 net/tls/tls_device.c                               |  60 +-
 42 files changed, 2130 insertions(+), 530 deletions(-)
 create mode 100644 drivers/net/ethernet/mellanox/mlx5/core/en_accel/fs_tcp.c
 create mode 100644 drivers/net/ethernet/mellanox/mlx5/core/en_accel/fs_tcp.h
 create mode 100644 drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls_rx.c
 create mode 100644 drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls_txrx.c
 create mode 100644 drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls_txrx.h
 create mode 100644 drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls_utils.h
-- 
bye,
p.



More information about the kernel-team mailing list