libosmocore  1.0.1.85-9f28
Osmocom core library
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
tdef.c File Reference

Implementation to define Tnnn timers globally and use for FSM state changes. More...

#include <limits.h>
#include <osmocom/core/fsm.h>
#include <osmocom/core/tdef.h>

Functions

static unsigned long osmo_tdef_factor (enum osmo_tdef_unit a, enum osmo_tdef_unit b)
 a = return_val * b. More...
 
static unsigned long osmo_tdef_round (unsigned long val, enum osmo_tdef_unit from_unit, enum osmo_tdef_unit to_unit)
 
void osmo_tdefs_reset (struct osmo_tdef *tdefs)
 Set all osmo_tdef values to the default_val. More...
 
unsigned long osmo_tdef_get (const struct osmo_tdef *tdefs, int T, enum osmo_tdef_unit as_unit, unsigned long val_if_not_present)
 Return the value of a T timer from a list of osmo_tdef, in the given unit. More...
 
struct osmo_tdefosmo_tdef_get_entry (struct osmo_tdef *tdefs, int T)
 Find tdef entry matching T. More...
 
const struct
osmo_tdef_state_timeout
osmo_tdef_get_state_timeout (uint32_t state, const struct osmo_tdef_state_timeout *timeouts_array)
 Using osmo_tdef for osmo_fsm_inst: find a given state's osmo_tdef_state_timeout entry. More...
 
int _osmo_tdef_fsm_inst_state_chg (struct osmo_fsm_inst *fi, uint32_t state, const struct osmo_tdef_state_timeout *timeouts_array, const struct osmo_tdef *tdefs, unsigned long default_timeout, const char *file, int line)
 See invocation macro osmo_tdef_fsm_inst_state_chg() instead. More...
 

Variables

const struct value_string osmo_tdef_unit_names []
 

Detailed Description

Implementation to define Tnnn timers globally and use for FSM state changes.