Loading...
Searching...
No Matches
congure_snd_driver Struct Reference

Driver for CongURE objects. More...

Detailed Description

Driver for CongURE objects.

Definition at line 119 of file congure.h.

#include <congure.h>

Data Fields

void(* init )(congure_snd_t *c, void *ctx)
 Initializes a CongURE object.
 
int32_t(* inter_msg_interval )(congure_snd_t *c, unsigned msg_size)
 Get current interval between messages for pacing.
 
void(* report_msg_sent )(congure_snd_t *c, unsigned msg_size)
 Report that a message was sent.
 
void(* report_msg_discarded )(congure_snd_t *c, unsigned msg_size)
 Report message as discarded.
 
void(* report_msgs_timeout )(congure_snd_t *c, congure_snd_msg_t *msgs)
 Report that the ACKs for a collection of messages timed out.
 
void(* report_msgs_lost )(congure_snd_t *c, congure_snd_msg_t *msgs)
 Report that a collection of messages that is known to be lost.
 
void(* report_msg_acked )(congure_snd_t *c, congure_snd_msg_t *msg, congure_snd_ack_t *ack)
 Report that the ACK for a message was received.
 
void(* report_ecn_ce )(congure_snd_t *c, ztimer_now_t time)
 Report that "congestion encountered" CE signals were received for a message by means of explicit congestion notification (ECN).
 

Field Documentation

◆ init

void(* congure_snd_driver::init) (congure_snd_t *c, void *ctx)

Initializes a CongURE object.

Parameters
[in,out]cThe CongURE object to initialize.
[in]ctxContext for callbacks specific to the congestion control (such as a TCP PCB). May be NULL.

Definition at line 128 of file congure.h.

◆ inter_msg_interval

int32_t(* congure_snd_driver::inter_msg_interval) (congure_snd_t *c, unsigned msg_size)

Get current interval between messages for pacing.

Parameters
[in]cThe CongURE state object.
[in]msg_sizeThe size of the next message to send in caller-defined unit.
Returns
The current interval between sent messages in microseconds when pacing supported by congestion control implementation.
-1, if pacing is not supported by the congestion control implementation.

Definition at line 142 of file congure.h.

◆ report_ecn_ce

void(* congure_snd_driver::report_ecn_ce) (congure_snd_t *c, ztimer_now_t time)

Report that "congestion encountered" CE signals were received for a message by means of explicit congestion notification (ECN).

Parameters
[in]cThe CongURE state object.
[in]timeTimestamp in milliseconds of the message the CE event occurred for was sent.

Definition at line 217 of file congure.h.

◆ report_msg_acked

void(* congure_snd_driver::report_msg_acked) (congure_snd_t *c, congure_snd_msg_t *msg, congure_snd_ack_t *ack)

Report that the ACK for a message was received.

Parameters
[in]cThe CongURE state object.
[in]msgThe ACK'd message.
[in]ackThe received ACK.

Definition at line 205 of file congure.h.

◆ report_msg_discarded

void(* congure_snd_driver::report_msg_discarded) (congure_snd_t *c, unsigned msg_size)

Report message as discarded.

Discarded messages are not further taken into account for congestion control.

Parameters
[in]cThe CongURE state object.
[in]msg_sizeSize of the discarded message in caller-defined unit.

Definition at line 162 of file congure.h.

◆ report_msg_sent

void(* congure_snd_driver::report_msg_sent) (congure_snd_t *c, unsigned msg_size)

Report that a message was sent.

Parameters
[in]cThe CongURE state object.
[in]msg_sizeSize of the message in caller-defined unit.

Definition at line 150 of file congure.h.

◆ report_msgs_lost

void(* congure_snd_driver::report_msgs_lost) (congure_snd_t *c, congure_snd_msg_t *msgs)

Report that a collection of messages that is known to be lost.

One indicator for a lost message may e.g. be the reception of an ACK of a later sent packet, but not a ACK timeout (see congure_snd_driver_t::report_msgs_timeout() for that).

Note
As many congestion control algorithms do not distinguish loss and ACK timeout, this method and congure_snd_t::report_msgs_timeout need to have the same signature so the same function can be used here
Parameters
[in]cThe CongURE state object.
[in]msgsA collection of messages that are known to be lost. The list must not be be changed by the method.

Definition at line 196 of file congure.h.

◆ report_msgs_timeout

void(* congure_snd_driver::report_msgs_timeout) (congure_snd_t *c, congure_snd_msg_t *msgs)

Report that the ACKs for a collection of messages timed out.

Note
As many congestion control algorithms do not distinguish loss and ACK timeout, this method and congure_snd_t::report_msgs_lost need to have the same signature so the same function can be used here
Parameters
[in]cThe CongURE state object.
[in]msgsA collection of messages for which the ACK timed out. The list must not be changed by the method.

Definition at line 177 of file congure.h.


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