\doxysection{ss7\+\_\+as\+\_\+loadshare\+\_\+tcap.\+h}
\label{ss7__as__loadshare__tcap_8h_source}\index{src/ss7\_as\_loadshare\_tcap.h@{src/ss7\_as\_loadshare\_tcap.h}}
\textbf{ Go to the documentation of this file.}
\begin{DoxyCode}{0}
\DoxyCodeLine{00001\ \textcolor{preprocessor}{\#pragma\ once}}
\DoxyCodeLine{00002\ }
\DoxyCodeLine{00003\ \textcolor{preprocessor}{\#include\ <complex.h>}}
\DoxyCodeLine{00004\ \textcolor{preprocessor}{\#include\ <stdint.h>}}
\DoxyCodeLine{00005\ }
\DoxyCodeLine{00006\ \textcolor{preprocessor}{\#include\ <osmocom/core/msgb.h>}}
\DoxyCodeLine{00007\ \textcolor{preprocessor}{\#include\ <osmocom/sigtran/osmo\_ss7.h>}}
\DoxyCodeLine{00008\ }
\DoxyCodeLine{00009\ \textcolor{keyword}{struct\ }xua\_msg;}
\DoxyCodeLine{00010\ }
\DoxyCodeLine{00011\ \textcolor{preprocessor}{\#define\ TCAP\_PC\_WILDCARD\ 0xffffffff}}
\DoxyCodeLine{00012\ \textcolor{preprocessor}{\#define\ TCAP\_SSN\_WILDCARD\ 0}}
\DoxyCodeLine{00013\ }
\DoxyCodeLine{00014\ \textcolor{preprocessor}{\#ifdef\ WITH\_TCAP\_LOADSHARING}}
\DoxyCodeLine{00015\ }
\DoxyCodeLine{00016\ \textcolor{keyword}{struct\ }tcap\_range\ \{}
\DoxyCodeLine{00017\ \ \ \ \ \ \ \ \ \textcolor{keyword}{struct\ }hlist\_node\ list;}
\DoxyCodeLine{00018\ \ \ \ \ \ \ \ \ \textcolor{keyword}{struct\ }osmo\_ss7\_asp\ *asp;}
\DoxyCodeLine{00019\ \ \ \ \ \ \ \ \ uint32\_t\ tid\_start;}
\DoxyCodeLine{00020\ \ \ \ \ \ \ \ \ uint32\_t\ tid\_end;}
\DoxyCodeLine{00021\ \ \ \ \ \ \ \ \ uint32\_t\ pc;}
\DoxyCodeLine{00022\ \ \ \ \ \ \ \ \ uint8\_t\ ssn;}
\DoxyCodeLine{00023\ \};}
\DoxyCodeLine{00024\ }
\DoxyCodeLine{00025\ \textcolor{comment}{/*\ IPA\ entry\ point\ */}}
\DoxyCodeLine{00026\ \textcolor{keywordtype}{int}\ ipa\_rx\_msg\_osmo\_ext\_tcap\_routing(\textcolor{keyword}{struct}\ osmo\_ss7\_asp\ *asp,\ \textcolor{keyword}{struct}\ msgb\ *msg);}
\DoxyCodeLine{00027\ }
\DoxyCodeLine{00028\ \textcolor{keywordtype}{bool}\ tcap\_range\_matches(\textcolor{keyword}{const}\ \textcolor{keyword}{struct}\ tcap\_range\ *tcrng,\ uint32\_t\ tid);}
\DoxyCodeLine{00029\ \textcolor{keywordtype}{bool}\ tcap\_range\_overlaps(\textcolor{keyword}{const}\ \textcolor{keyword}{struct}\ tcap\_range\ *a,\ uint32\_t\ tid\_min,\ uint32\_t\ tid\_max);}
\DoxyCodeLine{00030\ }
\DoxyCodeLine{00031\ \textcolor{keyword}{struct\ }tcap\_range\ *tcap\_range\_alloc(\textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as,\ \textcolor{keyword}{struct}\ osmo\_ss7\_asp\ *asp,}
\DoxyCodeLine{00032\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ uint32\_t\ tid\_start,\ uint32\_t\ tid\_end,\ uint32\_t\ pc,\ uint8\_t\ ssn);}
\DoxyCodeLine{00033\ \textcolor{keywordtype}{void}\ tcap\_range\_free(\textcolor{keyword}{struct}\ tcap\_range\ *tcrng);}
\DoxyCodeLine{00034\ }
\DoxyCodeLine{00035\ \textcolor{comment}{/*\ Traffic\ ASP\ -\/>\ AS\ -\/>\ STP\ (Rx\ path)\ From\ TCAP\ Routing\ AS,\ only\ used\ for\ connection\ tracking\ */}}
\DoxyCodeLine{00036\ \textcolor{keywordtype}{int}\ ss7\_asp\_tcap\_rx\_sccp(\textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as,\ \textcolor{keyword}{struct}\ osmo\_ss7\_asp\ *asp,\ uint32\_t\ opc,\ uint32\_t\ dpc,\ \textcolor{keyword}{struct}\ msgb\ *sccp\_msg);}
\DoxyCodeLine{00037\ }
\DoxyCodeLine{00038\ \textcolor{comment}{/*\ Traffic\ STP\ -\/>\ AS\ -\/>\ ASP\ (Tx\ path)\ Loadshare\ towards\ the\ TCAP\ routing\ AS\ */}}
\DoxyCodeLine{00039\ \textcolor{keywordtype}{int}\ ss7\_as\_select\_asp\_loadshare\_tcap(\textcolor{keyword}{struct}\ osmo\_ss7\_asp\ **asp,\ \textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as,\ \textcolor{keyword}{struct}\ xua\_msg\ *xua);}
\DoxyCodeLine{00040\ }
\DoxyCodeLine{00041\ \textcolor{comment}{/*\ When\ the\ ASP\ got\ removed\ */}}
\DoxyCodeLine{00042\ \textcolor{keywordtype}{void}\ tcap\_asp\_down(\textcolor{keyword}{struct}\ osmo\_ss7\_asp\ *asp);}
\DoxyCodeLine{00043\ }
\DoxyCodeLine{00044\ \textcolor{keywordtype}{void}\ tcap\_enable(\textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as);}
\DoxyCodeLine{00045\ \textcolor{keywordtype}{void}\ tcap\_disable(\textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as);}
\DoxyCodeLine{00046\ }
\DoxyCodeLine{00047\ \textcolor{preprocessor}{\#else}}
\DoxyCodeLine{00048\ }
\DoxyCodeLine{00049\ \textcolor{keyword}{static}\ \textcolor{keyword}{inline}\ \textcolor{keywordtype}{int}\ ss7\_as\_select\_asp\_loadshare\_tcap(}
\DoxyCodeLine{00050\ \ \ \ \ \ \ \ \ \textcolor{keyword}{struct}\ osmo\_ss7\_asp\ **asp,\ \textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as,\ \textcolor{keyword}{struct}\ xua\_msg\ *xua)\ \{\ \textcolor{keywordflow}{return}\ -\/EPROTONOSUPPORT;\ \};}
\DoxyCodeLine{00051\ \textcolor{keyword}{static}\ \textcolor{keyword}{inline}\ \textcolor{keywordtype}{int}\ ss7\_asp\_tcap\_rx\_sccp(}
\DoxyCodeLine{00052\ \ \ \ \ \ \ \ \ \textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as,\ \textcolor{keyword}{struct}\ osmo\_ss7\_asp\ *asp,}
\DoxyCodeLine{00053\ \ \ \ \ \ \ \ \ uint32\_t\ opc,\ uint32\_t\ dpc,}
\DoxyCodeLine{00054\ \ \ \ \ \ \ \ \ \textcolor{keyword}{struct}\ msgb\ *sccp\_msg)\ \{\ \textcolor{keywordflow}{return}\ -\/EINVAL;\ \};}
\DoxyCodeLine{00055\ \textcolor{keyword}{static}\ \textcolor{keyword}{inline}\ \textcolor{keywordtype}{void}\ tcap\_asp\_down(\textcolor{keyword}{struct}\ osmo\_ss7\_asp\ *asp)\ \{\};}
\DoxyCodeLine{00056\ \textcolor{keyword}{static}\ \textcolor{keyword}{inline}\ \textcolor{keywordtype}{void}\ tcap\_enable(\textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as)\ \{\};}
\DoxyCodeLine{00057\ \textcolor{keyword}{static}\ \textcolor{keyword}{inline}\ \textcolor{keywordtype}{void}\ tcap\_disable(\textcolor{keyword}{struct}\ osmo\_ss7\_as\ *as)\ \{\};}
\DoxyCodeLine{00058\ }
\DoxyCodeLine{00059\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{/*\ WITH\_TCAP\_LOADSHARING\ */}\textcolor{preprocessor}{}}

\end{DoxyCode}
