net/mlx5: wrap sampling actions per OS
authorOphir Munk <ophirmu@nvidia.com>
Sun, 3 Jan 2021 12:15:49 +0000 (12:15 +0000)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 8 Jan 2021 15:34:52 +0000 (16:34 +0100)
commitbd935fe3e624358d0980ed7f17863047ade07a8b
tree354fe74807f7828034732dd3d81763d67ff255a7
parentb689b00dd253356567c4d95f55921ce6c0e87d80
net/mlx5: wrap sampling actions per OS

Wrap glue calls dr_create_flow_action_sampler() and
dr_create_flow_action_dest_array() as OS-specific functions.
This is a follow up on
commit b293fbf9672b ("net/mlx5: add OS specific flow actions operations")

On Windows, the sampling actions wrappers currently return ENOTSUP.
Using configuration definitions HAVE_MLX5_DR_CREATE_ACTION_FLOW_SAMPLE and
HAVE_MLX5_DR_CREATE_ACTION_DEST_ARRAY the missing sampling DV structs
are added as stubs to windows/mlx5_glue.h file.

Signed-off-by: Ophir Munk <ophirmu@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
drivers/common/mlx5/windows/mlx5_glue.h
drivers/net/mlx5/linux/mlx5_flow_os.h
drivers/net/mlx5/mlx5_flow_dv.c
drivers/net/mlx5/windows/mlx5_flow_os.h