mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2025-01-18 12:52:44 +01:00
net/l2util: add nimble opt for addr resolution
This commit is contained in:
parent
8893b73682
commit
504acc5097
@ -32,7 +32,7 @@ netopt_t gnrc_netif_get_l2addr_opt(const gnrc_netif_t *netif)
|
|||||||
|
|
||||||
switch (netif->device_type) {
|
switch (netif->device_type) {
|
||||||
#if defined(MODULE_NETDEV_IEEE802154) || defined(MODULE_XBEE) || \
|
#if defined(MODULE_NETDEV_IEEE802154) || defined(MODULE_XBEE) || \
|
||||||
defined(MODULE_NORDIC_SOFTDEVICE_BLE)
|
defined(MODULE_NORDIC_SOFTDEVICE_BLE) || defined(MODULE_NIMBLE_NETIF)
|
||||||
case NETDEV_TYPE_IEEE802154:
|
case NETDEV_TYPE_IEEE802154:
|
||||||
case NETDEV_TYPE_BLE: {
|
case NETDEV_TYPE_BLE: {
|
||||||
netdev_t *dev = netif->dev;
|
netdev_t *dev = netif->dev;
|
||||||
@ -128,7 +128,7 @@ void gnrc_netif_ipv6_init_mtu(gnrc_netif_t *netif)
|
|||||||
#endif
|
#endif
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
#ifdef MODULE_NORDIC_SOFTDEVICE_BLE
|
#if defined(MODULE_NORDIC_SOFTDEVICE_BLE) || defined(MODULE_NIMBLE_NETIF)
|
||||||
case NETDEV_TYPE_BLE:
|
case NETDEV_TYPE_BLE:
|
||||||
netif->ipv6.mtu = IPV6_MIN_MTU;
|
netif->ipv6.mtu = IPV6_MIN_MTU;
|
||||||
#ifdef MODULE_GNRC_SIXLOWPAN_IPHC
|
#ifdef MODULE_GNRC_SIXLOWPAN_IPHC
|
||||||
|
@ -41,7 +41,7 @@ int l2util_eui64_from_addr(int dev_type, const uint8_t *addr, size_t addr_len,
|
|||||||
{
|
{
|
||||||
switch (dev_type) {
|
switch (dev_type) {
|
||||||
#if defined(MODULE_NETDEV_ETH) || defined(MODULE_ESP_NOW) || \
|
#if defined(MODULE_NETDEV_ETH) || defined(MODULE_ESP_NOW) || \
|
||||||
defined(MODULE_NORDIC_SOFTDEVICE_BLE)
|
defined(MODULE_NORDIC_SOFTDEVICE_BLE) || defined(MODULE_NIMBLE_NETIF)
|
||||||
case NETDEV_TYPE_ETHERNET:
|
case NETDEV_TYPE_ETHERNET:
|
||||||
case NETDEV_TYPE_ESP_NOW:
|
case NETDEV_TYPE_ESP_NOW:
|
||||||
case NETDEV_TYPE_BLE:
|
case NETDEV_TYPE_BLE:
|
||||||
@ -133,14 +133,15 @@ int l2util_ipv6_iid_to_addr(int dev_type, const eui64_t *iid, uint8_t *addr)
|
|||||||
{
|
{
|
||||||
switch (dev_type) {
|
switch (dev_type) {
|
||||||
#if defined(MODULE_NETDEV_ETH) || defined(MODULE_ESP_NOW) || \
|
#if defined(MODULE_NETDEV_ETH) || defined(MODULE_ESP_NOW) || \
|
||||||
defined(MODULE_NORDIC_SOFTDEVICE_BLE)
|
defined(MODULE_NORDIC_SOFTDEVICE_BLE) || defined(MODULE_NIMBLE_NETIF)
|
||||||
case NETDEV_TYPE_ETHERNET:
|
case NETDEV_TYPE_ETHERNET:
|
||||||
case NETDEV_TYPE_ESP_NOW:
|
case NETDEV_TYPE_ESP_NOW:
|
||||||
case NETDEV_TYPE_BLE:
|
case NETDEV_TYPE_BLE:
|
||||||
eui48_from_ipv6_iid((eui48_t *)addr, iid);
|
eui48_from_ipv6_iid((eui48_t *)addr, iid);
|
||||||
return sizeof(eui48_t);
|
return sizeof(eui48_t);
|
||||||
#endif /* defined(MODULE_NETDEV_ETH) || defined(MODULE_ESP_NOW) || \
|
#endif /* defined(MODULE_NETDEV_ETH) || defined(MODULE_ESP_NOW) || \
|
||||||
* defined(MODULE_NORDIC_SOFTDEVICE_BLE) */
|
* defined(MODULE_NORDIC_SOFTDEVICE_BLE) || \
|
||||||
|
* defined(MODULE_NIMBLE_NETIF) */
|
||||||
#if defined(MODULE_NETDEV_IEEE802154) || defined(MODULE_XBEE)
|
#if defined(MODULE_NETDEV_IEEE802154) || defined(MODULE_XBEE)
|
||||||
case NETDEV_TYPE_IEEE802154:
|
case NETDEV_TYPE_IEEE802154:
|
||||||
/* assume address was based on EUI-64
|
/* assume address was based on EUI-64
|
||||||
@ -183,7 +184,7 @@ int l2util_ndp_addr_len_from_l2ao(int dev_type,
|
|||||||
return sizeof(uint8_t);
|
return sizeof(uint8_t);
|
||||||
#endif /* MODULE_CC110X */
|
#endif /* MODULE_CC110X */
|
||||||
#if defined(MODULE_NETDEV_ETH) || defined(MODULE_ESP_NOW) || \
|
#if defined(MODULE_NETDEV_ETH) || defined(MODULE_ESP_NOW) || \
|
||||||
defined(MODULE_NORDIC_SOFTDEVICE_BLE)
|
defined(MODULE_NORDIC_SOFTDEVICE_BLE) || defined(MODULE_NIMBLE_NETIF)
|
||||||
case NETDEV_TYPE_ETHERNET:
|
case NETDEV_TYPE_ETHERNET:
|
||||||
case NETDEV_TYPE_ESP_NOW:
|
case NETDEV_TYPE_ESP_NOW:
|
||||||
case NETDEV_TYPE_BLE:
|
case NETDEV_TYPE_BLE:
|
||||||
|
Loading…
Reference in New Issue
Block a user