<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version="1.8.16">
  <compounddef id="group__netif" kind="group">
    <compoundname>netif</compoundname>
    <title>Network interface (NETIF)</title>
    <innergroup refid="group__netif__flags">Flags</innergroup>
    <innergroup refid="group__netif__mib2">MIB2 statistics</innergroup>
    <innergroup refid="group__netif__ip4">IPv4 address handling</innergroup>
    <innergroup refid="group__netif__ip6">IPv6 address handling</innergroup>
    <innergroup refid="group__netif__cd">Client data handling</innergroup>
      <sectiondef kind="func">
      <memberdef kind="function" id="group__netif_1ga66970b5877dd6b0cae906bfa78d0cb4c" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
        <definition>struct netif* netif_add</definition>
        <argsstring>(struct netif *netif, void *state, netif_init_fn init, netif_input_fn input)</argsstring>
        <name>netif_add</name>
        <param>
          <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
          <declname>netif</declname>
        </param>
        <param>
          <type>void *</type>
          <declname>state</declname>
        </param>
        <param>
          <type><ref refid="netif_8h_1a2b02a78a8769925ff8e4f83d34e5e1f5" kindref="member">netif_init_fn</ref></type>
          <declname>init</declname>
        </param>
        <param>
          <type><ref refid="netif_8h_1ab2302b1b64ac7b95f24c6bab754a575e" kindref="member">netif_input_fn</ref></type>
          <declname>input</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Add a network interface to the list of lwIP netifs.</para>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername>netif</parametername>
</parameternamelist>
<parameterdescription>
<para>a pre-allocated netif structure </para>
</parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername>ipaddr</parametername>
</parameternamelist>
<parameterdescription>
<para>IP address for the new netif </para>
</parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername>netmask</parametername>
</parameternamelist>
<parameterdescription>
<para>network mask for the new netif </para>
</parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername>gw</parametername>
</parameternamelist>
<parameterdescription>
<para>default gateway IP address for the new netif </para>
</parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername>state</parametername>
</parameternamelist>
<parameterdescription>
<para>opaque data passed to the new netif </para>
</parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername>init</parametername>
</parameternamelist>
<parameterdescription>
<para>callback function that initializes the interface </para>
</parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername>input</parametername>
</parameternamelist>
<parameterdescription>
<para>callback function that is called to pass ingress packets up in the protocol layer stack.<linebreak/>
It is recommended to use a function that passes the input directly to the stack (<ref refid="netif_8c_1a5532f93d68c874fb99c681bff2165385" kindref="member">netif_input()</ref>, NO_SYS=1 mode) or via sending a message to TCPIP thread (<ref refid="tcpip_8h_1ae510f195171bed8499ae94e264a92717" kindref="member">tcpip_input()</ref>, NO_SYS=0 mode).<linebreak/>
These functions use netif flags NETIF_FLAG_ETHARP and NETIF_FLAG_ETHERNET to decide whether to forward to ethernet_input() or ip_input(). In other words, the functions only work when the netif driver is implemented correctly!<linebreak/>
Most members of struct netif should be be initialized by the netif init function = netif driver (init parameter of this function).<linebreak/>
IPv6: Don&apos;t forget to call netif_create_ip6_linklocal_address() after setting the MAC address in struct <ref refid="structnetif_1aee967965d999fc1a4c40a66709304e69" kindref="member">netif.hwaddr</ref> (IPv6 requires a link-local address).</para>
</parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>netif, or NULL if failed. </para>
</simplesect>
</para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/net/core/netif.c" line="241" column="1" bodyfile="C:/Dev/git/UbixOS/sys/net/core/netif.c" bodystart="241" bodyend="338"/>
        <references refid="structnetif_1a1c171db6097bbb6f09f63549a66e00ea" compoundref="netif_8h" startline="313">flags</references>
        <references refid="ip__addr_8h_1afb3a0e5241683aff573e195f31ba8845" compoundref="ip__addr_8h" startline="310">ip_addr_set_zero_ip6</references>
        <references refid="debug_8h_1a94ad086267808462beae2b38f91996ed" compoundref="debug_8h" startline="116">LWIP_ASSERT</references>
        <references refid="lwipopts_8h_1a16c1b672604bfb0a66a6aeeb854589d3" compoundref="lwipopts_8h" startline="367">LWIP_IPV6_NUM_ADDRESSES</references>
        <references refid="lwipopts_8h_1a980909018aed54adc10dd68be3572b30" compoundref="lwipopts_8h" startline="385">LWIP_ND6_MAX_MULTICAST_SOLICIT</references>
        <references refid="string_8h_1ace4b911463887af5e748326323e99a23">memset</references>
        <references refid="netif_8h_1ac0aca2a2d3c7d7095939d818acf4dbd2" compoundref="netif_8h" startline="356">NETIF_SET_CHECKSUM_CTRL</references>
        <references refid="fat__string_8h_1a070d2ce7b6bb7e5c05602aa8c308d0c4" compoundref="fat__string_8h" startline="17">NULL</references>
        <references refid="structnetif_1ab7ef01e505dd2feb781fe86756b1c973" compoundref="netif_8h" startline="317">num</references>
        <references refid="structnetif_1a809cc57c0dff09c5c9ae45b02c2002f3" compoundref="netif_8h" startline="287">state</references>
        <referencedby refid="net_2init_8c_1a22b2914249628f6cba7d4e1f138c969f" compoundref="net_2init_8c" startline="52" endline="70">net_init</referencedby>
        <referencedby refid="netif_8c_1a0f4a53e47c840904f824a2a1c0d4ebf4" compoundref="netif_8c" startline="163" endline="191">netif_init</referencedby>
      </memberdef>
      <memberdef kind="function" id="group__netif_1ga69c93a139e8a1f6ef4e3d076a2897def" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
        <definition>struct netif* netif_find</definition>
        <argsstring>(const char *name)</argsstring>
        <name>netif_find</name>
        <param>
          <type><ref refid="cdefs_8h_1a2c212835823e3c54a8ab6d95c652660e" kindref="member">const</ref> char *</type>
          <declname>name</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Find a network interface by searching for its name</para>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername>name</parametername>
</parameternamelist>
<parameterdescription>
<para>the name of the netif (like netif-&gt;name) plus concatenated number in ascii representation (e.g. &apos;en0&apos;) </para>
</parameterdescription>
</parameteritem>
</parameterlist>
</para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/net/core/netif.c" line="472" column="1" bodyfile="C:/Dev/git/UbixOS/sys/net/core/netif.c" bodystart="472" bodyend="493"/>
        <references refid="debug_8h_1a63a04edf7ff63c951bd8706711956cdb" compoundref="debug_8h" startline="164">LWIP_DEBUGF</references>
        <references refid="pci_8c_1a8f8f80d37794cde9472343e4487ba3eb" compoundref="pci_8c" startline="37">name</references>
        <references refid="structnetif_1a32fca6ffd28bb9af3f891a378827a67e" compoundref="netif_8h" startline="315">name</references>
        <references refid="lwipopts_8h_1a2dfad02b075a7f9a8791a66fe40864a4" compoundref="lwipopts_8h" startline="433">NETIF_DEBUG</references>
        <references refid="netif_8c_1a1c8141eaa98f6dc6dfddbb23a706656c" compoundref="netif_8c" startline="104">netif_list</references>
        <references refid="structnetif_1ae77736b64df442242795220d76be6b86" compoundref="netif_8h" startline="235">next</references>
        <references refid="fat__string_8h_1a070d2ce7b6bb7e5c05602aa8c308d0c4" compoundref="fat__string_8h" startline="17">NULL</references>
        <references refid="structnetif_1ab7ef01e505dd2feb781fe86756b1c973" compoundref="netif_8h" startline="317">num</references>
      </memberdef>
      <memberdef kind="function" id="group__netif_1ga9c6e541f0c184e1ea61a5cd8afe3e979" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>void netif_remove</definition>
        <argsstring>(struct netif *netif)</argsstring>
        <name>netif_remove</name>
        <param>
          <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
          <declname>netif</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Remove a network interface from the list of lwIP netifs.</para>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername>netif</parametername>
