batman-adv: detect clients connected through a 802.11 device
Clients connected through a 802.11 device are now marked with the TT_CLIENT_WIFI flag. This flag is also advertised with the tt announcement. Signed-off-by: Antonio Quartulli <ordex@autistici.org> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
This commit is contained in:

committed by
Marek Lindner

parent
015758d002
commit
bc2790808a
@@ -536,7 +536,7 @@ static int interface_set_mac_addr(struct net_device *dev, void *p)
|
||||
if (atomic_read(&bat_priv->mesh_state) == MESH_ACTIVE) {
|
||||
tt_local_remove(bat_priv, dev->dev_addr,
|
||||
"mac address changed", false);
|
||||
tt_local_add(dev, addr->sa_data);
|
||||
tt_local_add(dev, addr->sa_data, NULL_IFINDEX);
|
||||
}
|
||||
|
||||
memcpy(dev->dev_addr, addr->sa_data, ETH_ALEN);
|
||||
@@ -595,7 +595,7 @@ static int interface_tx(struct sk_buff *skb, struct net_device *soft_iface)
|
||||
goto dropped;
|
||||
|
||||
/* Register the client MAC in the transtable */
|
||||
tt_local_add(soft_iface, ethhdr->h_source);
|
||||
tt_local_add(soft_iface, ethhdr->h_source, skb->skb_iif);
|
||||
|
||||
orig_node = transtable_search(bat_priv, ethhdr->h_dest);
|
||||
if (is_multicast_ether_addr(ethhdr->h_dest) ||
|
||||
|
Reference in New Issue
Block a user