]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
net: fix multiqueue selection
authorEric Dumazet <edumazet@google.com>
Sat, 7 Sep 2013 19:02:57 +0000 (12:02 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 11 Sep 2013 20:10:00 +0000 (16:10 -0400)
commit 416186fbf8c5b4e4465 ("net: Split core bits of netdev_pick_tx
into __netdev_pick_tx") added a bug that disables caching of queue
index in the socket.

This is the source of packet reorders for TCP flows, and
again this is happening more often when using FQ pacing.

Old code was doing

if (queue_index != old_index)
sk_tx_queue_set(sk, queue_index);

Alexander renamed the variables but forgot to change sk_tx_queue_set()
2nd parameter.

if (queue_index != new_index)
sk_tx_queue_set(sk, queue_index);

This means we store -1 over and over in sk->sk_tx_queue_mapping

Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Alexander Duyck <alexander.h.duyck@intel.com>
Acked-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/flow_dissector.c

index 0ff42f029ace683610115f5251554dc3e87b9210..1929af87b2609650d0b484e7d01dc4a405ba8389 100644 (file)
@@ -352,7 +352,7 @@ u16 __netdev_pick_tx(struct net_device *dev, struct sk_buff *skb)
 
                if (queue_index != new_index && sk &&
                    rcu_access_pointer(sk->sk_dst_cache))
-                       sk_tx_queue_set(sk, queue_index);
+                       sk_tx_queue_set(sk, new_index);
 
                queue_index = new_index;
        }