libosmo-sigtran 2.2.1.64-e866 Osmocom SIGTRAN library

ss7_link.h
Go to the documentation of this file.
1#pragma once
2
3#include <stdint.h>
4#include <osmocom/core/linuxlist.h>
5
6/***********************************************************************
7 * SS7 Linksets
8 ***********************************************************************/
9
10struct osmo_ss7_linkset;
11
12 enum osmo_ss7_link_adm_state {
13 OSMO_SS7_LS_SHUTDOWN,
14 OSMO_SS7_LS_INHIBITED,
15 OSMO_SS7_LS_ENABLED,
16 _NUM_OSMO_SS7_LS
17};
18
19 struct osmo_ss7_link {
21 struct osmo_ss7_linkset *linkset;
22 struct {
23 char *name;
24 char *description;
25 uint32_t id;
26
27 enum osmo_ss7_link_adm_state adm_state;
28 } cfg;
29};
30
31void ss7_link_destroy(struct osmo_ss7_link *link);
32struct osmo_ss7_link *
33 ss7_link_find_or_create(struct osmo_ss7_linkset *lset, uint32_t id);
34
35bool
36 ss7_link_is_available(const struct osmo_ss7_link *link);
ss7_link_destroy
void ss7_link_destroy(struct osmo_ss7_link *link)
Destroy SS7 Link.
Definition: ss7_link.c:38
osmo_ss7_link_adm_state
osmo_ss7_link_adm_state
Definition: ss7_link.h:12
OSMO_SS7_LS_ENABLED
@ OSMO_SS7_LS_ENABLED
Definition: ss7_link.h:15
OSMO_SS7_LS_INHIBITED
@ OSMO_SS7_LS_INHIBITED
Definition: ss7_link.h:14
OSMO_SS7_LS_SHUTDOWN
@ OSMO_SS7_LS_SHUTDOWN
Definition: ss7_link.h:13
_NUM_OSMO_SS7_LS
@ _NUM_OSMO_SS7_LS
Definition: ss7_link.h:16
ss7_link_find_or_create
struct osmo_ss7_link * ss7_link_find_or_create(struct osmo_ss7_linkset *lset, uint32_t id)
Find or create SS7 Link with given ID in given Linkset.
Definition: ss7_link.c:55
ss7_link_is_available
bool ss7_link_is_available(const struct osmo_ss7_link *link)
Definition: ss7_link.c:81
osmo_ss7_link
Definition: ss7_link.h:19
osmo_ss7_link::name
char * name
Definition: ss7_link.h:23
osmo_ss7_link::description
char * description
Definition: ss7_link.h:24
osmo_ss7_link::id
uint32_t id
Definition: ss7_link.h:25
osmo_ss7_link::cfg
struct osmo_ss7_link::@33 cfg
osmo_ss7_link::linkset
struct osmo_ss7_linkset * linkset
osmo_ss7_linkset to which we belong
Definition: ss7_link.h:21
osmo_ss7_link::adm_state
enum osmo_ss7_link_adm_state adm_state
Definition: ss7_link.h:27
osmo_ss7_linkset
Definition: ss7_linkset.h:13