Skip to content

Commit

Permalink
Add mirror session congestion mode (#786)
Browse files Browse the repository at this point in the history
* Add mirror session congestion mode

Controls whether mirroring traffic can cause back pressure and packet
drop of the original traffic

* Fix indentation
  • Loading branch information
itaibaz authored and lguohan committed May 1, 2018
1 parent d98f846 commit 07c23b3
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions inc/saimirror.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,19 @@ typedef enum _sai_erspan_encapsulation_type_t

} sai_erspan_encapsulation_type_t;

/**
* @brief Mirror session congestion mode
*/
typedef enum _sai_mirror_session_congestion_mode_t
{
/** Mirroring traffic is independent from original traffic, original traffic not affected by congestion of mirroring traffic */
SAI_MIRROR_SESSION_CONGESTION_MODE_INDEPENDENT,

/** Mirroring traffic is correlated with original traffic, and can cause back pressure and discards of original traffic if there is congestion */
SAI_MIRROR_SESSION_CONGESTION_MODE_CORRELATED,

} sai_mirror_session_congestion_mode_t;

/**
* @brief SAI attributes for mirror session
*/
Expand Down Expand Up @@ -112,6 +125,15 @@ typedef enum _sai_mirror_session_attr_t
*/
SAI_MIRROR_SESSION_ATTR_SAMPLE_RATE,

/**
* @brief Controls whether mirroring traffic can cause back pressure and packet drop of the original traffic
*
* @type sai_mirror_session_congestion_mode_t
* @flags CREATE_AND_SET
* @default SAI_MIRROR_SESSION_CONGESTION_MODE_INDEPENDENT
*/
SAI_MIRROR_SESSION_ATTR_CONGESTION_MODE,

/**
* @brief Class-of-Service (Traffic Class)
*
Expand Down

0 comments on commit 07c23b3

Please sign in to comment.