mac80211: fix station lookup issues
authorFelix Fietkau <nbd@openwrt.org>
Mon, 30 Apr 2012 07:57:09 +0000 (07:57 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Mon, 30 Apr 2012 07:57:09 +0000 (07:57 +0000)
SVN-Revision: 31539

package/mac80211/patches/300-pending_work.patch

index 668005b7f322d8593e890bf8e0071b9c2c117787..c702cfeb1c23d82c47733ee957c61dd33f0fe180 100644 (file)
                tx->sta = sta_info_get_bss(sdata, hdr->addr1);
        }
        if (!tx->sta)
+--- a/net/wireless/scan.c
++++ b/net/wireless/scan.c
+@@ -378,7 +378,11 @@ static int cmp_bss_core(struct cfg80211_
+                              b->len_information_elements);
+       }
+-      return compare_ether_addr(a->bssid, b->bssid);
++      /*
++       * we can't use compare_ether_addr here since we need a < > operator.
++       * The binary return value of compare_ether_addr isn't enough
++       */
++      return memcmp(a->bssid, b->bssid, sizeof(a->bssid));
+ }
+ static int cmp_bss(struct cfg80211_bss *a,