Remove CONFIG_NET_MULTILINK. This increases code size by a little, but greatly reduces the complexity of the network code.

This commit is contained in:
Gregory Nutt
2017-08-08 15:26:09 -06:00
parent bd7c84b23e
commit aeb59383cf
33 changed files with 171 additions and 554 deletions
+1 -30
View File
@@ -47,31 +47,6 @@
#include <nuttx/net/ip.h>
/****************************************************************************
* Public Data
****************************************************************************/
/* If there is only one supported link layer, then the size of the link
* layer address is a constant.
*
* NOTE: Literal constants are used here to avoid bringing in all of the
* header files where they are correctly defined.
*/
#ifndef CONFIG_NET_MULTILINK
# if defined(CONFIG_NET_ETHERNET)
# define NETDEV_LLADDRSIZE 6 /* IFHWADDRLEN */
# elif defined(CONFIG_NET_6LOWPAN)
# ifdef CONFIG_NET_6LOWPAN_EXTENDEDADDR
# define NETDEV_LLADDRSIZE 10 /* NET_6LOWPAN_EADDRSIZE */
# else
# define NETDEV_LLADDRSIZE 2 /* NET_6LOWPAN_SADDRSIZE */
# endif
# else
# define NETDEV_LLADDRSIZE 0 /* No link layer address */
# endif
#endif
/****************************************************************************
* Public Data
****************************************************************************/
@@ -458,11 +433,7 @@ int netdev_type_lladdrsize(uint8_t lltype);
*
****************************************************************************/
#ifdef CONFIG_NET_MULTILINK
# define netdev_dev_lladdrsize(dev) netdev_type_lladdrsize((dev)->d_lltype)
#else
# define netdev_dev_lladdrsize(dev) NETDEV_LLADDRSIZE
#endif
#define netdev_dev_lladdrsize(dev) netdev_type_lladdrsize((dev)->d_lltype)
#undef EXTERN
#ifdef __cplusplus