FreeBSD kernel IPv4 code
tcp_ratelimit.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  tcp_hwrate_limit_table
 
struct  tcp_rate_set
 

Macros

#define HDWRPACE_INITED   0x0001
 
#define HDWRPACE_TAGPRESENT   0x0002
 
#define HDWRPACE_IFPDEPARTED   0x0004
 
#define RS_IS_DEFF   0x0001 /* Its a lagg, do a double lookup */
 
#define RS_IS_INTF   0x0002 /* Its a plain interface */
 
#define RS_NO_PRE   0x0004 /* The interfacd has set rates */
 
#define RS_INT_TBL
 
#define RS_IS_DEAD   0x0020 /* The RS is dead list */
 
#define RS_FUNERAL_SCHD   0x0040 /* Is a epoch call scheduled to bury this guy?*/
 
#define RS_INTF_NO_SUP   0x0100 /* The interface does not support the ratelimiting */
 
#define RS_PACING_EXACT_MATCH   0x0001 /* Need an exact match for rate */
 
#define RS_PACING_GT   0x0002 /* Greater than requested */
 
#define RS_PACING_GEQ   0x0004 /* Greater than or equal too */
 
#define RS_PACING_LT   0x0008 /* Less than requested rate */
 
#define RS_PACING_SUB_OK
 
#define ETHERNET_SEGMENT_SIZE   1514
 

Functions

 CK_LIST_HEAD (head_tcp_rate_set, tcp_rate_set)
 
static const struct tcp_hwrate_limit_tabletcp_set_pacing_rate (struct tcpcb *tp, struct ifnet *ifp, uint64_t bytes_per_sec, int flags, int *error, uint64_t *lower_rate)
 
static const struct tcp_hwrate_limit_tabletcp_chg_pacing_rate (const struct tcp_hwrate_limit_table *crte, struct tcpcb *tp, struct ifnet *ifp, uint64_t bytes_per_sec, int flags, int *error, uint64_t *lower_rate)
 
static void tcp_rel_pacing_rate (const struct tcp_hwrate_limit_table *crte, struct tcpcb *tp)
 
static uint64_t tcp_hw_highest_rate (const struct tcp_hwrate_limit_table *rle)
 
static uint64_t tcp_hw_highest_rate_ifp (struct ifnet *ifp, struct inpcb *inp)
 
uint32_t tcp_get_pacing_burst_size (struct tcpcb *tp, uint64_t bw, uint32_t segsiz, int can_use_1mss, const struct tcp_hwrate_limit_table *te, int *err)
 
void tcp_rl_log_enobuf (const struct tcp_hwrate_limit_table *rte)
 

Macro Definition Documentation

◆ ETHERNET_SEGMENT_SIZE

#define ETHERNET_SEGMENT_SIZE   1514

Definition at line 89 of file tcp_ratelimit.h.

◆ HDWRPACE_IFPDEPARTED

#define HDWRPACE_IFPDEPARTED   0x0004

Definition at line 42 of file tcp_ratelimit.h.

◆ HDWRPACE_INITED

#define HDWRPACE_INITED   0x0001

Definition at line 40 of file tcp_ratelimit.h.

◆ HDWRPACE_TAGPRESENT

#define HDWRPACE_TAGPRESENT   0x0002

Definition at line 41 of file tcp_ratelimit.h.

◆ RS_FUNERAL_SCHD

#define RS_FUNERAL_SCHD   0x0040 /* Is a epoch call scheduled to bury this guy?*/

Definition at line 59 of file tcp_ratelimit.h.

◆ RS_INT_TBL

#define RS_INT_TBL
Value:
0x0010 /*
* The table is the internal version
* which has special setup requirements.
*/

Definition at line 57 of file tcp_ratelimit.h.

◆ RS_INTF_NO_SUP

#define RS_INTF_NO_SUP   0x0100 /* The interface does not support the ratelimiting */

Definition at line 60 of file tcp_ratelimit.h.

◆ RS_IS_DEAD

#define RS_IS_DEAD   0x0020 /* The RS is dead list */

Definition at line 58 of file tcp_ratelimit.h.

◆ RS_IS_DEFF

#define RS_IS_DEFF   0x0001 /* Its a lagg, do a double lookup */

