<?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="lnc_8c" kind="file" language="C++"> <compoundname>lnc.c</compoundname> <includes refid="lnc_8h" local="no">pci/lnc.h</includes> <includes refid="io_8h" local="no">sys/io.h</includes> <includes refid="include_2sys_2types_8h" local="no">sys/types.h</includes> <includes refid="idt_8h" local="no">sys/idt.h</includes> <includes refid="gdt_8h" local="no">sys/gdt.h</includes> <includes refid="kmalloc_8h" local="no">lib/kmalloc.h</includes> <includes refid="kprintf_8h" local="no">lib/kprintf.h</includes> <includes refid="video_8h" local="no">sys/video.h</includes> <includes refid="8259_8h" local="no">isa/8259.h</includes> <includes refid="net_8h" local="no">net/net.h</includes> <includes refid="netif_8h" local="no">net/netif.h</includes> <includes refid="spinlock_8h" local="no">ubixos/spinlock.h</includes> <incdepgraph> <node id="16"> <label>sys/video.h</label> <link refid="video_8h"/> <childnode refid="3" relation="include"> </childnode> </node> <node id="15"> <label>stdarg.h</label> <link refid="stdarg_8h"/> </node> <node id="26"> <label>ubixos/kpanic.h</label> <link refid="kpanic_8h"/> </node> <node id="10"> <label>sys/io.h</label> <link refid="io_8h"/> </node> <node id="12"> <label>sys/gdt.h</label> <link refid="gdt_8h"/> </node> <node id="32"> <label>net/pbuf.h</label> <link refid="pbuf_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="27" relation="include"> </childnode> </node> <node id="18"> <label>net/net.h</label> <link refid="net_8h"/> <childnode refid="3" relation="include"> </childnode> <childnode refid="19" relation="include"> </childnode> </node> <node id="37"> <label>net/priv/memp_priv.h</label> <link refid="memp__priv_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="34" relation="include"> </childnode> </node> <node id="11"> <label>sys/idt.h</label> <link refid="idt_8h"/> <childnode refid="3" relation="include"> </childnode> <childnode refid="12" relation="include"> </childnode> </node> <node id="5"> <label>sys/select.h</label> <link refid="select_8h"/> <childnode refid="6" relation="include"> </childnode> <childnode refid="4" relation="include"> </childnode> <childnode refid="7" relation="include"> </childnode> <childnode refid="8" relation="include"> </childnode> <childnode refid="9" relation="include"> </childnode> </node> <node id="38"> <label>ubixos/spinlock.h</label> <link refid="spinlock_8h"/> <childnode refid="3" relation="include"> </childnode> </node> <node id="1"> <label>C:/Dev/git/UbixOS/sys/pci/lnc.c</label> <link refid="lnc_8c"/> <childnode refid="2" relation="include"> </childnode> <childnode refid="10" relation="include"> </childnode> <childnode refid="3" relation="include"> </childnode> <childnode refid="11" relation="include"> </childnode> <childnode refid="12" relation="include"> </childnode> <childnode refid="13" relation="include"> </childnode> <childnode refid="14" relation="include"> </childnode> <childnode refid="16" relation="include"> </childnode> <childnode refid="17" relation="include"> </childnode> <childnode refid="18" relation="include"> </childnode> <childnode refid="19" relation="include"> </childnode> <childnode refid="38" relation="include"> </childnode> </node> <node id="24"> <label>net/arch/cc.h</label> <link refid="cc_8h"/> <childnode refid="25" relation="include"> </childnode> </node> <node id="9"> <label>sys/_sigset.h</label> <link refid="__sigset_8h"/> <childnode refid="4" relation="include"> </childnode> </node> <node id="13"> <label>lib/kmalloc.h</label> <link refid="kmalloc_8h"/> <childnode refid="3" relation="include"> </childnode> </node> <node id="34"> <label>net/mem.h</label> <link refid="mem_8h"/> <childnode refid="20" relation="include"> </childnode> </node> <node id="33"> <label>net/stats.h</label> <link refid="stats_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="34" relation="include"> </childnode> <childnode refid="35" relation="include"> </childnode> </node> <node id="21"> <label>net/lwipopts.h</label> <link refid="lwipopts_8h"/> </node> <node id="17"> <label>isa/8259.h</label> <link refid="8259_8h"/> <childnode refid="3" relation="include"> </childnode> </node> <node id="2"> <label>pci/lnc.h</label> <link refid="lnc_8h"/> <childnode refid="3" relation="include"> </childnode> </node> <node id="3"> <label>sys/types.h</label> <link refid="include_2sys_2types_8h"/> <childnode refid="4" relation="include"> </childnode> <childnode refid="5" relation="include"> </childnode> </node> <node id="29"> <label>net/def.h</label> <link refid="def_8h"/> <childnode refid="23" relation="include"> </childnode> <childnode refid="20" relation="include"> </childnode> </node> <node id="19"> <label>net/netif.h</label> <link refid="netif_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="27" relation="include"> </childnode> <childnode refid="28" relation="include"> </childnode> <childnode refid="29" relation="include"> </childnode> <childnode refid="32" relation="include"> </childnode> <childnode refid="33" relation="include"> </childnode> </node> <node id="23"> <label>net/arch.h</label> <link refid="arch_8h"/> <childnode refid="3" relation="include"> </childnode> <childnode refid="24" relation="include"> </childnode> <childnode refid="14" relation="include"> </childnode> <childnode refid="26" relation="include"> </childnode> </node> <node id="31"> <label>net/ip6_addr.h</label> <link refid="ip6__addr_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="29" relation="include"> </childnode> </node> <node id="20"> <label>net/opt.h</label> <link refid="opt_8h"/> <childnode refid="21" relation="include"> </childnode> <childnode refid="22" relation="include"> </childnode> </node> <node id="14"> <label>lib/kprintf.h</label> <link refid="kprintf_8h"/> <childnode refid="3" relation="include"> </childnode> <childnode refid="15" relation="include"> </childnode> </node> <node id="22"> <label>net/debug.h</label> <link refid="debug_8h"/> <childnode refid="23" relation="include"> </childnode> <childnode refid="20" relation="include"> </childnode> </node> <node id="30"> <label>net/ip4_addr.h</label> <link refid="ip4__addr_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="29" relation="include"> </childnode> </node> <node id="28"> <label>net/ip_addr.h</label> <link refid="ip__addr_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="29" relation="include"> </childnode> <childnode refid="30" relation="include"> </childnode> <childnode refid="31" relation="include"> </childnode> </node> <node id="36"> <label>net/priv/memp_std.h</label> <link refid="memp__std_8h"/> </node> <node id="6"> <label>sys/cdefs.h</label> <link refid="cdefs_8h"/> </node> <node id="25"> <label>ubixos/time.h</label> <link refid="time_8h"/> <childnode refid="3" relation="include"> </childnode> <childnode refid="7" relation="include"> </childnode> <childnode refid="10" relation="include"> </childnode> </node> <node id="4"> <label>sys/_types.h</label> <link refid="__types_8h"/> </node> <node id="27"> <label>net/err.h</label> <link refid="err_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="23" relation="include"> </childnode> </node> <node id="7"> <label>sys/_timespec.h</label> <link refid="__timespec_8h"/> <childnode refid="4" relation="include"> </childnode> </node> <node id="8"> <label>sys/_timeval.h</label> <link refid="__timeval_8h"/> <childnode refid="4" relation="include"> </childnode> </node> <node id="35"> <label>net/memp.h</label> <link refid="memp_8h"/> <childnode refid="20" relation="include"> </childnode> <childnode refid="36" relation="include"> </childnode> <childnode refid="37" relation="include"> </childnode> <childnode refid="33" relation="include"> </childnode> </node> </incdepgraph> <sectiondef kind="var"> <memberdef kind="variable" id="lnc_8c_1adb58b363370d88875089b34d06a9e08f" prot="public" static="yes" mutable="no"> <type><ref refid="cdefs_8h_1a2c212835823e3c54a8ab6d95c652660e" kindref="member">const</ref> char *<ref refid="cdefs_8h_1a2c212835823e3c54a8ab6d95c652660e" kindref="member">const</ref></type> <definition>const char* const icIdent[]</definition> <argsstring>[]</argsstring> <name>icIdent</name> <initializer>= { "Unknown", "<ref refid="lnc_8h_1a67dedc055b2e31a97ac3561a4a16b9af" kindref="member">LANCE</ref>", "C-<ref refid="lnc_8h_1a67dedc055b2e31a97ac3561a4a16b9af" kindref="member">LANCE</ref>", "PCnet-ISA", "PCnet-ISA+", "PCnet-ISA II", "PCnet-32 VL-Bus", "PCnet-PCI", "PCnet-PCI II", "PCnet-FAST", "PCnet-FAST+", "PCnet-Home", }</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="50" column="26" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="50" bodyend="-1"/> </memberdef> <memberdef kind="variable" id="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" prot="public" static="no" mutable="no"> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <definition>struct lncInfo* lnc</definition> <argsstring></argsstring> <name>lnc</name> <initializer>= 0x0</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="44" column="14" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="44" bodyend="-1"/> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> <referencedby refid="lnc_8c_1ac698a392b34b41b9aa3eed6ec7c2f8db" compoundref="lnc_8c" startline="231" endline="252">lanceProbe</referencedby> <referencedby refid="lnc_8c_1a15887c99a129da1ef80b030d097c6c80" compoundref="lnc_8c" startline="518" endline="520">lnc_driverOwnsRX</referencedby> <referencedby refid="lnc_8c_1ab876fabc49e39786f1a2ad625c90f2d2" compoundref="lnc_8c" startline="514" endline="516">lnc_driverOwnsTX</referencedby> <referencedby refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" compoundref="lnc_8c" startline="573" endline="583">lnc_getMode</referencedby> <referencedby refid="lnc_8c_1a91848001b8f3004373121f03951d4c4c" compoundref="lnc_8c" startline="254" endline="276">lnc_INT</referencedby> <referencedby refid="lnc_8c_1a3adb7ffd629931a01514727e774010be" compoundref="lnc_8c" startline="534" endline="544">lnc_nextRxPtr</referencedby> <referencedby refid="lnc_8c_1a2b7362bb168e98f74686a9e149e77766" compoundref="lnc_8c" startline="522" endline="532">lnc_nextTxPtr</referencedby> <referencedby refid="lnc_8c_1ad661daf22a22f6b9c428aebef31ea723" compoundref="lnc_8c" startline="191" endline="229">lnc_probe</referencedby> <referencedby refid="lnc_8c_1a213face33ee64fb988be9fa980589253" compoundref="lnc_8c" startline="84" endline="87">lnc_readBCR</referencedby> <referencedby refid="lnc_8c_1ad1848f3fed3685285d6218e19bec1605" compoundref="lnc_8c" startline="89" endline="92">lnc_readBCR32</referencedby> <referencedby refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" compoundref="lnc_8c" startline="64" endline="67">lnc_readCSR</referencedby> <referencedby refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" compoundref="lnc_8c" startline="69" endline="72">lnc_readCSR32</referencedby> <referencedby refid="lnc_8c_1a4acfee627f5b840fa9491efcd0ef384d" compoundref="lnc_8c" startline="585" endline="587">lnc_reset</referencedby> <referencedby refid="lnc_8c_1ab42934c99afb63e4dab3859307feeb80" compoundref="lnc_8c" startline="589" endline="591">lnc_reset32</referencedby> <referencedby refid="lnc_8c_1afa544fa662f94035a72f9c04f7f7fd5a" compoundref="lnc_8c" startline="316" endline="350">lnc_rxINT</referencedby> <referencedby refid="lnc_8c_1a85f794a709a826cb783b49a20dda4cf3" compoundref="lnc_8c" startline="546" endline="571">lnc_sendPacket</referencedby> <referencedby refid="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" compoundref="lnc_8c" startline="593" endline="609">lnc_switchDWord</referencedby> <referencedby refid="lnc_8c_1a6fb9d9c3d73ce2d10b2cebe1d71f07e2" compoundref="lnc_8c" startline="278" endline="314">lnc_thread</referencedby> <referencedby refid="lnc_8c_1a7542af3f8b6969da5e51db96f6013efe" compoundref="lnc_8c" startline="74" endline="77">lnc_writeBCR</referencedby> <referencedby refid="lnc_8c_1abc22d59a1dab450fde08b50ef668974a" compoundref="lnc_8c" startline="79" endline="82">lnc_writeBCR32</referencedby> <referencedby refid="lnc_8c_1a7ddaf6c2816ca0adea2397a0ccbc101b" compoundref="lnc_8c" startline="54" endline="57">lnc_writeCSR</referencedby> <referencedby refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" compoundref="lnc_8c" startline="59" endline="62">lnc_writeCSR32</referencedby> <referencedby refid="lnc_8c_1a86e977fd8113976b87da564f2b53a2d7" compoundref="lnc_8c" startline="419" endline="512">lncAttach</referencedby> <referencedby refid="lnc_8c_1a6fdabac3834c12782583e0a42f928295" compoundref="lnc_8c" startline="368" endline="392">lncInt</referencedby> </memberdef> <memberdef kind="variable" id="lnc_8c_1ace647f9c4c077c9f160f180ee37bd6ed" prot="public" static="no" mutable="no"> <type>struct <ref refid="structnetif" kindref="compound">netif</ref></type> <definition>struct netif lnc_netif</definition> <argsstring></argsstring> <name>lnc_netif</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="423" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="42" bodyend="-1"/> <referencedby refid="lnc_8c_1a6fb9d9c3d73ce2d10b2cebe1d71f07e2" compoundref="lnc_8c" startline="278" endline="314">lnc_thread</referencedby> </memberdef> <memberdef kind="variable" id="lnc_8c_1a55e965b764a2b0264e3c7e0251de20d4" prot="public" static="yes" mutable="no"> <type><ref refid="cdefs_8h_1a2c212835823e3c54a8ab6d95c652660e" kindref="member">const</ref> char *<ref refid="cdefs_8h_1a2c212835823e3c54a8ab6d95c652660e" kindref="member">const</ref></type> <definition>const char* const nicIdent[]</definition> <argsstring>[]</argsstring> <name>nicIdent</name> <initializer>= { "Unknown", "BICC", "<ref refid="lnc_8h_1a0f13e1c33c723fb1751c67d8dcd54df3" kindref="member">NE2100</ref>", "DEPCA", "CNET98S" }</initializer> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="48" column="26" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="48" bodyend="-1"/> </memberdef> <memberdef kind="variable" id="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" prot="public" static="no" mutable="no"> <type>struct <ref refid="structnicBuffer" kindref="compound">nicBuffer</ref> *</type> <definition>struct nicBuffer* tmpBuf</definition> <argsstring></argsstring> <name>tmpBuf</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="52" column="16" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="52" bodyend="-1"/> <referencedby refid="lnc_8c_1afa544fa662f94035a72f9c04f7f7fd5a" compoundref="lnc_8c" startline="316" endline="350">lnc_rxINT</referencedby> <referencedby refid="lnc_8c_1a6fb9d9c3d73ce2d10b2cebe1d71f07e2" compoundref="lnc_8c" startline="278" endline="314">lnc_thread</referencedby> <referencedby refid="ne2k_8c_1adae239918a8091c31abf996cee262c92" compoundref="ne2k_8c" startline="312" endline="339">ne2kAllocBuffer</referencedby> <referencedby refid="ne2k_8c_1a954f14d0270247855900254097728c57" compoundref="ne2k_8c" startline="341" endline="351">ne2kGetBuffer</referencedby> </memberdef> </sectiondef> <sectiondef kind="func"> <memberdef kind="function" id="lnc_8c_1af982ae3d36e6c05a80260e206255be26" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type></type> <definition>asm</definition> <argsstring>(".globl lnc_isr \n" "lnc_isr: \n" " pusha \n" " push %ss \n" " push %ds \n" " push %es \n" " push %fs \n" " push %gs \n" " call lnc_INT \n" " mov $0xA0,%dx \n" " mov $0x20,%ax \n" " outb %al,%dx \n" " mov $0x20,%dx \n" " mov $0x20,%ax \n" " outb %al,%dx \n" " pop %gs \n" " pop %fs \n" " pop %es \n" " pop %ds \n" " pop %ss \n" " popa \n" " iret \n")</argsstring> <name>asm</name> <param> <type>".globl <ref refid="lnc_8h_1a59af9e0fe8ee78093931131a8818e66f" kindref="member">lnc_isr</ref> \n" "lnc_isr: \n" " pusha \n" " push %ss \n" " push %ds \n" " push %es \n" " push %<ref refid="structfs" kindref="compound">fs</ref> \n" " push %gs \n" " call <ref refid="lnc_8c_1a91848001b8f3004373121f03951d4c4c" kindref="member">lnc_INT</ref> \n" " mov</type> <declname>$0xA0</declname> </param> <param> <type>%dx \n" " mov</type> <declname>$0x20</declname> </param> <param> <type>%ax \n" " outb %</type> <declname>al</declname> </param> <param> <type>%dx \n" " mov</type> <declname>$0x20</declname> </param> <param> <type>%dx \n" " mov</type> <declname>$0x20</declname> </param> <param> <type>%ax \n" " outb %</type> <declname>al</declname> </param> <param> <type>%dx \n" " pop %gs \n" " pop %<ref refid="structfs" kindref="compound">fs</ref> \n" " pop %es \n" " pop %ds \n" " pop %ss \n" " popa \n" " iret \n"</type> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="394" column="1" declfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" declline="394" declcolumn="1"/> </memberdef> <memberdef kind="function" id="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int initLNC</definition> <argsstring>()</argsstring> <name>initLNC</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="94" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="94" bodyend="189"/> <references refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" compoundref="lnc_8h" startline="93">arpcom::ac_enaddr</references> <references refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" compoundref="lnc_8h" startline="128">lncInfo::arpcom</references> <references refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" compoundref="lnc_8h" startline="138">lncInfo::bufferSize</references> <references refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" compoundref="lnc_8h" startline="57">CSR0</references> <references refid="lnc_8h_1aaa0004ce746adcb049f80ada0d848500" compoundref="lnc_8h" startline="208">CSR1</references> <references refid="lnc_8h_1a6f3bf10d90237a3c12153ebf8a52d586" compoundref="lnc_8h" startline="209">CSR2</references> <references refid="lnc_8h_1aaccfc3c68d398428c31b3c26cf3c7d5f" compoundref="lnc_8h" startline="210">CSR3</references> <references refid="gdt_8h_1a2e29d1e158d5e81dc70dfae75f17d7f4" compoundref="gdt_8h" startline="50">dDpl3</references> <references refid="gdt_8h_1a7eb6dc7004c613df58764da5df7d85d8" compoundref="gdt_8h" startline="43">dInt</references> <references refid="lnc_8h_1ac7329f246bfda2b0fc34bba5cae18380" compoundref="lnc_8h" startline="189">DMA_FIXED</references> <references refid="gdt_8h_1abe5eb76416aff1d9114e1cdb8b0797fe" compoundref="gdt_8h" startline="54">dPresent</references> <references refid="lnc_8h_1abf4fcaacb1ad2010711b7c880ec2ed20" compoundref="lnc_8h" startline="182">ETHER_ADDR_LEN</references> <references refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" compoundref="lnc_8h" startline="100">nicInfo::ic</references> <references refid="structnicInfo_1abc40ed67a91dece36218837e90a90218" compoundref="lnc_8h" startline="99">nicInfo::ident</references> <references refid="lnc_8h_1aca0dae20ad119b8bf8f368693eb2bff8" compoundref="lnc_8h" startline="221">IDON</references> <references refid="lnc_8h_1a93d733faa9617c2136ecc02953be45d5" compoundref="lnc_8h" startline="223">INEA</references> <references refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" compoundref="lnc_8h" startline="134">lncInfo::init</references> <references refid="lnc_8h_1ab5889105dcd019008c9448dff61323f6" compoundref="lnc_8h" startline="229">INIT</references> <references refid="io_8h_1a77b934268de1b3ecdcf3f275413b3108" compoundref="io_8c" startline="38" endline="46">inportByte</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="8259_8h_1a0ac079c4d770f02e505f4d8569a6960a">irqEnable</references> <references refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" compoundref="kmalloc_8c" startline="241" endline="331">kmalloc</references> <references refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" compoundref="kprintf_8c" startline="259" endline="276">kprintf</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" compoundref="lnc_8c" startline="573" endline="583">lnc_getMode</references> <references refid="lnc_8h_1a59af9e0fe8ee78093931131a8818e66f">lnc_isr</references> <references refid="lnc_8c_1ad661daf22a22f6b9c428aebef31ea723" compoundref="lnc_8c" startline="191" endline="229">lnc_probe</references> <references refid="lnc_8c_1ad1848f3fed3685285d6218e19bec1605" compoundref="lnc_8c" startline="89" endline="92">lnc_readBCR32</references> <references refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" compoundref="lnc_8c" startline="69" endline="72">lnc_readCSR32</references> <references refid="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" compoundref="lnc_8c" startline="593" endline="609">lnc_switchDWord</references> <references refid="lnc_8c_1abc22d59a1dab450fde08b50ef668974a" compoundref="lnc_8c" startline="79" endline="82">lnc_writeBCR32</references> <references refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" compoundref="lnc_8c" startline="59" endline="62">lnc_writeCSR32</references> <references refid="lnc_8c_1a86e977fd8113976b87da564f2b53a2d7" compoundref="lnc_8c" startline="419" endline="512">lncAttach</references> <references refid="structnicInfo_1a1260a18062e5cb16aac9b3f2b253409c" compoundref="lnc_8h" startline="101">nicInfo::memMode</references> <references refid="string_8h_1ace4b911463887af5e748326323e99a23">memset</references> <references refid="structinitBlock32_1a7a82e395fd7ebc9c6d49aaa076079edf" compoundref="lnc_8h" startline="117">initBlock32::mode</references> <references refid="lnc_8h_1a8208bd666b76f9875ef5d27cb001e264" compoundref="lnc_8h" startline="52">MODE_16</references> <references refid="lnc_8h_1a3da944764f31bb69cb2aa74d1115989e" compoundref="lnc_8h" startline="53">MODE_32</references> <references refid="lnc_8h_1a0f13e1c33c723fb1751c67d8dcd54df3" compoundref="lnc_8h" startline="186">NE2100</references> <references refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" compoundref="lnc_8h" startline="129">lncInfo::nic</references> <references refid="structlncInfo_1a7520aa6929e2407573acaa5d408c7af4" compoundref="lnc_8h" startline="136">lncInfo::nrdre</references> <references refid="lnc_8h_1a9a6f0938f7533adf6aebf030c2cff3d6" compoundref="lnc_8h" startline="180">NRDRE</references> <references refid="structlncInfo_1a1ca5c65a2fbc6bc1cd56930eeec0b7eb" compoundref="lnc_8h" startline="137">lncInfo::ntdre</references> <references refid="lnc_8h_1a5feb2f9782070ea70e997a934dba38b1" compoundref="lnc_8h" startline="181">NTDRE</references> <references refid="structinitBlock32_1ac1cc1926832f4faadf8c68d4d3efad9c" compoundref="lnc_8h" startline="120">initBlock32::padr</references> <references refid="lnc_8h_1af1a6cf2caeea69b144932f488e69ef9a" compoundref="lnc_8h" startline="200">PCnet_32</references> <references refid="structinitBlock32_1a8c7d3f96a698e973939ab069e779e60f" compoundref="lnc_8h" startline="123">initBlock32::rdra</references> <references refid="structinitBlock32_1a7d8e6b5186ef35e5867bcc2df83e177b" compoundref="lnc_8h" startline="118">initBlock32::rlen</references> <references refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" compoundref="lnc_8h" startline="130">lncInfo::rxRing</references> <references refid="idt_8h_1a174a47ed653fc64fff6b5bb1b895c2cf" compoundref="idt_8c" startline="208" endline="216">setVector</references> <references refid="lnc_8h_1a39aaa2cb5148aec0a6c4599feaf3a7d3" compoundref="lnc_8h" startline="228">STRT</references> <references refid="8259_8h_1a2f7f6ebf05739e77a7c20aee806b771c" compoundref="8259_8h" startline="42">sVec</references> <references refid="structinitBlock32_1a21be4224d33c7821c3ada11a0e8c3f08" compoundref="lnc_8h" startline="124">initBlock32::tdra</references> <references refid="structinitBlock32_1ad3c8914cac5a258208f737a446dfd78e" compoundref="lnc_8h" startline="119">initBlock32::tlen</references> <references refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" compoundref="lnc_8h" startline="132">lncInfo::txRing</references> <references refid="paging_8h_1a17fca9c83854e88d2ca3c0ef8ec687dc" compoundref="getphysicaladdr_8c" startline="56" endline="70">vmm_getRealAddr</references> </memberdef> <memberdef kind="function" id="lnc_8c_1ac698a392b34b41b9aa3eed6ec7c2f8db" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lanceProbe</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lanceProbe</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="231" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="231" bodyend="252"/> <references refid="lnc_8h_1a26eec45c0879e59438a7d2ca16fa8067" compoundref="lnc_8h" startline="196">C_LANCE</references> <references refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" compoundref="lnc_8h" startline="57">CSR0</references> <references refid="lnc_8h_1a1cf3194611b57177ea230f2994ee654c" compoundref="lnc_8h" startline="58">CSR0_STOP</references> <references refid="lnc_8h_1aaccfc3c68d398428c31b3c26cf3c7d5f" compoundref="lnc_8h" startline="210">CSR3</references> <references refid="lnc_8h_1a93d733faa9617c2136ecc02953be45d5" compoundref="lnc_8h" startline="223">INEA</references> <references refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" compoundref="io_8c" startline="55" endline="63">inportWord</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8h_1a67dedc055b2e31a97ac3561a4a16b9af" compoundref="lnc_8h" startline="195">LANCE</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" compoundref="lnc_8c" startline="64" endline="67">lnc_readCSR</references> <references refid="lnc_8c_1a7ddaf6c2816ca0adea2397a0ccbc101b" compoundref="lnc_8c" startline="54" endline="57">lnc_writeCSR</references> <references refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" compoundref="lnc_8h" startline="35">RDP</references> <references refid="lnc_8h_1ac1ae4add974b9cfc6b5aaf8a578f01ab" compoundref="lnc_8h" startline="194">UNKNOWN</references> <referencedby refid="lnc_8c_1ad661daf22a22f6b9c428aebef31ea723" compoundref="lnc_8c" startline="191" endline="229">lnc_probe</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a15887c99a129da1ef80b030d097c6c80" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lnc_driverOwnsRX</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_driverOwnsRX</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="518" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="518" bodyend="520"/> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" compoundref="lnc_8h" startline="87">hostRingEntry::md</references> <references refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" compoundref="lnc_8h" startline="140">lncInfo::rxPtr</references> <references refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" compoundref="lnc_8h" startline="130">lncInfo::rxRing</references> <referencedby refid="lnc_8c_1afa544fa662f94035a72f9c04f7f7fd5a" compoundref="lnc_8c" startline="316" endline="350">lnc_rxINT</referencedby> <referencedby refid="lnc_8c_1a6fb9d9c3d73ce2d10b2cebe1d71f07e2" compoundref="lnc_8c" startline="278" endline="314">lnc_thread</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1ab876fabc49e39786f1a2ad625c90f2d2" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lnc_driverOwnsTX</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_driverOwnsTX</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="514" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="514" bodyend="516"/> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" compoundref="lnc_8h" startline="87">hostRingEntry::md</references> <references refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" compoundref="lnc_8h" startline="139">lncInfo::txPtr</references> <references refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" compoundref="lnc_8h" startline="132">lncInfo::txRing</references> <referencedby refid="lnc_8c_1a85f794a709a826cb783b49a20dda4cf3" compoundref="lnc_8c" startline="546" endline="571">lnc_sendPacket</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lnc_getMode</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_getMode</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="573" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="573" bodyend="583"/> <references refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" compoundref="lnc_8h" startline="57">CSR0</references> <references refid="lnc_8h_1a1cf3194611b57177ea230f2994ee654c" compoundref="lnc_8h" startline="58">CSR0_STOP</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" compoundref="lnc_8c" startline="64" endline="67">lnc_readCSR</references> <references refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" compoundref="lnc_8c" startline="69" endline="72">lnc_readCSR32</references> <references refid="lnc_8c_1a4acfee627f5b840fa9491efcd0ef384d" compoundref="lnc_8c" startline="585" endline="587">lnc_reset</references> <references refid="lnc_8c_1ab42934c99afb63e4dab3859307feeb80" compoundref="lnc_8c" startline="589" endline="591">lnc_reset32</references> <references refid="lnc_8h_1a8208bd666b76f9875ef5d27cb001e264" compoundref="lnc_8h" startline="52">MODE_16</references> <references refid="lnc_8h_1a3da944764f31bb69cb2aa74d1115989e" compoundref="lnc_8h" startline="53">MODE_32</references> <references refid="lnc_8h_1ab0dd9a24ba036665f61ba3a10f159de0" compoundref="lnc_8h" startline="54">MODE_INVALID</references> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a91848001b8f3004373121f03951d4c4c" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_INT</definition> <argsstring>()</argsstring> <name>lnc_INT</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="254" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="254" bodyend="276"/> <references refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" compoundref="lnc_8h" startline="57">CSR0</references> <references refid="lnc_8h_1a735563036dced0b7d6cc98f97ea4978b" compoundref="lnc_8h" startline="214">ERR</references> <references refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" compoundref="kprintf_8c" startline="259" endline="276">kprintf</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" compoundref="lnc_8c" startline="59" endline="62">lnc_writeCSR32</references> <references refid="lnc_8h_1a4810d8325791be718f1bcb2a92fd3a0f" compoundref="lnc_8h" startline="219">RINT</references> <references refid="lnc_8h_1ac6f30425a8221b25e8ebf4cdeb804b0e" compoundref="lnc_8h" startline="220">TINT</references> </memberdef> <memberdef kind="function" id="lnc_8c_1a3adb7ffd629931a01514727e774010be" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lnc_nextRxPtr</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_nextRxPtr</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="534" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="534" bodyend="544"/> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" compoundref="lnc_8h" startline="175">NDESC</references> <references refid="structlncInfo_1a7520aa6929e2407573acaa5d408c7af4" compoundref="lnc_8h" startline="136">lncInfo::nrdre</references> <references refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" compoundref="lnc_8h" startline="140">lncInfo::rxPtr</references> <referencedby refid="lnc_8c_1afa544fa662f94035a72f9c04f7f7fd5a" compoundref="lnc_8c" startline="316" endline="350">lnc_rxINT</referencedby> <referencedby refid="lnc_8c_1a6fb9d9c3d73ce2d10b2cebe1d71f07e2" compoundref="lnc_8c" startline="278" endline="314">lnc_thread</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a2b7362bb168e98f74686a9e149e77766" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lnc_nextTxPtr</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_nextTxPtr</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="522" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="522" bodyend="532"/> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" compoundref="lnc_8h" startline="175">NDESC</references> <references refid="structlncInfo_1a1ca5c65a2fbc6bc1cd56930eeec0b7eb" compoundref="lnc_8h" startline="137">lncInfo::ntdre</references> <references refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" compoundref="lnc_8h" startline="139">lncInfo::txPtr</references> <referencedby refid="lnc_8c_1a85f794a709a826cb783b49a20dda4cf3" compoundref="lnc_8c" startline="546" endline="571">lnc_sendPacket</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1ad661daf22a22f6b9c428aebef31ea723" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lnc_probe</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_probe</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="191" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="191" bodyend="229"/> <references refid="lnc_8h_1a05aca4c2607e5cf418d26c6471c6df91" compoundref="lnc_8h" startline="234">Am79C960</references> <references refid="lnc_8h_1a91e4b6782cdb439f7d1493924b06036d" compoundref="lnc_8h" startline="235">Am79C961</references> <references refid="lnc_8h_1a3e6e658373fd814ca74785d82fb483df" compoundref="lnc_8h" startline="236">Am79C961A</references> <references refid="lnc_8h_1abe2e36dbd6a0dda5f7132f496d560751" compoundref="lnc_8h" startline="237">Am79C965</references> <references refid="lnc_8h_1a901c0fbc5ca77f43baa5468a0c554148" compoundref="lnc_8h" startline="238">Am79C970</references> <references refid="lnc_8h_1a26c7d28ffe133b74501f6c3cd3ee0afc" compoundref="lnc_8h" startline="239">Am79C970A</references> <references refid="lnc_8h_1a77cd476f0f327589173897cace2a6d5d" compoundref="lnc_8h" startline="240">Am79C971</references> <references refid="lnc_8h_1aec4eaac1bfb06a8d9d33802cd3481a71" compoundref="lnc_8h" startline="241">Am79C972</references> <references refid="lnc_8h_1a2418761a3aa861593c41df8a9c75c84b" compoundref="lnc_8h" startline="242">Am79C973</references> <references refid="lnc_8h_1a4377d3112a6628c997cd2a4fe9a5e3d8" compoundref="lnc_8h" startline="243">Am79C978</references> <references refid="lnc_8h_1ae3685f97383506d96630657d40139121" compoundref="lnc_8h" startline="232">AMD_MASK</references> <references refid="lnc_8h_1ac2969c1f9783df74d1315e32c8d7e512" compoundref="lnc_8h" startline="211">CSR88</references> <references refid="lnc_8h_1a64a850bd91da43c547e18e1b4cba0af2" compoundref="lnc_8h" startline="212">CSR89</references> <references refid="lnc_8c_1ac698a392b34b41b9aa3eed6ec7c2f8db" compoundref="lnc_8c" startline="231" endline="252">lanceProbe</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" compoundref="lnc_8c" startline="64" endline="67">lnc_readCSR</references> <references refid="lnc_8h_1af09868a61f66925c57b5d3e7fe36596b" compoundref="lnc_8h" startline="233">PART_MASK</references> <references refid="lnc_8h_1af1a6cf2caeea69b144932f488e69ef9a" compoundref="lnc_8h" startline="200">PCnet_32</references> <references refid="lnc_8h_1a33e34c2221d08ac7e5e4a76ad5fe5f2c" compoundref="lnc_8h" startline="203">PCnet_FAST</references> <references refid="lnc_8h_1a132ccf085a33454d996e0a80d804c391" compoundref="lnc_8h" startline="204">PCnet_FASTplus</references> <references refid="lnc_8h_1a42619f0c436d20482c7cb4b76fc643a5" compoundref="lnc_8h" startline="205">PCnet_Home</references> <references refid="lnc_8h_1a3baa99ddd1afd3e15b0895fd678db39e" compoundref="lnc_8h" startline="197">PCnet_ISA</references> <references refid="lnc_8h_1aed1e84c250032911bffed1b2f49fcf6e" compoundref="lnc_8h" startline="199">PCnet_ISA_II</references> <references refid="lnc_8h_1a9ad716fd5d7913ddf296a963b88c74e6" compoundref="lnc_8h" startline="198">PCnet_ISAplus</references> <references refid="lnc_8h_1a2da9a3ce30e040d19856a3aa23d11d09" compoundref="lnc_8h" startline="201">PCnet_PCI</references> <references refid="lnc_8h_1ae4152589aa28996d4f456ea1e3841613" compoundref="lnc_8h" startline="202">PCnet_PCI_II</references> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a213face33ee64fb988be9fa980589253" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref></type> <definition>uint16_t lnc_readBCR</definition> <argsstring>(struct lncInfo *lnc, uint16_t port)</argsstring> <name>lnc_readBCR</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref></type> <declname>port</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="84" column="10" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="84" bodyend="87"/> <references refid="lnc_8h_1a88310f276b7fab99e0ba6936c9554c71" compoundref="lnc_8h" startline="41">BDP</references> <references refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" compoundref="io_8c" startline="55" endline="63">inportWord</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" compoundref="io_8c" startline="103" endline="109">outportWord</references> <references refid="lnc_8h_1a7769dee41e40f208184d06305aa55a6c" compoundref="lnc_8h" startline="37">RAP</references> </memberdef> <memberdef kind="function" id="lnc_8c_1ad1848f3fed3685285d6218e19bec1605" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <definition>uint32_t lnc_readBCR32</definition> <argsstring>(struct lncInfo *lnc, uint32_t port)</argsstring> <name>lnc_readBCR32</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <declname>port</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="89" column="10" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="89" bodyend="92"/> <references refid="lnc_8h_1ad18ea98b9c83ca7ba86ca45baf65c9a1" compoundref="lnc_8h" startline="42">BDP32</references> <references refid="io_8h_1a8d6617406b264c7f9e143adab8406791" compoundref="io_8c" startline="133" endline="141">inportDWord</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" compoundref="io_8c" startline="118" endline="124">outportDWord</references> <references refid="lnc_8h_1a982ad181218cfa7ad17f5b0a58897e84" compoundref="lnc_8h" startline="38">RAP32</references> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> <referencedby refid="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" compoundref="lnc_8c" startline="593" endline="609">lnc_switchDWord</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref></type> <definition>uint16_t lnc_readCSR</definition> <argsstring>(struct lncInfo *lnc, uint16_t port)</argsstring> <name>lnc_readCSR</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref></type> <declname>port</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="64" column="10" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="64" bodyend="67"/> <references refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" compoundref="io_8c" startline="55" endline="63">inportWord</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" compoundref="io_8c" startline="103" endline="109">outportWord</references> <references refid="lnc_8h_1a7769dee41e40f208184d06305aa55a6c" compoundref="lnc_8h" startline="37">RAP</references> <references refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" compoundref="lnc_8h" startline="35">RDP</references> <referencedby refid="lnc_8c_1ac698a392b34b41b9aa3eed6ec7c2f8db" compoundref="lnc_8c" startline="231" endline="252">lanceProbe</referencedby> <referencedby refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" compoundref="lnc_8c" startline="573" endline="583">lnc_getMode</referencedby> <referencedby refid="lnc_8c_1ad661daf22a22f6b9c428aebef31ea723" compoundref="lnc_8c" startline="191" endline="229">lnc_probe</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <definition>uint32_t lnc_readCSR32</definition> <argsstring>(struct lncInfo *lnc, uint32_t port)</argsstring> <name>lnc_readCSR32</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <declname>port</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="69" column="10" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="69" bodyend="72"/> <references refid="io_8h_1a8d6617406b264c7f9e143adab8406791" compoundref="io_8c" startline="133" endline="141">inportDWord</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" compoundref="io_8c" startline="118" endline="124">outportDWord</references> <references refid="lnc_8h_1a982ad181218cfa7ad17f5b0a58897e84" compoundref="lnc_8h" startline="38">RAP32</references> <references refid="lnc_8h_1aed7bb762e822dafd4117dc5e5523da8e" compoundref="lnc_8h" startline="36">RDP32</references> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> <referencedby refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" compoundref="lnc_8c" startline="573" endline="583">lnc_getMode</referencedby> <referencedby refid="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" compoundref="lnc_8c" startline="593" endline="609">lnc_switchDWord</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a4acfee627f5b840fa9491efcd0ef384d" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_reset</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_reset</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="585" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="585" bodyend="587"/> <references refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" compoundref="io_8c" startline="55" endline="63">inportWord</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8h_1ab702106cf3b3e96750b6845ded4e0299" compoundref="lnc_8h" startline="39">RESET</references> <referencedby refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" compoundref="lnc_8c" startline="573" endline="583">lnc_getMode</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1ab42934c99afb63e4dab3859307feeb80" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_reset32</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_reset32</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="589" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="589" bodyend="591"/> <references refid="io_8h_1a8d6617406b264c7f9e143adab8406791" compoundref="io_8c" startline="133" endline="141">inportDWord</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8h_1a99afd52e2a5136f4df1040ae306eeacc" compoundref="lnc_8h" startline="40">RESET32</references> <referencedby refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" compoundref="lnc_8c" startline="573" endline="583">lnc_getMode</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1afa544fa662f94035a72f9c04f7f7fd5a" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_rxINT</definition> <argsstring>()</argsstring> <name>lnc_rxINT</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="316" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="316" bodyend="350"/> <references refid="structnicBuffer_1a9679b6c2e76a7617884e422c11aa3eac" compoundref="netif_8h" startline="55">nicBuffer::buffer</references> <references refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" compoundref="lnc_8h" startline="138">lncInfo::bufferSize</references> <references refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" compoundref="kmalloc_8c" startline="241" endline="331">kmalloc</references> <references refid="structnicBuffer_1a959ee09a7a6fc875f3d5d651576f37c4" compoundref="netif_8h" startline="54">nicBuffer::length</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1a15887c99a129da1ef80b030d097c6c80" compoundref="lnc_8c" startline="518" endline="520">lnc_driverOwnsRX</references> <references refid="lnc_8c_1a3adb7ffd629931a01514727e774010be" compoundref="lnc_8c" startline="534" endline="544">lnc_nextRxPtr</references> <references refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" compoundref="lnc_8h" startline="87">hostRingEntry::md</references> <references refid="string_8h_1ace4b911463887af5e748326323e99a23">memset</references> <references refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" compoundref="lnc_8h" startline="131">lncInfo::rxBuffer</references> <references refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" compoundref="lnc_8h" startline="140">lncInfo::rxPtr</references> <references refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" compoundref="lnc_8h" startline="130">lncInfo::rxRing</references> <references refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" compoundref="lnc_8c" startline="52">tmpBuf</references> </memberdef> <memberdef kind="function" id="lnc_8c_1a85f794a709a826cb783b49a20dda4cf3" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lnc_sendPacket</definition> <argsstring>(struct lncInfo *lnc, void *packet, size_t len, uint8_t *dest)</argsstring> <name>lnc_sendPacket</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type>void *</type> <declname>packet</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a7619b847aeded8a6d14cbfa212b2cdfb" kindref="member">size_t</ref></type> <declname>len</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a2aff71146ab4942b2b38860c749c4074" kindref="member">uint8_t</ref> *</type> <declname>dest</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="546" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="546" bodyend="571"/> <references refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" compoundref="lnc_8h" startline="86">hostRingEntry::bcnt</references> <references refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" compoundref="lnc_8h" startline="138">lncInfo::bufferSize</references> <references refid="armv6_2kpanic_8c_1adb9a182aa071791a306163d50d653deb" compoundref="armv6_2kpanic_8c" startline="41" endline="61">kpanic</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1ab876fabc49e39786f1a2ad625c90f2d2" compoundref="lnc_8c" startline="514" endline="516">lnc_driverOwnsTX</references> <references refid="lnc_8c_1a2b7362bb168e98f74686a9e149e77766" compoundref="lnc_8c" startline="522" endline="532">lnc_nextTxPtr</references> <references refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" compoundref="lnc_8h" startline="87">hostRingEntry::md</references> <references refid="string_8h_1ae33b18edb618c656b9b795b9fce2316c">memcpy</references> <references refid="structlncInfo_1ace83a5fa2170e2d3ea36ef987186b580" compoundref="lnc_8h" startline="133">lncInfo::txBuffer</references> <references refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" compoundref="lnc_8h" startline="139">lncInfo::txPtr</references> <references refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" compoundref="lnc_8h" startline="132">lncInfo::txRing</references> </memberdef> <memberdef kind="function" id="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lnc_switchDWord</definition> <argsstring>(struct lncInfo *lnc)</argsstring> <name>lnc_switchDWord</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="593" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="593" bodyend="609"/> <references refid="lnc_8h_1a68b0ced7df1599e51f1260147d3d0c48" compoundref="lnc_8h" startline="45">BCR18</references> <references refid="lnc_8h_1a2285233a4ac1ed9ee8ee81f2fdc4ba1e" compoundref="lnc_8h" startline="46">BCR18_DWIO</references> <references refid="lnc_8h_1a7152294a2766ee5fcf0dca9fba61cfcd" compoundref="lnc_8h" startline="67">CSR58</references> <references refid="io_8h_1a8d6617406b264c7f9e143adab8406791" compoundref="io_8c" startline="133" endline="141">inportDWord</references> <references refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" compoundref="io_8c" startline="55" endline="63">inportWord</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" compoundref="kprintf_8c" startline="259" endline="276">kprintf</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1ad1848f3fed3685285d6218e19bec1605" compoundref="lnc_8c" startline="89" endline="92">lnc_readBCR32</references> <references refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" compoundref="lnc_8c" startline="69" endline="72">lnc_readCSR32</references> <references refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" compoundref="lnc_8c" startline="59" endline="62">lnc_writeCSR32</references> <references refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" compoundref="io_8c" startline="118" endline="124">outportDWord</references> <references refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" compoundref="lnc_8h" startline="35">RDP</references> <references refid="lnc_8h_1ab702106cf3b3e96750b6845ded4e0299" compoundref="lnc_8h" startline="39">RESET</references> <references refid="lnc_8h_1a99afd52e2a5136f4df1040ae306eeacc" compoundref="lnc_8h" startline="40">RESET32</references> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a6fb9d9c3d73ce2d10b2cebe1d71f07e2" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_thread</definition> <argsstring>()</argsstring> <name>lnc_thread</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="278" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="278" bodyend="314"/> <references refid="structnicBuffer_1a9679b6c2e76a7617884e422c11aa3eac" compoundref="netif_8h" startline="55">nicBuffer::buffer</references> <references refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" compoundref="lnc_8h" startline="138">lncInfo::bufferSize</references> <references refid="netif_8h_1a53b1dadb198f26ea67bf74d4d3e8daef" compoundref="ethernetif_8c" startline="270" endline="288">ethernetif_input</references> <references refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" compoundref="kmalloc_8c" startline="241" endline="331">kmalloc</references> <references refid="structnicBuffer_1a959ee09a7a6fc875f3d5d651576f37c4" compoundref="netif_8h" startline="54">nicBuffer::length</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="lnc_8c_1a15887c99a129da1ef80b030d097c6c80" compoundref="lnc_8c" startline="518" endline="520">lnc_driverOwnsRX</references> <references refid="lnc_8c_1ace647f9c4c077c9f160f180ee37bd6ed" compoundref="lnc_8c" startline="42">lnc_netif</references> <references refid="lnc_8c_1a3adb7ffd629931a01514727e774010be" compoundref="lnc_8c" startline="534" endline="544">lnc_nextRxPtr</references> <references refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" compoundref="lnc_8h" startline="87">hostRingEntry::md</references> <references refid="string_8h_1ace4b911463887af5e748326323e99a23">memset</references> <references refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" compoundref="lnc_8h" startline="131">lncInfo::rxBuffer</references> <references refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" compoundref="lnc_8h" startline="140">lncInfo::rxPtr</references> <references refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" compoundref="lnc_8h" startline="130">lncInfo::rxRing</references> <references refid="armv6_2sched_8c_1a08933fe6d593a1c78b9080359f15a0b7" compoundref="armv6_2sched_8c" startline="244" endline="246">sched_yield</references> <references refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" compoundref="lnc_8c" startline="52">tmpBuf</references> <referencedby refid="net_2init_8c_1a22b2914249628f6cba7d4e1f138c969f" compoundref="net_2init_8c" startline="52" endline="70">net_init</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1af76f3bd737b9ae341630ec574e25735b" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_txINT</definition> <argsstring>()</argsstring> <name>lnc_txINT</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="352" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="352" bodyend="366"/> </memberdef> <memberdef kind="function" id="lnc_8c_1a7542af3f8b6969da5e51db96f6013efe" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_writeBCR</definition> <argsstring>(struct lncInfo *lnc, uint16_t port, uint16_t val)</argsstring> <name>lnc_writeBCR</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref></type> <declname>port</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref></type> <declname>val</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="74" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="74" bodyend="77"/> <references refid="lnc_8h_1a88310f276b7fab99e0ba6936c9554c71" compoundref="lnc_8h" startline="41">BDP</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" compoundref="io_8c" startline="103" endline="109">outportWord</references> <references refid="lnc_8h_1a7769dee41e40f208184d06305aa55a6c" compoundref="lnc_8h" startline="37">RAP</references> </memberdef> <memberdef kind="function" id="lnc_8c_1abc22d59a1dab450fde08b50ef668974a" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_writeBCR32</definition> <argsstring>(struct lncInfo *lnc, uint32_t port, uint32_t val)</argsstring> <name>lnc_writeBCR32</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <declname>port</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <declname>val</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="79" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="79" bodyend="82"/> <references refid="lnc_8h_1ad18ea98b9c83ca7ba86ca45baf65c9a1" compoundref="lnc_8h" startline="42">BDP32</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" compoundref="io_8c" startline="118" endline="124">outportDWord</references> <references refid="lnc_8h_1a982ad181218cfa7ad17f5b0a58897e84" compoundref="lnc_8h" startline="38">RAP32</references> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a7ddaf6c2816ca0adea2397a0ccbc101b" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_writeCSR</definition> <argsstring>(struct lncInfo *lnc, uint16_t port, uint16_t val)</argsstring> <name>lnc_writeCSR</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref></type> <declname>port</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref></type> <declname>val</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="54" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="54" bodyend="57"/> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" compoundref="io_8c" startline="103" endline="109">outportWord</references> <references refid="lnc_8h_1a7769dee41e40f208184d06305aa55a6c" compoundref="lnc_8h" startline="37">RAP</references> <references refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" compoundref="lnc_8h" startline="35">RDP</references> <referencedby refid="lnc_8c_1ac698a392b34b41b9aa3eed6ec7c2f8db" compoundref="lnc_8c" startline="231" endline="252">lanceProbe</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lnc_writeCSR32</definition> <argsstring>(struct lncInfo *lnc, uint32_t port, uint32_t val)</argsstring> <name>lnc_writeCSR32</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <declname>port</declname> </param> <param> <type><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref></type> <declname>val</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="59" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="59" bodyend="62"/> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" compoundref="io_8c" startline="118" endline="124">outportDWord</references> <references refid="lnc_8h_1a982ad181218cfa7ad17f5b0a58897e84" compoundref="lnc_8h" startline="38">RAP32</references> <references refid="lnc_8h_1aed7bb762e822dafd4117dc5e5523da8e" compoundref="lnc_8h" startline="36">RDP32</references> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> <referencedby refid="lnc_8c_1a91848001b8f3004373121f03951d4c4c" compoundref="lnc_8c" startline="254" endline="276">lnc_INT</referencedby> <referencedby refid="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" compoundref="lnc_8c" startline="593" endline="609">lnc_switchDWord</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a86e977fd8113976b87da564f2b53a2d7" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>int</type> <definition>int lncAttach</definition> <argsstring>(struct lncInfo *lnc, int unit)</argsstring> <name>lncAttach</name> <param> <type>struct <ref refid="structlncInfo" kindref="compound">lncInfo</ref> *</type> <declname>lnc</declname> </param> <param> <type>int</type> <declname>unit</declname> </param> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="419" column="5" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="419" bodyend="512"/> <references refid="structhostRingEntry_1a34d92363e396c0ca0beb6dc8707e7fcb" compoundref="lnc_8h" startline="85">hostRingEntry::addr</references> <references refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" compoundref="lnc_8h" startline="86">hostRingEntry::bcnt</references> <references refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" compoundref="lnc_8h" startline="138">lncInfo::bufferSize</references> <references refid="lnc_8h_1a26eec45c0879e59438a7d2ca16fa8067" compoundref="lnc_8h" startline="196">C_LANCE</references> <references refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" compoundref="lnc_8h" startline="100">nicInfo::ic</references> <references refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" compoundref="kmalloc_8c" startline="241" endline="331">kmalloc</references> <references refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" compoundref="kprintf_8c" startline="259" endline="276">kprintf</references> <references refid="lnc_8h_1a67dedc055b2e31a97ac3561a4a16b9af" compoundref="lnc_8h" startline="195">LANCE</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" compoundref="lnc_8h" startline="87">hostRingEntry::md</references> <references refid="structnicInfo_1a1260a18062e5cb16aac9b3f2b253409c" compoundref="lnc_8h" startline="101">nicInfo::memMode</references> <references refid="string_8h_1ace4b911463887af5e748326323e99a23">memset</references> <references refid="structnicInfo_1a3dc304d78fecc9112cf979b7b1fc3525" compoundref="lnc_8h" startline="103">nicInfo::mode</references> <references refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" compoundref="lnc_8h" startline="175">NDESC</references> <references refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" compoundref="lnc_8h" startline="129">lncInfo::nic</references> <references refid="lnc_8h_1a1291f416b069313021b519eea62d5bf1" compoundref="lnc_8h" startline="176">NORMAL</references> <references refid="structlncInfo_1a7520aa6929e2407573acaa5d408c7af4" compoundref="lnc_8h" startline="136">lncInfo::nrdre</references> <references refid="structlncInfo_1a1ca5c65a2fbc6bc1cd56930eeec0b7eb" compoundref="lnc_8h" startline="137">lncInfo::ntdre</references> <references refid="lnc_8h_1af1a6cf2caeea69b144932f488e69ef9a" compoundref="lnc_8h" startline="200">PCnet_32</references> <references refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" compoundref="lnc_8h" startline="131">lncInfo::rxBuffer</references> <references refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" compoundref="lnc_8h" startline="130">lncInfo::rxRing</references> <references refid="lnc_8h_1aef3765fe92001684a71af27e0d738038" compoundref="lnc_8h" startline="191">SHMEM</references> <references refid="structlncInfo_1ace83a5fa2170e2d3ea36ef987186b580" compoundref="lnc_8h" startline="133">lncInfo::txBuffer</references> <references refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" compoundref="lnc_8h" startline="132">lncInfo::txRing</references> <references refid="paging_8h_1a17fca9c83854e88d2ca3c0ef8ec687dc" compoundref="getphysicaladdr_8c" startline="56" endline="70">vmm_getRealAddr</references> <referencedby refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" compoundref="lnc_8c" startline="94" endline="189">initLNC</referencedby> </memberdef> <memberdef kind="function" id="lnc_8c_1a6fdabac3834c12782583e0a42f928295" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual"> <type>void</type> <definition>void lncInt</definition> <argsstring>()</argsstring> <name>lncInt</name> <briefdescription> </briefdescription> <detaileddescription> </detaileddescription> <inbodydescription> </inbodydescription> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c" line="368" column="6" bodyfile="C:/Dev/git/UbixOS/sys/pci/lnc.c" bodystart="368" bodyend="392"/> <references refid="lnc_8h_1a735563036dced0b7d6cc98f97ea4978b" compoundref="lnc_8h" startline="214">ERR</references> <references refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" compoundref="io_8c" startline="55" endline="63">inportWord</references> <references refid="lnc_8h_1a71e19ac3883e6cdbc2a19126e1b590ab" compoundref="lnc_8h" startline="222">INTR</references> <references refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" compoundref="lnc_8h" startline="135">lncInfo::ioAddr</references> <references refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" compoundref="kprintf_8c" startline="259" endline="276">kprintf</references> <references refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" compoundref="lnc_8c" startline="44">lnc</references> <references refid="io_8h_1a8acc1a06073db2e7b92ffbd00fbd0cf1" compoundref="io_8c" startline="72" endline="78">outportByte</references> <references refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" compoundref="io_8c" startline="103" endline="109">outportWord</references> <references refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" compoundref="lnc_8h" startline="35">RDP</references> <references refid="lnc_8h_1a4810d8325791be718f1bcb2a92fd3a0f" compoundref="lnc_8h" startline="219">RINT</references> <references refid="lnc_8h_1ac6f30425a8221b25e8ebf4cdeb804b0e" compoundref="lnc_8h" startline="220">TINT</references> </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/>2002-2018<sp/>The<sp/>UbixOS<sp/>Project.</highlight></codeline> <codeline lineno="3"><highlight class="comment"><sp/>*<sp/>All<sp/>rights<sp/>reserved.</highlight></codeline> <codeline lineno="4"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="5"><highlight class="comment"><sp/>*<sp/>This<sp/>was<sp/>developed<sp/>by<sp/>Christopher<sp/>W.<sp/>Olsen<sp/>for<sp/>the<sp/>UbixOS<sp/>Project.</highlight></codeline> <codeline lineno="6"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="7"><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/>modification,<sp/>are<sp/>permitted</highlight></codeline> <codeline lineno="8"><highlight class="comment"><sp/>*<sp/>provided<sp/>that<sp/>the<sp/>following<sp/>conditions<sp/>are<sp/>met:</highlight></codeline> <codeline lineno="9"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="10"><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/>notice,<sp/>this<sp/>list<sp/>of</highlight></codeline> <codeline lineno="11"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>conditions,<sp/>the<sp/>following<sp/>disclaimer<sp/>and<sp/>the<sp/>list<sp/>of<sp/>authors.</highlight></codeline> <codeline lineno="12"><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/>notice,<sp/>this<sp/>list<sp/>of</highlight></codeline> <codeline lineno="13"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>conditions,<sp/>the<sp/>following<sp/>disclaimer<sp/>and<sp/>the<sp/>list<sp/>of<sp/>authors<sp/>in<sp/>the<sp/>documentation<sp/>and/or</highlight></codeline> <codeline lineno="14"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>other<sp/>materials<sp/>provided<sp/>with<sp/>the<sp/>distribution.</highlight></codeline> <codeline lineno="15"><highlight class="comment"><sp/>*<sp/>3)<sp/>Neither<sp/>the<sp/>name<sp/>of<sp/>the<sp/>UbixOS<sp/>Project<sp/>nor<sp/>the<sp/>names<sp/>of<sp/>its<sp/>contributors<sp/>may<sp/>be<sp/>used<sp/>to</highlight></codeline> <codeline lineno="16"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>endorse<sp/>or<sp/>promote<sp/>products<sp/>derived<sp/>from<sp/>this<sp/>software<sp/>without<sp/>specific<sp/>prior<sp/>written</highlight></codeline> <codeline lineno="17"><highlight class="comment"><sp/>*<sp/><sp/><sp/><sp/>permission.</highlight></codeline> <codeline lineno="18"><highlight class="comment"><sp/>*</highlight></codeline> <codeline lineno="19"><highlight class="comment"><sp/>*<sp/>THIS<sp/>SOFTWARE<sp/>IS<sp/>PROVIDED<sp/>BY<sp/>THE<sp/>AUTHOR<sp/>AND<sp/>CONTRIBUTORS<sp/>"AS<sp/>IS"<sp/>AND<sp/>ANY<sp/>EXPRESS<sp/>OR<sp/>IMPLIED</highlight></codeline> <codeline lineno="20"><highlight class="comment"><sp/>*<sp/>WARRANTIES,<sp/>INCLUDING,<sp/>BUT<sp/>NOT<sp/>LIMITED<sp/>TO,<sp/>THE<sp/>IMPLIED<sp/>WARRANTIES<sp/>OF<sp/>MERCHANTABILITY<sp/>AND<sp/>FITNESS</highlight></codeline> <codeline lineno="21"><highlight class="comment"><sp/>*<sp/>FOR<sp/>A<sp/>PARTICULAR<sp/>PURPOSE<sp/>ARE<sp/>DISCLAIMED.<sp/>IN<sp/>NO<sp/>EVENT<sp/>SHALL<sp/>THE<sp/>COPYRIGHT<sp/>OWNER<sp/>OR<sp/>CONTRIBUTORS</highlight></codeline> <codeline lineno="22"><highlight class="comment"><sp/>*<sp/>BE<sp/>LIABLE<sp/>FOR<sp/>ANY<sp/>DIRECT,<sp/>INDIRECT,<sp/>INCIDENTAL,<sp/>SPECIAL,<sp/>EXEMPLARY,<sp/>OR<sp/>CONSEQUENTIAL<sp/>DAMAGES</highlight></codeline> <codeline lineno="23"><highlight class="comment"><sp/>*<sp/>(INCLUDING,<sp/>BUT<sp/>NOT<sp/>LIMITED<sp/>TO,<sp/>PROCUREMENT<sp/>OF<sp/>SUBSTITUTE<sp/>GOODS<sp/>OR<sp/>SERVICES;<sp/>LOSS<sp/>OF<sp/>USE,<sp/>DATA,</highlight></codeline> <codeline lineno="24"><highlight class="comment"><sp/>*<sp/>OR<sp/>PROFITS;<sp/>OR<sp/>BUSINESS<sp/>INTERRUPTION)<sp/>HOWEVER<sp/>CAUSED<sp/>AND<sp/>ON<sp/>ANY<sp/>THEORY<sp/>OF<sp/>LIABILITY,<sp/>WHETHER<sp/>IN</highlight></codeline> <codeline lineno="25"><highlight class="comment"><sp/>*<sp/>CONTRACT,<sp/>STRICT<sp/>LIABILITY,<sp/>OR<sp/>TORT<sp/>(INCLUDING<sp/>NEGLIGENCE<sp/>OR<sp/>OTHERWISE)<sp/>ARISING<sp/>IN<sp/>ANY<sp/>WAY<sp/>OUT</highlight></codeline> <codeline lineno="26"><highlight class="comment"><sp/>*<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/>SUCH<sp/>DAMAGE.</highlight></codeline> <codeline lineno="27"><highlight class="comment"><sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="28"><highlight class="normal"></highlight></codeline> <codeline lineno="29"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="lnc_8h" kindref="compound">pci/lnc.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="30"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="io_8h" kindref="compound">sys/io.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="31"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="include_2sys_2types_8h" kindref="compound">sys/types.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="32"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="idt_8h" kindref="compound">sys/idt.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="33"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="gdt_8h" kindref="compound">sys/gdt.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="34"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="kmalloc_8h" kindref="compound">lib/kmalloc.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="35"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="kprintf_8h" kindref="compound">lib/kprintf.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="36"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="video_8h" kindref="compound">sys/video.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="37"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="8259_8h" kindref="compound">isa/8259.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="38"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="net_8h" kindref="compound">net/net.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="39"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="netif_8h" kindref="compound">net/netif.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="40"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/><<ref refid="spinlock_8h" kindref="compound">ubixos/spinlock.h</ref>></highlight><highlight class="normal"></highlight></codeline> <codeline lineno="41"><highlight class="normal"></highlight></codeline> <codeline lineno="42" refid="lnc_8c_1ace647f9c4c077c9f160f180ee37bd6ed" refkind="member"><highlight class="normal"></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structnetif" kindref="compound">netif</ref><sp/><ref refid="lnc_8c_1ace647f9c4c077c9f160f180ee37bd6ed" kindref="member">lnc_netif</ref>;</highlight></codeline> <codeline lineno="43"><highlight class="normal"></highlight></codeline> <codeline lineno="44" refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" refkind="member"><highlight class="normal"></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref><sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="45"><highlight class="normal"></highlight></codeline> <codeline lineno="46"><highlight class="normal"></highlight><highlight class="comment">//static<sp/>struct<sp/>spinLock<sp/>lnc_intSpinLock<sp/>=<sp/>SPIN_LOCK_INITIALIZER;</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="47"><highlight class="normal"></highlight></codeline> <codeline lineno="48"><highlight class="normal"></highlight><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/>nicIdent[]<sp/>=<sp/>{<sp/></highlight><highlight class="stringliteral">"Unknown"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"BICC"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"NE2100"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"DEPCA"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"CNET98S"</highlight><highlight class="normal"><sp/>};</highlight></codeline> <codeline lineno="49"><highlight class="normal"></highlight></codeline> <codeline lineno="50"><highlight class="normal"></highlight><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/>icIdent[]<sp/>=<sp/>{<sp/></highlight><highlight class="stringliteral">"Unknown"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"LANCE"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"C-LANCE"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-ISA"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-ISA+"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-ISA<sp/>II"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-32<sp/>VL-Bus"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-PCI"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-PCI<sp/>II"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-FAST"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-FAST+"</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">"PCnet-Home"</highlight><highlight class="normal">,<sp/>};</highlight></codeline> <codeline lineno="51"><highlight class="normal"></highlight></codeline> <codeline lineno="52" refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" refkind="member"><highlight class="normal"></highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref><sp/>*<ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>;</highlight></codeline> <codeline lineno="53"><highlight class="normal"></highlight></codeline> <codeline lineno="54" refid="lnc_8c_1a7ddaf6c2816ca0adea2397a0ccbc101b" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a7ddaf6c2816ca0adea2397a0ccbc101b" kindref="member">lnc_writeCSR</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>port,<sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>val)<sp/>{</highlight></codeline> <codeline lineno="55"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" kindref="member">outportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a7769dee41e40f208184d06305aa55a6c" kindref="member">RAP</ref>,<sp/>port);</highlight></codeline> <codeline lineno="56"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" kindref="member">outportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" kindref="member">RDP</ref>,<sp/>val);</highlight></codeline> <codeline lineno="57"><highlight class="normal">}</highlight></codeline> <codeline lineno="58"><highlight class="normal"></highlight></codeline> <codeline lineno="59" refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" kindref="member">lnc_writeCSR32</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>port,<sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>val)<sp/>{</highlight></codeline> <codeline lineno="60"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" kindref="member">outportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a982ad181218cfa7ad17f5b0a58897e84" kindref="member">RAP32</ref>,<sp/>port);</highlight></codeline> <codeline lineno="61"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" kindref="member">outportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1aed7bb762e822dafd4117dc5e5523da8e" kindref="member">RDP32</ref>,<sp/>val);</highlight></codeline> <codeline lineno="62"><highlight class="normal">}</highlight></codeline> <codeline lineno="63"><highlight class="normal"></highlight></codeline> <codeline lineno="64" refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" refkind="member"><highlight class="normal"><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/><ref refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" kindref="member">lnc_readCSR</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>port)<sp/>{</highlight></codeline> <codeline lineno="65"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" kindref="member">outportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a7769dee41e40f208184d06305aa55a6c" kindref="member">RAP</ref>,<sp/>port);</highlight></codeline> <codeline lineno="66"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" kindref="member">inportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" kindref="member">RDP</ref>));</highlight></codeline> <codeline lineno="67"><highlight class="normal">}</highlight></codeline> <codeline lineno="68"><highlight class="normal"></highlight></codeline> <codeline lineno="69" refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" refkind="member"><highlight class="normal"><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/><ref refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" kindref="member">lnc_readCSR32</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>port)<sp/>{</highlight></codeline> <codeline lineno="70"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" kindref="member">outportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a982ad181218cfa7ad17f5b0a58897e84" kindref="member">RAP32</ref>,<sp/>port);</highlight></codeline> <codeline lineno="71"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="io_8h_1a8d6617406b264c7f9e143adab8406791" kindref="member">inportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1aed7bb762e822dafd4117dc5e5523da8e" kindref="member">RDP32</ref>));</highlight></codeline> <codeline lineno="72"><highlight class="normal">}</highlight></codeline> <codeline lineno="73"><highlight class="normal"></highlight></codeline> <codeline lineno="74" refid="lnc_8c_1a7542af3f8b6969da5e51db96f6013efe" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a7542af3f8b6969da5e51db96f6013efe" kindref="member">lnc_writeBCR</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>port,<sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>val)<sp/>{</highlight></codeline> <codeline lineno="75"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" kindref="member">outportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a7769dee41e40f208184d06305aa55a6c" kindref="member">RAP</ref>,<sp/>port);</highlight></codeline> <codeline lineno="76"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" kindref="member">outportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a88310f276b7fab99e0ba6936c9554c71" kindref="member">BDP</ref>,<sp/>val);</highlight></codeline> <codeline lineno="77"><highlight class="normal">}</highlight></codeline> <codeline lineno="78"><highlight class="normal"></highlight></codeline> <codeline lineno="79" refid="lnc_8c_1abc22d59a1dab450fde08b50ef668974a" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1abc22d59a1dab450fde08b50ef668974a" kindref="member">lnc_writeBCR32</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>port,<sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>val)<sp/>{</highlight></codeline> <codeline lineno="80"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" kindref="member">outportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a982ad181218cfa7ad17f5b0a58897e84" kindref="member">RAP32</ref>,<sp/>port);</highlight></codeline> <codeline lineno="81"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" kindref="member">outportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ad18ea98b9c83ca7ba86ca45baf65c9a1" kindref="member">BDP32</ref>,<sp/>val);</highlight></codeline> <codeline lineno="82"><highlight class="normal">}</highlight></codeline> <codeline lineno="83"><highlight class="normal"></highlight></codeline> <codeline lineno="84" refid="lnc_8c_1a213face33ee64fb988be9fa980589253" refkind="member"><highlight class="normal"><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/><ref refid="lnc_8c_1a213face33ee64fb988be9fa980589253" kindref="member">lnc_readBCR</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>port)<sp/>{</highlight></codeline> <codeline lineno="85"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" kindref="member">outportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a7769dee41e40f208184d06305aa55a6c" kindref="member">RAP</ref>,<sp/>port);</highlight></codeline> <codeline lineno="86"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" kindref="member">inportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a88310f276b7fab99e0ba6936c9554c71" kindref="member">BDP</ref>));</highlight></codeline> <codeline lineno="87"><highlight class="normal">}</highlight></codeline> <codeline lineno="88"><highlight class="normal"></highlight></codeline> <codeline lineno="89" refid="lnc_8c_1ad1848f3fed3685285d6218e19bec1605" refkind="member"><highlight class="normal"><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/><ref refid="lnc_8c_1ad1848f3fed3685285d6218e19bec1605" kindref="member">lnc_readBCR32</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>port)<sp/>{</highlight></codeline> <codeline lineno="90"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" kindref="member">outportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a982ad181218cfa7ad17f5b0a58897e84" kindref="member">RAP32</ref>,<sp/>port);</highlight></codeline> <codeline lineno="91"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="io_8h_1a8d6617406b264c7f9e143adab8406791" kindref="member">inportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ad18ea98b9c83ca7ba86ca45baf65c9a1" kindref="member">BDP32</ref>));</highlight></codeline> <codeline lineno="92"><highlight class="normal">}</highlight></codeline> <codeline lineno="93"><highlight class="normal"></highlight></codeline> <codeline lineno="94" refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a0c06be8c0c0c046c5073f4cfae3eed7c" kindref="member">initLNC</ref>()<sp/>{</highlight></codeline> <codeline lineno="95"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>i<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="96"><highlight class="normal"></highlight></codeline> <codeline lineno="97"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>data[64]<sp/>=<sp/></highlight><highlight class="stringliteral">"abcDEFghiJKLmnoPQRstuVWXyz"</highlight><highlight class="normal">;</highlight></codeline> <codeline lineno="98"><highlight class="normal"></highlight></codeline> <codeline lineno="99"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref><sp/>=<sp/><ref refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" kindref="member">kmalloc</ref>(</highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref>));</highlight></codeline> <codeline lineno="100"><highlight class="normal"><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/>0x0,<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref>));</highlight></codeline> <codeline lineno="101"><highlight class="normal"></highlight></codeline> <codeline lineno="102"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref><sp/>=<sp/>1548;</highlight></codeline> <codeline lineno="103"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>=<sp/>0xD020;</highlight></codeline> <codeline lineno="104"><highlight class="normal"></highlight></codeline> <codeline lineno="105"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" kindref="member">ic</ref><sp/>=<sp/><ref refid="lnc_8c_1ad661daf22a22f6b9c428aebef31ea723" kindref="member">lnc_probe</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="106"><highlight class="normal"></highlight></codeline> <codeline lineno="107"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("ID:<sp/>%i\n",<sp/>lnc->nic.ic);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="108"><highlight class="normal"></highlight></codeline> <codeline lineno="109"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>((<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" kindref="member">ic</ref><sp/>><sp/>0)<sp/>&&<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" kindref="member">ic</ref><sp/>>=<sp/><ref refid="lnc_8h_1af1a6cf2caeea69b144932f488e69ef9a" kindref="member">PCnet_32</ref>))<sp/>{</highlight></codeline> <codeline lineno="110"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1abc40ed67a91dece36218837e90a90218" kindref="member">ident</ref><sp/>=<sp/><ref refid="lnc_8h_1a0f13e1c33c723fb1751c67d8dcd54df3" kindref="member">NE2100</ref>;</highlight></codeline> <codeline lineno="111"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1a1260a18062e5cb16aac9b3f2b253409c" kindref="member">memMode</ref><sp/>=<sp/><ref refid="lnc_8h_1ac7329f246bfda2b0fc34bba5cae18380" kindref="member">DMA_FIXED</ref>;</highlight></codeline> <codeline lineno="112"><highlight class="normal"></highlight></codeline> <codeline lineno="113"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a7520aa6929e2407573acaa5d408c7af4" kindref="member">nrdre</ref><sp/>=<sp/><ref refid="lnc_8h_1a9a6f0938f7533adf6aebf030c2cff3d6" kindref="member">NRDRE</ref>;</highlight></codeline> <codeline lineno="114"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a1ca5c65a2fbc6bc1cd56930eeec0b7eb" kindref="member">ntdre</ref><sp/>=<sp/><ref refid="lnc_8h_1a5feb2f9782070ea70e997a934dba38b1" kindref="member">NTDRE</ref>;</highlight></codeline> <codeline lineno="115"><highlight class="normal"></highlight></codeline> <codeline lineno="116"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*<sp/>Extract<sp/>MAC<sp/>address<sp/>from<sp/>PROM<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="117"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">for</highlight><highlight class="normal"><sp/>(i<sp/>=<sp/>0;<sp/>i<sp/><<sp/><ref refid="lnc_8h_1abf4fcaacb1ad2010711b7c880ec2ed20" kindref="member">ETHER_ADDR_LEN</ref>;<sp/>i++)<sp/>{</highlight></codeline> <codeline lineno="118"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[i]<sp/>=<sp/><ref refid="io_8h_1a77b934268de1b3ecdcf3f275413b3108" kindref="member">inportByte</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/>i);</highlight></codeline> <codeline lineno="119"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"[0x%X]"</highlight><highlight class="normal">,<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[i]);</highlight></codeline> <codeline lineno="120"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="121"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="122"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline> <codeline lineno="123"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"LNC<sp/>Init<sp/>Error\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="124"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(-1);</highlight></codeline> <codeline lineno="125"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="126"><highlight class="normal"></highlight></codeline> <codeline lineno="127"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a86e977fd8113976b87da564f2b53a2d7" kindref="member">lncAttach</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/>0);</highlight></codeline> <codeline lineno="128"><highlight class="normal"></highlight></codeline> <codeline lineno="129"><highlight class="normal"><sp/><sp/>i<sp/>=<sp/><ref refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" kindref="member">lnc_getMode</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="130"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(i<sp/>==<sp/><ref refid="lnc_8h_1a8208bd666b76f9875ef5d27cb001e264" kindref="member">MODE_16</ref>)</highlight></codeline> <codeline lineno="131"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"16<sp/>Bit"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="132"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(i<sp/>==<sp/><ref refid="lnc_8h_1a3da944764f31bb69cb2aa74d1115989e" kindref="member">MODE_32</ref>)</highlight></codeline> <codeline lineno="133"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"32<sp/>Bit"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="134"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="135"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"Invalid<sp/>Mode:<sp/>[%i]"</highlight><highlight class="normal">,<sp/>i);</highlight></codeline> <codeline lineno="136"><highlight class="normal"></highlight></codeline> <codeline lineno="137"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" kindref="member">lnc_switchDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="138"><highlight class="normal"></highlight></codeline> <codeline lineno="139"><highlight class="normal"><sp/><sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>iW<sp/>=<sp/>0;</highlight></codeline> <codeline lineno="140"><highlight class="normal"></highlight></codeline> <codeline lineno="141"><highlight class="normal"><sp/><sp/>iW<sp/>=<sp/><ref refid="lnc_8c_1ad1848f3fed3685285d6218e19bec1605" kindref="member">lnc_readBCR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/>0x2);</highlight></codeline> <codeline lineno="142"><highlight class="normal"><sp/><sp/>iW<sp/>|=<sp/>0x2;</highlight></codeline> <codeline lineno="143"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1abc22d59a1dab450fde08b50ef668974a" kindref="member">lnc_writeBCR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/>0x2,<sp/>iW);</highlight></codeline> <codeline lineno="144"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("BCR2:<sp/>[0x%X]",<sp/>lnc_readBCR32(lnc,<sp/>0x2));</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="145"><highlight class="normal"></highlight></codeline> <codeline lineno="146"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1a7a82e395fd7ebc9c6d49aaa076079edf" kindref="member">mode</ref><sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="147"><highlight class="normal"></highlight></codeline> <codeline lineno="148"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1ac1cc1926832f4faadf8c68d4d3efad9c" kindref="member">padr</ref>[0]<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[0];</highlight></codeline> <codeline lineno="149"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1ac1cc1926832f4faadf8c68d4d3efad9c" kindref="member">padr</ref>[1]<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[1];</highlight></codeline> <codeline lineno="150"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1ac1cc1926832f4faadf8c68d4d3efad9c" kindref="member">padr</ref>[2]<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[2];</highlight></codeline> <codeline lineno="151"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1ac1cc1926832f4faadf8c68d4d3efad9c" kindref="member">padr</ref>[3]<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[3];</highlight></codeline> <codeline lineno="152"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1ac1cc1926832f4faadf8c68d4d3efad9c" kindref="member">padr</ref>[4]<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[4];</highlight></codeline> <codeline lineno="153"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1ac1cc1926832f4faadf8c68d4d3efad9c" kindref="member">padr</ref>[5]<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[5];</highlight></codeline> <codeline lineno="154"><highlight class="normal"></highlight></codeline> <codeline lineno="155"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1a8c7d3f96a698e973939ab069e779e60f" kindref="member">rdra</ref><sp/>=<sp/>(<ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref>)<sp/><ref refid="paging_8h_1a17fca9c83854e88d2ca3c0ef8ec687dc" kindref="member">vmm_getRealAddr</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>);</highlight></codeline> <codeline lineno="156"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1a7d8e6b5186ef35e5867bcc2df83e177b" kindref="member">rlen</ref><sp/>=<sp/>3<sp/><<<sp/>4;</highlight></codeline> <codeline lineno="157"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("Virt<sp/>Addr:<sp/>0x%X,<sp/>Real<sp/>Addr:<sp/>0x%X",<sp/>lnc->rxRing,<sp/>vmm_getRealAddr(lnc->rxRing));</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="158"><highlight class="normal"></highlight></codeline> <codeline lineno="159"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1a21be4224d33c7821c3ada11a0e8c3f08" kindref="member">tdra</ref><sp/>=<sp/>(<ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref>)<sp/><ref refid="paging_8h_1a17fca9c83854e88d2ca3c0ef8ec687dc" kindref="member">vmm_getRealAddr</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>);</highlight></codeline> <codeline lineno="160"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>.<ref refid="structinitBlock32_1ad3c8914cac5a258208f737a446dfd78e" kindref="member">tlen</ref><sp/>=<sp/>3<sp/><<<sp/>4;</highlight></codeline> <codeline lineno="161"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("Virt<sp/>Addr:<sp/>0x%X,<sp/>Real<sp/>Addr:<sp/>0x%X",<sp/>lnc->txRing,<sp/>vmm_getRealAddr(lnc->txRing));</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="162"><highlight class="normal"></highlight></codeline> <codeline lineno="163"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("Virt<sp/>Addr:<sp/>0x%X,<sp/>Real<sp/>Addr:<sp/>0x%X",<sp/>&lnc->init,<sp/>vmm_getRealAddr(&lnc->init));</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="164"><highlight class="normal"></highlight></codeline> <codeline lineno="165"><highlight class="normal"><sp/><sp/>iW<sp/>=<sp/><ref refid="paging_8h_1a17fca9c83854e88d2ca3c0ef8ec687dc" kindref="member">vmm_getRealAddr</ref>(&<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e865d1cef832d16bfd9305f19ee43d4" kindref="member">init</ref>);</highlight></codeline> <codeline lineno="166"><highlight class="normal"></highlight></codeline> <codeline lineno="167"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" kindref="member">lnc_writeCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1aaa0004ce746adcb049f80ada0d848500" kindref="member">CSR1</ref>,<sp/>iW<sp/>&<sp/>0xFFFF);</highlight></codeline> <codeline lineno="168"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" kindref="member">lnc_writeCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a6f3bf10d90237a3c12153ebf8a52d586" kindref="member">CSR2</ref>,<sp/>(iW<sp/>>><sp/>16)<sp/>&<sp/>0xFFFF);</highlight></codeline> <codeline lineno="169"><highlight class="normal"></highlight></codeline> <codeline lineno="170"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" kindref="member">lnc_writeCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1aaccfc3c68d398428c31b3c26cf3c7d5f" kindref="member">CSR3</ref>,<sp/>0);</highlight></codeline> <codeline lineno="171"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" kindref="member">lnc_writeCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>,<sp/><ref refid="lnc_8h_1ab5889105dcd019008c9448dff61323f6" kindref="member">INIT</ref>);</highlight></codeline> <codeline lineno="172"><highlight class="normal"></highlight></codeline> <codeline lineno="173"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">for</highlight><highlight class="normal"><sp/>(i<sp/>=<sp/>0;<sp/>i<sp/><<sp/>1000;<sp/>i++)</highlight></codeline> <codeline lineno="174"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" kindref="member">lnc_readCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>)<sp/>&<sp/><ref refid="lnc_8h_1aca0dae20ad119b8bf8f368693eb2bff8" kindref="member">IDON</ref>)</highlight></codeline> <codeline lineno="175"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">break</highlight><highlight class="normal">;</highlight></codeline> <codeline lineno="176"><highlight class="normal"></highlight></codeline> <codeline lineno="177"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" kindref="member">lnc_readCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>)<sp/>&<sp/><ref refid="lnc_8h_1aca0dae20ad119b8bf8f368693eb2bff8" kindref="member">IDON</ref>)<sp/>{</highlight></codeline> <codeline lineno="178"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="idt_8h_1a174a47ed653fc64fff6b5bb1b895c2cf" kindref="member">setVector</ref>(&<ref refid="lnc_8h_1a59af9e0fe8ee78093931131a8818e66f" kindref="member">lnc_isr</ref>,<sp/><ref refid="8259_8h_1a2f7f6ebf05739e77a7c20aee806b771c" kindref="member">sVec</ref><sp/>+<sp/>0x1,<sp/>(<ref refid="gdt_8h_1a7eb6dc7004c613df58764da5df7d85d8" kindref="member">dInt</ref><sp/>+<sp/><ref refid="gdt_8h_1abe5eb76416aff1d9114e1cdb8b0797fe" kindref="member">dPresent</ref><sp/>+<sp/><ref refid="gdt_8h_1a2e29d1e158d5e81dc70dfae75f17d7f4" kindref="member">dDpl3</ref>));</highlight></codeline> <codeline lineno="179"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="8259_8h_1a0ac079c4d770f02e505f4d8569a6960a" kindref="member">irqEnable</ref>(2);</highlight></codeline> <codeline lineno="180"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//irqEnable(0x9);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="181"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" kindref="member">lnc_writeCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>,<sp/><ref refid="lnc_8h_1a39aaa2cb5148aec0a6c4599feaf3a7d3" kindref="member">STRT</ref><sp/>|<sp/><ref refid="lnc_8h_1a93d733faa9617c2136ecc02953be45d5" kindref="member">INEA</ref>);</highlight></codeline> <codeline lineno="182"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="183"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline> <codeline lineno="184"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"LNC:<sp/>init<sp/>Error\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="185"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(-1);</highlight></codeline> <codeline lineno="186"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="187"><highlight class="normal"></highlight></codeline> <codeline lineno="188"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(0);</highlight></codeline> <codeline lineno="189"><highlight class="normal">}</highlight></codeline> <codeline lineno="190"><highlight class="normal"></highlight></codeline> <codeline lineno="191" refid="lnc_8c_1ad661daf22a22f6b9c428aebef31ea723" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1ad661daf22a22f6b9c428aebef31ea723" kindref="member">lnc_probe</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="192"><highlight class="normal"></highlight></codeline> <codeline lineno="193"><highlight class="normal"><sp/><sp/><ref refid="objgfx30_8h_1ada085051a6d9a8e00a2cb256d1af14ba" kindref="member">uInt32</ref><sp/>chipId<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="194"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>type<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="195"><highlight class="normal"></highlight></codeline> <codeline lineno="196"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>((type<sp/>=<sp/><ref refid="lnc_8c_1ac698a392b34b41b9aa3eed6ec7c2f8db" kindref="member">lanceProbe</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)))<sp/>{</highlight></codeline> <codeline lineno="197"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("Type:<sp/>[0x%X]",<sp/>type);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="198"><highlight class="normal"><sp/><sp/><sp/><sp/>chipId<sp/>=<sp/><ref refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" kindref="member">lnc_readCSR</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a64a850bd91da43c547e18e1b4cba0af2" kindref="member">CSR89</ref>);</highlight></codeline> <codeline lineno="199"><highlight class="normal"><sp/><sp/><sp/><sp/>chipId<sp/><<=<sp/>16;</highlight></codeline> <codeline lineno="200"><highlight class="normal"><sp/><sp/><sp/><sp/>chipId<sp/>|=<sp/><ref refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" kindref="member">lnc_readCSR</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1ac2969c1f9783df74d1315e32c8d7e512" kindref="member">CSR88</ref>);</highlight></codeline> <codeline lineno="201"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(chipId<sp/>&<sp/><ref refid="lnc_8h_1ae3685f97383506d96630657d40139121" kindref="member">AMD_MASK</ref>)<sp/>{</highlight></codeline> <codeline lineno="202"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>chipId<sp/>>>=<sp/>12;</highlight></codeline> <codeline lineno="203"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">switch</highlight><highlight class="normal"><sp/>(chipId<sp/>&<sp/><ref refid="lnc_8h_1af09868a61f66925c57b5d3e7fe36596b" kindref="member">PART_MASK</ref>)<sp/>{</highlight></codeline> <codeline lineno="204"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a05aca4c2607e5cf418d26c6471c6df91" kindref="member">Am79C960</ref>:</highlight></codeline> <codeline lineno="205"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1a3baa99ddd1afd3e15b0895fd678db39e" kindref="member">PCnet_ISA</ref>);</highlight></codeline> <codeline lineno="206"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a91e4b6782cdb439f7d1493924b06036d" kindref="member">Am79C961</ref>:</highlight></codeline> <codeline lineno="207"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1a9ad716fd5d7913ddf296a963b88c74e6" kindref="member">PCnet_ISAplus</ref>);</highlight></codeline> <codeline lineno="208"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a3e6e658373fd814ca74785d82fb483df" kindref="member">Am79C961A</ref>:</highlight></codeline> <codeline lineno="209"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1aed1e84c250032911bffed1b2f49fcf6e" kindref="member">PCnet_ISA_II</ref>);</highlight></codeline> <codeline lineno="210"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1abe2e36dbd6a0dda5f7132f496d560751" kindref="member">Am79C965</ref>:</highlight></codeline> <codeline lineno="211"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1af1a6cf2caeea69b144932f488e69ef9a" kindref="member">PCnet_32</ref>);</highlight></codeline> <codeline lineno="212"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a901c0fbc5ca77f43baa5468a0c554148" kindref="member">Am79C970</ref>:</highlight></codeline> <codeline lineno="213"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1a2da9a3ce30e040d19856a3aa23d11d09" kindref="member">PCnet_PCI</ref>);</highlight></codeline> <codeline lineno="214"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a26c7d28ffe133b74501f6c3cd3ee0afc" kindref="member">Am79C970A</ref>:</highlight></codeline> <codeline lineno="215"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1ae4152589aa28996d4f456ea1e3841613" kindref="member">PCnet_PCI_II</ref>);</highlight></codeline> <codeline lineno="216"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a77cd476f0f327589173897cace2a6d5d" kindref="member">Am79C971</ref>:</highlight></codeline> <codeline lineno="217"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1a33e34c2221d08ac7e5e4a76ad5fe5f2c" kindref="member">PCnet_FAST</ref>);</highlight></codeline> <codeline lineno="218"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1aec4eaac1bfb06a8d9d33802cd3481a71" kindref="member">Am79C972</ref>:</highlight></codeline> <codeline lineno="219"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a2418761a3aa861593c41df8a9c75c84b" kindref="member">Am79C973</ref>:</highlight></codeline> <codeline lineno="220"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1a132ccf085a33454d996e0a80d804c391" kindref="member">PCnet_FASTplus</ref>);</highlight></codeline> <codeline lineno="221"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">case</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a4377d3112a6628c997cd2a4fe9a5e3d8" kindref="member">Am79C978</ref>:</highlight></codeline> <codeline lineno="222"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1a42619f0c436d20482c7cb4b76fc643a5" kindref="member">PCnet_Home</ref>);</highlight></codeline> <codeline lineno="223"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">default</highlight><highlight class="normal">:</highlight></codeline> <codeline lineno="224"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">break</highlight><highlight class="normal">;</highlight></codeline> <codeline lineno="225"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="226"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="227"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="228"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(type);</highlight></codeline> <codeline lineno="229"><highlight class="normal">}</highlight></codeline> <codeline lineno="230"><highlight class="normal"></highlight></codeline> <codeline lineno="231" refid="lnc_8c_1ac698a392b34b41b9aa3eed6ec7c2f8db" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1ac698a392b34b41b9aa3eed6ec7c2f8db" kindref="member">lanceProbe</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="232"><highlight class="normal"><sp/><sp/><ref refid="objgfx30_8h_1a81f3b46fa4ddd984830104840a08da82" kindref="member">uInt16</ref><sp/>inW<sp/>=<sp/>0;</highlight></codeline> <codeline lineno="233"><highlight class="normal"></highlight></codeline> <codeline lineno="234"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a7ddaf6c2816ca0adea2397a0ccbc101b" kindref="member">lnc_writeCSR</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>,<sp/><ref refid="lnc_8h_1a1cf3194611b57177ea230f2994ee654c" kindref="member">CSR0_STOP</ref>);</highlight></codeline> <codeline lineno="235"><highlight class="normal"></highlight></codeline> <codeline lineno="236"><highlight class="normal"><sp/><sp/>inW<sp/>=<sp/><ref refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" kindref="member">inportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" kindref="member">RDP</ref>);</highlight></codeline> <codeline lineno="237"><highlight class="normal"></highlight></codeline> <codeline lineno="238"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>((inW<sp/>&<sp/><ref refid="lnc_8h_1a1cf3194611b57177ea230f2994ee654c" kindref="member">CSR0_STOP</ref>)<sp/>&&<sp/>!(<ref refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" kindref="member">lnc_readCSR</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1aaccfc3c68d398428c31b3c26cf3c7d5f" kindref="member">CSR3</ref>)))<sp/>{</highlight></codeline> <codeline lineno="239"><highlight class="normal"></highlight></codeline> <codeline lineno="240"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a7ddaf6c2816ca0adea2397a0ccbc101b" kindref="member">lnc_writeCSR</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>,<sp/><ref refid="lnc_8h_1a93d733faa9617c2136ecc02953be45d5" kindref="member">INEA</ref>);</highlight></codeline> <codeline lineno="241"><highlight class="normal"></highlight></codeline> <codeline lineno="242"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" kindref="member">lnc_readCSR</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>)<sp/>&<sp/><ref refid="lnc_8h_1a93d733faa9617c2136ecc02953be45d5" kindref="member">INEA</ref>)<sp/>{</highlight></codeline> <codeline lineno="243"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1a26eec45c0879e59438a7d2ca16fa8067" kindref="member">C_LANCE</ref>);</highlight></codeline> <codeline lineno="244"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="245"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline> <codeline lineno="246"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1a67dedc055b2e31a97ac3561a4a16b9af" kindref="member">LANCE</ref>);</highlight></codeline> <codeline lineno="247"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="248"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="249"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline> <codeline lineno="250"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1ac1ae4add974b9cfc6b5aaf8a578f01ab" kindref="member">UNKNOWN</ref>);</highlight></codeline> <codeline lineno="251"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="252"><highlight class="normal">}</highlight></codeline> <codeline lineno="253"><highlight class="normal"></highlight></codeline> <codeline lineno="254" refid="lnc_8c_1a91848001b8f3004373121f03951d4c4c" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a91848001b8f3004373121f03951d4c4c" kindref="member">lnc_INT</ref>()<sp/>{</highlight></codeline> <codeline lineno="255"><highlight class="normal"><sp/><sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>csr0<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="256"><highlight class="normal"></highlight></codeline> <codeline lineno="257"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("\nINTR\n");</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="258"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//while<sp/>((csr0<sp/>=<sp/>lnc_readCSR32(lnc,<sp/>CSR0))<sp/>&<sp/>INTR)<sp/>{</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="259"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("CSR0:<sp/>[0x%X]\n",<sp/>csr0);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="260"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(csr0<sp/>&<sp/><ref refid="lnc_8h_1a735563036dced0b7d6cc98f97ea4978b" kindref="member">ERR</ref>)<sp/>{</highlight></codeline> <codeline lineno="261"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"Error:<sp/>[0x%X]\n"</highlight><highlight class="normal">,<sp/>csr0);</highlight></codeline> <codeline lineno="262"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="263"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(csr0<sp/>&<sp/><ref refid="lnc_8h_1a4810d8325791be718f1bcb2a92fd3a0f" kindref="member">RINT</ref>)<sp/>{</highlight></codeline> <codeline lineno="264"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">asm</highlight><highlight class="normal">(</highlight><highlight class="stringliteral">"nop"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="265"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//lnc_rxINT();</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="266"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="267"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(csr0<sp/>&<sp/><ref refid="lnc_8h_1ac6f30425a8221b25e8ebf4cdeb804b0e" kindref="member">TINT</ref>)<sp/>{</highlight></codeline> <codeline lineno="268"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">asm</highlight><highlight class="normal">(</highlight><highlight class="stringliteral">"nop"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="269"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("TINT");</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="270"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//lnc_txINT();</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="271"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="272"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/><sp/><sp/>kprintf("CSR0.1:<sp/>[0x%X]\n",<sp/>lnc_readCSR32(lnc,<sp/>CSR0));</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="273"><highlight class="normal"></highlight><highlight class="comment">//<sp/><sp/>}</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="274"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" kindref="member">lnc_writeCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>,<sp/>0x7940);<sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//csr0);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="275"><highlight class="normal"></highlight><highlight class="comment">//<sp/><sp/>kprintf("INT<sp/>DONE");</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="276"><highlight class="normal">}</highlight></codeline> <codeline lineno="277"><highlight class="normal"></highlight></codeline> <codeline lineno="278" refid="lnc_8c_1a6fb9d9c3d73ce2d10b2cebe1d71f07e2" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a6fb9d9c3d73ce2d10b2cebe1d71f07e2" kindref="member">lnc_thread</ref>()<sp/>{</highlight></codeline> <codeline lineno="279"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>i<sp/>=<sp/>0;</highlight></codeline> <codeline lineno="280"><highlight class="normal"></highlight></codeline> <codeline lineno="281"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref><sp/>==<sp/>0x0)<sp/>{</highlight></codeline> <codeline lineno="282"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref><sp/>=<sp/>(</highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref><sp/>*)<sp/><ref refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" kindref="member">kmalloc</ref>(</highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref>));</highlight></codeline> <codeline lineno="283"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>,<sp/>0x0,<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref>));</highlight></codeline> <codeline lineno="284"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="285"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline> <codeline lineno="286"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>,<sp/>0x0,<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref>));</highlight></codeline> <codeline lineno="287"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="288"><highlight class="normal"></highlight></codeline> <codeline lineno="289"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>(1)<sp/>{</highlight></codeline> <codeline lineno="290"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1a15887c99a129da1ef80b030d097c6c80" kindref="member">lnc_driverOwnsRX</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>))<sp/>{</highlight></codeline> <codeline lineno="291"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//uint16_t<sp/>plen<sp/>=<sp/>0<sp/>+<sp/>(uint16_t)lnc->rxRing[lnc->rxPtr].md[2];</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="292"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>plen<sp/>=<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[2]<sp/>&<sp/>0x0fff)<sp/>-<sp/>4;</highlight></codeline> <codeline lineno="293"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*</highlight></codeline> <codeline lineno="294"><highlight class="comment"><sp/><sp/><sp/><sp/><sp/><sp/><sp/>if<sp/>(plen<sp/>><sp/>0)</highlight></codeline> <codeline lineno="295"><highlight class="comment"><sp/><sp/><sp/><sp/><sp/><sp/><sp/>kprintf("plen.0:<sp/>[0x%X]",<sp/>plen);</highlight></codeline> <codeline lineno="296"><highlight class="comment"><sp/><sp/><sp/><sp/><sp/><sp/><sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="297"><highlight class="normal"></highlight></codeline> <codeline lineno="298"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>-><ref refid="structnicBuffer_1a959ee09a7a6fc875f3d5d651576f37c4" kindref="member">length</ref><sp/>=<sp/>plen;</highlight></codeline> <codeline lineno="299"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>-><ref refid="structnicBuffer_1a9679b6c2e76a7617884e422c11aa3eac" kindref="member">buffer</ref><sp/>=<sp/>(</highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*)<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" kindref="member">rxBuffer</ref><sp/>+<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref><sp/>*<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>));<sp/></highlight><highlight class="comment">//(char<sp/>*)kmalloc(length);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="300"><highlight class="normal"></highlight></codeline> <codeline lineno="301"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//<sp/>kprintf("RINT2\n");</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="302"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="netif_8h_1a53b1dadb198f26ea67bf74d4d3e8daef" kindref="member">ethernetif_input</ref>(&<ref refid="lnc_8c_1ace647f9c4c077c9f160f180ee37bd6ed" kindref="member">lnc_netif</ref>);</highlight></codeline> <codeline lineno="303"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("RINT3\n");</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="304"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("RINT-LOOP[%i][0x%X][0x%X]",<sp/>lnc->rxPtr,lnc->rxRing[lnc->rxPtr].md[1],plen);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="305"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>=<sp/>0x80;</highlight></codeline> <codeline lineno="306"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("RINT-LOOP[%i][0x%X][0x%X]",<sp/>lnc->rxPtr,lnc->rxRing[lnc->rxPtr].md[1],plen);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="307"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a3adb7ffd629931a01514727e774010be" kindref="member">lnc_nextRxPtr</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="308"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("RINT-LOOP[%i][0x%X][0x%X]\n",<sp/>lnc->rxPtr,lnc->rxRing[lnc->rxPtr].md[1],plen);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="309"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="310"><highlight class="normal"></highlight><highlight class="comment">//<sp/><sp/>kprintf("RINT-DONE[%i][0x%X]\n",<sp/>lnc->rxPtr,lnc->rxRing[lnc->rxPtr].md[1]);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="311"><highlight class="normal"></highlight></codeline> <codeline lineno="312"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="armv6_2sched_8c_1a08933fe6d593a1c78b9080359f15a0b7" kindref="member">sched_yield</ref>();</highlight></codeline> <codeline lineno="313"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="314"><highlight class="normal">}</highlight></codeline> <codeline lineno="315"><highlight class="normal"></highlight></codeline> <codeline lineno="316" refid="lnc_8c_1afa544fa662f94035a72f9c04f7f7fd5a" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1afa544fa662f94035a72f9c04f7f7fd5a" kindref="member">lnc_rxINT</ref>()<sp/>{</highlight></codeline> <codeline lineno="317"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>i<sp/>=<sp/>0;</highlight></codeline> <codeline lineno="318"><highlight class="normal"></highlight></codeline> <codeline lineno="319"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref><sp/>==<sp/>0x0)<sp/>{</highlight></codeline> <codeline lineno="320"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref><sp/>=<sp/>(</highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref><sp/>*)<sp/><ref refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" kindref="member">kmalloc</ref>(</highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref>));</highlight></codeline> <codeline lineno="321"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>,<sp/>0x0,<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref>));</highlight></codeline> <codeline lineno="322"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="323"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline> <codeline lineno="324"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>,<sp/>0x0,<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structnicBuffer" kindref="compound">nicBuffer</ref>));</highlight></codeline> <codeline lineno="325"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="326"><highlight class="normal"></highlight></codeline> <codeline lineno="327"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1a15887c99a129da1ef80b030d097c6c80" kindref="member">lnc_driverOwnsRX</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>))<sp/>{</highlight></codeline> <codeline lineno="328"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//uint16_t<sp/>plen<sp/>=<sp/>0<sp/>+<sp/>(uint16_t)lnc->rxRing[lnc->rxPtr].md[2];</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="329"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>plen<sp/>=<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[2]<sp/>&<sp/>0x0fff)<sp/>-<sp/>4;</highlight></codeline> <codeline lineno="330"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*</highlight></codeline> <codeline lineno="331"><highlight class="comment"><sp/><sp/><sp/><sp/><sp/>if<sp/>(plen<sp/>><sp/>0)</highlight></codeline> <codeline lineno="332"><highlight class="comment"><sp/><sp/><sp/><sp/><sp/>kprintf("plen.0:<sp/>[0x%X]",<sp/>plen);</highlight></codeline> <codeline lineno="333"><highlight class="comment"><sp/><sp/><sp/><sp/><sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="334"><highlight class="normal"></highlight></codeline> <codeline lineno="335"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>-><ref refid="structnicBuffer_1a959ee09a7a6fc875f3d5d651576f37c4" kindref="member">length</ref><sp/>=<sp/>plen;</highlight></codeline> <codeline lineno="336"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a4a11421d92a3c6d8d9fae9db3bb9f299" kindref="member">tmpBuf</ref>-><ref refid="structnicBuffer_1a9679b6c2e76a7617884e422c11aa3eac" kindref="member">buffer</ref><sp/>=<sp/>(</highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*)<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" kindref="member">rxBuffer</ref><sp/>+<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref><sp/>*<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>));<sp/></highlight><highlight class="comment">//(char<sp/>*)kmalloc(length);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="337"><highlight class="normal"></highlight></codeline> <codeline lineno="338"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//<sp/>kprintf("RINT2\n");</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="339"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//ethernetif_input(netif_default);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="340"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("RINT3\n");</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="341"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("RINT-LOOP[%i][0x%X][0x%X]",<sp/>lnc->rxPtr,lnc->rxRing[lnc->rxPtr].md[1],plen);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="342"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>=<sp/>0x80;</highlight></codeline> <codeline lineno="343"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("RINT-LOOP[%i][0x%X][0x%X]",<sp/>lnc->rxPtr,lnc->rxRing[lnc->rxPtr].md[1],plen);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="344"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a3adb7ffd629931a01514727e774010be" kindref="member">lnc_nextRxPtr</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="345"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("RINT-LOOP[%i][0x%X][0x%X]\n",<sp/>lnc->rxPtr,lnc->rxRing[lnc->rxPtr].md[1],plen);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="346"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="347"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//<sp/>kprintf("RINT-DONE[%i][0x%X]\n",<sp/>lnc->rxPtr,lnc->rxRing[lnc->rxPtr].md[1]);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="348"><highlight class="normal"></highlight><highlight class="comment">//while(1);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="349"><highlight class="normal"></highlight></codeline> <codeline lineno="350"><highlight class="normal">}</highlight></codeline> <codeline lineno="351"><highlight class="normal"></highlight></codeline> <codeline lineno="352" refid="lnc_8c_1af76f3bd737b9ae341630ec574e25735b" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1af76f3bd737b9ae341630ec574e25735b" kindref="member">lnc_txINT</ref>()<sp/>{</highlight></codeline> <codeline lineno="353"><highlight class="normal"><sp/><sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>status<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="354"><highlight class="normal"></highlight></codeline> <codeline lineno="355"><highlight class="normal"><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"TINT\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="356"><highlight class="normal"><sp/><sp/>status<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>+<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/><<<sp/>16);</highlight></codeline> <codeline lineno="357"><highlight class="normal"><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"Status:<sp/>[0x%X]\n"</highlight><highlight class="normal">,<sp/>status);</highlight></codeline> <codeline lineno="358"><highlight class="normal"></highlight></codeline> <codeline lineno="359"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>(!<ref refid="lnc_8c_1ab876fabc49e39786f1a2ad625c90f2d2" kindref="member">lnc_driverOwnsTX</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>))<sp/>{</highlight></codeline> <codeline lineno="360"><highlight class="normal"><sp/><sp/><sp/><sp/>status<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>+<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/><<<sp/>16);</highlight></codeline> <codeline lineno="361"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"md[1]:<sp/>0x%X(%i)[0x%X]\n"</highlight><highlight class="normal">,<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1],<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>,<sp/>status);</highlight></codeline> <codeline lineno="362"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="363"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1a2b7362bb168e98f74686a9e149e77766" kindref="member">lnc_nextTxPtr</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="364"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="365"><highlight class="normal"><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"TINT-DONE\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="366"><highlight class="normal">}</highlight></codeline> <codeline lineno="367"><highlight class="normal"></highlight></codeline> <codeline lineno="368" refid="lnc_8c_1a6fdabac3834c12782583e0a42f928295" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a6fdabac3834c12782583e0a42f928295" kindref="member">lncInt</ref>()<sp/>{</highlight></codeline> <codeline lineno="369"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>(1)<sp/>{</highlight></codeline> <codeline lineno="370"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"Finished!!!\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="371"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="372"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a8acc1a06073db2e7b92ffbd00fbd0cf1" kindref="member">outportByte</ref>(0x20,<sp/>0x20);</highlight></codeline> <codeline lineno="373"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal">;</highlight></codeline> <codeline lineno="374"><highlight class="normal"><sp/><sp/><ref refid="objgfx30_8h_1a81f3b46fa4ddd984830104840a08da82" kindref="member">uInt16</ref><sp/>csr0<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="375"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">while</highlight><highlight class="normal"><sp/>((csr0<sp/>=<sp/><ref refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" kindref="member">inportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" kindref="member">RDP</ref>))<sp/>&<sp/><ref refid="lnc_8h_1a71e19ac3883e6cdbc2a19126e1b590ab" kindref="member">INTR</ref>)<sp/>{</highlight></codeline> <codeline lineno="376"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" kindref="member">outportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" kindref="member">RDP</ref>,<sp/>csr0);</highlight></codeline> <codeline lineno="377"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"CSR0:<sp/>[0x%X]\n"</highlight><highlight class="normal">,<sp/>csr0);</highlight></codeline> <codeline lineno="378"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(csr0<sp/>&<sp/><ref refid="lnc_8h_1a735563036dced0b7d6cc98f97ea4978b" kindref="member">ERR</ref>)<sp/>{</highlight></codeline> <codeline lineno="379"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"Error:<sp/>[0x%X]\n"</highlight><highlight class="normal">,<sp/>csr0);</highlight></codeline> <codeline lineno="380"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="381"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(csr0<sp/>&<sp/><ref refid="lnc_8h_1a4810d8325791be718f1bcb2a92fd3a0f" kindref="member">RINT</ref>)<sp/>{</highlight></codeline> <codeline lineno="382"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"RINT\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="383"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="384"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(csr0<sp/>&<sp/><ref refid="lnc_8h_1ac6f30425a8221b25e8ebf4cdeb804b0e" kindref="member">TINT</ref>)<sp/>{</highlight></codeline> <codeline lineno="385"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"TINT\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="386"><highlight class="normal"><sp/><sp/><sp/><sp/>}</highlight></codeline> <codeline lineno="387"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="io_8h_1a243f6b6d22cc5948908b764d58efc2b0" kindref="member">outportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" kindref="member">RDP</ref>,<sp/>csr0);</highlight></codeline> <codeline lineno="388"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"CSR0:<sp/>[0x%X]\n"</highlight><highlight class="normal">,<sp/>csr0);</highlight></codeline> <codeline lineno="389"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="390"><highlight class="normal"><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"Finished!!!\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="391"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal">;</highlight></codeline> <codeline lineno="392"><highlight class="normal">}</highlight></codeline> <codeline lineno="393"><highlight class="normal"></highlight></codeline> <codeline lineno="394"><highlight class="normal"></highlight><highlight class="keyword">asm</highlight><highlight class="normal">(</highlight></codeline> <codeline lineno="395"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">".globl<sp/>lnc_isr<sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="396"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"lnc_isr:<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="397"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>pusha<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"><sp/></highlight><highlight class="comment">/*<sp/>Save<sp/>all<sp/>registers<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="398"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>push<sp/>%ss<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="399"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>push<sp/>%ds<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="400"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>push<sp/>%es<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="401"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>push<sp/>%fs<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="402"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>push<sp/>%gs<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="403"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>call<sp/>lnc_INT<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="404"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>mov<sp/>$0xA0,%dx<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="405"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>mov<sp/>$0x20,%ax<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="406"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>outb<sp/>%al,%dx<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="407"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>mov<sp/>$0x20,%dx<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="408"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>mov<sp/>$0x20,%ax<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="409"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>outb<sp/>%al,%dx<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="410"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>pop<sp/>%gs<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="411"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>pop<sp/>%fs<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="412"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>pop<sp/>%es<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="413"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>pop<sp/>%ds<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="414"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>pop<sp/>%ss<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="415"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>popa<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="416"><highlight class="normal"><sp/><sp/></highlight><highlight class="stringliteral">"<sp/><sp/>iret<sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>\n"</highlight><highlight class="normal"><sp/></highlight><highlight class="comment">/*<sp/>Exit<sp/>interrupt<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><highlight class="normal"></highlight></codeline> <codeline lineno="417"><highlight class="normal">);</highlight></codeline> <codeline lineno="418"><highlight class="normal"></highlight></codeline> <codeline lineno="419" refid="lnc_8c_1a86e977fd8113976b87da564f2b53a2d7" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a86e977fd8113976b87da564f2b53a2d7" kindref="member">lncAttach</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>unit)<sp/>{</highlight></codeline> <codeline lineno="420"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>i<sp/>=<sp/>0;</highlight></codeline> <codeline lineno="421"><highlight class="normal"><sp/><sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>lncSize<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="422"><highlight class="normal"><sp/><sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/>bcnt<sp/>=<sp/>0x0;</highlight></codeline> <codeline lineno="423"><highlight class="normal"></highlight></codeline> <codeline lineno="424"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>Initialize<sp/>rxRing<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="425"><highlight class="normal"><sp/><sp/>lncSize<sp/>=<sp/>(<ref refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" kindref="member">NDESC</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a7520aa6929e2407573acaa5d408c7af4" kindref="member">nrdre</ref>)<sp/>*<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structhostRingEntry" kindref="compound">hostRingEntry</ref>));</highlight></codeline> <codeline lineno="426"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("rxRing<sp/>Size:<sp/>[%i]",<sp/>lncSize);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="427"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref><sp/>=<sp/><ref refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" kindref="member">kmalloc</ref>(lncSize);</highlight></codeline> <codeline lineno="428"><highlight class="normal"></highlight></codeline> <codeline lineno="429"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(!<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>)<sp/>{</highlight></codeline> <codeline lineno="430"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"lnc%d:<sp/>Couldn't<sp/>allocate<sp/>memory<sp/>for<sp/>rxRing\n"</highlight><highlight class="normal">,<sp/>unit);</highlight></codeline> <codeline lineno="431"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(-1);</highlight></codeline> <codeline lineno="432"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="433"><highlight class="normal"></highlight></codeline> <codeline lineno="434"><highlight class="normal"><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>,<sp/>0x0,<sp/>lncSize);</highlight></codeline> <codeline lineno="435"><highlight class="normal"></highlight></codeline> <codeline lineno="436"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>Initialize<sp/>rxBuffer<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="437"><highlight class="normal"><sp/><sp/>lncSize<sp/>=<sp/>(<ref refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" kindref="member">NDESC</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a7520aa6929e2407573acaa5d408c7af4" kindref="member">nrdre</ref>)<sp/>*<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>);</highlight></codeline> <codeline lineno="438"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("rxBuffer<sp/>Size:<sp/>[%i]\n",<sp/>lncSize);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="439"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" kindref="member">rxBuffer</ref><sp/>=<sp/><ref refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" kindref="member">kmalloc</ref>(lncSize);</highlight></codeline> <codeline lineno="440"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(!<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" kindref="member">rxBuffer</ref>)<sp/>{</highlight></codeline> <codeline lineno="441"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"lnc%d:<sp/>Couldn't<sp/>allocate<sp/>memory<sp/>for<sp/>rXBuffer\n"</highlight><highlight class="normal">,<sp/>unit);</highlight></codeline> <codeline lineno="442"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(-1);</highlight></codeline> <codeline lineno="443"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="444"><highlight class="normal"><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" kindref="member">rxBuffer</ref>,<sp/>0x0,<sp/>lncSize);</highlight></codeline> <codeline lineno="445"><highlight class="normal"></highlight></codeline> <codeline lineno="446"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>Setup<sp/>the<sp/>RX<sp/>Ring<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="447"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">for</highlight><highlight class="normal"><sp/>(i<sp/>=<sp/>0;<sp/>i<sp/><<sp/><ref refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" kindref="member">NDESC</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a7520aa6929e2407573acaa5d408c7af4" kindref="member">nrdre</ref>);<sp/>i++)<sp/>{</highlight></codeline> <codeline lineno="448"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>[i].<ref refid="structhostRingEntry_1a34d92363e396c0ca0beb6dc8707e7fcb" kindref="member">addr</ref><sp/>=<sp/>(<ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref>)<sp/><ref refid="paging_8h_1a17fca9c83854e88d2ca3c0ef8ec687dc" kindref="member">vmm_getRealAddr</ref>((<ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref>)<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a0b2b816f287ef9e2d6a4f254c3dd3e7d" kindref="member">rxBuffer</ref><sp/>+<sp/>(i<sp/>*<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>));</highlight></codeline> <codeline lineno="449"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>=<sp/>(<ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref>)<sp/>(-<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>);</highlight></codeline> <codeline lineno="450"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>&=<sp/>0x0FFF;</highlight></codeline> <codeline lineno="451"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>|=<sp/>0xF000;</highlight></codeline> <codeline lineno="452"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("rxR[%i].addr<sp/>=<sp/>0x%X,<sp/>BCNT<sp/>0x%X",<sp/>i,<sp/>lnc->rxRing[i].addr,bcnt);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="453"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>[i].<ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>=<sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref>;</highlight></codeline> <codeline lineno="454"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>[i].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>=<sp/>0x80;</highlight></codeline> <codeline lineno="455"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="456"><highlight class="normal"></highlight></codeline> <codeline lineno="457"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>Initialize<sp/>txRing<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="458"><highlight class="normal"><sp/><sp/>lncSize<sp/>=<sp/>(<ref refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" kindref="member">NDESC</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a1ca5c65a2fbc6bc1cd56930eeec0b7eb" kindref="member">ntdre</ref>)<sp/>*<sp/></highlight><highlight class="keyword">sizeof</highlight><highlight class="normal">(</highlight><highlight class="keyword">struct<sp/></highlight><highlight class="normal"><ref refid="structhostRingEntry" kindref="compound">hostRingEntry</ref>));</highlight></codeline> <codeline lineno="459"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("txRing<sp/>Size:<sp/>[%i]",<sp/>lncSize);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="460"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref><sp/>=<sp/><ref refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" kindref="member">kmalloc</ref>(lncSize);</highlight></codeline> <codeline lineno="461"><highlight class="normal"></highlight></codeline> <codeline lineno="462"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(!<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>)<sp/>{</highlight></codeline> <codeline lineno="463"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"lnc%d:<sp/>Couldn't<sp/>allocate<sp/>memory<sp/>for<sp/>txRing\n"</highlight><highlight class="normal">,<sp/>unit);</highlight></codeline> <codeline lineno="464"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(-1);</highlight></codeline> <codeline lineno="465"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="466"><highlight class="normal"></highlight></codeline> <codeline lineno="467"><highlight class="normal"><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>,<sp/>0x0,<sp/>lncSize);</highlight></codeline> <codeline lineno="468"><highlight class="normal"></highlight></codeline> <codeline lineno="469"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>Initialize<sp/>txBuffer<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="470"><highlight class="normal"><sp/><sp/>lncSize<sp/>=<sp/>(<ref refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" kindref="member">NDESC</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a1ca5c65a2fbc6bc1cd56930eeec0b7eb" kindref="member">ntdre</ref>)<sp/>*<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>);</highlight></codeline> <codeline lineno="471"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("txBuffer<sp/>Size:<sp/>[%i]\n",<sp/>lncSize);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="472"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1ace83a5fa2170e2d3ea36ef987186b580" kindref="member">txBuffer</ref><sp/>=<sp/><ref refid="kmalloc_8h_1a150eab2ac4ce4553e21ca10e7f441762" kindref="member">kmalloc</ref>(lncSize);</highlight></codeline> <codeline lineno="473"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(!<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1ace83a5fa2170e2d3ea36ef987186b580" kindref="member">txBuffer</ref>)<sp/>{</highlight></codeline> <codeline lineno="474"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"lnc%d:<sp/>Couldn't<sp/>allocate<sp/>memory<sp/>for<sp/>txBuffer\n"</highlight><highlight class="normal">,<sp/>unit);</highlight></codeline> <codeline lineno="475"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(-1);</highlight></codeline> <codeline lineno="476"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="477"><highlight class="normal"><sp/><sp/><ref refid="string_8h_1ace4b911463887af5e748326323e99a23" kindref="member">memset</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1ace83a5fa2170e2d3ea36ef987186b580" kindref="member">txBuffer</ref>,<sp/>0x0,<sp/>lncSize);</highlight></codeline> <codeline lineno="478"><highlight class="normal"></highlight></codeline> <codeline lineno="479"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>Setup<sp/>the<sp/>TX<sp/>Ring<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="480"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">for</highlight><highlight class="normal"><sp/>(i<sp/>=<sp/>0;<sp/>i<sp/><<sp/><ref refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" kindref="member">NDESC</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a1ca5c65a2fbc6bc1cd56930eeec0b7eb" kindref="member">ntdre</ref>);<sp/>i++)<sp/>{</highlight></codeline> <codeline lineno="481"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[i].<ref refid="structhostRingEntry_1a34d92363e396c0ca0beb6dc8707e7fcb" kindref="member">addr</ref><sp/>=<sp/>(<ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref>)<sp/><ref refid="paging_8h_1a17fca9c83854e88d2ca3c0ef8ec687dc" kindref="member">vmm_getRealAddr</ref>((<ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref>)<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1ace83a5fa2170e2d3ea36ef987186b580" kindref="member">txBuffer</ref><sp/>+<sp/>(i<sp/>*<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>));</highlight></codeline> <codeline lineno="482"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>=<sp/>(<ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref>)<sp/>(-<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>);</highlight></codeline> <codeline lineno="483"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>&=<sp/>0x0FFF;</highlight></codeline> <codeline lineno="484"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>|=<sp/>0xF000;</highlight></codeline> <codeline lineno="485"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//kprintf("txR[%i].addr<sp/>=<sp/>0x%X,<sp/>BCNT<sp/>0x%X",<sp/>i,<sp/>lnc->txRing[i].addr,bcnt);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="486"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[i].<ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>=<sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref>;</highlight></codeline> <codeline lineno="487"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="488"><highlight class="normal"></highlight></codeline> <codeline lineno="489"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>MrOlsen<sp/>2017-12-16</highlight></codeline> <codeline lineno="490"><highlight class="comment"><sp/><sp/><sp/>if<sp/>(lnc->nic.memMode<sp/>!=<sp/>SHMEM)</highlight></codeline> <codeline lineno="491"><highlight class="comment"><sp/><sp/><sp/>lncMemSize<sp/>+=<sp/>sizeof(struct<sp/>initBlock)<sp/>+<sp/>(sizeof(struct<sp/>mds)<sp/>*<sp/>(NDESC(lnc->nrdre)<sp/>+<sp/>NDESC(lnc->ntdre)))<sp/>+<sp/>MEM_SLEW;</highlight></codeline> <codeline lineno="492"><highlight class="comment"><sp/><sp/><sp/>if<sp/>(lnc->nic.memMode<sp/>==<sp/>DMA_FIXED)</highlight></codeline> <codeline lineno="493"><highlight class="comment"><sp/><sp/><sp/>lncMemSize<sp/>+=<sp/>(NDESC(lnc->nrdre)<sp/>*<sp/>RECVBUFSIZE)<sp/>+<sp/>(NDESC(lnc->ntdre)<sp/>*<sp/>TRANSBUFSIZE);</highlight></codeline> <codeline lineno="494"><highlight class="comment"><sp/><sp/><sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="495"><highlight class="normal"></highlight></codeline> <codeline lineno="496"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1a1260a18062e5cb16aac9b3f2b253409c" kindref="member">memMode</ref><sp/>!=<sp/><ref refid="lnc_8h_1aef3765fe92001684a71af27e0d738038" kindref="member">SHMEM</ref>)</highlight></codeline> <codeline lineno="497"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" kindref="member">ic</ref><sp/><<sp/><ref refid="lnc_8h_1af1a6cf2caeea69b144932f488e69ef9a" kindref="member">PCnet_32</ref>)</highlight></codeline> <codeline lineno="498"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"ISA<sp/>Board\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="499"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="500"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"PCI<sp/>Board\n"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="501"><highlight class="normal"></highlight></codeline> <codeline lineno="502"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1a3dc304d78fecc9112cf979b7b1fc3525" kindref="member">mode</ref><sp/>=<sp/><ref refid="lnc_8h_1a1291f416b069313021b519eea62d5bf1" kindref="member">NORMAL</ref>;</highlight></codeline> <codeline lineno="503"><highlight class="normal"></highlight></codeline> <codeline lineno="504"><highlight class="normal"><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"lnc%d:<sp/>"</highlight><highlight class="normal">,<sp/>unit);</highlight></codeline> <codeline lineno="505"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" kindref="member">ic</ref><sp/>==<sp/><ref refid="lnc_8h_1a67dedc055b2e31a97ac3561a4a16b9af" kindref="member">LANCE</ref><sp/>||<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" kindref="member">ic</ref><sp/>==<sp/><ref refid="lnc_8h_1a26eec45c0879e59438a7d2ca16fa8067" kindref="member">C_LANCE</ref>)</highlight></codeline> <codeline lineno="506"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"%s<sp/>(%s)"</highlight><highlight class="normal">,<sp/>nicIdent[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1abc40ed67a91dece36218837e90a90218" kindref="member">ident</ref>],<sp/>icIdent[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" kindref="member">ic</ref>]);</highlight></codeline> <codeline lineno="507"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="508"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"%s"</highlight><highlight class="normal">,<sp/>icIdent[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1aeccb5006639cf653b6a42de7b4ae1555" kindref="member">nic</ref>.<ref refid="structnicInfo_1ace0bfd3296cc049fa333e59b1b272072" kindref="member">ic</ref>]);</highlight></codeline> <codeline lineno="509"><highlight class="normal"></highlight></codeline> <codeline lineno="510"><highlight class="normal"><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"<sp/>address<sp/>%x:%x:%x:%x:%x:%x\n"</highlight><highlight class="normal">,<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[0],<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[1],<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[2],<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[3],<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[4],<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a6ab65edc0c5bba6523ed5b95f3a25fd5" kindref="member">arpcom</ref>.<ref refid="structarpcom_1a33db97a0b3650089799388e5f47adc9d" kindref="member">ac_enaddr</ref>[5]);</highlight></codeline> <codeline lineno="511"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(1);</highlight></codeline> <codeline lineno="512"><highlight class="normal">}</highlight></codeline> <codeline lineno="513"><highlight class="normal"></highlight></codeline> <codeline lineno="514" refid="lnc_8c_1ab876fabc49e39786f1a2ad625c90f2d2" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1ab876fabc49e39786f1a2ad625c90f2d2" kindref="member">lnc_driverOwnsTX</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="515"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>&<sp/>0x80)<sp/>==<sp/>0;</highlight></codeline> <codeline lineno="516"><highlight class="normal">}</highlight></codeline> <codeline lineno="517"><highlight class="normal"></highlight></codeline> <codeline lineno="518" refid="lnc_8c_1a15887c99a129da1ef80b030d097c6c80" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a15887c99a129da1ef80b030d097c6c80" kindref="member">lnc_driverOwnsRX</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="519"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1acbc5278e1bddc916566dab1234121b4f" kindref="member">rxRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>&<sp/>0x80)<sp/>==<sp/>0;</highlight></codeline> <codeline lineno="520"><highlight class="normal">}</highlight></codeline> <codeline lineno="521"><highlight class="normal"></highlight></codeline> <codeline lineno="522" refid="lnc_8c_1a2b7362bb168e98f74686a9e149e77766" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a2b7362bb168e98f74686a9e149e77766" kindref="member">lnc_nextTxPtr</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="523"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref><sp/>+<sp/>1;</highlight></codeline> <codeline lineno="524"><highlight class="normal"></highlight></codeline> <codeline lineno="525"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>==<sp/><ref refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" kindref="member">NDESC</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a1ca5c65a2fbc6bc1cd56930eeec0b7eb" kindref="member">ntdre</ref>))<sp/>{</highlight></codeline> <codeline lineno="526"><highlight class="normal"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>0;</highlight></codeline> <codeline lineno="527"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="528"><highlight class="normal"></highlight></codeline> <codeline lineno="529"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref><sp/>=<sp/>ret;</highlight></codeline> <codeline lineno="530"><highlight class="normal"></highlight></codeline> <codeline lineno="531"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(0);</highlight></codeline> <codeline lineno="532"><highlight class="normal">}</highlight></codeline> <codeline lineno="533"><highlight class="normal"></highlight></codeline> <codeline lineno="534" refid="lnc_8c_1a3adb7ffd629931a01514727e774010be" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a3adb7ffd629931a01514727e774010be" kindref="member">lnc_nextRxPtr</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="535"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>ret<sp/>=<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref><sp/>+<sp/>1;</highlight></codeline> <codeline lineno="536"><highlight class="normal"></highlight></codeline> <codeline lineno="537"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(ret<sp/>==<sp/><ref refid="lnc_8h_1a3924669c8950a7f0b9b30e2841c21986" kindref="member">NDESC</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a7520aa6929e2407573acaa5d408c7af4" kindref="member">nrdre</ref>))<sp/>{</highlight></codeline> <codeline lineno="538"><highlight class="normal"><sp/><sp/><sp/><sp/>ret<sp/>=<sp/>0;</highlight></codeline> <codeline lineno="539"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="540"><highlight class="normal"></highlight></codeline> <codeline lineno="541"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a405d0044e90efe89f3057502d43dfa2c" kindref="member">rxPtr</ref><sp/>=<sp/>ret;</highlight></codeline> <codeline lineno="542"><highlight class="normal"></highlight></codeline> <codeline lineno="543"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(0);</highlight></codeline> <codeline lineno="544"><highlight class="normal">}</highlight></codeline> <codeline lineno="545"><highlight class="normal"></highlight></codeline> <codeline lineno="546" refid="lnc_8c_1a85f794a709a826cb783b49a20dda4cf3" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a85f794a709a826cb783b49a20dda4cf3" kindref="member">lnc_sendPacket</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*packet,<sp/></highlight><highlight class="keywordtype">size_t</highlight><highlight class="normal"><sp/>len,<sp/><ref refid="include_2sys_2types_8h_1a2aff71146ab4942b2b38860c749c4074" kindref="member">uint8_t</ref><sp/>*dest)<sp/>{</highlight></codeline> <codeline lineno="547"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("SEND<sp/>PACKET1![%i]\n",<sp/>lnc->txPtr);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="548"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(!<ref refid="lnc_8c_1ab876fabc49e39786f1a2ad625c90f2d2" kindref="member">lnc_driverOwnsTX</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>))<sp/>{</highlight></codeline> <codeline lineno="549"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="armv6_2kpanic_8c_1adb9a182aa071791a306163d50d653deb" kindref="member">kpanic</ref>(</highlight><highlight class="stringliteral">"NO<sp/>TX<sp/>BUFFERS"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="550"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(0);</highlight></codeline> <codeline lineno="551"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="552"><highlight class="normal"></highlight></codeline> <codeline lineno="553"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("SEND<sp/>PACKET2![%i]\n",<sp/>lnc->txPtr);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="554"><highlight class="normal"></highlight></codeline> <codeline lineno="555"><highlight class="normal"><sp/><sp/><ref refid="string_8h_1ae33b18edb618c656b9b795b9fce2316c" kindref="member">memcpy</ref>((</highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*)<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1ace83a5fa2170e2d3ea36ef987186b580" kindref="member">txBuffer</ref><sp/>+<sp/>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref><sp/>*<sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9e80c42e71b5d9ca504f6f031f6f3a3e" kindref="member">bufferSize</ref>)),<sp/>packet,<sp/>len);</highlight></codeline> <codeline lineno="556"><highlight class="normal"></highlight></codeline> <codeline lineno="557"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>|=<sp/>0x2;</highlight></codeline> <codeline lineno="558"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>|=<sp/>0x1;</highlight></codeline> <codeline lineno="559"><highlight class="normal"></highlight></codeline> <codeline lineno="560"><highlight class="normal"><sp/><sp/><ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>=<sp/>(<ref refid="include_2sys_2types_8h_1a281b4b5562236420969a830503b0ba19" kindref="member">uint16_t</ref>)<sp/>(-len);</highlight></codeline> <codeline lineno="561"><highlight class="normal"><sp/><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>&=<sp/>0xFFF;</highlight></codeline> <codeline lineno="562"><highlight class="normal"><sp/><sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>|=<sp/>0xF000;</highlight></codeline> <codeline lineno="563"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref><sp/>=<sp/><ref refid="structhostRingEntry_1a8d309990c12b073a189107ee78313e3e" kindref="member">bcnt</ref>;</highlight></codeline> <codeline lineno="564"><highlight class="normal"></highlight></codeline> <codeline lineno="565"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a9f1ca6c5efebea8081f9705d4cfc3927" kindref="member">txRing</ref>[<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1a8e5109e21b1f7d36abd9adc91a0f5c96" kindref="member">txPtr</ref>].<ref refid="structhostRingEntry_1ad47f374df8b180e7fa5c58cfa9ef474e" kindref="member">md</ref>[1]<sp/>|=<sp/>0x80;</highlight></codeline> <codeline lineno="566"><highlight class="normal"></highlight></codeline> <codeline lineno="567"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a2b7362bb168e98f74686a9e149e77766" kindref="member">lnc_nextTxPtr</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="568"><highlight class="normal"></highlight></codeline> <codeline lineno="569"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">//kprintf("SEND<sp/>PACKET3![%i]\n",<sp/>lnc->txPtr);</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="570"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(len);</highlight></codeline> <codeline lineno="571"><highlight class="normal">}</highlight></codeline> <codeline lineno="572"><highlight class="normal"></highlight></codeline> <codeline lineno="573" refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1adca06b8ca41f65a590bfabd9e2a24b9b" kindref="member">lnc_getMode</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="574"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1ab42934c99afb63e4dab3859307feeb80" kindref="member">lnc_reset32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="575"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" kindref="member">lnc_readCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>)<sp/>==<sp/><ref refid="lnc_8h_1a1cf3194611b57177ea230f2994ee654c" kindref="member">CSR0_STOP</ref>)</highlight></codeline> <codeline lineno="576"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a3da944764f31bb69cb2aa74d1115989e" kindref="member">MODE_32</ref>;</highlight></codeline> <codeline lineno="577"><highlight class="normal"></highlight></codeline> <codeline lineno="578"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a4acfee627f5b840fa9491efcd0ef384d" kindref="member">lnc_reset</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>);</highlight></codeline> <codeline lineno="579"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8c_1a752b6613ae8e3adf7c11e20bd94be152" kindref="member">lnc_readCSR</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a09512b5b7cf54991bf82200f66bd1b8c" kindref="member">CSR0</ref>)<sp/>==<sp/><ref refid="lnc_8h_1a1cf3194611b57177ea230f2994ee654c" kindref="member">CSR0_STOP</ref>)</highlight></codeline> <codeline lineno="580"><highlight class="normal"><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/><ref refid="lnc_8h_1a8208bd666b76f9875ef5d27cb001e264" kindref="member">MODE_16</ref>;</highlight></codeline> <codeline lineno="581"><highlight class="normal"></highlight></codeline> <codeline lineno="582"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(<ref refid="lnc_8h_1ab0dd9a24ba036665f61ba3a10f159de0" kindref="member">MODE_INVALID</ref>);</highlight></codeline> <codeline lineno="583"><highlight class="normal">}</highlight></codeline> <codeline lineno="584"><highlight class="normal"></highlight></codeline> <codeline lineno="585" refid="lnc_8c_1a4acfee627f5b840fa9491efcd0ef384d" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a4acfee627f5b840fa9491efcd0ef384d" kindref="member">lnc_reset</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="586"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" kindref="member">inportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ab702106cf3b3e96750b6845ded4e0299" kindref="member">RESET</ref>);</highlight></codeline> <codeline lineno="587"><highlight class="normal">}</highlight></codeline> <codeline lineno="588"><highlight class="normal"></highlight></codeline> <codeline lineno="589" refid="lnc_8c_1ab42934c99afb63e4dab3859307feeb80" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1ab42934c99afb63e4dab3859307feeb80" kindref="member">lnc_reset32</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="590"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a8d6617406b264c7f9e143adab8406791" kindref="member">inportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a99afd52e2a5136f4df1040ae306eeacc" kindref="member">RESET32</ref>);</highlight></codeline> <codeline lineno="591"><highlight class="normal">}</highlight></codeline> <codeline lineno="592"><highlight class="normal"></highlight></codeline> <codeline lineno="593" refid="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" refkind="member"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/><ref refid="lnc_8c_1a63b705fcc8bfad509be7dcb6bef7d821" kindref="member">lnc_switchDWord</ref>(</highlight><highlight class="keyword">struct</highlight><highlight class="normal"><sp/><ref refid="structlncInfo" kindref="compound">lncInfo</ref><sp/>*<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>)<sp/>{</highlight></codeline> <codeline lineno="594"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a8d6617406b264c7f9e143adab8406791" kindref="member">inportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1a99afd52e2a5136f4df1040ae306eeacc" kindref="member">RESET32</ref>);</highlight></codeline> <codeline lineno="595"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1afb703b187feb4b92444454df6c3dd9e6" kindref="member">inportWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ab702106cf3b3e96750b6845ded4e0299" kindref="member">RESET</ref>);</highlight></codeline> <codeline lineno="596"><highlight class="normal"><sp/><sp/><ref refid="io_8h_1a2e2ad8d744ae4b35ea37d39dcfea1296" kindref="member">outportDWord</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>-><ref refid="structlncInfo_1af005a894cb0e625cb484cd61e5dc792e" kindref="member">ioAddr</ref><sp/>+<sp/><ref refid="lnc_8h_1ac15c6fd68ca6f958468c68795a25937c" kindref="member">RDP</ref>,<sp/>0);</highlight></codeline> <codeline lineno="597"><highlight class="normal"></highlight></codeline> <codeline lineno="598"><highlight class="normal"><sp/><sp/></highlight><highlight class="comment">/*<sp/>a<sp/>dword<sp/>write<sp/>to<sp/>RDP<sp/>sets<sp/>controller<sp/>into<sp/>32-bit<sp/>I/O<sp/>mode<sp/>*/</highlight><highlight class="normal"></highlight></codeline> <codeline lineno="599"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(!(<ref refid="lnc_8c_1ad1848f3fed3685285d6218e19bec1605" kindref="member">lnc_readBCR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a68b0ced7df1599e51f1260147d3d0c48" kindref="member">BCR18</ref>)<sp/>&<sp/><ref refid="lnc_8h_1a2285233a4ac1ed9ee8ee81f2fdc4ba1e" kindref="member">BCR18_DWIO</ref>))<sp/>{</highlight></codeline> <codeline lineno="600"><highlight class="normal"><sp/><sp/><sp/><sp/><ref refid="kprintf_8h_1a20b56810edb62a6fe59917015c30848f" kindref="member">kprintf</ref>(</highlight><highlight class="stringliteral">"Cannot<sp/>Swithc<sp/>To<sp/>32<sp/>Bit"</highlight><highlight class="normal">);</highlight></codeline> <codeline lineno="601"><highlight class="normal"><sp/><sp/>}</highlight></codeline> <codeline lineno="602"><highlight class="normal"><sp/><sp/><ref refid="include_2sys_2types_8h_1a0238af00180b6d9278fa1c6aa790fdf4" kindref="member">uint32_t</ref><sp/>_csr58<sp/>=<sp/><ref refid="lnc_8c_1afe2d2cf61518c2dbc5abbf42cadec6b2" kindref="member">lnc_readCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a7152294a2766ee5fcf0dca9fba61cfcd" kindref="member">CSR58</ref>);</highlight></codeline> <codeline lineno="603"><highlight class="normal"><sp/><sp/>_csr58<sp/>&=<sp/>0xFFF0;</highlight></codeline> <codeline lineno="604"><highlight class="normal"><sp/><sp/>_csr58<sp/>|=<sp/>2;</highlight></codeline> <codeline lineno="605"><highlight class="normal"><sp/><sp/><ref refid="lnc_8c_1a343a05a27f9bf30d01eda3470668e624" kindref="member">lnc_writeCSR32</ref>(<ref refid="lnc_8c_1af5e66182cc3ee40ca7dab1a2449d002e" kindref="member">lnc</ref>,<sp/><ref refid="lnc_8h_1a7152294a2766ee5fcf0dca9fba61cfcd" kindref="member">CSR58</ref>,<sp/>_csr58);</highlight></codeline> <codeline lineno="606"><highlight class="normal"></highlight></codeline> <codeline lineno="607"><highlight class="normal"><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>(0);</highlight></codeline> <codeline lineno="608"><highlight class="normal"></highlight></codeline> <codeline lineno="609"><highlight class="normal">}</highlight></codeline> </programlisting> <location file="C:/Dev/git/UbixOS/sys/pci/lnc.c"/> </compounddef> </doxygen>