Skip to content

Commit

Permalink
net/mlx5: DR, Add STE modify header actions per-device API
Browse files Browse the repository at this point in the history
Extend the STE context struct with per-device modify header actions.

Signed-off-by: Yevgeny Kliteynik <kliteyn@nvidia.com>
Reviewed-by: Saeed Mahameed <saeedm@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
  • Loading branch information
Yevgeny Kliteynik authored and Saeed Mahameed committed Jan 5, 2021
1 parent ad17dc8 commit 3ad5838
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions drivers/net/ethernet/mellanox/mlx5/core/steering/dr_ste.h
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,29 @@ struct mlx5dr_ste_ctx {
u8 *hw_ste_arr,
struct mlx5dr_ste_actions_attr *attr,
u32 *added_stes);
u32 modify_field_arr_sz;
const struct mlx5dr_ste_action_modify_field *modify_field_arr;
void (*set_action_set)(u8 *hw_action,
u8 hw_field,
u8 shifter,
u8 length,
u32 data);
void (*set_action_add)(u8 *hw_action,
u8 hw_field,
u8 shifter,
u8 length,
u32 data);
void (*set_action_copy)(u8 *hw_action,
u8 dst_hw_field,
u8 dst_shifter,
u8 dst_len,
u8 src_hw_field,
u8 src_shifter);
int (*set_action_decap_l3_list)(void *data,
u32 data_sz,
u8 *hw_action,
u32 hw_action_sz,
u16 *used_hw_action_num);
};

extern struct mlx5dr_ste_ctx ste_ctx_v0;
Expand Down

0 comments on commit 3ad5838

Please sign in to comment.