Skip to content

[cherry-pick] Tunnel Scoped TC MAP and Remarking (#1413) #1451

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions inc/saiswitch.h
Original file line number Diff line number Diff line change
Expand Up @@ -514,6 +514,56 @@ typedef enum _sai_switch_tunnel_attr_t
*/
SAI_SWITCH_TUNNEL_ATTR_VXLAN_UDP_SPORT_MASK,

/**
* @brief Enable TC AND COLOR -> DSCP MAP on tunnel at encapsulation (access-to-network) node to remark the DSCP in tunnel header
*
* @type sai_object_id_t
* @flags CREATE_AND_SET
* @objects SAI_OBJECT_TYPE_QOS_MAP
* @allownull true
* @default SAI_NULL_OBJECT_ID
*/
SAI_SWITCH_TUNNEL_ATTR_ENCAP_QOS_TC_AND_COLOR_TO_DSCP_MAP,

/**
* @brief Enable TC -> Queue MAP on tunnel encap
*
* Map id = #SAI_NULL_OBJECT_ID to disable map on tunnel.
* Default no map, i.e. packets are queued with static mapping.
*
* @type sai_object_id_t
* @flags CREATE_AND_SET
* @objects SAI_OBJECT_TYPE_QOS_MAP
* @allownull true
* @default SAI_NULL_OBJECT_ID
*/
SAI_SWITCH_TUNNEL_ATTR_ENCAP_QOS_TC_TO_QUEUE_MAP,

/**
* @brief Enable DSCP -> TC MAP on tunnel at termination (Network-to-access) node.
*
* @type sai_object_id_t
* @flags CREATE_AND_SET
* @objects SAI_OBJECT_TYPE_QOS_MAP
* @allownull true
* @default SAI_NULL_OBJECT_ID
*/
SAI_SWITCH_TUNNEL_ATTR_DECAP_QOS_DSCP_TO_TC_MAP,

/**
* @brief Enable TC -> Priority Group MAP
*
* Map id = #SAI_NULL_OBJECT_ID to disable map on port.
* Default no map
*
* @type sai_object_id_t
* @flags CREATE_AND_SET
* @objects SAI_OBJECT_TYPE_QOS_MAP
* @allownull true
* @default SAI_NULL_OBJECT_ID
*/
SAI_SWITCH_TUNNEL_ATTR_DECAP_QOS_TC_TO_PRIORITY_GROUP_MAP,

/**
* @brief End of attributes
*/
Expand Down
52 changes: 52 additions & 0 deletions inc/saitunnel.h
Original file line number Diff line number Diff line change
Expand Up @@ -686,6 +686,56 @@ typedef enum _sai_tunnel_attr_t
*/
SAI_TUNNEL_ATTR_IPSEC_SA_PORT_LIST,

/**
* @brief Enable TC AND COLOR -> DSCP MAP on tunnel at encapsulation (access-to-network) node to remark the DSCP in tunnel header
*
* @type sai_object_id_t
* @flags CREATE_AND_SET
* @objects SAI_OBJECT_TYPE_QOS_MAP
* @allownull true
* @default SAI_NULL_OBJECT_ID
*/
SAI_TUNNEL_ATTR_ENCAP_QOS_TC_AND_COLOR_TO_DSCP_MAP,

/**
* @brief Enable TC -> Queue MAP on tunnel encap
*
* Map id = #SAI_NULL_OBJECT_ID to disable map on tunnel.
* Default no map, i.e. packets are queued with static mapping.
*
* @type sai_object_id_t
* @flags CREATE_AND_SET
* @objects SAI_OBJECT_TYPE_QOS_MAP
* @allownull true
* @default SAI_NULL_OBJECT_ID
*/
SAI_TUNNEL_ATTR_ENCAP_QOS_TC_TO_QUEUE_MAP,

/**
* @brief Enable DSCP -> TC MAP on tunnel at termination (Network-to-access) node. This map if configured overrides the port MAP
*
* @type sai_object_id_t
* @flags CREATE_AND_SET
* @objects SAI_OBJECT_TYPE_QOS_MAP
* @allownull true
* @default SAI_NULL_OBJECT_ID
*/
SAI_TUNNEL_ATTR_DECAP_QOS_DSCP_TO_TC_MAP,

/**
* @brief Enable TC -> Priority Group MAP. TC is derived from the tunnel MAP
*
* Map id = #SAI_NULL_OBJECT_ID to disable map on port.
* Default no map
*
* @type sai_object_id_t
* @flags CREATE_AND_SET
* @objects SAI_OBJECT_TYPE_QOS_MAP
* @allownull true
* @default SAI_NULL_OBJECT_ID
*/
SAI_TUNNEL_ATTR_DECAP_QOS_TC_TO_PRIORITY_GROUP_MAP,

/**
* @brief End of attributes
*/
Expand Down Expand Up @@ -1082,6 +1132,8 @@ typedef struct _sai_tunnel_api_t
sai_remove_tunnel_map_entry_fn remove_tunnel_map_entry;
sai_set_tunnel_map_entry_attribute_fn set_tunnel_map_entry_attribute;
sai_get_tunnel_map_entry_attribute_fn get_tunnel_map_entry_attribute;
sai_bulk_object_get_attribute_fn get_tunnels_attribute;
sai_bulk_object_set_attribute_fn set_tunnels_attribute;

} sai_tunnel_api_t;

Expand Down
1 change: 1 addition & 0 deletions inc/saitypes.h
Original file line number Diff line number Diff line change
Expand Up @@ -764,6 +764,7 @@ typedef struct _sai_acl_capability_t
* @passparam &sai_metadata_enum_sai_acl_action_type_t
*/
sai_s32_list_t action_list;

} sai_acl_capability_t;

/**
Expand Down