libosmo-sigtran 2.1.0.134-a6b3
Osmocom SIGTRAN library
|
#include <stdint.h>
#include <osmocom/core/linuxlist.h>
#include <osmocom/core/fsm.h>
#include <osmocom/core/msgb.h>
#include <osmocom/core/tdef.h>
#include <osmocom/netif/stream.h>
#include <osmocom/sigtran/osmo_ss7.h>
#include "ss7_internal.h"
Go to the source code of this file.
Data Structures | |
struct | osmo_ss7_as_esls_entry |
struct | osmo_ss7_as |
Macros | |
#define | NUM_AS_EXT_SLS 128 |
#define | LOGPAS(as, subsys, level, fmt, args ...) _LOGSS7((as)->inst, subsys, level, "AS(%s) " fmt, (as)->cfg.name, ## args) |
Typedefs | |
typedef uint8_t | as_ext_sls_t |
Functions | |
struct osmo_ss7_as * | ss7_as_alloc (struct osmo_ss7_instance *inst, const char *name, enum osmo_ss7_asp_protocol proto) |
Allocate an Application Server. More... | |
struct osmo_ss7_asp * | ss7_as_select_asp (struct osmo_ss7_as *as, const struct osmo_mtp_transfer_param *mtp) |
Select an AS to transmit a message, according to AS configuration and ASP availability. More... | |
unsigned int | osmo_ss7_as_count_asp (const struct osmo_ss7_as *as) |
Determine amount of ASPs associated to an AS. More... | |
int | ss7_as_add_asp (struct osmo_ss7_as *as, struct osmo_ss7_asp *asp) |
Add given ASP to given AS. More... | |
void | ss7_as_loadshare_binding_table_reset (struct osmo_ss7_as *as) |
#define LOGPAS | ( | as, | |
subsys, | |||
level, | |||
fmt, | |||
args ... | |||
) | _LOGSS7((as)->inst, subsys, level, "AS(%s) " fmt, (as)->cfg.name, ## args) |
#define NUM_AS_EXT_SLS 128 |
typedef uint8_t as_ext_sls_t |
enum ss7_as_ctr |
unsigned int osmo_ss7_as_count_asp | ( | const struct osmo_ss7_as * | as | ) |
Determine amount of ASPs associated to an AS.
[in] | as | Application Server. |
References osmo_ss7_as::asps, and osmo_ss7_as::cfg.
Referenced by xua_rkm_cleanup_dyn_as_for_asp().
int ss7_as_add_asp | ( | struct osmo_ss7_as * | as, |
struct osmo_ss7_asp * | asp | ||
) |
Add given ASP to given AS.
[in] | as | Application Server to which asp is added |
[in] | asp | Application Server Process to be added to as |
References osmo_ss7_as::asps, osmo_ss7_as::cfg, osmo_ss7_asp::cfg, osmo_ss7_asp::fi, LOGPAS, osmo_ss7_asp::name, osmo_ss7_as_has_asp(), and XUA_ASP_E_AS_ASSIGNED.
Referenced by handle_rkey_reg(), ipa_asp_fsm_wait_id_resp(), osmo_sccp_simple_client_on_ss7_id(), osmo_sccp_simple_server_add_clnt(), and osmo_ss7_as_add_asp().
struct osmo_ss7_as * ss7_as_alloc | ( | struct osmo_ss7_instance * | inst, |
const char * | name, | ||
enum osmo_ss7_asp_protocol | proto | ||
) |
Allocate an Application Server.
[in] | inst | SS7 Instance on which we operate |
[in] | name | Name of Application Server |
[in] | proto | Protocol of Application Server |
References osmo_ss7_instance::as_list, osmo_ss7_as::asps, osmo_ss7_as::cfg, osmo_ss7_as::ctrg, osmo_ss7_as::fi, g_ss7_as_rcg_idx, osmo_ss7_as::inst, osmo_ss7_routing_key::l_rk_id, osmo_ss7_as::last_asp_idx_assigned, osmo_ss7_as::list, osmo_ss7_as::mode, osmo_ss7_as::name, NULL, OSMO_SS7_AS_TMOD_OVERRIDE, osmo_ss7_as::proto, osmo_ss7_as::recovery_timeout_msec, osmo_ss7_as::routing_key, ss7_as_rcgd, ss7_find_free_l_rk_id(), and xua_as_fsm_start().
Referenced by osmo_ss7_as_find_or_create().
void ss7_as_loadshare_binding_table_reset | ( | struct osmo_ss7_as * | as | ) |
References osmo_ss7_as::aesls_table, osmo_ss7_as::asps, osmo_ss7_as::cfg, and osmo_ss7_as::last_asp_idx_assigned.
Referenced by DEFUN_ATTR().
struct osmo_ss7_asp * ss7_as_select_asp | ( | struct osmo_ss7_as * | as, |
const struct osmo_mtp_transfer_param * | mtp | ||
) |
Select an AS to transmit a message, according to AS configuration and ASP availability.
[in] | as | Application Server. |
This function returns NULL too if multiple ASPs would be selected, ie. AS is configured in broadcast mode and more than one ASP is configured.
References _NUM_OSMO_SS7_ASP_TMOD, osmo_ss7_as::cfg, osmo_ss7_as::fi, osmo_ss7_as::mode, NULL, OSMO_SS7_AS_TMOD_BCAST, OSMO_SS7_AS_TMOD_LOADSHARE, OSMO_SS7_AS_TMOD_OVERRIDE, OSMO_SS7_AS_TMOD_ROUNDROBIN, ss7_as_select_asp_broadcast(), ss7_as_select_asp_loadshare(), ss7_as_select_asp_override(), and ss7_as_select_asp_roundrobin().
Referenced by xua_as_transmit_msg().