\doxysection{stream.\+h}
\label{stream_8h_source}\index{include/osmocom/netif/stream.h@{include/osmocom/netif/stream.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 <stdbool.h>}}
\DoxyCodeLine{4 \textcolor{preprocessor}{\#include <stdint.h>}}
\DoxyCodeLine{5 \textcolor{preprocessor}{\#include <unistd.h>}}
\DoxyCodeLine{6 }
\DoxyCodeLine{7 \textcolor{preprocessor}{\#include <osmocom/core/msgb.h>}}
\DoxyCodeLine{8 }
\DoxyCodeLine{12 \textcolor{preprocessor}{\#define OSMO\_STREAM\_SCTP\_MSG\_FLAGS\_NOTIFICATION 0x80 }\textcolor{comment}{/* sctp\_recvmsg() flags=MSG\_NOTIFICATION, msgb\_data() contains "{}union sctp\_notification*"{} */}\textcolor{preprocessor}{}}
\DoxyCodeLine{13 \textcolor{preprocessor}{\#define msgb\_sctp\_msg\_flags(msg)        (msg)-\/>cb[2]}}
\DoxyCodeLine{14 }
\DoxyCodeLine{16 \textcolor{preprocessor}{\#define msgb\_sctp\_ppid(msg)             (msg)-\/>cb[3]}}
\DoxyCodeLine{18 \textcolor{preprocessor}{\#define msgb\_sctp\_stream(msg)           (msg)-\/>cb[4]}}
\DoxyCodeLine{19 }
\DoxyCodeLine{66 \textcolor{keyword}{struct }osmo\_stream\_srv\_link;}
\DoxyCodeLine{67 }
\DoxyCodeLine{68 \textcolor{keyword}{typedef} int (*osmo\_stream\_srv\_link\_accept\_cb\_t)(\textcolor{keyword}{struct }osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{int} fd);}
\DoxyCodeLine{69 }
\DoxyCodeLine{70 \textcolor{keyword}{struct }osmo\_stream\_srv\_link *osmo\_stream\_srv\_link\_create(\textcolor{keywordtype}{void} *ctx);}
\DoxyCodeLine{71 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_destroy(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{72 }
\DoxyCodeLine{73 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_set\_name(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name);}
\DoxyCodeLine{74 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_stream\_srv\_link\_get\_name(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{75 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_set\_nodelay(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{bool} nodelay);}
\DoxyCodeLine{76 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_set\_priority(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{int} sk\_prio);}
\DoxyCodeLine{77 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_set\_ip\_dscp(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, uint8\_t ip\_dscp);}
\DoxyCodeLine{78 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_set\_addr(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *addr);}
\DoxyCodeLine{79 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_set\_addrs(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keyword}{const} \textcolor{keywordtype}{char} **addr, \textcolor{keywordtype}{size\_t} addrcnt);}
\DoxyCodeLine{80 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_set\_port(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, uint16\_t port);}
\DoxyCodeLine{81 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_set\_proto(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, uint16\_t proto);}
\DoxyCodeLine{82 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_set\_type(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{int} type);}
\DoxyCodeLine{83 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_set\_domain(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{int} domain);}
\DoxyCodeLine{84 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_set\_accept\_cb(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, osmo\_stream\_srv\_link\_accept\_cb\_t accept\_cb);}
\DoxyCodeLine{85 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_set\_data(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{void} *data);}
\DoxyCodeLine{86 \textcolor{keywordtype}{void} *osmo\_stream\_srv\_link\_get\_data(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{87 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_set\_tx\_queue\_max\_length(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{unsigned} \textcolor{keywordtype}{int} size);}
\DoxyCodeLine{88 \textcolor{keywordtype}{char} *osmo\_stream\_srv\_link\_get\_sockname(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{89 \textcolor{keyword}{struct }osmo\_fd *osmo\_stream\_srv\_link\_get\_ofd(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{90 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_get\_fd(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{91 \textcolor{keywordtype}{bool} osmo\_stream\_srv\_link\_is\_opened(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{92 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_open(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{93 \textcolor{keywordtype}{void} osmo\_stream\_srv\_link\_close(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link);}
\DoxyCodeLine{94 }
\DoxyCodeLine{95 \textcolor{keyword}{enum} osmo\_stream\_srv\_link\_param \{}
\DoxyCodeLine{96         OSMO\_STREAM\_SRV\_LINK\_PAR\_SCTP\_SOCKOPT\_AUTH\_SUPPORTED, \textcolor{comment}{/* uint8\_t: 0 disable, 1 enable, 2 force disable, 3 force enable */}}
\DoxyCodeLine{97         OSMO\_STREAM\_SRV\_LINK\_PAR\_SCTP\_SOCKOPT\_ASCONF\_SUPPORTED, \textcolor{comment}{/* uint8\_t: 0 disable, 1 enable, 2 force disable, 3 force enable */}}
\DoxyCodeLine{98         OSMO\_STREAM\_SRV\_LINK\_PAR\_SCTP\_INIT\_NUM\_OSTREAMS, \textcolor{comment}{/* uint16\_t: amount of streams */}}
\DoxyCodeLine{99         OSMO\_STREAM\_SRV\_LINK\_PAR\_SCTP\_INIT\_MAX\_INSTREAMS, \textcolor{comment}{/* uint16\_t: amount of streams */}}
\DoxyCodeLine{100 \};}
\DoxyCodeLine{101 }
\DoxyCodeLine{102 \textcolor{keywordtype}{int} osmo\_stream\_srv\_link\_set\_param(\textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keyword}{enum} osmo\_stream\_srv\_link\_param par,}
\DoxyCodeLine{103                                    \textcolor{keywordtype}{void} *val, \textcolor{keywordtype}{size\_t} val\_len);}
\DoxyCodeLine{104 }
\DoxyCodeLine{107 \textcolor{keyword}{struct }osmo\_stream\_srv;}
\DoxyCodeLine{108 }
\DoxyCodeLine{109 \textcolor{keyword}{typedef} int (*osmo\_stream\_srv\_read\_cb\_t)(\textcolor{keyword}{struct }osmo\_stream\_srv *conn);}
\DoxyCodeLine{110 \textcolor{keyword}{typedef} int (*osmo\_stream\_srv\_closed\_cb\_t)(\textcolor{keyword}{struct }osmo\_stream\_srv *conn);}
\DoxyCodeLine{111 }
\DoxyCodeLine{117 \textcolor{keyword}{typedef} int (*osmo\_stream\_srv\_read\_cb2\_t)(\textcolor{keyword}{struct }osmo\_stream\_srv *conn, \textcolor{keywordtype}{int} res, \textcolor{keyword}{struct }msgb *msg);}
\DoxyCodeLine{118 }
\DoxyCodeLine{119 \textcolor{keyword}{typedef} int (*osmo\_stream\_srv\_segmentation\_cb\_t)(\textcolor{keyword}{struct }msgb *msg);}
\DoxyCodeLine{120 }
\DoxyCodeLine{121 \textcolor{keyword}{struct }osmo\_stream\_srv *osmo\_stream\_srv\_create(\textcolor{keywordtype}{void} *ctx, \textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{int} fd,}
\DoxyCodeLine{122                                                osmo\_stream\_srv\_read\_cb\_t read\_cb,}
\DoxyCodeLine{123                                                osmo\_stream\_srv\_closed\_cb\_t closed\_cb,}
\DoxyCodeLine{124                                                \textcolor{keywordtype}{void} *data);}
\DoxyCodeLine{125 \textcolor{keyword}{struct }osmo\_stream\_srv *osmo\_stream\_srv\_create2(\textcolor{keywordtype}{void} *ctx, \textcolor{keyword}{struct} osmo\_stream\_srv\_link *link, \textcolor{keywordtype}{int} fd, \textcolor{keywordtype}{void} *data);}
\DoxyCodeLine{126 \textcolor{keywordtype}{void} osmo\_stream\_srv\_set\_name(\textcolor{keyword}{struct} osmo\_stream\_srv *conn, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name);}
\DoxyCodeLine{127 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_stream\_srv\_get\_name(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_srv *conn);}
\DoxyCodeLine{128 \textcolor{keywordtype}{void} osmo\_stream\_srv\_set\_read\_cb(\textcolor{keyword}{struct} osmo\_stream\_srv *conn, osmo\_stream\_srv\_read\_cb2\_t read\_cb);}
\DoxyCodeLine{129 \textcolor{keywordtype}{void} osmo\_stream\_srv\_set\_closed\_cb(\textcolor{keyword}{struct} osmo\_stream\_srv *conn, osmo\_stream\_srv\_closed\_cb\_t close\_cb);}
\DoxyCodeLine{130 \textcolor{keywordtype}{void} *osmo\_stream\_srv\_get\_data(\textcolor{keyword}{struct} osmo\_stream\_srv *conn);}
\DoxyCodeLine{131 \textcolor{keyword}{struct }osmo\_stream\_srv\_link *osmo\_stream\_srv\_get\_master(\textcolor{keyword}{struct} osmo\_stream\_srv *conn);}
\DoxyCodeLine{132 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_stream\_srv\_get\_sockname(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_srv *conn);}
\DoxyCodeLine{133 \textcolor{keyword}{struct }osmo\_fd *osmo\_stream\_srv\_get\_ofd(\textcolor{keyword}{struct} osmo\_stream\_srv *srv);}
\DoxyCodeLine{134 \textcolor{keywordtype}{int} osmo\_stream\_srv\_get\_fd(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_srv *srv);}
\DoxyCodeLine{135 \textcolor{keyword}{struct }osmo\_io\_fd *osmo\_stream\_srv\_get\_iofd(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_srv *srv);}
\DoxyCodeLine{136 \textcolor{keywordtype}{void} osmo\_stream\_srv\_destroy(\textcolor{keyword}{struct} osmo\_stream\_srv *conn);}
\DoxyCodeLine{137 }
\DoxyCodeLine{138 \textcolor{keywordtype}{void} osmo\_stream\_srv\_set\_flush\_and\_destroy(\textcolor{keyword}{struct} osmo\_stream\_srv *conn);}
\DoxyCodeLine{139 \textcolor{keywordtype}{void} osmo\_stream\_srv\_set\_data(\textcolor{keyword}{struct} osmo\_stream\_srv *conn, \textcolor{keywordtype}{void} *data);}
\DoxyCodeLine{140 }
\DoxyCodeLine{141 \textcolor{keywordtype}{void} osmo\_stream\_srv\_set\_segmentation\_cb(\textcolor{keyword}{struct} osmo\_stream\_srv *conn, osmo\_stream\_srv\_segmentation\_cb\_t segmentation\_cb);}
\DoxyCodeLine{142 }
\DoxyCodeLine{143 \textcolor{keywordtype}{void} osmo\_stream\_srv\_send(\textcolor{keyword}{struct} osmo\_stream\_srv *conn, \textcolor{keyword}{struct} msgb *msg);}
\DoxyCodeLine{144 \textcolor{keywordtype}{int} osmo\_stream\_srv\_recv(\textcolor{keyword}{struct} osmo\_stream\_srv *conn, \textcolor{keyword}{struct} msgb *msg);}
\DoxyCodeLine{145 }
\DoxyCodeLine{146 \textcolor{keywordtype}{void} osmo\_stream\_srv\_clear\_tx\_queue(\textcolor{keyword}{struct} osmo\_stream\_srv *conn);}
\DoxyCodeLine{147 }
\DoxyCodeLine{186 \textcolor{keyword}{struct }osmo\_stream\_cli;}
\DoxyCodeLine{187 }
\DoxyCodeLine{188 \textcolor{keyword}{typedef} int (*osmo\_stream\_cli\_connect\_cb\_t)(\textcolor{keyword}{struct }osmo\_stream\_cli *cli);}
\DoxyCodeLine{189 \textcolor{keyword}{typedef} int (*osmo\_stream\_cli\_disconnect\_cb\_t)(\textcolor{keyword}{struct }osmo\_stream\_cli *cli);}
\DoxyCodeLine{190 \textcolor{keyword}{typedef} int (*osmo\_stream\_cli\_read\_cb\_t)(\textcolor{keyword}{struct }osmo\_stream\_cli *cli);}
\DoxyCodeLine{191 }
\DoxyCodeLine{197 \textcolor{keyword}{typedef} int (*osmo\_stream\_cli\_read\_cb2\_t)(\textcolor{keyword}{struct }osmo\_stream\_cli *cli, \textcolor{keywordtype}{int} res, \textcolor{keyword}{struct }msgb *msg);}
\DoxyCodeLine{198 }
\DoxyCodeLine{199 \textcolor{keyword}{typedef} int (*osmo\_stream\_cli\_segmentation\_cb\_t)(\textcolor{keyword}{struct }msgb *msg);}
\DoxyCodeLine{200 }
\DoxyCodeLine{201 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_name(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *name);}
\DoxyCodeLine{202 \textcolor{keyword}{const} \textcolor{keywordtype}{char} *osmo\_stream\_cli\_get\_name(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{203 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_nodelay(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keywordtype}{bool} nodelay);}
\DoxyCodeLine{204 \textcolor{keywordtype}{int} osmo\_stream\_cli\_set\_priority(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keywordtype}{int} sk\_prio);}
\DoxyCodeLine{205 \textcolor{keywordtype}{int} osmo\_stream\_cli\_set\_ip\_dscp(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, uint8\_t ip\_dscp);}
\DoxyCodeLine{206 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_addr(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *addr);}
\DoxyCodeLine{207 \textcolor{keywordtype}{int} osmo\_stream\_cli\_set\_addrs(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keyword}{const} \textcolor{keywordtype}{char} **addr, \textcolor{keywordtype}{size\_t} addrcnt);}
\DoxyCodeLine{208 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_port(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, uint16\_t port);}
\DoxyCodeLine{209 \textcolor{keywordtype}{int} osmo\_stream\_cli\_set\_type(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keywordtype}{int} type);}
\DoxyCodeLine{210 \textcolor{keywordtype}{int} osmo\_stream\_cli\_set\_domain(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keywordtype}{int} domain);}
\DoxyCodeLine{211 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_proto(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, uint16\_t proto);}
\DoxyCodeLine{212 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_local\_addr(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keyword}{const} \textcolor{keywordtype}{char} *addr);}
\DoxyCodeLine{213 \textcolor{keywordtype}{int} osmo\_stream\_cli\_set\_local\_addrs(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keyword}{const} \textcolor{keywordtype}{char} **addr, \textcolor{keywordtype}{size\_t} addrcnt);}
\DoxyCodeLine{214 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_local\_port(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, uint16\_t port);}
\DoxyCodeLine{215 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_data(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keywordtype}{void} *data);}
\DoxyCodeLine{216 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_reconnect\_timeout(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keywordtype}{int} timeout);}
\DoxyCodeLine{217 \textcolor{keywordtype}{void} *osmo\_stream\_cli\_get\_data(\textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{218 \textcolor{keywordtype}{int} osmo\_stream\_cli\_set\_tx\_queue\_max\_length(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keywordtype}{unsigned} \textcolor{keywordtype}{int} size);}
\DoxyCodeLine{219 \textcolor{keywordtype}{char} *osmo\_stream\_cli\_get\_sockname(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{220 \textcolor{keyword}{struct }osmo\_fd *osmo\_stream\_cli\_get\_ofd(\textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{221 \textcolor{keywordtype}{int} osmo\_stream\_cli\_get\_fd(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{222 \textcolor{keyword}{struct }osmo\_io\_fd *osmo\_stream\_cli\_get\_iofd(\textcolor{keyword}{const} \textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{223 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_connect\_cb(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, osmo\_stream\_cli\_connect\_cb\_t connect\_cb);}
\DoxyCodeLine{224 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_disconnect\_cb(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, osmo\_stream\_cli\_disconnect\_cb\_t disconnect\_cb);}
\DoxyCodeLine{225 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_read\_cb(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, osmo\_stream\_cli\_read\_cb\_t read\_cb);}
\DoxyCodeLine{226 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_read\_cb2(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, osmo\_stream\_cli\_read\_cb2\_t read\_cb);}
\DoxyCodeLine{227 \textcolor{keywordtype}{void} osmo\_stream\_cli\_set\_segmentation\_cb(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, osmo\_stream\_cli\_segmentation\_cb\_t segmentation\_cb);}
\DoxyCodeLine{228 \textcolor{keywordtype}{void} osmo\_stream\_cli\_reconnect(\textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{229 \textcolor{keywordtype}{bool} osmo\_stream\_cli\_is\_connected(\textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{230 }
\DoxyCodeLine{231 \textcolor{keyword}{struct }osmo\_stream\_cli *osmo\_stream\_cli\_create(\textcolor{keywordtype}{void} *ctx);}
\DoxyCodeLine{232 \textcolor{keywordtype}{void} osmo\_stream\_cli\_destroy(\textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{233 }
\DoxyCodeLine{234 \textcolor{keywordtype}{int} osmo\_stream\_cli\_open(\textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{235 \textcolor{keywordtype}{int} osmo\_stream\_cli\_open2(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keywordtype}{int} reconnect) \(\backslash\)}
\DoxyCodeLine{236         OSMO\_DEPRECATED(\textcolor{stringliteral}{"{}Use osmo\_stream\_cli\_set\_reconnect\_timeout() or osmo\_stream\_cli\_reconnect() instead"{}});}
\DoxyCodeLine{237 \textcolor{keywordtype}{void} osmo\_stream\_cli\_close(\textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{238 }
\DoxyCodeLine{239 \textcolor{keywordtype}{void} osmo\_stream\_cli\_send(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keyword}{struct} msgb *msg);}
\DoxyCodeLine{240 \textcolor{keywordtype}{int} osmo\_stream\_cli\_recv(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keyword}{struct} msgb *msg);}
\DoxyCodeLine{241 }
\DoxyCodeLine{242 \textcolor{keywordtype}{void} osmo\_stream\_cli\_clear\_tx\_queue(\textcolor{keyword}{struct} osmo\_stream\_cli *cli);}
\DoxyCodeLine{243 }
\DoxyCodeLine{244 \textcolor{keyword}{enum} osmo\_stream\_cli\_param \{}
\DoxyCodeLine{245         OSMO\_STREAM\_CLI\_PAR\_SCTP\_SOCKOPT\_AUTH\_SUPPORTED, \textcolor{comment}{/* uint8\_t: 0 disable, 1 enable, 2 force disable, 3 force enable */}}
\DoxyCodeLine{246         OSMO\_STREAM\_CLI\_PAR\_SCTP\_SOCKOPT\_ASCONF\_SUPPORTED, \textcolor{comment}{/* uint8\_t: 0 disable, 1 enable, 2 force disable, 3 force enable */}}
\DoxyCodeLine{247         OSMO\_STREAM\_CLI\_PAR\_SCTP\_INIT\_NUM\_OSTREAMS, \textcolor{comment}{/* uint16\_t: amount of streams */}}
\DoxyCodeLine{248         OSMO\_STREAM\_CLI\_PAR\_SCTP\_INIT\_MAX\_INSTREAMS, \textcolor{comment}{/* uint16\_t: amount of streams */}}
\DoxyCodeLine{249         OSMO\_STREAM\_CLI\_PAR\_SCTP\_INIT\_MAX\_ATTEMPTS, \textcolor{comment}{/* uint16\_t: amount of attempts */}}
\DoxyCodeLine{250         OSMO\_STREAM\_CLI\_PAR\_SCTP\_INIT\_TIMEOUT, \textcolor{comment}{/* uint16\_t: milliseconds */}}
\DoxyCodeLine{251 \};}
\DoxyCodeLine{252 }
\DoxyCodeLine{253 \textcolor{keywordtype}{int} osmo\_stream\_cli\_set\_param(\textcolor{keyword}{struct} osmo\_stream\_cli *cli, \textcolor{keyword}{enum} osmo\_stream\_cli\_param par,}
\DoxyCodeLine{254                               \textcolor{keywordtype}{void} *val, \textcolor{keywordtype}{size\_t} val\_len);}
\DoxyCodeLine{255 }

\end{DoxyCode}
