Commit 5cd51c2b authored by Hante Meuleman's avatar Hante Meuleman Committed by John W. Linville

brcmfmac: Find correct MAC descriptor in case of TDLS.

In case of TDLS find the correct MAC descriptor for fw signalling
data. In case of TDLS each destination gets its own entry. This
was not handled correctly for P2P client.
Reviewed-by: default avatarArend Van Spriel <arend@broadcom.com>
Signed-off-by: default avatarHante Meuleman <meuleman@broadcom.com>
Signed-off-by: default avatarArend van Spriel <arend@broadcom.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent afc3bbfc
...@@ -677,26 +677,21 @@ brcmf_fws_find_mac_desc(struct brcmf_fws_info *fws, struct brcmf_if *ifp, ...@@ -677,26 +677,21 @@ brcmf_fws_find_mac_desc(struct brcmf_fws_info *fws, struct brcmf_if *ifp,
{ {
struct brcmf_fws_mac_descriptor *entry = &fws->desc.other; struct brcmf_fws_mac_descriptor *entry = &fws->desc.other;
bool multicast; bool multicast;
enum nl80211_iftype iftype;
multicast = is_multicast_ether_addr(da); multicast = is_multicast_ether_addr(da);
iftype = brcmf_cfg80211_get_iftype(ifp);
/* Multicast destination and P2P clients get the interface entry. /* Multicast destination, STA and P2P clients get the interface entry.
* STA gets the interface entry if there is no exact match. For * STA/GC gets the Mac Entry for TDLS destinations, TDLS destinations
* example, TDLS destinations have their own entry. * have their own entry.
*/ */
entry = NULL; if (multicast && ifp->fws_desc) {
if ((multicast || iftype == NL80211_IFTYPE_STATION ||
iftype == NL80211_IFTYPE_P2P_CLIENT) && ifp->fws_desc)
entry = ifp->fws_desc; entry = ifp->fws_desc;
if (entry != NULL && iftype != NL80211_IFTYPE_STATION)
goto done; goto done;
}
entry = brcmf_fws_mac_descriptor_lookup(fws, da); entry = brcmf_fws_mac_descriptor_lookup(fws, da);
if (IS_ERR(entry)) if (IS_ERR(entry))
entry = &fws->desc.other; entry = ifp->fws_desc;
done: done:
return entry; return entry;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment