\doxysection{osmo\+\_\+ss7.\+h} \label{osmo__ss7_8h_source}\index{include/osmocom/sigtran/osmo\_ss7.h@{include/osmocom/sigtran/osmo\_ss7.h}} \textbf{ Go to the documentation of this file.} \begin{DoxyCode}{0} \DoxyCodeLine{1 \textcolor{preprocessor}{\#pragma once}} \DoxyCodeLine{2 } \DoxyCodeLine{3 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{4 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{5 } \DoxyCodeLine{6 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{7 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{8 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{9 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{10 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{11 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{12 \textcolor{preprocessor}{\#include }} \DoxyCodeLine{13 } \DoxyCodeLine{14 \textcolor{keyword}{struct }osmo\_ss7\_instance;} \DoxyCodeLine{15 } \DoxyCodeLine{16 \textcolor{keyword}{extern} \textcolor{keyword}{struct }llist\_head osmo\_ss7\_instances;} \DoxyCodeLine{17 \textcolor{comment}{/* Get an entry pointer from a list item in osmo\_ss7\_instances: */}} \DoxyCodeLine{18 \textcolor{keyword}{struct }osmo\_ss7\_instance *osmo\_ss7\_instances\_llist\_entry(\textcolor{keyword}{struct} llist\_head *list);} \DoxyCodeLine{19 } \DoxyCodeLine{20 \textcolor{keywordtype}{int} osmo\_ss7\_init(\textcolor{keywordtype}{void});} \DoxyCodeLine{21 } \DoxyCodeLine{22 \textcolor{comment}{/* All known point-\/code formats have a length of or below 24 bit.}} \DoxyCodeLine{23 \textcolor{comment}{ * A point-\/code value exceeding that is used to indicate an unset PC. */}} \DoxyCodeLine{24 \textcolor{preprocessor}{\#define OSMO\_SS7\_PC\_INVALID 0xffffffff}} \DoxyCodeLine{25 \textcolor{keyword}{static} \textcolor{keyword}{inline} \textcolor{keywordtype}{bool} osmo\_ss7\_pc\_is\_valid(uint32\_t pc)} \DoxyCodeLine{26 \{} \DoxyCodeLine{27 \textcolor{keywordflow}{return} pc <= 0x00ffffff;} \DoxyCodeLine{28 \}} \DoxyCodeLine{29 } \DoxyCodeLine{30 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{31 \textcolor{comment}{ * xUA Servers}} \DoxyCodeLine{32 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{33 } \DoxyCodeLine{34 \textcolor{keyword}{struct }osmo\_xua\_layer\_manager;} \DoxyCodeLine{35 } \DoxyCodeLine{36 \textcolor{keyword}{struct }osmo\_xua\_server;} \DoxyCodeLine{37 } \DoxyCodeLine{38 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{39 \textcolor{comment}{ * SS7 Instances}} \DoxyCodeLine{40 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{41 } \DoxyCodeLine{42 \textcolor{keyword}{struct }osmo\_ss7\_pc\_fmt;} \DoxyCodeLine{43 \textcolor{keyword}{struct }osmo\_ss7\_instance;} \DoxyCodeLine{44 } \DoxyCodeLine{45 \textcolor{keyword}{struct }osmo\_ss7\_instance *osmo\_ss7\_instance\_find(uint32\_t \textcolor{keywordtype}{id});} \DoxyCodeLine{46 \textcolor{keyword}{struct }osmo\_ss7\_instance *} \DoxyCodeLine{47 osmo\_ss7\_instance\_find\_or\_create(\textcolor{keywordtype}{void} *ctx, uint32\_t \textcolor{keywordtype}{id});} \DoxyCodeLine{48 \textcolor{keywordtype}{void} osmo\_ss7\_instance\_destroy(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst);} \DoxyCodeLine{49 } \DoxyCodeLine{50 uint32\_t osmo\_ss7\_instance\_get\_id(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst);} \DoxyCodeLine{51 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_ss7\_instance\_get\_name(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst);} \DoxyCodeLine{52 } \DoxyCodeLine{53 \textcolor{keywordtype}{int} osmo\_ss7\_instance\_set\_pc\_fmt(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst,} \DoxyCodeLine{54 uint8\_t c0, uint8\_t c1, uint8\_t c2);} \DoxyCodeLine{55 \textcolor{keyword}{const} \textcolor{keyword}{struct }osmo\_ss7\_pc\_fmt *} \DoxyCodeLine{56 osmo\_ss7\_instance\_get\_pc\_fmt(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst);} \DoxyCodeLine{57 } \DoxyCodeLine{58 uint32\_t osmo\_ss7\_instance\_get\_primary\_pc(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst);} \DoxyCodeLine{59 } \DoxyCodeLine{60 \textcolor{keyword}{struct }osmo\_sccp\_instance *osmo\_ss7\_ensure\_sccp(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst);} \DoxyCodeLine{61 \textcolor{keyword}{struct }osmo\_sccp\_instance *osmo\_ss7\_get\_sccp(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst);} \DoxyCodeLine{62 } \DoxyCodeLine{63 \textcolor{keywordtype}{int} osmo\_ss7\_find\_free\_rctx(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst);} \DoxyCodeLine{64 } \DoxyCodeLine{65 \textcolor{keywordtype}{bool} osmo\_ss7\_pc\_is\_local(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint32\_t pc);} \DoxyCodeLine{66 \textcolor{keywordtype}{int} osmo\_ss7\_pointcode\_parse(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *str);} \DoxyCodeLine{67 \textcolor{keywordtype}{int} osmo\_ss7\_pointcode\_parse\_mask\_or\_len(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *in);} \DoxyCodeLine{68 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_ss7\_pointcode\_print\_buf(\textcolor{keywordtype}{char} *buf, \textcolor{keywordtype}{size\_t} buf\_len, \textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint32\_t pc);} \DoxyCodeLine{69 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_ss7\_pointcode\_print(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint32\_t pc);} \DoxyCodeLine{70 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_ss7\_pointcode\_print2(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint32\_t pc);} \DoxyCodeLine{71 } \DoxyCodeLine{72 uint8\_t osmo\_ss7\_pc\_width(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_pc\_fmt *pc\_fmt);} \DoxyCodeLine{73 uint32\_t osmo\_ss7\_pc\_normalize(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_pc\_fmt *pc\_fmt, uint32\_t pc);} \DoxyCodeLine{74 } \DoxyCodeLine{75 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{76 \textcolor{comment}{ * MTP Users (Users of MTP, such as SCCP or ISUP)}} \DoxyCodeLine{77 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{78 } \DoxyCodeLine{79 \textcolor{keyword}{struct }osmo\_ss7\_user;} \DoxyCodeLine{80 \textcolor{keyword}{struct }osmo\_mtp\_prim;} \DoxyCodeLine{81 } \DoxyCodeLine{82 } \DoxyCodeLine{83 \textcolor{keyword}{struct }osmo\_ss7\_user *osmo\_ss7\_user\_create(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name);} \DoxyCodeLine{84 \textcolor{keywordtype}{void} osmo\_ss7\_user\_destroy(\textcolor{keyword}{struct} osmo\_ss7\_user *user);} \DoxyCodeLine{85 } \DoxyCodeLine{86 \textcolor{keyword}{struct }osmo\_ss7\_instance *osmo\_ss7\_user\_get\_instance(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_user *user);} \DoxyCodeLine{87 \textcolor{keywordtype}{void} osmo\_ss7\_user\_set\_prim\_cb(\textcolor{keyword}{struct} osmo\_ss7\_user *user, osmo\_prim\_cb prim\_cb);} \DoxyCodeLine{88 \textcolor{keywordtype}{void} osmo\_ss7\_user\_set\_priv(\textcolor{keyword}{struct} osmo\_ss7\_user *user, \textcolor{keywordtype}{void} *priv);} \DoxyCodeLine{89 \textcolor{keywordtype}{void} *osmo\_ss7\_user\_get\_priv(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_user *user);} \DoxyCodeLine{90 } \DoxyCodeLine{91 \textcolor{keywordtype}{int} osmo\_ss7\_user\_register(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint8\_t service\_ind,} \DoxyCodeLine{92 \textcolor{keyword}{struct} osmo\_ss7\_user *user);} \DoxyCodeLine{93 \textcolor{keywordtype}{int} osmo\_ss7\_user\_unregister(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint8\_t service\_ind,} \DoxyCodeLine{94 \textcolor{keyword}{struct} osmo\_ss7\_user *user);} \DoxyCodeLine{95 } \DoxyCodeLine{96 \textcolor{comment}{/* SS7 User wants to issue MTP-\/TRANSFER.req */}} \DoxyCodeLine{97 \textcolor{keywordtype}{int} osmo\_ss7\_user\_mtp\_xfer\_req(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst,} \DoxyCodeLine{98 \textcolor{keyword}{struct} osmo\_mtp\_prim *omp);} \DoxyCodeLine{99 } \DoxyCodeLine{100 } \DoxyCodeLine{101 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{102 \textcolor{comment}{ * SCCP Instance}} \DoxyCodeLine{103 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{104 } \DoxyCodeLine{105 \textcolor{keyword}{struct }osmo\_sccp\_instance;} \DoxyCodeLine{106 } \DoxyCodeLine{107 \textcolor{keywordtype}{void} osmo\_sccp\_set\_max\_optional\_data(\textcolor{keyword}{struct} osmo\_sccp\_instance *inst, \textcolor{keywordtype}{int} val);} \DoxyCodeLine{108 } \DoxyCodeLine{109 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{110 \textcolor{comment}{ * SS7 Links}} \DoxyCodeLine{111 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{112 } \DoxyCodeLine{113 \textcolor{keyword}{struct }osmo\_ss7\_link;} \DoxyCodeLine{114 } \DoxyCodeLine{115 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{116 \textcolor{comment}{ * SS7 Linksets}} \DoxyCodeLine{117 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{118 } \DoxyCodeLine{119 \textcolor{keyword}{struct }osmo\_ss7\_linkset;} \DoxyCodeLine{120 } \DoxyCodeLine{121 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{122 \textcolor{comment}{ * SS7 Routes}} \DoxyCodeLine{123 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{124 } \DoxyCodeLine{125 \textcolor{keyword}{struct }osmo\_ss7\_route;} \DoxyCodeLine{126 } \DoxyCodeLine{127 \textcolor{keyword}{struct }osmo\_ss7\_route *} \DoxyCodeLine{128 osmo\_ss7\_route\_lookup(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint32\_t dpc);} \DoxyCodeLine{129 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_ss7\_route\_print(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_route *rt);} \DoxyCodeLine{130 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_ss7\_route\_name(\textcolor{keyword}{struct} osmo\_ss7\_route *rt, \textcolor{keywordtype}{bool} list\_asps);} \DoxyCodeLine{131 \textcolor{keyword}{struct }osmo\_ss7\_as *} \DoxyCodeLine{132 osmo\_ss7\_route\_get\_dest\_as(\textcolor{keyword}{struct} osmo\_ss7\_route *rt);} \DoxyCodeLine{133 } \DoxyCodeLine{134 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{135 \textcolor{comment}{ * SS7 Routing key}} \DoxyCodeLine{136 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{137 } \DoxyCodeLine{138 \textcolor{keyword}{struct }osmo\_ss7\_routing\_key \{} \DoxyCodeLine{139 uint32\_t context;} \DoxyCodeLine{140 uint32\_t l\_rk\_id;} \DoxyCodeLine{141 } \DoxyCodeLine{142 uint32\_t pc;} \DoxyCodeLine{143 uint8\_t si;} \DoxyCodeLine{144 uint32\_t ssn;} \DoxyCodeLine{145 \textcolor{comment}{/* FIXME: more complex routing keys */}} \DoxyCodeLine{146 \};} \DoxyCodeLine{147 } \DoxyCodeLine{148 } \DoxyCodeLine{149 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{150 \textcolor{comment}{ * SS7 ASP Protocols}} \DoxyCodeLine{151 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{152 } \DoxyCodeLine{153 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol \{} \DoxyCodeLine{154 OSMO\_SS7\_ASP\_PROT\_NONE,} \DoxyCodeLine{155 OSMO\_SS7\_ASP\_PROT\_SUA,} \DoxyCodeLine{156 OSMO\_SS7\_ASP\_PROT\_M3UA,} \DoxyCodeLine{157 OSMO\_SS7\_ASP\_PROT\_IPA,} \DoxyCodeLine{158 \_NUM\_OSMO\_SS7\_ASP\_PROT} \DoxyCodeLine{159 \};} \DoxyCodeLine{160 } \DoxyCodeLine{161 \textcolor{keyword}{extern} \textcolor{keyword}{struct }value\_string osmo\_ss7\_asp\_protocol\_vals[];} \DoxyCodeLine{162 \textcolor{keyword}{static} \textcolor{keyword}{inline} \textcolor{keyword}{const} \textcolor{keywordtype}{char} *} \DoxyCodeLine{163 osmo\_ss7\_asp\_protocol\_name(\textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol mode)} \DoxyCodeLine{164 \{} \DoxyCodeLine{165 \textcolor{keywordflow}{return} get\_value\_string(osmo\_ss7\_asp\_protocol\_vals, mode);} \DoxyCodeLine{166 \}} \DoxyCodeLine{167 } \DoxyCodeLine{168 \textcolor{keywordtype}{int} osmo\_ss7\_asp\_protocol\_port(\textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol prot);} \DoxyCodeLine{169 } \DoxyCodeLine{170 } \DoxyCodeLine{171 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{172 \textcolor{comment}{ * SS7 AS Traffic Mode}} \DoxyCodeLine{173 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{174 } \DoxyCodeLine{175 \textcolor{keyword}{enum} osmo\_ss7\_as\_traffic\_mode \{} \DoxyCodeLine{176 OSMO\_SS7\_AS\_TMOD\_OVERRIDE = 0, \textcolor{comment}{/* default */}} \DoxyCodeLine{177 OSMO\_SS7\_AS\_TMOD\_BCAST,} \DoxyCodeLine{178 OSMO\_SS7\_AS\_TMOD\_LOADSHARE,} \DoxyCodeLine{179 OSMO\_SS7\_AS\_TMOD\_ROUNDROBIN,} \DoxyCodeLine{180 \_NUM\_OSMO\_SS7\_ASP\_TMOD} \DoxyCodeLine{181 \};} \DoxyCodeLine{182 } \DoxyCodeLine{183 \textcolor{keyword}{extern} \textcolor{keyword}{struct }value\_string osmo\_ss7\_as\_traffic\_mode\_vals[];} \DoxyCodeLine{184 } \DoxyCodeLine{185 \textcolor{keyword}{static} \textcolor{keyword}{inline} \textcolor{keyword}{const} \textcolor{keywordtype}{char} *} \DoxyCodeLine{186 osmo\_ss7\_as\_traffic\_mode\_name(\textcolor{keyword}{enum} osmo\_ss7\_as\_traffic\_mode mode)} \DoxyCodeLine{187 \{} \DoxyCodeLine{188 \textcolor{keywordflow}{return} get\_value\_string(osmo\_ss7\_as\_traffic\_mode\_vals, mode);} \DoxyCodeLine{189 \}} \DoxyCodeLine{190 } \DoxyCodeLine{191 \textcolor{keyword}{enum} osmo\_ss7\_as\_traffic\_mode osmo\_ss7\_tmode\_from\_xua(uint32\_t in);} \DoxyCodeLine{192 \textcolor{keywordtype}{int} osmo\_ss7\_tmode\_to\_xua(\textcolor{keyword}{enum} osmo\_ss7\_as\_traffic\_mode tmod);} \DoxyCodeLine{193 } \DoxyCodeLine{194 } \DoxyCodeLine{195 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{196 \textcolor{comment}{ * SS7 Application Servers}} \DoxyCodeLine{197 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{198 } \DoxyCodeLine{199 \textcolor{keyword}{struct }osmo\_ss7\_as;} \DoxyCodeLine{200 \textcolor{keyword}{struct }osmo\_ss7\_asp;} \DoxyCodeLine{201 } \DoxyCodeLine{202 \textcolor{keyword}{struct }osmo\_ss7\_as *} \DoxyCodeLine{203 osmo\_ss7\_as\_find\_by\_name(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name);} \DoxyCodeLine{204 \textcolor{keyword}{struct }osmo\_ss7\_as *} \DoxyCodeLine{205 osmo\_ss7\_as\_find\_by\_rctx(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint32\_t rctx);} \DoxyCodeLine{206 \textcolor{keyword}{struct }osmo\_ss7\_as *} \DoxyCodeLine{207 osmo\_ss7\_as\_find\_by\_l\_rk\_id(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, uint32\_t l\_rk\_id);} \DoxyCodeLine{208 \textcolor{keyword}{struct }osmo\_ss7\_as *osmo\_ss7\_as\_find\_by\_proto(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst,} \DoxyCodeLine{209 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol proto);} \DoxyCodeLine{210 \textcolor{keyword}{struct }osmo\_ss7\_as *} \DoxyCodeLine{211 osmo\_ss7\_as\_find\_or\_create(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name,} \DoxyCodeLine{212 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol proto);} \DoxyCodeLine{213 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol osmo\_ss7\_as\_get\_asp\_protocol(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_as *as);} \DoxyCodeLine{214 \textcolor{keywordtype}{int} osmo\_ss7\_as\_add\_asp(\textcolor{keyword}{struct} osmo\_ss7\_as *as, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *asp\_name);} \DoxyCodeLine{215 \textcolor{keywordtype}{int} osmo\_ss7\_as\_del\_asp(\textcolor{keyword}{struct} osmo\_ss7\_as *as, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *asp\_name);} \DoxyCodeLine{216 \textcolor{keywordtype}{void} osmo\_ss7\_as\_destroy(\textcolor{keyword}{struct} osmo\_ss7\_as *as);} \DoxyCodeLine{217 \textcolor{keywordtype}{bool} osmo\_ss7\_as\_has\_asp(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_as *as,} \DoxyCodeLine{218 \textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{219 \textcolor{keyword}{struct }osmo\_ss7\_asp *osmo\_ss7\_as\_select\_asp(\textcolor{keyword}{struct} osmo\_ss7\_as *as);} \DoxyCodeLine{220 \textcolor{keywordtype}{bool} osmo\_ss7\_as\_down(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_as *as);} \DoxyCodeLine{221 \textcolor{keywordtype}{bool} osmo\_ss7\_as\_active(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_as *as);} \DoxyCodeLine{222 \textcolor{keywordtype}{bool} osmo\_ss7\_as\_tmode\_compatible\_xua(\textcolor{keyword}{struct} osmo\_ss7\_as *as, uint32\_t m3ua\_tmt);} \DoxyCodeLine{223 } \DoxyCodeLine{224 } \DoxyCodeLine{225 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{226 \textcolor{comment}{ * SS7 Application Server Processes}} \DoxyCodeLine{227 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{228 } \DoxyCodeLine{229 \textcolor{keyword}{enum} osmo\_ss7\_asp\_admin\_state \{} \DoxyCodeLine{231 OSMO\_SS7\_ASP\_ADM\_S\_SHUTDOWN,} \DoxyCodeLine{233 OSMO\_SS7\_ASP\_ADM\_S\_BLOCKED,} \DoxyCodeLine{235 OSMO\_SS7\_ASP\_ADM\_S\_ENABLED,} \DoxyCodeLine{236 \};} \DoxyCodeLine{237 } \DoxyCodeLine{238 \textcolor{keyword}{enum} osmo\_ss7\_asp\_role \{} \DoxyCodeLine{239 OSMO\_SS7\_ASP\_ROLE\_ASP,} \DoxyCodeLine{240 OSMO\_SS7\_ASP\_ROLE\_SG,} \DoxyCodeLine{241 OSMO\_SS7\_ASP\_ROLE\_IPSP,} \DoxyCodeLine{242 \};} \DoxyCodeLine{243 } \DoxyCodeLine{244 \textcolor{keyword}{extern} \textcolor{keyword}{const} \textcolor{keyword}{struct }value\_string osmo\_ss7\_asp\_role\_names[];} \DoxyCodeLine{245 } \DoxyCodeLine{246 \textcolor{keyword}{struct }osmo\_ss7\_asp;} \DoxyCodeLine{247 } \DoxyCodeLine{249 \textcolor{preprocessor}{\#define OSMO\_SS7\_ASP\_QUIRK\_NO\_NOTIFY 0x00000001}} \DoxyCodeLine{251 \textcolor{preprocessor}{\#define OSMO\_SS7\_ASP\_QUIRK\_DAUD\_IN\_ASP 0x00000002}} \DoxyCodeLine{253 \textcolor{preprocessor}{\#define OSMO\_SS7\_ASP\_QUIRK\_SNM\_INACTIVE 0x00000004}} \DoxyCodeLine{254 } \DoxyCodeLine{255 } \DoxyCodeLine{256 \textcolor{keyword}{struct }osmo\_ss7\_asp *} \DoxyCodeLine{257 osmo\_ss7\_asp\_find\_by\_name(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name);} \DoxyCodeLine{258 \textcolor{keyword}{struct }osmo\_ss7\_asp *} \DoxyCodeLine{259 osmo\_ss7\_asp\_find\_by\_proto(\textcolor{keyword}{struct} osmo\_ss7\_as *as,} \DoxyCodeLine{260 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol proto);} \DoxyCodeLine{261 \textcolor{keyword}{struct }osmo\_ss7\_asp *} \DoxyCodeLine{262 osmo\_ss7\_asp\_find(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name,} \DoxyCodeLine{263 uint16\_t remote\_port, uint16\_t local\_port,} \DoxyCodeLine{264 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol proto)} \DoxyCodeLine{265 OSMO\_DEPRECATED(\textcolor{stringliteral}{"{}Use osmo\_ss7\_asp\_find2() instead"{}});} \DoxyCodeLine{266 \textcolor{keyword}{struct }osmo\_ss7\_asp *} \DoxyCodeLine{267 osmo\_ss7\_asp\_find2(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name,} \DoxyCodeLine{268 uint16\_t remote\_port, uint16\_t local\_port,} \DoxyCodeLine{269 \textcolor{keywordtype}{int} trans\_proto, \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol proto);} \DoxyCodeLine{270 \textcolor{keyword}{struct }osmo\_ss7\_asp *} \DoxyCodeLine{271 osmo\_ss7\_asp\_find\_or\_create(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name,} \DoxyCodeLine{272 uint16\_t remote\_port, uint16\_t local\_port,} \DoxyCodeLine{273 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol proto)} \DoxyCodeLine{274 OSMO\_DEPRECATED(\textcolor{stringliteral}{"{}Use osmo\_ss7\_asp\_find\_or\_create2() instead"{}});} \DoxyCodeLine{275 \textcolor{keyword}{struct }osmo\_ss7\_asp *} \DoxyCodeLine{276 osmo\_ss7\_asp\_find\_or\_create2(\textcolor{keyword}{struct} osmo\_ss7\_instance *inst, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name,} \DoxyCodeLine{277 uint16\_t remote\_port, uint16\_t local\_port,} \DoxyCodeLine{278 \textcolor{keywordtype}{int} trans\_proto, \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol proto);} \DoxyCodeLine{279 \textcolor{keywordtype}{void} osmo\_ss7\_asp\_disconnect(\textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{280 \textcolor{keywordtype}{void} osmo\_ss7\_asp\_destroy(\textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{281 \textcolor{keywordtype}{int} osmo\_ss7\_asp\_send(\textcolor{keyword}{struct} osmo\_ss7\_asp *asp, \textcolor{keyword}{struct} msgb *msg);} \DoxyCodeLine{282 \textcolor{keywordtype}{int} osmo\_ss7\_asp\_restart(\textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{283 \textcolor{keywordtype}{int} osmo\_ss7\_asp\_use\_default\_lm(\textcolor{keyword}{struct} osmo\_ss7\_asp *asp, \textcolor{keywordtype}{int} log\_level);} \DoxyCodeLine{284 \textcolor{keywordtype}{bool} osmo\_ss7\_asp\_active(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{285 \textcolor{keywordtype}{int} osmo\_ss7\_asp\_get\_log\_subsys(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{286 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_ss7\_asp\_get\_name(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{287 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol osmo\_ss7\_asp\_get\_proto(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{288 \textcolor{keywordtype}{int} osmo\_ss7\_asp\_get\_trans\_proto(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_ss7\_asp *asp);} \DoxyCodeLine{289 } \DoxyCodeLine{297 \textcolor{keyword}{typedef} \textcolor{keywordtype}{int} osmo\_ss7\_asp\_rx\_unknown\_cb(\textcolor{keyword}{struct} osmo\_ss7\_asp *asp, \textcolor{keywordtype}{int} ppid\_mux, \textcolor{keyword}{struct} msgb *msg);} \DoxyCodeLine{298 } \DoxyCodeLine{299 \textcolor{keywordtype}{void} osmo\_ss7\_register\_rx\_unknown\_cb(osmo\_ss7\_asp\_rx\_unknown\_cb *cb);} \DoxyCodeLine{300 } \DoxyCodeLine{301 } \DoxyCodeLine{302 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{303 \textcolor{comment}{ * Simple Client}} \DoxyCodeLine{304 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{305 } \DoxyCodeLine{306 \textcolor{keyword}{struct }osmo\_sccp\_instance *} \DoxyCodeLine{307 osmo\_sccp\_simple\_client(\textcolor{keywordtype}{void} *ctx, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name, uint32\_t default\_pc,} \DoxyCodeLine{308 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol prot, \textcolor{keywordtype}{int} default\_local\_port,} \DoxyCodeLine{309 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *default\_local\_ip, \textcolor{keywordtype}{int} default\_remote\_port,} \DoxyCodeLine{310 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *default\_remote\_ip);} \DoxyCodeLine{311 } \DoxyCodeLine{312 \textcolor{keyword}{struct }osmo\_sccp\_instance *} \DoxyCodeLine{313 osmo\_sccp\_simple\_client\_on\_ss7\_id(\textcolor{keywordtype}{void} *ctx, uint32\_t ss7\_id, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name,} \DoxyCodeLine{314 uint32\_t default\_pc,} \DoxyCodeLine{315 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol prot,} \DoxyCodeLine{316 \textcolor{keywordtype}{int} default\_local\_port,} \DoxyCodeLine{317 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *default\_local\_ip,} \DoxyCodeLine{318 \textcolor{keywordtype}{int} default\_remote\_port,} \DoxyCodeLine{319 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *default\_remote\_ip);} \DoxyCodeLine{320 } \DoxyCodeLine{321 \textcolor{comment}{/***********************************************************************}} \DoxyCodeLine{322 \textcolor{comment}{ * Simple Server}} \DoxyCodeLine{323 \textcolor{comment}{ ***********************************************************************/}} \DoxyCodeLine{324 } \DoxyCodeLine{325 \textcolor{keyword}{struct }osmo\_sccp\_instance *} \DoxyCodeLine{326 osmo\_sccp\_simple\_server(\textcolor{keywordtype}{void} *ctx, uint32\_t pc,} \DoxyCodeLine{327 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol prot, \textcolor{keywordtype}{int} local\_port,} \DoxyCodeLine{328 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *local\_ip);} \DoxyCodeLine{329 } \DoxyCodeLine{330 \textcolor{keyword}{struct }osmo\_sccp\_instance *} \DoxyCodeLine{331 osmo\_sccp\_simple\_server\_on\_ss7\_id(\textcolor{keywordtype}{void} *ctx, uint32\_t ss7\_id, uint32\_t pc,} \DoxyCodeLine{332 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol prot,} \DoxyCodeLine{333 \textcolor{keywordtype}{int} local\_port, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *local\_ip);} \DoxyCodeLine{334 } \DoxyCodeLine{335 \textcolor{keyword}{struct }osmo\_sccp\_instance *} \DoxyCodeLine{336 osmo\_sccp\_simple\_server\_add\_clnt(\textcolor{keyword}{struct} osmo\_sccp\_instance *inst,} \DoxyCodeLine{337 \textcolor{keyword}{enum} osmo\_ss7\_asp\_protocol prot,} \DoxyCodeLine{338 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name, uint32\_t pc,} \DoxyCodeLine{339 \textcolor{keywordtype}{int} local\_port, \textcolor{keywordtype}{int} remote\_port,} \DoxyCodeLine{340 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *remote\_ip);} \DoxyCodeLine{341 } \DoxyCodeLine{342 \textcolor{comment}{/* VTY related */}} \DoxyCodeLine{343 \textcolor{keyword}{struct }vty;} \DoxyCodeLine{344 \textcolor{keywordtype}{void} osmo\_ss7\_vty\_init\_asp(\textcolor{keywordtype}{void} *ctx);} \DoxyCodeLine{345 \textcolor{keywordtype}{void} osmo\_ss7\_vty\_init\_sg(\textcolor{keywordtype}{void} *ctx);} \DoxyCodeLine{346 \textcolor{keywordtype}{int} osmo\_ss7\_vty\_go\_parent(\textcolor{keyword}{struct} vty *vty);} \DoxyCodeLine{347 \textcolor{keywordtype}{int} osmo\_ss7\_is\_config\_node(\textcolor{keyword}{struct} vty *vty, \textcolor{keywordtype}{int} node);} \end{DoxyCode}