The following commit has been merged in the merge/master branch: commit 2a938c750a3ffe57baa22ce37e7a20617899473d Merge: 41e304b2983b08b11952f64b36280f0bb313edae 6846ad869ff55346cb572e90fb5fb9440c60061f Author: Marek Lindner mareklindner@neomailbox.ch Date: Sun Sep 6 16:27:38 2015 +0800
Merge branch 'next'
diff --combined net/batman-adv/routing.c index a43f02e,3207667..e4f2646 --- a/net/batman-adv/routing.c +++ b/net/batman-adv/routing.c @@@ -497,9 -497,9 +497,9 @@@ batadv_find_router(struct batadv_priv * /* alternative candidate should be good enough to be * considered */ - if (!bao->bat_neigh_is_equiv_or_better(cand_router, - cand->if_outgoing, - router, recv_if)) + if (!bao->bat_neigh_is_similar_or_better(cand_router, + cand->if_outgoing, + router, recv_if)) goto next;
/* don't use the same router twice */ @@@ -836,6 -836,7 +836,7 @@@ int batadv_recv_unicast_packet(struct s u8 *orig_addr; struct batadv_orig_node *orig_node = NULL; int check, hdr_size = sizeof(*unicast_packet); + enum batadv_subtype subtype; bool is4addr;
unicast_packet = (struct batadv_unicast_packet *)skb->data; @@@ -863,10 -864,20 +864,20 @@@ /* packet for me */ if (batadv_is_my_mac(bat_priv, unicast_packet->dest)) { if (is4addr) { - batadv_dat_inc_counter(bat_priv, - unicast_4addr_packet->subtype); - orig_addr = unicast_4addr_packet->src; - orig_node = batadv_orig_hash_find(bat_priv, orig_addr); + subtype = unicast_4addr_packet->subtype; + batadv_dat_inc_counter(bat_priv, subtype); + + /* Only payload data should be considered for speedy + * join. For example, DAT also uses unicast 4addr + * types, but those packets should not be considered + * for speedy join, since the clients do not actually + * reside at the sending originator. + */ + if (subtype == BATADV_P_DATA) { + orig_addr = unicast_4addr_packet->src; + orig_node = batadv_orig_hash_find(bat_priv, + orig_addr); + } }
if (batadv_dat_snoop_incoming_arp_request(bat_priv, skb,