aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChun-Yeow Yeoh2013-02-18 20:04:50 -0600
committerJohannes Berg2013-02-25 17:09:22 -0600
commit163df6cf292a1024277f500038fc0ed493635673 (patch)
tree0ec07ee68f2e69e1c1601c70460e92db2a1d5665
parent162589f7b162b916ac377753c086e3ba76a9f33d (diff)
downloadam43-linux-kernel-163df6cf292a1024277f500038fc0ed493635673.tar.gz
am43-linux-kernel-163df6cf292a1024277f500038fc0ed493635673.tar.xz
am43-linux-kernel-163df6cf292a1024277f500038fc0ed493635673.zip
mac80211: fix the problem of forwarding from DS to DS in Mesh
Unicast frame with unknown forwarding information always trigger the path discovery assuming destination is always located inside the MBSS. This patch allows the forwarding to look for mesh gate if path discovery inside the MBSS has failed. Reported-by: Cedric Voncken <cedric.voncken@acksys.fr> Signed-off-by: Chun-Yeow Yeoh <yeohchunyeow@gmail.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-rw-r--r--net/mac80211/tx.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index 5800c7a0d07..bb05a0f8603 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -1844,9 +1844,24 @@ netdev_tx_t ieee80211_subif_start_xmit(struct sk_buff *skb,
1844 } 1844 }
1845 1845
1846 if (!is_multicast_ether_addr(skb->data)) { 1846 if (!is_multicast_ether_addr(skb->data)) {
1847 struct sta_info *next_hop;
1848 bool mpp_lookup = true;
1849
1847 mpath = mesh_path_lookup(sdata, skb->data); 1850 mpath = mesh_path_lookup(sdata, skb->data);
1848 if (!mpath) 1851 if (mpath) {
1852 mpp_lookup = false;
1853 next_hop = rcu_dereference(mpath->next_hop);
1854 if (!next_hop ||
1855 !(mpath->flags & (MESH_PATH_ACTIVE |
1856 MESH_PATH_RESOLVING)))
1857 mpp_lookup = true;
1858 }
1859
1860 if (mpp_lookup)
1849 mppath = mpp_path_lookup(sdata, skb->data); 1861 mppath = mpp_path_lookup(sdata, skb->data);
1862
1863 if (mppath && mpath)
1864 mesh_path_del(mpath->sdata, mpath->dst);
1850 } 1865 }
1851 1866
1852 /* 1867 /*