mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 16:50:55 +08:00
et/icmpv6: Remove the coupling between ICMPv6 and Ethernet by moving all Ethernet stuff to neighbor_ethernet_out.c and make the mac address as first field.
This commit is contained in:
@@ -128,8 +128,8 @@
|
||||
* layer address taking into account a header of the two-bytes.
|
||||
*/
|
||||
|
||||
#define ICMPv6_OPT_SIZE(a) (((a) + 2 + 7) & ~7)
|
||||
#define ICMPv6_OPT_OCTECTS(a) (((a) + 2 + 7) >> 3)
|
||||
#define ICMPv6_OPT_SIZE(a) ((a) > 0 ? ((a) + 2 + 7) & ~7 : 0)
|
||||
#define ICMPv6_OPT_OCTECTS(a) ((a) > 0 ? ((a) + 2 + 7) >> 3 : 0)
|
||||
|
||||
/****************************************************************************
|
||||
* Public Type Definitions
|
||||
|
||||
@@ -212,8 +212,8 @@ struct netdev_maxaddr_s
|
||||
|
||||
struct netdev_varaddr_s
|
||||
{
|
||||
uint8_t nv_addrlen;
|
||||
uint8_t nv_addr[RADIO_MAX_ADDRLEN];
|
||||
uint8_t nv_addrlen;
|
||||
};
|
||||
#endif
|
||||
|
||||
@@ -255,9 +255,6 @@ struct net_driver_s
|
||||
|
||||
uint16_t d_pktsize; /* Maximum packet size */
|
||||
|
||||
#if defined(CONFIG_NET_ETHERNET) || defined(CONFIG_NET_6LOWPAN) || \
|
||||
defined(CONFIG_NET_BLUETOOTH) || defined(CONFIG_NET_IEEE802154)
|
||||
|
||||
/* Link layer address */
|
||||
|
||||
union
|
||||
@@ -275,7 +272,6 @@ struct net_driver_s
|
||||
struct netdev_varaddr_s radio;
|
||||
#endif
|
||||
} d_mac;
|
||||
#endif /* CONFIG_NET_ETHERNET || CONFIG_NET_6LOWPAN ... || CONFIG_NET_IEEE802154 */
|
||||
|
||||
/* Network identity */
|
||||
|
||||
|
||||
@@ -103,8 +103,8 @@
|
||||
|
||||
struct pktradio_addr_s
|
||||
{
|
||||
uint8_t pa_addrlen; /* Length of the following address */
|
||||
uint8_t pa_addr[RADIO_MAX_ADDRLEN];
|
||||
uint8_t pa_addrlen; /* Length of the following address */
|
||||
};
|
||||
|
||||
/* Different packet radios may have different properties. If there are
|
||||
|
||||
Reference in New Issue
Block a user