</parameternamelist>
<parameterdescription>
<para>the network interface to remove </para>
</parameterdescription>
</parameteritem>
</parameterlist>
</para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/net/core/netif.c" line="377" column="1" bodyfile="C:/Dev/git/UbixOS/sys/net/core/netif.c" bodystart="377" bodyend="462"/>
        <references refid="structnetif_1a1c171db6097bbb6f09f63549a66e00ea" compoundref="netif_8h" startline="313">flags</references>
        <references refid="debug_8h_1a63a04edf7ff63c951bd8706711956cdb" compoundref="debug_8h" startline="164">LWIP_DEBUGF</references>
        <references refid="lwipopts_8h_1a16c1b672604bfb0a66a6aeeb854589d3" compoundref="lwipopts_8h" startline="367">LWIP_IPV6_NUM_ADDRESSES</references>
        <references refid="snmp_8h_1a8199a60f5794825ce5d9d03fa6d09ce8" compoundref="snmp_8h" startline="178">mib2_netif_removed</references>
        <references refid="snmp_8h_1adb3ddfac76153a97bbe02c220f8f85a0" compoundref="snmp_8h" startline="186">mib2_remove_ip4</references>
        <references refid="lwipopts_8h_1a2dfad02b075a7f9a8791a66fe40864a4" compoundref="lwipopts_8h" startline="433">NETIF_DEBUG</references>
        <references refid="netif_8c_1a3d0925cbce550ed461907aee816713ba" compoundref="netif_8c" startline="105">netif_default</references>
        <references refid="group__netif__flags_1gac9493b923d733c73f6006d9714826558" compoundref="netif_8h" startline="106">NETIF_FLAG_IGMP</references>
        <references refid="group__netif_1ga94a4c24c988afc0a577387730f303b19" compoundref="netif_8h" startline="409">netif_is_up</references>
        <references refid="netif_8c_1a1c8141eaa98f6dc6dfddbb23a706656c" compoundref="netif_8c" startline="104">netif_list</references>
        <references refid="group__netif_1gac90f290edd005238d62aa94c4ac9dea3" compoundref="netif_8c" startline="604" endline="616">netif_set_default</references>
        <references refid="group__netif_1ga641d07ed8c31fe5306bc01605a6790cf" compoundref="netif_8c" startline="682" endline="700">netif_set_down</references>
        <references refid="structnetif_1ae77736b64df442242795220d76be6b86" compoundref="netif_8h" startline="235">next</references>
        <references refid="fat__string_8h_1a070d2ce7b6bb7e5c05602aa8c308d0c4" compoundref="fat__string_8h" startline="17">NULL</references>
      </memberdef>
      <memberdef kind="function" id="group__netif_1gac90f290edd005238d62aa94c4ac9dea3" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>void netif_set_default</definition>
        <argsstring>(struct netif *netif)</argsstring>
        <name>netif_set_default</name>
        <param>
          <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
          <declname>netif</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Set a network interface as the default network interface (used to output all packets for which no specific route is found)</para>