Definition at line 54 of file tcp_ratelimit.h.

◆ RS_IS_INTF

#define RS_IS_INTF   0x0002 /* Its a plain interface */

Definition at line 55 of file tcp_ratelimit.h.

◆ RS_NO_PRE

#define RS_NO_PRE   0x0004 /* The interfacd has set rates */

Definition at line 56 of file tcp_ratelimit.h.

◆ RS_PACING_EXACT_MATCH

#define RS_PACING_EXACT_MATCH   0x0001 /* Need an exact match for rate */

Definition at line 82 of file tcp_ratelimit.h.

◆ RS_PACING_GEQ

#define RS_PACING_GEQ   0x0004 /* Greater than or equal too */

Definition at line 84 of file tcp_ratelimit.h.

◆ RS_PACING_GT

#define RS_PACING_GT   0x0002 /* Greater than requested */

Definition at line 83 of file tcp_ratelimit.h.

◆ RS_PACING_LT

#define RS_PACING_LT   0x0008 /* Less than requested rate */

Definition at line 85 of file tcp_ratelimit.h.

◆ RS_PACING_SUB_OK

#define RS_PACING_SUB_OK
Value:
0x0010 /* If a rate can't be found get the
* next best rate (highest or lowest). */

Definition at line 86 of file tcp_ratelimit.h.

Function Documentation

◆ CK_LIST_HEAD()

CK_LIST_HEAD ( head_tcp_rate_set  ,
tcp_rate_set   
)

◆ tcp_chg_pacing_rate()

static const struct tcp_hwrate_limit_table * tcp_chg_pacing_rate ( const struct tcp_hwrate_limit_table crte,
struct tcpcb tp,
struct ifnet *  ifp,
uint64_t  bytes_per_sec,
int  flags,
int *  error,
uint64_t *  lower_rate 
)
inlinestatic

Definition at line 131 of file tcp_ratelimit.h.

Referenced by bbr_update_hardware_pacing_rate(), and rack_get_pacing_delay().

Here is the caller graph for this function:

◆ tcp_get_pacing_burst_size()

uint32_t tcp_get_pacing_burst_size ( struct tcpcb tp,
uint64_t  bw,
uint32_t  segsiz,
int  can_use_1mss,
const struct tcp_hwrate_limit_table te,
int *  err 
)

Referenced by rack_get_pacing_delay(), rack_get_pacing_len(), and rack_set_pace_segments().

Here is the caller graph for this function:

◆ tcp_hw_highest_rate()

static uint64_t tcp_hw_highest_rate ( const struct tcp_hwrate_limit_table rle)
inlinestatic

Definition at line 148 of file tcp_ratelimit.h.

Referenced by pace_to_fill_cwnd(), and rack_get_output_bw().

Here is the caller graph for this function:

◆ tcp_hw_highest_rate_ifp()

static uint64_t tcp_hw_highest_rate_ifp ( struct ifnet *  ifp,
struct inpcb inp 
)
inlinestatic

Definition at line 154 of file tcp_ratelimit.h.

Referenced by pace_to_fill_cwnd(), and rack_get_output_bw().

Here is the caller graph for this function:

◆ tcp_rel_pacing_rate()

static void tcp_rel_pacing_rate ( const struct tcp_hwrate_limit_table crte,
struct tcpcb tp 
)
inlinestatic

Definition at line 141 of file tcp_ratelimit.h.

Referenced by bbr_fini(), bbr_output_wtime(), bbr_set_sockopt(), rack_fini(), rack_get_pacing_delay(), and rack_process_option().

Here is the caller graph for this function:

◆ tcp_rl_log_enobuf()

void tcp_rl_log_enobuf ( const struct tcp_hwrate_limit_table rte)

Referenced by rack_output().

Here is the caller graph for this function:

◆ tcp_set_pacing_rate()

static const struct tcp_hwrate_limit_table * tcp_set_pacing_rate ( struct tcpcb tp,
struct ifnet *  ifp,
uint64_t  bytes_per_sec,
int  flags,
int *  error,
uint64_t *  lower_rate 
)
inlinestatic

Definition at line 122 of file tcp_ratelimit.h.

Referenced by bbr_output_wtime(), and rack_get_pacing_delay().

Here is the caller graph for this function: