Nut/OS  4.10.3
API Reference
eth0cs.c
Go to the documentation of this file.
00001 
00069 /*
00070  * $Log$
00071  * Revision 1.4  2008/08/28 11:12:15  haraldkipp
00072  * Added interface flags, which will be required to implement Ethernet ioctl
00073  * functions.
00074  *
00075  * Revision 1.3  2007/05/02 11:22:51  haraldkipp
00076  * Added multicast table entry.
00077  *
00078  * Revision 1.2  2005/08/02 17:46:45  haraldkipp
00079  * Major API documentation update.
00080  *
00081  * Revision 1.1  2005/07/26 18:02:27  haraldkipp
00082  * Moved from dev.
00083  *
00084  * Revision 1.3  2003/08/05 20:05:11  haraldkipp
00085  * DNS removed from interface
00086  *
00087  * Revision 1.2  2003/07/20 20:07:38  haraldkipp
00088  * Conflicting Ethernet driver routine names solved.
00089  *
00090  * Revision 1.1  2003/07/20 16:37:21  haraldkipp
00091  * CrystalTek 8900A driver added.
00092  *
00093  * Revision 0.1  2002/05/02 CDCS MJC
00094  * Created
00095  *
00096  */
00097 
00098 #include <netinet/if_ether.h>
00099 #include <net/ether.h>
00100 #include <net/if_var.h>
00101 #include <dev/nicrtl.h>
00102 
00103 
00104 NICINFO dcb_eth0cs;
00105 
00106 extern int CSNicOutput(NUTDEVICE * dev, NETBUF * nb);
00107 extern int CSNicInit(NUTDEVICE * dev);
00108 
00109 /*
00110  * \brief Network interface information structure.
00111  *
00112  * Used to call.
00113  */
00114 IFNET ifn_eth0cs = {
00115     IFT_ETHER,                  
00116     0,                          
00117     {0, 0, 0, 0, 0, 0},         
00118     0,                          
00119     0,                          
00120     0,                          
00121     567,                        
00122     0,                          
00123     0,                          
00124     0,                          
00125     NutEtherInput,              
00126     CSNicOutput,                
00127     NutEtherOutput              
00128 };
00129 
00130 /*
00131  * \brief Device information structure.
00132  *
00133  * Applications must pass this structure to NutRegisterDevice() 
00134  * to bind this Ethernet device driver to the Nut/OS kernel.
00135  * Having done that, the application may call NutNetIfConfig()
00136  * with the name \em eth0 of this driver to initialize the network
00137  * interface.
00138  * 
00139  */
00140 NUTDEVICE devEth0cs = {
00141     0,                          
00142     {'e', 't', 'h', '0', 'c', 's', 0, 0, 0}
00143     ,                           
00144     IFTYP_NET,                  
00145     0,                          
00146     0,                          
00147     &ifn_eth0cs,                
00148     &dcb_eth0cs,                
00149     CSNicInit,                  
00150     0,                          
00151     0,                          
00152     0,                          
00153     0,                          
00154     0,                          
00155     0,                          
00156     0                           
00157 };
00158