<para><parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername>netif</parametername>
</parameternamelist>
<parameterdescription>
<para>the default network interface </para>
</parameterdescription>
</parameteritem>
</parameterlist>
</para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/net/core/netif.c" line="604" column="1" bodyfile="C:/Dev/git/UbixOS/sys/net/core/netif.c" bodystart="604" bodyend="616"/>
        <references refid="debug_8h_1a63a04edf7ff63c951bd8706711956cdb" compoundref="debug_8h" startline="164">LWIP_DEBUGF</references>
        <references refid="snmp_8h_1a4fc7123213fe9bbf0fb743e953f24043" compoundref="snmp_8h" startline="187">mib2_add_route_ip4</references>
        <references refid="snmp_8h_1aa3d83533068f4a497d6e29288973c9c3" compoundref="snmp_8h" startline="188">mib2_remove_route_ip4</references>
        <references refid="structnetif_1a32fca6ffd28bb9af3f891a378827a67e" compoundref="netif_8h" startline="315">name</references>
        <references refid="lwipopts_8h_1a2dfad02b075a7f9a8791a66fe40864a4" compoundref="lwipopts_8h" startline="433">NETIF_DEBUG</references>
        <references refid="netif_8c_1a3d0925cbce550ed461907aee816713ba" compoundref="netif_8c" startline="105">netif_default</references>
        <references refid="fat__string_8h_1a070d2ce7b6bb7e5c05602aa8c308d0c4" compoundref="fat__string_8h" startline="17">NULL</references>
        <referencedby refid="net_2init_8c_1a22b2914249628f6cba7d4e1f138c969f" compoundref="net_2init_8c" startline="52" endline="70">net_init</referencedby>
        <referencedby refid="group__netif_1ga9c6e541f0c184e1ea61a5cd8afe3e979" compoundref="netif_8c" startline="377" endline="462">netif_remove</referencedby>
      </memberdef>
      <memberdef kind="function" id="group__netif_1ga641d07ed8c31fe5306bc01605a6790cf" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>void netif_set_down</definition>
        <argsstring>(struct netif *netif)</argsstring>
        <name>netif_set_down</name>
        <param>
          <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
          <declname>netif</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Bring an interface down, disabling any traffic processing. </para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/net/core/netif.c" line="682" column="1" bodyfile="C:/Dev/git/UbixOS/sys/net/core/netif.c" bodystart="682" bodyend="700"/>
        <references refid="structnetif_1a1c171db6097bbb6f09f63549a66e00ea" compoundref="netif_8h" startline="313">flags</references>
        <references refid="snmp_8h_1abe6b270482ca9af07c029f3136d8ec9c" compoundref="snmp_8h" startline="136">MIB2_COPY_SYSUPTIME_TO</references>
        <references refid="group__netif__flags_1ga92448dc510bc8d700c09e5c971ef0676" compoundref="netif_8h" startline="99">NETIF_FLAG_ETHARP</references>
        <references refid="group__netif__flags_1gab47d7d130693dc155f480a5bf447725e" compoundref="netif_8h" startline="86">NETIF_FLAG_UP</references>
        <references refid="netif_8c_1a67d78318251432e9e4416f7ceab23ecb" compoundref="netif_8c" startline="95">NETIF_STATUS_CALLBACK</references>
        <referencedby refid="group__netif_1ga9c6e541f0c184e1ea61a5cd8afe3e979" compoundref="netif_8c" startline="377" endline="462">netif_remove</referencedby>
      </memberdef>
      <memberdef kind="function" id="group__netif_1ga34e37a1e8e358760dc1c43887922c7db" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>void netif_set_link_down</definition>
        <argsstring>(struct netif *netif)</argsstring>
        <name>netif_set_link_down</name>
        <param>
          <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
          <declname>netif</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Called by a driver when its link goes down </para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/net/core/netif.c" line="760" column="1" bodyfile="C:/Dev/git/UbixOS/sys/net/core/netif.c" bodystart="760" bodyend="766"/>
        <references refid="structnetif_1a1c171db6097bbb6f09f63549a66e00ea" compoundref="netif_8h" startline="313">flags</references>
        <references refid="group__netif__flags_1ga75f5a2b9276c93e3bd18a568459fd2d8" compoundref="netif_8h" startline="95">NETIF_FLAG_LINK_UP</references>
        <references refid="netif_8c_1aa4ea2644fa9858891412e976a24a0179" compoundref="netif_8c" startline="101">NETIF_LINK_CALLBACK</references>
      </memberdef>
      <memberdef kind="function" id="group__netif_1gae0d2975f189277990e9d5276fdd9e9ea" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>void netif_set_link_up</definition>
        <argsstring>(struct netif *netif)</argsstring>
        <name>netif_set_link_up</name>
        <param>
          <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
          <declname>netif</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Called by a driver when its link goes up </para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/net/core/netif.c" line="735" column="1" bodyfile="C:/Dev/git/UbixOS/sys/net/core/netif.c" bodystart="735" bodyend="753"/>
        <references refid="structnetif_1a1c171db6097bbb6f09f63549a66e00ea" compoundref="netif_8h" startline="313">flags</references>
        <references refid="group__netif__flags_1ga75f5a2b9276c93e3bd18a568459fd2d8" compoundref="netif_8h" startline="95">NETIF_FLAG_LINK_UP</references>
        <references refid="group__netif__flags_1gab47d7d130693dc155f480a5bf447725e" compoundref="netif_8h" startline="86">NETIF_FLAG_UP</references>
        <referencedby refid="net_2init_8c_1a22b2914249628f6cba7d4e1f138c969f" compoundref="net_2init_8c" startline="52" endline="70">net_init</referencedby>
        <referencedby refid="netif_8c_1a0f4a53e47c840904f824a2a1c0d4ebf4" compoundref="netif_8c" startline="163" endline="191">netif_init</referencedby>
      </memberdef>
      <memberdef kind="function" id="group__netif_1gaf19693be401a265a52d2a56c65753121" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>void netif_set_up</definition>
        <argsstring>(struct netif *netif)</argsstring>
        <name>netif_set_up</name>
        <param>
          <type>struct <ref refid="structnetif" kindref="compound">netif</ref> *</type>
          <declname>netif</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Bring an interface up, available for processing traffic. </para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/net/core/netif.c" line="624" column="1" bodyfile="C:/Dev/git/UbixOS/sys/net/core/netif.c" bodystart="624" bodyend="637"/>
        <references refid="structnetif_1a1c171db6097bbb6f09f63549a66e00ea" compoundref="netif_8h" startline="313">flags</references>
        <references refid="snmp_8h_1abe6b270482ca9af07c029f3136d8ec9c" compoundref="snmp_8h" startline="136">MIB2_COPY_SYSUPTIME_TO</references>
        <references refid="group__netif__flags_1ga75f5a2b9276c93e3bd18a568459fd2d8" compoundref="netif_8h" startline="95">NETIF_FLAG_LINK_UP</references>
        <references refid="group__netif__flags_1gab47d7d130693dc155f480a5bf447725e" compoundref="netif_8h" startline="86">NETIF_FLAG_UP</references>
        <references refid="netif_8c_1a67d78318251432e9e4416f7ceab23ecb" compoundref="netif_8c" startline="95">NETIF_STATUS_CALLBACK</references>
        <referencedby refid="net_2init_8c_1a22b2914249628f6cba7d4e1f138c969f" compoundref="net_2init_8c" startline="52" endline="70">net_init</referencedby>
        <referencedby refid="netif_8c_1a0f4a53e47c840904f824a2a1c0d4ebf4" compoundref="netif_8c" startline="163" endline="191">netif_init</referencedby>
      </memberdef>
      </sectiondef>
      <sectiondef kind="define">
      <memberdef kind="define" id="group__netif_1ga94a4c24c988afc0a577387730f303b19" prot="public" static="no">
        <name>netif_is_up</name>
        <param><defname>netif</defname></param>
        <initializer>(((<ref refid="structnetif" kindref="compound">netif</ref>)-&gt;flags &amp; <ref refid="group__netif__flags_1gab47d7d130693dc155f480a5bf447725e" kindref="member">NETIF_FLAG_UP</ref>) ? (<ref refid="group__compiler__abstraction_1ga4caecabca98b43919dd11be1c0d4cd8e" kindref="member">u8_t</ref>)1 : (<ref refid="group__compiler__abstraction_1ga4caecabca98b43919dd11be1c0d4cd8e" kindref="member">u8_t</ref>)0)</initializer>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Ask if an interface is up </para>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Dev/git/UbixOS/sys/include/net/netif.h" line="409" column="9" bodyfile="C:/Dev/git/UbixOS/sys/include/net/netif.h" bodystart="409" bodyend="-1"/>
      </memberdef>
      </sectiondef>
    <briefdescription>
    </briefdescription>
    <detaileddescription>
    </detaileddescription>
  </compounddef>
</doxygen>
