From: Ivan Malov <ivan.ma...@oktetlabs.ru> Add MCDI-compatible enumeration for these fields and provide necessary mappings for them to be inserted directly into mask-value pairs buffer.
Signed-off-by: Ivan Malov <ivan.ma...@oktetlabs.ru> Signed-off-by: Andrew Rybchenko <arybche...@solarflare.com> Reviewed-by: Andy Moreton <amore...@xilinx.com> --- drivers/common/sfc_efx/base/efx.h | 4 ++++ drivers/common/sfc_efx/base/efx_mae.c | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/drivers/common/sfc_efx/base/efx.h b/drivers/common/sfc_efx/base/efx.h index 75edb59a49..30bd411843 100644 --- a/drivers/common/sfc_efx/base/efx.h +++ b/drivers/common/sfc_efx/base/efx.h @@ -4103,6 +4103,10 @@ typedef enum efx_mae_field_id_e { EFX_MAE_FIELD_ETHER_TYPE_BE, EFX_MAE_FIELD_ETH_SADDR_BE, EFX_MAE_FIELD_ETH_DADDR_BE, + EFX_MAE_FIELD_VLAN0_TCI_BE, + EFX_MAE_FIELD_VLAN0_PROTO_BE, + EFX_MAE_FIELD_VLAN1_TCI_BE, + EFX_MAE_FIELD_VLAN1_PROTO_BE, EFX_MAE_FIELD_NIDS } efx_mae_field_id_t; diff --git a/drivers/common/sfc_efx/base/efx_mae.c b/drivers/common/sfc_efx/base/efx_mae.c index 0cfa3f6c06..334b46630c 100644 --- a/drivers/common/sfc_efx/base/efx_mae.c +++ b/drivers/common/sfc_efx/base/efx_mae.c @@ -286,6 +286,10 @@ typedef enum efx_mae_field_cap_id_e { EFX_MAE_FIELD_ID_ETHER_TYPE_BE = MAE_FIELD_ETHER_TYPE, EFX_MAE_FIELD_ID_ETH_SADDR_BE = MAE_FIELD_ETH_SADDR, EFX_MAE_FIELD_ID_ETH_DADDR_BE = MAE_FIELD_ETH_DADDR, + EFX_MAE_FIELD_ID_VLAN0_TCI_BE = MAE_FIELD_VLAN0_TCI, + EFX_MAE_FIELD_ID_VLAN0_PROTO_BE = MAE_FIELD_VLAN0_PROTO, + EFX_MAE_FIELD_ID_VLAN1_TCI_BE = MAE_FIELD_VLAN1_TCI, + EFX_MAE_FIELD_ID_VLAN1_PROTO_BE = MAE_FIELD_VLAN1_PROTO, EFX_MAE_FIELD_CAP_NIDS } efx_mae_field_cap_id_t; @@ -331,6 +335,10 @@ static const efx_mae_mv_desc_t __efx_mae_action_rule_mv_desc_set[] = { EFX_MAE_MV_DESC(ETHER_TYPE_BE, EFX_MAE_FIELD_BE), EFX_MAE_MV_DESC(ETH_SADDR_BE, EFX_MAE_FIELD_BE), EFX_MAE_MV_DESC(ETH_DADDR_BE, EFX_MAE_FIELD_BE), + EFX_MAE_MV_DESC(VLAN0_TCI_BE, EFX_MAE_FIELD_BE), + EFX_MAE_MV_DESC(VLAN0_PROTO_BE, EFX_MAE_FIELD_BE), + EFX_MAE_MV_DESC(VLAN1_TCI_BE, EFX_MAE_FIELD_BE), + EFX_MAE_MV_DESC(VLAN1_PROTO_BE, EFX_MAE_FIELD_BE), #undef EFX_MAE_MV_DESC }; -- 2.17.1