5#include <osmocom/core/fsm.h>
6#include <osmocom/core/prim.h>
7#include <osmocom/core/linuxlist.h>
8#include <osmocom/core/linuxrbtree.h>
9#include <osmocom/core/tdef.h>
14#define SCCP_STR "Signalling Connection Control Part\n"
74#define _LOGPSCI(sci, subsys, level, fmt, args ...) \
75 _LOGSS7((sci)->ss7, subsys, level, "SCCP(rctx=%" PRIu32 ") " fmt, (sci)->route_ctx, ## args)
76#define LOGPSCI(sci, level, fmt, args ...) \
77 _LOGPSCI(sci, DLSCCP, level, fmt, ## args)
102#define _LOGPSCU(scu, subsys, level, fmt, args ...) \
103 _LOGPSCI((scu)->inst, subsys, level, "SCU(%s) " fmt, osmo_sccp_user_name(scu), ## args)
104#define LOGPSCU(scu, level, fmt, args ...) \
105 _LOGPSCU(scu, DLSCCP, level, fmt, ## args)
129 struct xua_msg *xua, uint32_t cause);
137 struct xua_msg *xua, uint32_t cause);
uint32_t dpc
Definition: m3ua.h:1
mtp_unavail_cause
Definition: mtp.h:28
void osmo_sccp_vty_write_cs7_node(struct vty *vty, const char *indent, struct osmo_sccp_instance *inst)
Definition: sccp_vty.c:255
void sccp_sclc_rx_scrc_rout_fail(struct osmo_sccp_instance *inst, struct xua_msg *xua, uint32_t cause)
SCRC -> SCLC (Routing Failure.
Definition: sccp_sclc.c:392
struct llist_head sccp_address_book_global
void sccp_scmg_rx_ssn_allowed(struct osmo_sccp_instance *inst, uint32_t dpc, uint32_t ssn, uint32_t smi)
Definition: sccp_scmg.c:41
int sccp_scrc_rx_scoc_conn_msg(struct osmo_sccp_instance *inst, struct xua_msg *xua)
Definition: sccp_scrc.c:451
struct msgb * sccp_msgb_alloc(const char *name)
Definition: sua.c:67
struct osmo_sccp_addr_entry * addr_entry_by_name_local(const char *name, const struct osmo_ss7_instance *inst)
Definition: ss7_instance.c:692
osmo_sccp_timer
Definition: sccp_internal.h:32
@ OSMO_SCCP_TIMER_REPEAT_REL
Definition: sccp_internal.h:38
@ OSMO_SCCP_TIMER_INT
Definition: sccp_internal.h:39
@ OSMO_SCCP_TIMER_GUARD
Definition: sccp_internal.h:40
@ OSMO_SCCP_TIMER_REASSEMBLY
Definition: sccp_internal.h:42
@ OSMO_SCCP_TIMERS_LEN
Definition: sccp_internal.h:44
@ OSMO_SCCP_TIMER_REL
Definition: sccp_internal.h:37
@ OSMO_SCCP_TIMER_IAS
Definition: sccp_internal.h:35
@ OSMO_SCCP_TIMER_CONN_EST
Definition: sccp_internal.h:34
@ OSMO_SCCP_TIMER_RESET
Definition: sccp_internal.h:41
@ OSMO_SCCP_TIMER_IAR
Definition: sccp_internal.h:36
int scrc_rx_mtp_xfer_ind_xua(struct osmo_sccp_instance *inst, struct xua_msg *xua)
Definition: sccp_scrc.c:539
void sccp_scmg_rx_mtp_status(struct osmo_sccp_instance *inst, uint32_t dpc, enum mtp_unavail_cause cause)
Definition: sccp_scmg.c:126
int sccp_sclc_user_sap_down(struct osmo_sccp_user *scu, struct osmo_prim_hdr *oph)
Main entrance function for primitives from SCCP User.
Definition: sccp_sclc.c:174
struct osmo_sccp_addr_entry * addr_entry_by_name_global(const char *name)
Definition: ss7_instance.c:710
struct osmo_sccp_user * sccp_user_find(struct osmo_sccp_instance *inst, uint16_t ssn, uint32_t pc)
Find a SCCP User registered for given PC+SSN or SSN only First search all users with a valid PC for a...
Definition: sccp_user.c:57
int sccp_sclc_user_sap_down_nofree(struct osmo_sccp_user *scu, struct osmo_prim_hdr *oph)
Main entrance function for primitives from SCCP User.
Definition: sccp_sclc.c:151
void sccp_scmg_rx_ssn_prohibited(struct osmo_sccp_instance *inst, uint32_t dpc, uint32_t ssn, uint32_t smi)
Definition: sccp_scmg.c:59
void sccp_scmg_rx_mtp_pause(struct osmo_sccp_instance *inst, uint32_t dpc)
brief MTP -> SNM (MTP-PAUSE.ind) - inability to providing MTP service Q.714 5.2.2
Definition: sccp_scmg.c:80
int sccp_scmg_init(struct osmo_sccp_instance *inst)
Definition: sccp_scmg.c:313
void sccp_scoc_rx_from_scrc(struct osmo_sccp_instance *inst, struct xua_msg *xua)
Main entrance function for primitives from the SCRC (Routing Control)
Definition: sccp_scoc.c:1847
int sccp_sclc_rx_from_scrc(struct osmo_sccp_instance *inst, struct xua_msg *xua)
SCRC -> SCLC (connectionless message)
Definition: sccp_sclc.c:315
int sccp_scrc_rx_sclc_msg(struct osmo_sccp_instance *inst, struct xua_msg *xua)
Definition: sccp_scrc.c:479
void sccp_scoc_rx_scrc_rout_fail(struct osmo_sccp_instance *inst, struct xua_msg *xua, uint32_t cause)
SCOC: Receive SCRC Routing Failure.
Definition: sccp_scoc.c:1600
void sccp_scmg_rx_mtp_resume(struct osmo_sccp_instance *inst, uint32_t dpc)
brief MTP -> SNM (MTP-RESUME.ind) - ability of providing the MTP service Q.714 5.2....
Definition: sccp_scmg.c:103
void sccp_scoc_show_connections(struct vty *vty, struct osmo_sccp_instance *inst)
Definition: sccp_scoc.c:2048
void sccp_lbcs_local_bcast_state(struct osmo_sccp_instance *inst, const struct osmo_scu_state_param *state)
Definition: sccp_lbcs.c:55
void sccp_lbcs_local_bcast_pcstate(struct osmo_sccp_instance *inst, const struct osmo_scu_pcstate_param *pcstate)
Definition: sccp_lbcs.c:39
void sccp_scoc_flush_connections(struct osmo_sccp_instance *inst)
Definition: sccp_scoc.c:2011
int sccp_user_prim_up(struct osmo_sccp_user *scut, struct osmo_scu_prim *prim)
Send a SCCP User SAP Primitive up to the User.
Definition: sccp_user.c:195
struct osmo_fsm sccp_scoc_fsm
Definition: sccp_scoc.c:1513
static const char * osmo_sccp_timer_name(enum osmo_sccp_timer val)
Definition: sccp_internal.h:50
const struct value_string osmo_sccp_timer_names[]
Definition: sccp_scoc.c:275
const struct osmo_tdef osmo_sccp_timer_defaults[OSMO_SCCP_TIMERS_LEN]
Definition: sccp_scoc.c:251
uint8_t smi
Definition: sccp_scmg.h:3
Definition: sccp_internal.h:20
struct osmo_ss7_instance * inst
Definition: sccp_internal.h:23
char name[32]
Definition: sccp_internal.h:24
struct llist_head list
Definition: sccp_internal.h:21
struct llist_head list_global
Definition: sccp_internal.h:22
struct osmo_sccp_addr addr
Definition: sccp_internal.h:25
Definition: sccp_sap.h:183
Definition: sccp_internal.h:54
uint32_t next_id
Definition: sccp_internal.h:64
struct osmo_ss7_user * ss7_user
Definition: sccp_internal.h:68
uint32_t route_ctx
Definition: sccp_internal.h:62
struct osmo_tdef * tdefs
Definition: sccp_internal.h:70
struct osmo_ss7_instance * ss7
Definition: sccp_internal.h:65
struct llist_head list
Definition: sccp_internal.h:56
void * priv
Definition: sccp_internal.h:66
uint32_t max_optional_data
Definition: sccp_internal.h:72
struct llist_head users
Definition: sccp_internal.h:60
struct rb_root connections
Definition: sccp_internal.h:58
Definition: sccp_internal.h:80
struct osmo_fsm_inst * as_fi
Definition: sccp_internal.h:100
struct osmo_sccp_instance * inst
pointer back to SCCP instance
Definition: sccp_internal.h:84
uint32_t pc
Definition: sccp_internal.h:90
struct llist_head links
Definition: sccp_internal.h:93
void * priv
Definition: sccp_internal.h:97
uint16_t ssn
SSN and/or point code to which we are bound.
Definition: sccp_internal.h:89
char * name
human-readable name of this user
Definition: sccp_internal.h:86
osmo_prim_cb prim_cb
Definition: sccp_internal.h:96
struct llist_head list
entry in list of sccp users of osmo_sccp_instance
Definition: sccp_internal.h:82
Definition: sccp_sap.h:273
Definition: sccp_sap.h:280
Definition: sccp_sap.h:265
Definition: ss7_instance.h:21
Definition: ss7_user.h:13