API Reference Manual  1.45.0
odp_tm_shaper_params_t Struct Reference

TM shaper parameters. More...

#include <traffic_mngr.h>

Data Fields

odp_tm_shaper_mode_t mode
 Shaper mode. More...
 
uint64_t commit_rate
 The committed information rate for this shaper profile. More...
 
uint64_t peak_rate
 The peak information rate for this shaper profile. More...
 
uint32_t commit_burst
 The commit burst tolerance for this shaper profile. More...
 
uint32_t peak_burst
 The peak burst tolerance for this shaper profile. More...
 
int8_t shaper_len_adjust
 The shaper_len_adjust is a value between -128 and 127 which is directly added to the frame_len of a packet associated with this profile. More...
 
odp_bool_t dual_rate
 If dual_rate is TRUE it indicates the desire for the implementation to use dual rate shaping for packets associated with this profile. More...
 
odp_bool_t packet_mode
 If packet_mode is TRUE it indicates that shaper should work in packet mode ignoring lengths of packet and hence shaping traffic in packet's per second as opposed to bits per second. More...
 

Detailed Description

TM shaper parameters.

Use odp_tm_shaper_params_init() to initialize parameters into their default values.

Examples
odp_traffic_mgmt.c.

Definition at line 1050 of file api/spec/traffic_mngr.h.

Field Documentation

◆ mode

odp_tm_shaper_mode_t odp_tm_shaper_params_t::mode

Shaper mode.

The default value is ODP_TM_SHAPER_RATE_SHAPE.

A shaper profile must not be used in a TM queue or TM node if the queue/node does not support shaper or if it does not support the shaper mode set in the profile.

See also
odp_tm_capabilities_t::tm_queue_shaper_supported
odp_tm_capabilities_t::tm_queue_rate_limiter_supported
odp_tm_level_capabilities_t::tm_node_shaper_supported
odp_tm_level_capabilities_t::tm_node_rate_limiter_supported

Definition at line 1062 of file api/spec/traffic_mngr.h.

◆ commit_rate

uint64_t odp_tm_shaper_params_t::commit_rate

The committed information rate for this shaper profile.

The units for this integer is in bits per second when packet_mode is not TRUE while packets per second when packet mode is TRUE.

Examples
odp_traffic_mgmt.c.

Definition at line 1068 of file api/spec/traffic_mngr.h.

◆ peak_rate

uint64_t odp_tm_shaper_params_t::peak_rate

The peak information rate for this shaper profile.

The units for this integer is in bits per second when packet_mode is not TRUE while in packets per second when packet mode is TRUE. This field is ignored when dual_rate is FALSE.

Examples
odp_traffic_mgmt.c.

Definition at line 1075 of file api/spec/traffic_mngr.h.

◆ commit_burst

uint32_t odp_tm_shaper_params_t::commit_burst

The commit burst tolerance for this shaper profile.

The units for this field is bits when packet_mode is not TRUE and packets when packet_mode is TRUE. This value sets an upper limit for the size of the commitCnt.

Examples
odp_traffic_mgmt.c.

Definition at line 1081 of file api/spec/traffic_mngr.h.

◆ peak_burst

uint32_t odp_tm_shaper_params_t::peak_burst

The peak burst tolerance for this shaper profile.

The units for this field in bits when packet_mode is not TRUE and packets when packet_mode is TRUE. This value sets an upper limit for the size of the peakCnt. This field is ignored when dual_rate is FALSE.

Examples
odp_traffic_mgmt.c.

Definition at line 1089 of file api/spec/traffic_mngr.h.

◆ shaper_len_adjust

int8_t odp_tm_shaper_params_t::shaper_len_adjust

The shaper_len_adjust is a value between -128 and 127 which is directly added to the frame_len of a packet associated with this profile.

The frame_len would normally include the outermost Ethernet header (DA, SA, ...) through to the outermost Ethernet CRC inclusive. Hence this field - when non-zero - will usually be set to a value approximating the "time" (in units of bytes) taken by the Ethernet preamble and Inter Frame Gap. Traditionally this would be the value 20 (8 + 12), but in same cases can be as low as 9 (4 + 5). This field is ignored when packet_mode is TRUE.

The default value is 0.

Examples
odp_traffic_mgmt.c.

Definition at line 1103 of file api/spec/traffic_mngr.h.

◆ dual_rate

odp_bool_t odp_tm_shaper_params_t::dual_rate

If dual_rate is TRUE it indicates the desire for the implementation to use dual rate shaping for packets associated with this profile.

The precise semantics of dual rate shaping are implementation specific, but in any case require a non-zero set of both commit and peak parameters.

The default value is false.

Examples
odp_traffic_mgmt.c.

Definition at line 1112 of file api/spec/traffic_mngr.h.

◆ packet_mode

odp_bool_t odp_tm_shaper_params_t::packet_mode

If packet_mode is TRUE it indicates that shaper should work in packet mode ignoring lengths of packet and hence shaping traffic in packet's per second as opposed to bits per second.

The default value is false.

Definition at line 1119 of file api/spec/traffic_mngr.h.


The documentation for this struct was generated from the following file: