aboutsummaryrefslogtreecommitdiffstats
path: root/net/batman-adv/distributed-arp-table.c
diff options
context:
space:
mode:
authorAntonio Quartulli <antonio@open-mesh.com>2013-11-05 13:31:08 -0500
committerAntonio Quartulli <antonio@meshcoding.com>2014-01-08 14:49:42 -0500
commit6c413b1c22a2c4ef324f1c6f2c282f1ca10a93b9 (patch)
tree5e7d10d691a64b8ae180d4f718a41120118c6432 /net/batman-adv/distributed-arp-table.c
parent36484f84d567f79fc7cc62c4391c7752a0ede7f2 (diff)
batman-adv: send every DHCP packet as bat-unicast
In different situations it is possible that the DHCP server or client uses broadcast Ethernet frames to send messages to each other. The GW component in batman-adv takes care of using bat-unicast packets to bring broadcast DHCP Discover/Requests to the "best" server. On the way back the DHCP server usually sends unicasts, but upon client request it may decide to use broadcasts as well. This patch improves the GW component so that it now snoops and sends as unicast all the DHCP packets, no matter if they were generated by a DHCP server or client. Signed-off-by: Antonio Quartulli <antonio@open-mesh.com> Signed-off-by: Marek Lindner <mareklindner@neomailbox.ch>
Diffstat (limited to 'net/batman-adv/distributed-arp-table.c')
-rw-r--r--net/batman-adv/distributed-arp-table.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/batman-adv/distributed-arp-table.c b/net/batman-adv/distributed-arp-table.c
index 93e1fb049055..997ae6ac51ff 100644
--- a/net/batman-adv/distributed-arp-table.c
+++ b/net/batman-adv/distributed-arp-table.c
@@ -1037,9 +1037,9 @@ bool batadv_dat_snoop_incoming_arp_request(struct batadv_priv *bat_priv,
1037 if (hdr_size == sizeof(struct batadv_unicast_4addr_packet)) 1037 if (hdr_size == sizeof(struct batadv_unicast_4addr_packet))
1038 err = batadv_send_skb_via_tt_4addr(bat_priv, skb_new, 1038 err = batadv_send_skb_via_tt_4addr(bat_priv, skb_new,
1039 BATADV_P_DAT_CACHE_REPLY, 1039 BATADV_P_DAT_CACHE_REPLY,
1040 vid); 1040 NULL, vid);
1041 else 1041 else
1042 err = batadv_send_skb_via_tt(bat_priv, skb_new, vid); 1042 err = batadv_send_skb_via_tt(bat_priv, skb_new, NULL, vid);
1043 1043
1044 if (err != NET_XMIT_DROP) { 1044 if (err != NET_XMIT_DROP) {
1045 batadv_inc_counter(bat_priv, BATADV_CNT_DAT_CACHED_REPLY_TX); 1045 batadv_inc_counter(bat_priv, BATADV_CNT_DAT_CACHED_REPLY_TX);