diff --git a/src/include/lwip/netif.h b/src/include/lwip/netif.h index bde006a7..81dd338b 100644 --- a/src/include/lwip/netif.h +++ b/src/include/lwip/netif.h @@ -171,7 +171,7 @@ struct netif { #define NETIF_INIT_SNMP(netif, type, speed) \ /* use "snmp_ifType" enum from snmp.h for "type", snmp_ifType_ethernet_csmacd by example */ \ netif->link_type = type; \ - /* your link speed here */ \ + /* your link speed here (units: bits per second) */ \ netif->link_speed = speed; \ netif->ts = 0; \ netif->ifinoctets = 0; \ diff --git a/src/netif/ethernetif.c b/src/netif/ethernetif.c index b69bc4f6..26d2f818 100644 --- a/src/netif/ethernetif.c +++ b/src/netif/ethernetif.c @@ -288,7 +288,11 @@ ethernetif_init(struct netif *netif) netif->hostname = "lwip"; #endif /* LWIP_NETIF_HOSTNAME */ - /* initialize the snmp variables and counters inside the struct netif */ + /* + * Initialize the snmp variables and counters inside the struct netif. + * The last argument should be replaced with your link speed, in units + * of bits per second. + */ NETIF_INIT_SNMP(netif, snmp_ifType_ethernet_csmacd, ???); netif->state = ethernetif;