summaryrefslogtreecommitdiff
path: root/nuttx/arch/arm/src/tiva/tm4c_ethernet.c
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2015-01-21 11:36:33 -0600
committerGregory Nutt <gnutt@nuttx.org>2015-01-21 11:36:33 -0600
commit926f204fe26a9798ef119dd3170c81b2d43175b3 (patch)
tree5b13afa47fe9b6cf8e1129d4a088b3e363c27357 /nuttx/arch/arm/src/tiva/tm4c_ethernet.c
parenta4aaf127457d1092916b2c4f87272c3471345ae3 (diff)
downloadpx4-nuttx-926f204fe26a9798ef119dd3170c81b2d43175b3.tar.gz
px4-nuttx-926f204fe26a9798ef119dd3170c81b2d43175b3.tar.bz2
px4-nuttx-926f204fe26a9798ef119dd3170c81b2d43175b3.zip
All Ethernet drivers (again): Missed one place where arp_out() is called and neighber_out() needs to be called
Diffstat (limited to 'nuttx/arch/arm/src/tiva/tm4c_ethernet.c')
-rw-r--r--nuttx/arch/arm/src/tiva/tm4c_ethernet.c23
1 files changed, 22 insertions, 1 deletions
diff --git a/nuttx/arch/arm/src/tiva/tm4c_ethernet.c b/nuttx/arch/arm/src/tiva/tm4c_ethernet.c
index 5910b0953..93d6df9cb 100644
--- a/nuttx/arch/arm/src/tiva/tm4c_ethernet.c
+++ b/nuttx/arch/arm/src/tiva/tm4c_ethernet.c
@@ -1251,9 +1251,30 @@ static int tiva_txpoll(struct net_driver_s *dev)
if (priv->dev.d_len > 0)
{
+ /* Look up the destination MAC address and add it to the Ethernet
+ * header.
+ */
+
+#ifdef CONFIG_NET_IPv4
+#ifdef CONFIG_NET_IPv6
+ if (IFF_IS_IPv4(priv->dev.d_flags))
+#endif
+ {
+ arp_out(&priv->dev);
+ }
+#endif /* CONFIG_NET_IPv4 */
+
+#ifdef CONFIG_NET_IPv6
+#ifdef CONFIG_NET_IPv4
+ else
+#endif
+ {
+ neighbor_out(&priv->dev);
+ }
+#endif /* CONFIG_NET_IPv6 */
+
/* Send the packet */
- arp_out(&priv->dev);
tiva_transmit(priv);
DEBUGASSERT(dev->d_len == 0 && dev->d_buf == NULL);