\doxysection{src/osmux\+\_\+input.c File Reference}
\label{osmux__input_8c}\index{src/osmux\_input.c@{src/osmux\_input.c}}


Osmocom multiplex protocol helpers (input)  


{\ttfamily \#include $<$stdio.\+h$>$}\newline
{\ttfamily \#include $<$string.\+h$>$}\newline
{\ttfamily \#include $<$inttypes.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/core/msgb.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/core/timer.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/core/timer\+\_\+compat.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/core/select.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/core/talloc.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/core/logging.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/netif/amr.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/netif/rtp.\+h$>$}\newline
{\ttfamily \#include $<$osmocom/netif/osmux.\+h$>$}\newline
{\ttfamily \#include $<$arpa/inet.\+h$>$}\newline
\doxysubsubsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\label{osmux__input_8c_af5909a93287ea334985b9d1735ad0b60} 
\#define {\bfseries DELTA\+\_\+\+RTP\+\_\+\+MSG}~20000
\item 
\label{osmux__input_8c_aeac1d5817fbc8473765723ddad171dc5} 
\#define {\bfseries DELTA\+\_\+\+RTP\+\_\+\+TIMESTAMP}~160
\item 
\#define \textbf{ LOGMUXLK\+\_\+}(link,  lvl,  fmt,  args ...)
\item 
\label{osmux__input_8c_a5ca92e306de357e51c43ddd4af0f1f15} 
\#define {\bfseries LOGMUXLK}(link,  lvl,  fmt,  args ...)~ LOGMUXLK\+\_\+(link, lvl, "{} "{} fmt, \#\# args)
\item 
\#define \textbf{ LOGMUXCID}(link,  circuit,  lvl,  fmt,  args ...)
\end{DoxyCompactItemize}
\doxysubsubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
void {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+deliver} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h)
\item 
int \textbf{ osmux\+\_\+xfrm\+\_\+input} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h, struct msgb $\ast$msg, int ccid)
\begin{DoxyCompactList}\small\item\em osmux\+\_\+xfrm\+\_\+input -\/ add RTP message to OSmux batch \end{DoxyCompactList}\item 
struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$ \textbf{ osmux\+\_\+xfrm\+\_\+input\+\_\+alloc} (void $\ast$ctx)
\begin{DoxyCompactList}\small\item\em Allocate a new osmux in handle (osmux source, tx side) \end{DoxyCompactList}\item 
void \textbf{ osmux\+\_\+xfrm\+\_\+input\+\_\+init} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h) OSMO\+\_\+\+DEPRECATED("{}Use \textbf{ osmux\+\_\+xfrm\+\_\+input\+\_\+alloc}() instead"{})
\item 
int {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+set\+\_\+batch\+\_\+factor} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h, uint8\+\_\+t batch\+\_\+factor)
\item 
void {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+set\+\_\+batch\+\_\+size} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h, uint16\+\_\+t batch\+\_\+size)
\item 
void {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+set\+\_\+initial\+\_\+seqnum} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h, uint8\+\_\+t osmux\+\_\+seqnum)
\item 
void {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+set\+\_\+deliver\+\_\+cb} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h, void($\ast$deliver\+\_\+cb)(struct msgb $\ast$msg, void $\ast$data), void $\ast$data)
\item 
void $\ast$ {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+get\+\_\+deliver\+\_\+cb\+\_\+data} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h)
\item 
void {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+set\+\_\+name} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h, const char $\ast$name)
\item 
int {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+open\+\_\+circuit} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h, int ccid, int dummy)
\item 
void {\bfseries osmux\+\_\+xfrm\+\_\+input\+\_\+close\+\_\+circuit} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h, int ccid)
\item 
void \textbf{ osmux\+\_\+xfrm\+\_\+input\+\_\+fini} (struct \textbf{ osmux\+\_\+in\+\_\+handle} $\ast$h) OSMO\+\_\+\+DEPRECATED("{}Use talloc\+\_\+free() instead"{})
\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
Osmocom multiplex protocol helpers (input) 



\doxysubsection{Macro Definition Documentation}
\label{osmux__input_8c_a2217c19e7c5af4eb4ac0e13607bbdd7f} 
\index{osmux\_input.c@{osmux\_input.c}!LOGMUXCID@{LOGMUXCID}}
\index{LOGMUXCID@{LOGMUXCID}!osmux\_input.c@{osmux\_input.c}}
\doxysubsubsection{LOGMUXCID}
{\footnotesize\ttfamily \#define LOGMUXCID(\begin{DoxyParamCaption}\item[{}]{link,  }\item[{}]{circuit,  }\item[{}]{lvl,  }\item[{}]{fmt,  }\item[{}]{args ... }\end{DoxyParamCaption})}

{\bfseries Value\+:}
\begin{DoxyCode}{0}
\DoxyCodeLine{\ \ \ \ \ \ \ \ LOGMUXLK\_(link,\ lvl,\ \textcolor{stringliteral}{"{}[CID=\%"{}}\ PRIu8\ \textcolor{stringliteral}{"{},batched=\%u/\%u]\ "{}}\ fmt,\ \(\backslash\)}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (circuit)-\/>ccid,\ (circuit)-\/>nmsgs,\ (link)-\/>h-\/>batch\_factor,\ \#\#\ args)}

\end{DoxyCode}
\label{osmux__input_8c_a6fe4b8658d8a96a1ad44dfb706b7e512} 
\index{osmux\_input.c@{osmux\_input.c}!LOGMUXLK\_@{LOGMUXLK\_}}
\index{LOGMUXLK\_@{LOGMUXLK\_}!osmux\_input.c@{osmux\_input.c}}
\doxysubsubsection{LOGMUXLK\_}
{\footnotesize\ttfamily \#define LOGMUXLK\+\_\+(\begin{DoxyParamCaption}\item[{}]{link,  }\item[{}]{lvl,  }\item[{}]{fmt,  }\item[{}]{args ... }\end{DoxyParamCaption})}

{\bfseries Value\+:}
\begin{DoxyCode}{0}
\DoxyCodeLine{\ \ \ \ \ \ \ \ LOGP(DLMUX,\ lvl,\ \textcolor{stringliteral}{"{}[\%s,\%u/\%"{}}\ PRIu16\ \textcolor{stringliteral}{"{}]"{}}\ fmt,\ \(\backslash\)}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ (link)-\/>name,\ (link)-\/>h-\/>batch\_size\ -\/\ (link)-\/>remaining\_bytes,\ \(\backslash\)}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ (link)-\/>h-\/>batch\_size,\ \(\backslash\)}
\DoxyCodeLine{\ \ \ \ \ \ \ \ \ \ \ \ \ \#\#\ args)}

\end{DoxyCode}
