]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
mac80211: Improve dequeing from mpath frame queue.
authorJavier Cardona <javier@cozybit.com>
Mon, 10 Aug 2009 19:15:46 +0000 (12:15 -0700)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 14 Aug 2009 13:13:58 +0000 (09:13 -0400)
Also, fix typo in comment.

Signed-off-by: Javier Cardona <javier@cozybit.com>
Tested-by: Andrey Yurovsky <andrey@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
net/mac80211/mesh.h
net/mac80211/mesh_hwmp.c

index ce538814b9bdfc1ee360777eba6758b1b2979408..6aaf1ecbcb63807247de44893eb03247f73d2dc1 100644 (file)
@@ -61,7 +61,7 @@ enum mesh_path_flags {
  *     retry
  * @discovery_retries: number of discovery retries
  * @flags: mesh path flags, as specified on &enum mesh_path_flags
- * @state_lock: mesh pat state lock
+ * @state_lock: mesh path state lock
  *
  *
  * The combination of dst and sdata is unique in the mesh path table. Since the
index e1a763ea1e39c3670ee04b4d252d78d1a67d45fa..b54c21cf5f73cd0a05e132ed0153ed7c28fc86a5 100644 (file)
@@ -810,10 +810,8 @@ int mesh_nexthop_lookup(struct sk_buff *skb,
                }
 
                if (skb_queue_len(&mpath->frame_queue) >=
-                               MESH_FRAME_QUEUE_LEN) {
-                       skb_to_free = mpath->frame_queue.next;
-                       skb_unlink(skb_to_free, &mpath->frame_queue);
-               }
+                               MESH_FRAME_QUEUE_LEN)
+                       skb_to_free = skb_dequeue(&mpath->frame_queue);
 
                info->flags |= IEEE80211_TX_INTFL_NEED_TXPROCESSING;
                skb_queue_tail(&mpath->frame_queue, skb);