Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
loss_interval.h File Reference
#include <linux/ktime.h>
#include <linux/list.h>
#include <linux/slab.h>

Go to the source code of this file.

Data Structures

struct  tfrc_loss_interval
 
struct  tfrc_loss_hist
 

Macros

#define NINTERVAL   8
 
#define LIH_SIZE   (NINTERVAL + 1)
 

Functions

int tfrc_lh_interval_add (struct tfrc_loss_hist *, struct tfrc_rx_hist *, u32(*first_li)(struct sock *), struct sock *)
 
u8 tfrc_lh_update_i_mean (struct tfrc_loss_hist *lh, struct sk_buff *)
 
void tfrc_lh_cleanup (struct tfrc_loss_hist *lh)
 

Macro Definition Documentation

#define LIH_SIZE   (NINTERVAL + 1)

Definition at line 23 of file loss_interval.h.

#define NINTERVAL   8

Definition at line 22 of file loss_interval.h.

Function Documentation

void tfrc_lh_cleanup ( struct tfrc_loss_hist lh)

Definition at line 49 of file loss_interval.c.

int tfrc_lh_interval_add ( struct tfrc_loss_hist lh,
struct tfrc_rx_hist rh,
u32(*)(struct sock *)  calc_first_li,
struct sock sk 
)

tfrc_lh_interval_add - Insert new record into the Loss Interval database : Loss Interval database : Receive history containing a fresh loss event : Caller-dependent routine to compute length of first interval : Used by in caller-specific way (subtyping)

Updates I_mean and returns 1 if a new interval has in fact been added to .

Definition at line 139 of file loss_interval.c.

u8 tfrc_lh_update_i_mean ( struct tfrc_loss_hist lh,
struct sk_buff skb 
)

tfrc_lh_update_i_mean - Update the `open' loss interval I_0 For recomputing p: returns `true' if p > p_prev <=> 1/p < 1/p_prev

Definition at line 88 of file loss_interval.c.