/[lwip]/lwip/src/include/lwip/netif.h
ViewVC logotype

Diff of /lwip/src/include/lwip/netif.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.8.2.3 by likewise, Mon Feb 10 22:42:59 2003 UTC revision 1.8.2.4 by likewise, Mon Feb 10 23:56:30 2003 UTC
# Line 45  Line 45 
45    
46  /** must be the maximum of all used hardware address lengths  /** must be the maximum of all used hardware address lengths
47      across all types of interfaces in use */      across all types of interfaces in use */
48  #define NETIF_HWADDR_LEN 6  #define NETIF_MAX_HWADDR_LEN 6
49    
50  /** whether the network interface is 'up'. this is  /** whether the network interface is 'up'. this is
51   * a software flag used to control whether this network   * a software flag used to control whether this network
# Line 64  struct netif { Line 64  struct netif {
64    struct netif *next;    struct netif *next;
65    /** The following fields should be filled in by the    /** The following fields should be filled in by the
66        initialization function for the device driver. */        initialization function for the device driver. */
   char name[2];  
   /** number of this interface */  
   u8_t num;  
   /** NETIF_FLAG_* */  
   u8_t flags;  
   /** maximum transfer unit (in bytes) */  
   u16_t mtu;  
67        
68      /** IP address configuration in network byte order */
69    struct ip_addr ip_addr;    struct ip_addr ip_addr;
   /** netmask in network byte order */  
70    struct ip_addr netmask;    struct ip_addr netmask;
71    struct ip_addr gw;    struct ip_addr gw;
72    
73    /** This function is called by the network device driver    /** This function is called by the network device driver
74        to pass a packet up the TCP/IP stack. */        to pass a packet up the TCP/IP stack. */
75    err_t (* input)(struct pbuf *p, struct netif *inp);    err_t (* input)(struct pbuf *p, struct netif *inp);
   
76    /** This function is called by the IP module when it wants    /** This function is called by the IP module when it wants
77        to send a packet on the interface. This function typically        to send a packet on the interface. This function typically
78        first resolves the hardware address, then sends the packet. */        first resolves the hardware address, then sends the packet. */
# Line 98  struct netif { Line 90  struct netif {
90    /** number of bytes used in hwaddr */    /** number of bytes used in hwaddr */
91    unsigned char hwaddr_len;    unsigned char hwaddr_len;
92    /** link level hardware address of this interface */    /** link level hardware address of this interface */
93    unsigned char hwaddr[NETIF_HWADDR_LEN];    unsigned char hwaddr[NETIF_MAX_HWADDR_LEN];
94      /** maximum transfer unit (in bytes) */
95      u16_t mtu;
96      /** descriptive abbreviation */
97      char name[2];
98      /** number of this interface */
99      u8_t num;
100      /** NETIF_FLAG_* */
101      u8_t flags;
102  };  };
103    
104  /** The list of network interfaces. */  /** The list of network interfaces. */

Legend:
Removed from v.1.8.2.3  
changed lines
  Added in v.1.8.2.4

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26