]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blobdiff - net/mac80211/mesh_pathtbl.c
iwlwifi: make iwl_fill_probe_req static
[mirror_ubuntu-artful-kernel.git] / net / mac80211 / mesh_pathtbl.c
index edf167e3b8f391d65784bc56f3a3f43fc07b9169..157642f780b91296873ae3dfa73423d2244e7c49 100644 (file)
@@ -336,7 +336,7 @@ static void mesh_path_move_to_queue(struct mesh_path *gate_mpath,
 }
 
 
-static struct mesh_path *path_lookup(struct mesh_table *tbl, u8 *dst,
+static struct mesh_path *mpath_lookup(struct mesh_table *tbl, u8 *dst,
                                          struct ieee80211_sub_if_data *sdata)
 {
        struct mesh_path *mpath;
@@ -348,7 +348,7 @@ static struct mesh_path *path_lookup(struct mesh_table *tbl, u8 *dst,
        hlist_for_each_entry_rcu(node, n, bucket, list) {
                mpath = node->mpath;
                if (mpath->sdata == sdata &&
-                               memcmp(dst, mpath->dst, ETH_ALEN) == 0) {
+                               compare_ether_addr(dst, mpath->dst) == 0) {
                        if (MPATH_EXPIRED(mpath)) {
                                spin_lock_bh(&mpath->state_lock);
                                mpath->flags &= ~MESH_PATH_ACTIVE;
@@ -371,12 +371,12 @@ static struct mesh_path *path_lookup(struct mesh_table *tbl, u8 *dst,
  */
 struct mesh_path *mesh_path_lookup(u8 *dst, struct ieee80211_sub_if_data *sdata)
 {
-       return path_lookup(rcu_dereference(mesh_paths), dst, sdata);
+       return mpath_lookup(rcu_dereference(mesh_paths), dst, sdata);
 }
 
 struct mesh_path *mpp_path_lookup(u8 *dst, struct ieee80211_sub_if_data *sdata)
 {
-       return path_lookup(rcu_dereference(mpp_paths), dst, sdata);
+       return mpath_lookup(rcu_dereference(mpp_paths), dst, sdata);
 }
 
 
@@ -523,7 +523,7 @@ int mesh_path_add(u8 *dst, struct ieee80211_sub_if_data *sdata)
        int err = 0;
        u32 hash_idx;
 
-       if (memcmp(dst, sdata->vif.addr, ETH_ALEN) == 0)
+       if (compare_ether_addr(dst, sdata->vif.addr) == 0)
                /* never add ourselves as neighbours */
                return -ENOTSUPP;
 
@@ -564,7 +564,8 @@ int mesh_path_add(u8 *dst, struct ieee80211_sub_if_data *sdata)
        err = -EEXIST;
        hlist_for_each_entry(node, n, bucket, list) {
                mpath = node->mpath;
-               if (mpath->sdata == sdata && memcmp(dst, mpath->dst, ETH_ALEN) == 0)
+               if (mpath->sdata == sdata &&
+                   compare_ether_addr(dst, mpath->dst) == 0)
                        goto err_exists;
        }
 
@@ -655,7 +656,7 @@ int mpp_path_add(u8 *dst, u8 *mpp, struct ieee80211_sub_if_data *sdata)
        int err = 0;
        u32 hash_idx;
 
-       if (memcmp(dst, sdata->vif.addr, ETH_ALEN) == 0)
+       if (compare_ether_addr(dst, sdata->vif.addr) == 0)
                /* never add ourselves as neighbours */
                return -ENOTSUPP;
 
@@ -692,7 +693,8 @@ int mpp_path_add(u8 *dst, u8 *mpp, struct ieee80211_sub_if_data *sdata)
        err = -EEXIST;
        hlist_for_each_entry(node, n, bucket, list) {
                mpath = node->mpath;
-               if (mpath->sdata == sdata && memcmp(dst, mpath->dst, ETH_ALEN) == 0)
+               if (mpath->sdata == sdata &&
+                   compare_ether_addr(dst, mpath->dst) == 0)
                        goto err_exists;
        }
 
@@ -886,7 +888,7 @@ int mesh_path_del(u8 *addr, struct ieee80211_sub_if_data *sdata)
        hlist_for_each_entry(node, n, bucket, list) {
                mpath = node->mpath;
                if (mpath->sdata == sdata &&
-                   memcmp(addr, mpath->dst, ETH_ALEN) == 0) {
+                   compare_ether_addr(addr, mpath->dst) == 0) {
                        __mesh_path_del(tbl, node);
                        goto enddel;
                }