1. 09 Dec, 2022 4 commits
    • Yevgeny Kliteynik's avatar
      net/mlx5: DR, Rework is_fw_table function · 0a8c20e2
      Yevgeny Kliteynik authored
      This patch handles the following two changes w.r.t. is_fw_table function:
      
      1. When SW steering is asked to create/destroy FW table, we allow for
      creation/destruction of only termination tables. Rename mlx5_dr_is_fw_table
      both to comply with the static function naming and to reflect that we're
      actually checking for FW termination table.
      
      2. When the action 'go to flow table' is created, the destination flow
      table can be any FW table, not only termination table. Adding function
      to check if the dest table is FW table. This function will also be used
      by the later creation of range match action, so putting it the header file.
      Signed-off-by: default avatarYevgeny Kliteynik <kliteyn@nvidia.com>
      Reviewed-by: default avatarAlex Vesker <valex@nvidia.com>
      Reviewed-by: default avatarMark Bloch <mbloch@nvidia.com>
      Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
      0a8c20e2
    • Yevgeny Kliteynik's avatar
      net/mlx5: DR, Add functions to create/destroy MATCH_DEFINER general object · e046b86e
      Yevgeny Kliteynik authored
      SW steering is able to match only on the exact values of the packet fields,
      as requested by the user: the user provides mask for the fields that are of
      interest, and the exact values to be matched on when the traffic is handled.
      
      Match Definer is a general FW object that defines which fields in the
      packet will be referenced by the mask and tag of each STE. Match definer ID
      is part of STE fields, and it defines how the HW needs to interpret the STE's
      mask/tag values.
      Till now SW steering used the definers that were managed by FW and implemented
      the STE layout as described by the HW spec. Now that we're adding a new type
      of STE, SW steering needs to define for the HW how it should interpret this
      new STE's layout.
      This is done with a programmable match definer.
      
      The programmable definer allows to selects which fields will be included in
      the definer, and their layout: it has up to 9 DW selectors 8 Byte selectors.
      Each selector indicates a DW/Byte worth of fields out of the table that
      is defined by HW spec by referencing the offset of the required DW/Byte.
      
      This patch adds dr_cmd function to create and destroy MATCH_DEFINER
      general object.
      Signed-off-by: default avatarYevgeny Kliteynik <kliteyn@nvidia.com>
      Reviewed-by: default avatarAlex Vesker <valex@nvidia.com>
      Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
      e046b86e
    • Yevgeny Kliteynik's avatar
      net/mlx5: fs, add match on ranges API · 38bf24c3
      Yevgeny Kliteynik authored
      Range is a new flow destination type which allows matching on
      a range of values instead of matching on a specific value.
      
      Range flow destination has the following fields:
       - hit_ft: flow table to forward the traffic in case of hit
       - miss_ft: flow table to forward the traffic in case of miss
       - field: which packet characteristic to match on
       - min: minimal value for the selected field
       - max: maximal value for the selected field
      
      Note:
       - In order to match, the value in the packet should meet
         the following criteria: min <= value < max
       - Currently, the only supported field type is L2 packet length
      Signed-off-by: default avatarYevgeny Kliteynik <kliteyn@nvidia.com>
      Reviewed-by: default avatarAlex Vesker <valex@nvidia.com>
      Reviewed-by: default avatarMark Bloch <mbloch@nvidia.com>
      Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
      38bf24c3
    • Yevgeny Kliteynik's avatar
      net/mlx5: mlx5_ifc updates for MATCH_DEFINER general object · f1543c7a
      Yevgeny Kliteynik authored
      Update full structure of match definer and add an ID of
      the SELECT match definer type.
      Signed-off-by: default avatarYevgeny Kliteynik <kliteyn@nvidia.com>
      Reviewed-by: default avatarAlex Vesker <valex@nvidia.com>
      Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
      f1543c7a
  2. 08 Dec, 2022 36 commits