summaryrefslogtreecommitdiff
path: root/nuttx/net/arp/arp_send.c
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-11-15 08:22:51 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-11-15 08:22:51 -0600
commitb68b625556543fd9a9c9ba40ed5ca5c4b725f7ed (patch)
treeae5f590da1302541d30c3a26f4a9ffc7d599b338 /nuttx/net/arp/arp_send.c
parentc43a244ee4d243ab3429a39ed90408eeb02a864c (diff)
downloadpx4-nuttx-b68b625556543fd9a9c9ba40ed5ca5c4b725f7ed.tar.gz
px4-nuttx-b68b625556543fd9a9c9ba40ed5ca5c4b725f7ed.tar.bz2
px4-nuttx-b68b625556543fd9a9c9ba40ed5ca5c4b725f7ed.zip
Netwoek: Ada a parameter to netdev_register() to indicate the link protocol supported by the driver. Use this value to replace some logic commited yesterday
Diffstat (limited to 'nuttx/net/arp/arp_send.c')
-rw-r--r--nuttx/net/arp/arp_send.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/nuttx/net/arp/arp_send.c b/nuttx/net/arp/arp_send.c
index 2a7694d5d..d03c6005e 100644
--- a/nuttx/net/arp/arp_send.c
+++ b/nuttx/net/arp/arp_send.c
@@ -229,17 +229,15 @@ int arp_send(in_addr_t ipaddr)
goto errout;
}
-#ifdef CONFIG_NET_SLIP
- /* If this device does not require ARP bail out. ARP is only built of
- * CONFIG_NET_ETHERNET is enabled which always requires ARP support. The
- * following can happening only there multiple network interfaces enabled
- * (CONFIG_NET_MULTINIC) and one of the interfaces is not Ethernet. At
- * present, this is possible only if one of the interfaces is SLIP.
- *
- * REVISIT: This will need to be extended if PPP is ever incorporated.
+#ifdef CONFIG_NET_MULTILINK
+ /* ARP support is only built if the Ethernet data link is supported.
+ * However, if we are supporting multiple network devices and using
+ * different link level protocols then we can get here for other
+ * link protocals as well. Continue and send the ARP request only
+ * if this device uses the Ethernet data link protocol.
*/
- if (dev->d_flags & IFF_NOARP)
+ if (dev->d_lltype != NET_LL_ETHERNET)
{
return OK;
}