<?xml version='1.0' encoding='iso-8859-1' standalone='no'?> <doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version="1.4.7"> <compounddef id="ipv4_2ip__addr_8h" kind="file"> <compoundname>ip_addr.h</compoundname> <includes refid="arch_8h" local="yes">net/arch.h</includes> <includedby refid="ipv4_2inet_8h" local="yes">src/sys/include/net/ipv4/inet.h</includedby> <includedby refid="ipv4_2ip_8h" local="yes">src/sys/include/net/ipv4/ip.h</includedby> <includedby refid="netif_8h" local="yes">src/sys/include/net/netif.h</includedby> <includedby refid="arp_8h" local="yes">src/sys/include/netif/arp.h</includedby> <incdepgraph> <node id="773"> <label>arch/cpu.h</label> <link refid="cpu_8h"/> </node> <node id="772"> <label>net/arch.h</label> <link refid="arch_8h"/> <childnode refid="773" relation="include"> </childnode> <childnode refid="774" relation="include"> </childnode> </node> <node id="771"> <label>src/sys/include/net/ipv4/ip_addr.h</label> <link refid="ipv4/ip_addr.h"/> <childnode refid="772" relation="include"> </childnode> </node> <node id="774"> <label>arch/cc.h</label> <link refid="cc_8h"/> </node> </incdepgraph> <invincdepgraph> <node id="790"> <label>src/sys/net/net/udpecho.c</label> <link refid="udpecho_8c"/> </node> <node id="793"> <label>src/sys/include/net/ipv4/ip.h</label> <link refid="ipv4_2ip_8h"/> <childnode refid="780" relation="include"> </childnode> <childnode refid="781" relation="include"> </childnode> <childnode refid="779" relation="include"> </childnode> <childnode refid="794" relation="include"> </childnode> <childnode refid="784" relation="include"> </childnode> <childnode refid="795" relation="include"> </childnode> <childnode refid="791" relation="include"> </childnode> <childnode refid="792" relation="include"> </childnode> </node> <node id="792"> <label>src/sys/net/netif/tcpdump.c</label> <link refid="tcpdump_8c"/> </node> <node id="777"> <label>src/sys/include/net/netif.h</label> <link refid="netif_8h"/> <childnode refid="778" relation="include"> </childnode> <childnode refid="793" relation="include"> </childnode> <childnode refid="796" relation="include"> </childnode> <childnode refid="798" relation="include"> </childnode> <childnode refid="799" relation="include"> </childnode> </node> <node id="791"> <label>src/sys/net/netif/loopif.c</label> <link refid="loopif_8c"/> </node> <node id="794"> <label>src/sys/include/net/udp.h</label> <link refid="udp_8h"/> <childnode refid="780" relation="include"> </childnode> <childnode refid="781" relation="include"> </childnode> <childnode refid="784" relation="include"> </childnode> <childnode refid="792" relation="include"> </childnode> </node> <node id="796"> <label>src/sys/include/netif/arp.h</label> <link refid="arp_8h"/> <childnode refid="795" relation="include"> </childnode> <childnode refid="797" relation="include"> </childnode> </node> <node id="779"> <label>src/sys/include/net/tcp.h</label> <link refid="tcp_8h"/> <childnode refid="780" relation="include"> </childnode> <childnode refid="781" relation="include"> </childnode> <childnode refid="784" relation="include"> </childnode> <childnode refid="791" relation="include"> </childnode> <childnode refid="792" relation="include"> </childnode> </node> <node id="797"> <label>src/sys/net/netif/ethernetif.c</label> <link refid="ethernetif_8c"/> </node> <node id="795"> <label>src/sys/net/netif/arp.c</label> <link refid="arp_8c"/> </node> <node id="778"> <label>src/sys/include/net/ipv4/icmp.h</label> <link refid="ipv4_2icmp_8h"/> <childnode refid="779" relation="include"> </childnode> </node> <node id="788"> <label>src/sys/net/net/bot.c</label> <link refid="bot_8c"/> </node> <node id="784"> <label>src/sys/net/api/tcpip.c</label> <link refid="tcpip_8c"/> </node> <node id="782"> <label>src/sys/include/net/tcpip.h</label> <link refid="tcpip_8h"/> <childnode refid="783" relation="include"> </childnode> <childnode refid="784" relation="include"> </childnode> <childnode refid="785" relation="include"> </childnode> </node> <node id="781"> <label>src/sys/include/net/api_msg.h</label> <link refid="api__msg_8h"/> <childnode refid="782" relation="include"> </childnode> <childnode refid="786" relation="include"> </childnode> <childnode refid="783" relation="include"> </childnode> </node> <node id="798"> <label>src/sys/include/netif/ethernetif.h</label> <link refid="ethernetif_8h"/> <childnode refid="785" relation="include"> </childnode> </node> <node id="789"> <label>src/sys/net/net/shell.c</label> <link refid="shell_8c"/> </node> <node id="786"> <label>src/sys/net/api/api_lib.c</label> <link refid="api__lib_8c"/> </node> <node id="785"> <label>src/sys/net/net/init.c</label> <link refid="init_8c"/> </node> <node id="775"> <label>src/sys/include/net/ipv4/ip_addr.h</label> <link refid="ipv4/ip_addr.h"/> <childnode refid="776" relation="include"> </childnode> <childnode refid="793" relation="include"> </childnode> <childnode refid="777" relation="include"> </childnode> <childnode refid="796" relation="include"> </childnode> </node> <node id="780"> <label>src/sys/include/net/api.h</label> <link refid="api_8h"/> <childnode refid="781" relation="include"> </childnode> <childnode refid="786" relation="include"> </childnode> <childnode refid="787" relation="include"> </childnode> <childnode refid="788" relation="include"> </childnode> <childnode refid="789" relation="include"> </childnode> <childnode refid="790" relation="include"> </childnode> </node> <node id="799"> <label>src/sys/include/netif/loopif.h</label> <link refid="loopif_8h"/> <childnode refid="785" relation="include"> </childnode> <childnode refid="791" relation="include"> </childnode> </node> <node id="787"> <label>src/sys/net/api/sockets.c</label> <link refid="sockets_8c"/> </node> <node id="783"> <label>src/sys/net/api/api_msg.c</label> <link refid="api__msg_8c"/> </node> <node id="776"> <label>src/sys/include/net/ipv4/inet.h</label> <link refid="ipv4_2inet_8h"/> <childnode refid="777" relation="include"> </childnode> <childnode refid="794" relation="include"> </childnode> <childnode refid="795" relation="include"> </childnode> <childnode refid="792" relation="include"> </childnode> </node> </invincdepgraph> <innerclass refid="structip__addr" prot="public">ip_addr</innerclass> <sectiondef kind="define"> <memberdef kind="define" id="ipv4_2ip__addr_8h_158aee4166c466f9ac7035bf5cc9f9974" prot="public" static="no"> <name>IP4_ADDR</name> <param><defname>ipaddr</defname></param> <param><defname>a</defname></param> <param><defname>b</defname></param> <param><defname>c</defname></param> <param><defname>d</defname></param> <initializer>(ipaddr)->addr = htonl(((<ref refid="types_8h_15847ea0262a5aa61eee48cbe95544a78" kindref="member">uInt32</ref>)(a & 0xff) << 24) | ((uInt32)(b & 0xff) << 16) | \ ((uInt32)(c & 0xff) << 8) | (uInt32)(d & 0xff))</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="53" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="52" bodyend="-1"/> <referencedby refid="bot_8c_1ab86e03f8301aa7da6924fe6120e0d31" compoundref="bot_8c" startline="56" endline="81">bot_thread</referencedby> <referencedby refid="init_8c_1ced8bfa512e574c34b87586a3de7a94a" compoundref="init_8c" startline="66" endline="92">netMainThread</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_132caf20405b8659c07758352746c4331" prot="public" static="no"> <name>ip4_addr1</name> <param><defname>ipaddr</defname></param> <initializer>((<ref refid="types_8h_1a4e0f27a9aca905e340c06d2dcae843c" kindref="member">uInt8</ref>)(ntohl((ipaddr)->addr) >> 24) & 0xff)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="82" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="82" bodyend="-1"/> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_1ee091caef24dd1705876bb8dbe28035c" prot="public" static="no"> <name>ip4_addr2</name> <param><defname>ipaddr</defname></param> <initializer>((<ref refid="types_8h_1a4e0f27a9aca905e340c06d2dcae843c" kindref="member">uInt8</ref>)(ntohl((ipaddr)->addr) >> 16) & 0xff)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="83" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="83" bodyend="-1"/> <referencedby refid="ethernetif_8c_1eb49a49ab62789d8e32fddf180d52ebf" compoundref="ethernetif_8c" startline="186" endline="263">ethernetif_output</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_1ead691bee580ea8111b70e67cf971c40" prot="public" static="no"> <name>ip4_addr3</name> <param><defname>ipaddr</defname></param> <initializer>((<ref refid="types_8h_1a4e0f27a9aca905e340c06d2dcae843c" kindref="member">uInt8</ref>)(ntohl((ipaddr)->addr) >> 8) & 0xff)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="84" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="84" bodyend="-1"/> <referencedby refid="ethernetif_8c_1eb49a49ab62789d8e32fddf180d52ebf" compoundref="ethernetif_8c" startline="186" endline="263">ethernetif_output</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_178cbf5c1fd832f909f755c4cc9036f02" prot="public" static="no"> <name>ip4_addr4</name> <param><defname>ipaddr</defname></param> <initializer>((<ref refid="types_8h_1a4e0f27a9aca905e340c06d2dcae843c" kindref="member">uInt8</ref>)(ntohl((ipaddr)->addr)) & 0xff)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="85" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="85" bodyend="-1"/> <referencedby refid="ethernetif_8c_1eb49a49ab62789d8e32fddf180d52ebf" compoundref="ethernetif_8c" startline="186" endline="263">ethernetif_output</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_13e5e67b7292b156034560fef2202776c" prot="public" static="no"> <name>IP_ADDR_ANY</name> <initializer>0</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="40" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="40" bodyend="-1"/> <referencedby refid="arp_8c_1c8ad5a32790d172fcec2eac97a87ee9f" compoundref="arp_8c" startline="93" endline="101">arp_init</referencedby> <referencedby refid="arp_8c_12cc298ed4c68289160da1376faf20938" compoundref="arp_8c" startline="104" endline="117">arp_tmr</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_1d546955e48dada78b552375b873f6986" prot="public" static="no"> <name>IP_ADDR_BROADCAST</name> <initializer>(&<ref refid="ipv4_2ip__addr_8h_1b35a6f60a0081bf09d1e03c48c3605a4" kindref="member">ip_addr_broadcast</ref>)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="42" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="42" bodyend="-1"/> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_1008c9c92d770cc030ea054e6b259835a" prot="public" static="no"> <name>ip_addr_cmp</name> <param><defname>addr1</defname></param> <param><defname>addr2</defname></param> <initializer>((addr1)->addr == (addr2)->addr)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="62" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="62" bodyend="-1"/> <referencedby refid="arp_8c_1038bb8fc3bcc993d8b7724632e43ed0f" compoundref="arp_8c" startline="120" endline="178">add_arp_entry</referencedby> <referencedby refid="arp_8c_157a25dd51cf73f048ad5364ecc2f040b" compoundref="arp_8c" startline="197" endline="250">arp_arp_input</referencedby> <referencedby refid="arp_8c_1eec8fff4f036cca2ac1b5635fa46d21b" compoundref="arp_8c" startline="253" endline="263">arp_lookup</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_1a41e0b5b64b12921f01894962c6fc9d9" prot="public" static="no"> <name>ip_addr_debug_print</name> <param><defname>ipaddr</defname></param> <initializer>kprintf("%d.%d.%d.%d", \ (uInt8)(ntohl((ipaddr)->addr) >> 24) & 0xff, \ (uInt8)(ntohl((ipaddr)->addr) >> 16) & 0xff, \ (uInt8)(ntohl((ipaddr)->addr) >> 8) & 0xff, \ (uInt8)ntohl((ipaddr)->addr) & 0xff)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="79" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="75" bodyend="-1"/> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_10d51c2bb5f2af51392540af1c5df511a" prot="public" static="no"> <name>ip_addr_isany</name> <param><defname>addr1</defname></param> <initializer>((addr1) == NULL || (addr1)->addr == 0)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="64" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="64" bodyend="-1"/> <referencedby refid="arp_8c_1038bb8fc3bcc993d8b7724632e43ed0f" compoundref="arp_8c" startline="120" endline="178">add_arp_entry</referencedby> <referencedby refid="arp_8c_12cc298ed4c68289160da1376faf20938" compoundref="arp_8c" startline="104" endline="117">arp_tmr</referencedby> <referencedby refid="ethernetif_8c_1eb49a49ab62789d8e32fddf180d52ebf" compoundref="ethernetif_8c" startline="186" endline="263">ethernetif_output</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_1ae42518ced1dbfbc55034642012055e9" prot="public" static="no"> <name>ip_addr_isbroadcast</name> <param><defname>addr1</defname></param> <param><defname>mask</defname></param> <initializer>(((((addr1)->addr) & ~((mask)->addr)) == \ (0xffffffff & ~((mask)->addr))) || \ ((addr1)->addr == 0xffffffff) || \ ((addr1)->addr == 0x00000000))</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="69" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="66" bodyend="-1"/> <referencedby refid="ethernetif_8c_1eb49a49ab62789d8e32fddf180d52ebf" compoundref="ethernetif_8c" startline="186" endline="263">ethernetif_output</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_1312e629c950c8e0add5b5e5897334beb" prot="public" static="no"> <name>ip_addr_ismulticast</name> <param><defname>addr1</defname></param> <initializer>(((addr1)->addr & ntohl(0xf0000000)) == ntohl(0xe0000000))</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="72" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="72" bodyend="-1"/> <referencedby refid="ethernetif_8c_1eb49a49ab62789d8e32fddf180d52ebf" compoundref="ethernetif_8c" startline="186" endline="263">ethernetif_output</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_1f656f30425e386d96d0e1a1b2dcb3952" prot="public" static="no"> <name>ip_addr_maskcmp</name> <param><defname>addr1</defname></param> <param><defname>addr2</defname></param> <param><defname>mask</defname></param> <initializer>(((addr1)->addr & \ (mask)->addr) == \ ((addr2)->addr & \ (mask)->addr))</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="61" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="58" bodyend="-1"/> <referencedby refid="arp_8c_1916d08dbb8f4a38e1e904a8a018b000c" compoundref="arp_8c" startline="181" endline="194">arp_ip_input</referencedby> <referencedby refid="ethernetif_8c_1eb49a49ab62789d8e32fddf180d52ebf" compoundref="ethernetif_8c" startline="186" endline="263">ethernetif_output</referencedby> </memberdef> <memberdef kind="define" id="ipv4_2ip__addr_8h_140db7feae2b92f7a7a01d65a85b06e18" prot="public" static="no"> <name>ip_addr_set</name> <param><defname>dest</defname></param> <param><defname>src</defname></param> <initializer>(dest)->addr = \ ((src) == IP_ADDR_ANY? IP_ADDR_ANY:\ ((struct <ref refid="structip__addr" kindref="compound">ip_addr</ref> *)src)->addr)</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="57" bodyfile="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" bodystart="55" bodyend="-1"/> <referencedby refid="arp_8c_1038bb8fc3bcc993d8b7724632e43ed0f" compoundref="arp_8c" startline="120" endline="178">add_arp_entry</referencedby> <referencedby refid="arp_8c_157a25dd51cf73f048ad5364ecc2f040b" compoundref="arp_8c" startline="197" endline="250">arp_arp_input</referencedby> <referencedby refid="arp_8c_1c8ad5a32790d172fcec2eac97a87ee9f" compoundref="arp_8c" startline="93" endline="101">arp_init</referencedby> <referencedby refid="arp_8c_19d1287b9a80c370797b2ac5c63f70e2e" compoundref="arp_8c" startline="266" endline="302">arp_query</referencedby> <referencedby refid="arp_8c_12cc298ed4c68289160da1376faf20938" compoundref="arp_8c" startline="104" endline="117">arp_tmr</referencedby> </memberdef> </sectiondef> <sectiondef kind="var"> <memberdef kind="variable" id="ipv4_2ip__addr_8h_1b35a6f60a0081bf09d1e03c48c3605a4" prot="public" static="no" mutable="no"> <type>PACK_STRUCT_END struct <ref refid="structip__addr" kindref="compound">ip_addr</ref></type> <definition>PACK_STRUCT_END struct ip_addr ip_addr_broadcast</definition> <argsstring></argsstring> <name>ip_addr_broadcast</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="50"/> </memberdef> <memberdef kind="variable" id="ipv4_2ip__addr_8h_1d85f58889938c4e164ac22093c9d5ffb" prot="public" static="no" mutable="no"> <type>PACK_STRUCT_BEGIN struct <ref refid="structip__addr" kindref="compound">ip_addr</ref></type> <definition>PACK_STRUCT_BEGIN struct ip_addr PACK_STRUCT_STRUCT</definition> <argsstring></argsstring> <name>PACK_STRUCT_STRUCT</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h" line="47"/> </memberdef> </sectiondef> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <programlisting> <codeline lineno="1"><highlight class="comment">/*</highlight></codeline> <codeline lineno="2"><highlight class="comment"><sp/>*<sp/>Copyright<sp/>(c)<sp/>2001,<sp/>Swedish<sp/>Institute<sp/>of<sp/>Computer<sp/>Science.</highlight></codeline> <codeline lineno="3"><highlight class="comment"><sp/>*<sp/>All<sp/>rights<sp/>reserved.<sp/></highlight></codeline> <codeline lineno="4"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="5"><highlight class="comment"><sp/>*<sp/>Redistribution<sp/>and<sp/>use<sp/>in<sp/>source<sp/>and<sp/>binary<sp/>forms,<sp/>with<sp/>or<sp/>without<sp/></highlight></codeline> <codeline lineno="6"><highlight class="comment"><sp/>*<sp/>modification,<sp/>are<sp/>permitted<sp/>provided<sp/>that<sp/>the<sp/>following<sp/>conditions<sp/></highlight></codeline> <codeline lineno="7"><highlight class="comment"><sp/>*<sp/>are<sp/>met:<sp/></highlight></codeline> <codeline lineno="8"><highlight class="comment"><sp/>*<sp/>1.<sp/>Redistributions<sp/>of<sp/>source<sp/>code<sp/>must<sp/>retain<sp/>the<sp/>above<sp/>copyright<sp/></highlight></codeline> <codeline lineno="9"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>notice,<sp/>this<sp/>list<sp/>of<sp/>conditions<sp/>and<sp/>the<sp/>following<sp/>disclaimer.<sp/></highlight></codeline> <codeline lineno="10"><highlight class="comment"><sp/>*<sp/>2.<sp/>Redistributions<sp/>in<sp/>binary<sp/>form<sp/>must<sp/>reproduce<sp/>the<sp/>above<sp/>copyright<sp/></highlight></codeline> <codeline lineno="11"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>notice,<sp/>this<sp/>list<sp/>of<sp/>conditions<sp/>and<sp/>the<sp/>following<sp/>disclaimer<sp/>in<sp/>the<sp/></highlight></codeline> <codeline lineno="12"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>documentation<sp/>and/or<sp/>other<sp/>materials<sp/>provided<sp/>with<sp/>the<sp/>distribution.<sp/></highlight></codeline> <codeline lineno="13"><highlight class="comment"><sp/>*<sp/>3.<sp/>Neither<sp/>the<sp/>name<sp/>of<sp/>the<sp/>Institute<sp/>nor<sp/>the<sp/>names<sp/>of<sp/>its<sp/>contributors<sp/></highlight></codeline> <codeline lineno="14"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>may<sp/>be<sp/>used<sp/>to<sp/>endorse<sp/>or<sp/>promote<sp/>products<sp/>derived<sp/>from<sp/>this<sp/>software<sp/></highlight></codeline> <codeline lineno="15"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>without<sp/>specific<sp/>prior<sp/>written<sp/>permission.<sp/></highlight></codeline> <codeline lineno="16"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="17"><highlight class="comment"><sp/>*<sp/>THIS<sp/>SOFTWARE<sp/>IS<sp/>PROVIDED<sp/>BY<sp/>THE<sp/>INSTITUTE<sp/>AND<sp/>CONTRIBUTORS<sp/>``AS<sp/>IS''<sp/>AND<sp/></highlight></codeline> <codeline lineno="18"><highlight class="comment"><sp/>*<sp/>ANY<sp/>EXPRESS<sp/>OR<sp/>IMPLIED<sp/>WARRANTIES,<sp/>INCLUDING,<sp/>BUT<sp/>NOT<sp/>LIMITED<sp/>TO,<sp/>THE<sp/></highlight></codeline> <codeline lineno="19"><highlight class="comment"><sp/>*<sp/>IMPLIED<sp/>WARRANTIES<sp/>OF<sp/>MERCHANTABILITY<sp/>AND<sp/>FITNESS<sp/>FOR<sp/>A<sp/>PARTICULAR<sp/>PURPOSE<sp/></highlight></codeline> <codeline lineno="20"><highlight class="comment"><sp/>*<sp/>ARE<sp/>DISCLAIMED.<sp/><sp/>IN<sp/>NO<sp/>EVENT<sp/>SHALL<sp/>THE<sp/>INSTITUTE<sp/>OR<sp/>CONTRIBUTORS<sp/>BE<sp/>LIABLE<sp/></highlight></codeline> <codeline lineno="21"><highlight class="comment"><sp/>*<sp/>FOR<sp/>ANY<sp/>DIRECT,<sp/>INDIRECT,<sp/>INCIDENTAL,<sp/>SPECIAL,<sp/>EXEMPLARY,<sp/>OR<sp/>CONSEQUENTIAL<sp/></highlight></codeline> <codeline lineno="22"><highlight class="comment"><sp/>*<sp/>DAMAGES<sp/>(INCLUDING,<sp/>BUT<sp/>NOT<sp/>LIMITED<sp/>TO,<sp/>PROCUREMENT<sp/>OF<sp/>SUBSTITUTE<sp/>GOODS<sp/></highlight></codeline> <codeline lineno="23"><highlight class="comment"><sp/>*<sp/>OR<sp/>SERVICES;<sp/>LOSS<sp/>OF<sp/>USE,<sp/>DATA,<sp/>OR<sp/>PROFITS;<sp/>OR<sp/>BUSINESS<sp/>INTERRUPTION)<sp/></highlight></codeline> <codeline lineno="24"><highlight class="comment"><sp/>*<sp/>HOWEVER<sp/>CAUSED<sp/>AND<sp/>ON<sp/>ANY<sp/>THEORY<sp/>OF<sp/>LIABILITY,<sp/>WHETHER<sp/>IN<sp/>CONTRACT,<sp/>STRICT<sp/></highlight></codeline> <codeline lineno="25"><highlight class="comment"><sp/>*<sp/>LIABILITY,<sp/>OR<sp/>TORT<sp/>(INCLUDING<sp/>NEGLIGENCE<sp/>OR<sp/>OTHERWISE)<sp/>ARISING<sp/>IN<sp/>ANY<sp/>WAY<sp/></highlight></codeline> <codeline lineno="26"><highlight class="comment"><sp/>*<sp/>OUT<sp/>OF<sp/>THE<sp/>USE<sp/>OF<sp/>THIS<sp/>SOFTWARE,<sp/>EVEN<sp/>IF<sp/>ADVISED<sp/>OF<sp/>THE<sp/>POSSIBILITY<sp/>OF<sp/></highlight></codeline> <codeline lineno="27"><highlight class="comment"><sp/>*<sp/>SUCH<sp/>DAMAGE.<sp/></highlight></codeline> <codeline lineno="28"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="29"><highlight class="comment"><sp/>*<sp/>This<sp/>file<sp/>is<sp/>part<sp/>of<sp/>the<sp/>lwIP<sp/>TCP/IP<sp/>stack.</highlight></codeline> <codeline lineno="30"><highlight class="comment"><sp/>*<sp/></highlight></codeline> <codeline lineno="31"><highlight class="comment"><sp/>*<sp/>Author:<sp/>Adam<sp/>Dunkels<sp/><adam@sics.se></highlight></codeline> <codeline lineno="32"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="33"><highlight class="comment"><sp/>*<sp/>$Id: ipv4_2ip__addr_8h.xml 88 2016-01-12 00:11:29Z reddawg $</highlight></codeline> <codeline lineno="34"><highlight class="comment"><sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="35"><highlight class="normal"></highlight><highlight class="preprocessor">#ifndef<sp/>__LWIP_IP_ADDR_H__</highlight></codeline> <codeline lineno="36"><highlight class="preprocessor"></highlight><highlight class="preprocessor">#define<sp/>__LWIP_IP_ADDR_H__</highlight></codeline> <codeline lineno="37"><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="38"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/>"<ref refid="arch_8h" kindref="compound">net/arch.h</ref>"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="39"><highlight class="normal"></highlight></codeline> <codeline lineno="40" refid="ipv4_2ip__addr_8h_13e5e67b7292b156034560fef2202776c" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>IP_ADDR_ANY<sp/>0</highlight></codeline> <codeline lineno="41"><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="42" refid="ipv4_2ip__addr_8h_1d546955e48dada78b552375b873f6986" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>IP_ADDR_BROADCAST<sp/>(&ip_addr_broadcast)</highlight></codeline> <codeline lineno="43"><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="44"><highlight class="normal"><ref refid="cc_8h_173199061891adf1b912d20835c7d5e96" kindref="member">PACK_STRUCT_BEGIN</ref></highlight></codeline> <codeline lineno="45" refid="structip__addr" refkind="compound"><highlight class="normal"></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structip__addr" kindref="compound">ip_addr</ref><sp/>{</highlight></codeline> <codeline lineno="46"><highlight class="normal"><sp/><sp/><ref refid="structip__addr_160186a1db9399a085ce26b9a3cdf6c22" kindref="member">PACK_STRUCT_FIELD</ref>(<ref refid="types_8h_15847ea0262a5aa61eee48cbe95544a78" kindref="member">uInt32</ref><sp/><ref refid="structip__addr_1aca6b7136a4c4efb4e0da1384d76f4b5" kindref="member">addr</ref>);</highlight></codeline> <codeline lineno="47"><highlight class="normal">}<sp/><ref refid="cc_8h_133623da05bb55497534c3dc26ebebeb2" kindref="member">PACK_STRUCT_STRUCT</ref>;</highlight></codeline> <codeline lineno="48"><highlight class="normal"><ref refid="cc_8h_1465fef70f294e21cbf4ea51fc342f20e" kindref="member">PACK_STRUCT_END</ref></highlight></codeline> <codeline lineno="49"><highlight class="normal"></highlight></codeline> <codeline lineno="50"><highlight class="normal"></highlight><highlight class="keyword">extern</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structip__addr" kindref="compound">ip_addr</ref><sp/>ip_addr_broadcast;</highlight></codeline> <codeline lineno="51"><highlight class="normal"></highlight></codeline> <codeline lineno="52" refid="ipv4_2ip__addr_8h_158aee4166c466f9ac7035bf5cc9f9974" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>IP4_ADDR(ipaddr,<sp/>a,b,c,d)<sp/>(ipaddr)->addr<sp/>=<sp/>htonl(((uInt32)(a<sp/>&<sp/>0xff)<sp/><<<sp/>24)<sp/>|<sp/>((uInt32)(b<sp/>&<sp/>0xff)<sp/><<<sp/>16)<sp/>|<sp/>\</highlight></codeline> <codeline lineno="53"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>((uInt32)(c<sp/>&<sp/>0xff)<sp/><<<sp/>8)<sp/>|<sp/>(uInt32)(d<sp/>&<sp/>0xff))</highlight></codeline> <codeline lineno="54"><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="55" refid="ipv4_2ip__addr_8h_140db7feae2b92f7a7a01d65a85b06e18" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>ip_addr_set(dest,<sp/>src)<sp/>(dest)->addr<sp/>=<sp/>\</highlight></codeline> <codeline lineno="56"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>((src)<sp/>==<sp/>IP_ADDR_ANY?<sp/>IP_ADDR_ANY:\</highlight></codeline> <codeline lineno="57"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>((struct<sp/>ip_addr<sp/>*)src)->addr)</highlight></codeline> <codeline lineno="58" refid="ipv4_2ip__addr_8h_1f656f30425e386d96d0e1a1b2dcb3952" refkind="member"><highlight class="preprocessor"></highlight><highlight class="preprocessor">#define<sp/>ip_addr_maskcmp(addr1,<sp/>addr2,<sp/>mask)<sp/>(((addr1)->addr<sp/>&<sp/>\</highlight></codeline> <codeline lineno="59"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(mask)->addr)<sp/>==<sp/>\</highlight></codeline> <codeline lineno="60"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>((addr2)->addr<sp/>&<sp/>\</highlight></codeline> <codeline lineno="61"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(mask)->addr))</highlight></codeline> <codeline lineno="62" refid="ipv4_2ip__addr_8h_1008c9c92d770cc030ea054e6b259835a" refkind="member"><highlight class="preprocessor"></highlight><highlight class="preprocessor">#define<sp/>ip_addr_cmp(addr1,<sp/>addr2)<sp/>((addr1)->addr<sp/>==<sp/>(addr2)->addr)</highlight></codeline> <codeline lineno="63"><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="64" refid="ipv4_2ip__addr_8h_10d51c2bb5f2af51392540af1c5df511a" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>ip_addr_isany(addr1)<sp/>((addr1)<sp/>==<sp/>NULL<sp/>||<sp/>(addr1)->addr<sp/>==<sp/>0)</highlight></codeline> <codeline lineno="65"><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="66" refid="ipv4_2ip__addr_8h_1ae42518ced1dbfbc55034642012055e9" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>ip_addr_isbroadcast(addr1,<sp/>mask)<sp/>(((((addr1)->addr)<sp/>&<sp/>~((mask)->addr))<sp/>==<sp/>\</highlight></codeline> <codeline lineno="67"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(0xffffffff<sp/>&<sp/>~((mask)->addr)))<sp/>||<sp/>\</highlight></codeline> <codeline lineno="68"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>((addr1)->addr<sp/>==<sp/>0xffffffff)<sp/>||<sp/>\</highlight></codeline> <codeline lineno="69"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>((addr1)->addr<sp/>==<sp/>0x00000000))</highlight></codeline> <codeline lineno="70"><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="71"><highlight class="normal"></highlight></codeline> <codeline lineno="72" refid="ipv4_2ip__addr_8h_1312e629c950c8e0add5b5e5897334beb" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>ip_addr_ismulticast(addr1)<sp/>(((addr1)->addr<sp/>&<sp/>ntohl(0xf0000000))<sp/>==<sp/>ntohl(0xe0000000))</highlight></codeline> <codeline lineno="73"><highlight class="preprocessor"></highlight><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight></codeline> <codeline lineno="74"><highlight class="normal"></highlight></codeline> <codeline lineno="75" refid="ipv4_2ip__addr_8h_1a41e0b5b64b12921f01894962c6fc9d9" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>ip_addr_debug_print(ipaddr)<sp/>kprintf("%d.%d.%d.%d",<sp/>\</highlight></codeline> <codeline lineno="76"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(uInt8)(ntohl((ipaddr)->addr)<sp/>>><sp/>24)<sp/>&<sp/>0xff,<sp/>\</highlight></codeline> <codeline lineno="77"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(uInt8)(ntohl((ipaddr)->addr)<sp/>>><sp/>16)<sp/>&<sp/>0xff,<sp/>\</highlight></codeline> <codeline lineno="78"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(uInt8)(ntohl((ipaddr)->addr)<sp/>>><sp/>8)<sp/>&<sp/>0xff,<sp/>\</highlight></codeline> <codeline lineno="79"><highlight class="preprocessor"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>(uInt8)ntohl((ipaddr)->addr)<sp/>&<sp/>0xff)</highlight></codeline> <codeline lineno="80"><highlight class="preprocessor"></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="81"><highlight class="normal"></highlight></codeline> <codeline lineno="82" refid="ipv4_2ip__addr_8h_132caf20405b8659c07758352746c4331" refkind="member"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>ip4_addr1(ipaddr)<sp/>((uInt8)(ntohl((ipaddr)->addr)<sp/>>><sp/>24)<sp/>&<sp/>0xff)</highlight></codeline> <codeline lineno="83" refid="ipv4_2ip__addr_8h_1ee091caef24dd1705876bb8dbe28035c" refkind="member"><highlight class="preprocessor"></highlight><highlight class="preprocessor">#define<sp/>ip4_addr2(ipaddr)<sp/>((uInt8)(ntohl((ipaddr)->addr)<sp/>>><sp/>16)<sp/>&<sp/>0xff)</highlight></codeline> <codeline lineno="84" refid="ipv4_2ip__addr_8h_1ead691bee580ea8111b70e67cf971c40" refkind="member"><highlight class="preprocessor"></highlight><highlight class="preprocessor">#define<sp/>ip4_addr3(ipaddr)<sp/>((uInt8)(ntohl((ipaddr)->addr)<sp/>>><sp/>8)<sp/>&<sp/>0xff)</highlight></codeline> <codeline lineno="85" refid="ipv4_2ip__addr_8h_178cbf5c1fd832f909f755c4cc9036f02" refkind="member"><highlight class="preprocessor"></highlight><highlight class="preprocessor">#define<sp/>ip4_addr4(ipaddr)<sp/>((uInt8)(ntohl((ipaddr)->addr))<sp/>&<sp/>0xff)</highlight></codeline> <codeline lineno="86"><highlight class="preprocessor"></highlight><highlight class="preprocessor">#endif<sp/></highlight><highlight class="comment">/*<sp/>__LWIP_IP_ADDR_H__<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="87"><highlight class="normal"></highlight></codeline> <codeline lineno="88"><highlight class="normal"></highlight></codeline> <codeline lineno="89"><highlight class="normal"></highlight></codeline> <codeline lineno="90"><highlight class="normal"></highlight></codeline> <codeline lineno="91"><highlight class="normal"></highlight></codeline> <codeline lineno="92"><highlight class="normal"></highlight></codeline> </programlisting> <location file="/usr/home/reddawg/source/ubix2/src/sys/include/net/ipv4/ip_addr.h"/> </compounddef> </doxygen>