[PATCH rdma-next v1 00/15] ESP flow action support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Leon Romanovsky <leonro@xxxxxxxxxxxx>

Hi,

This series from Matan, Aviad and Boris reuses the ioctl()
infrastructure added in latest kernels and convert it from
"experimental" to be the "real" one.

Changelog:
  v0 -> v1:
   * Annotated code with various static/const attributes
   * Alignment left as is, no change to require 64bits
   * Use of u64_to_user_ptr() instead of _force
   * Change declaration of keymat and replay to use unions

Thanks

----------------------------------------------------------------------------
>From Matan:

Hi,

This series adds ESP flow action support for both uverbs and mlx5_ib driver.

Currently, when adding a flow steering rule, actions such as TAG or DROP
could be specified in the flow action specification.

However, some flow actions could be complex and needs to be shared
between several flow steering rules. Therefore, we add a new flow
actions mechanism. Flow actions are actions the user creates and are
given as handles for the flow steering rules (reference count is managed
appropriately).

We start with adding the ESP flow action, which supports both full
offload and inline crypto mode.

We currently only support AES_GCM crypto with bitmap replay protection.

These new create, modify and destroy flow_action_esp methods are
implemented using the new uverbs ioctl() infrastructure.

In order to do this, we add support for ENUM based attributes. These kind of
attributes let the user choose exactly one attribute out of a pre-defined group.
This is used for choosing the keymat and the replay protection algorithms.

Furthermore, the current mlx5 device works in a different way from
future devices. Thus, when creating the flow action, the user has to specify a
MLX5_IB_UAPI_FLOW_ACTION_FLAGS_REQUIRE_METADATA flag. This uses another
feature of the ioctl() infrastructure. The mlx5_ib driver creates its own
parsing tree and merge it with the common uverbs methods. This series also
includes the required bits for it.

ESP flow action is supported for both egress and ingress. Therefore, we
also add a flag for egress steering in our flow steering uverbs implementation.
Egress steering is currently only implemented for ESP flows.

In order to carry these actions only for ESP packets, we also add an ESP
match filter. Finally, we also add the required bits to support RSS for ESP
flows and query the feature's support.

Thanks

Aviad Yehezkel (3):
  IB/mlx5: Add implementation for create and destroy action_xfrm
  {net,IB}/mlx5: Add ipsec helper
  IB/mlx5: Add IPsec support for egress and ingress

Boris Pismenny (2):
  IB/mlx4: Check for egress flow steering
  IB/uverbs: Introduce egress flow steering

Matan Barak (10):
  IB/mlx5: Initialize the parsing tree root without the help of uverbs
  IB/uverbs: Add enum attribute type to ioctl() interface
  IB/uverbs: Refactor kern_spec_to_ib_spec_filter
  IB/uverbs: Add flow_action create and destroy verbs
  IB/uverbs: Add action_handle flow steering specification
  IB/uverbs: Add modify ESP flow_action
  IB/uverbs: Introduce ESP steering match filter
  IB/mlx5: Add modify_flow_action_esp verb
  IB/mlx5: Add information for querying IPsec capabilities
  IB/mlx5: Add ability to hash by IPSEC_SPI when creating a TIR

 drivers/infiniband/core/Makefile                   |   3 +-
 drivers/infiniband/core/uverbs.h                   |  19 +
 drivers/infiniband/core/uverbs_cmd.c               | 144 +++++--
 drivers/infiniband/core/uverbs_ioctl.c             |  39 +-
 drivers/infiniband/core/uverbs_std_types.c         |  24 +-
 .../infiniband/core/uverbs_std_types_flow_action.c | 435 +++++++++++++++++++++
 drivers/infiniband/hw/mlx4/main.c                  |   3 +
 drivers/infiniband/hw/mlx5/main.c                  | 361 ++++++++++++++++-
 drivers/infiniband/hw/mlx5/mlx5_ib.h               |  19 +
 drivers/infiniband/hw/mlx5/qp.c                    |  16 +-
 include/linux/mlx5/fs_helpers.h                    |   8 +
 include/rdma/ib_verbs.h                            | 102 ++++-
 include/rdma/uverbs_ioctl.h                        |  34 ++
 include/uapi/rdma/ib_user_ioctl_cmds.h             |  20 +
 include/uapi/rdma/ib_user_ioctl_verbs.h            |  59 +++
 include/uapi/rdma/ib_user_verbs.h                  |  31 ++
 include/uapi/rdma/mlx5-abi.h                       |  11 +-
 ...b_user_ioctl_verbs.h => mlx5_user_ioctl_cmds.h} |  17 +-
 ..._user_ioctl_verbs.h => mlx5_user_ioctl_verbs.h} |  14 +-
 include/uapi/rdma/rdma_user_ioctl_cmds.h           |   8 +-
 20 files changed, 1298 insertions(+), 69 deletions(-)
 create mode 100644 drivers/infiniband/core/uverbs_std_types_flow_action.c
 copy include/uapi/rdma/{ib_user_ioctl_verbs.h => mlx5_user_ioctl_cmds.h} (80%)
 copy include/uapi/rdma/{ib_user_ioctl_verbs.h => mlx5_user_ioctl_verbs.h} (82%)

--
2.14.3

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux