Eric Dumazet
b88dd52c62
net: sched: fix reordering issues
...
Whenever MQ is not used on a multiqueue device, we experience
serious reordering problems. Bisection found the cited
commit.
The issue can be described this way :
- A single qdisc hierarchy is shared by all transmit queues.
(eg : tc qdisc replace dev eth0 root fq_codel)
- When/if try_bulk_dequeue_skb_slow() dequeues a packet targetting
a different transmit queue than the one used to build a packet train,
we stop building the current list and save the 'bad' skb (P1) in a
special queue. (bad_txq)
- When dequeue_skb() calls qdisc_dequeue_skb_bad_txq() and finds this
skb (P1), it checks if the associated transmit queues is still in frozen
state. If the queue is still blocked (by BQL or NIC tx ring full),
we leave the skb in bad_txq and return NULL.
- dequeue_skb() calls q->dequeue() to get another packet (P2)
The other packet can target the problematic queue (that we found
in frozen state for the bad_txq packet), but another cpu just ran
TX completion and made room in the txq that is now ready to accept
new packets.
- Packet P2 is sent while P1 is still held in bad_txq, P1 might be sent
at next round. In practice P2 is the lead of a big packet train
(P2,P3,P4 ...) filling the BQL budget and delaying P1 by many packets :/
To solve this problem, we have to block the dequeue process as long
as the first packet in bad_txq can not be sent. Reordering issues
disappear and no side effects have been seen.
Fixes: a53851e2c3 ("net: sched: explicit locking in gso_cpu fallback")
Signed-off-by: Eric Dumazet <[email protected] >
Cc: John Fastabend <[email protected] >
Acked-by: John Fastabend <[email protected] >
Signed-off-by: David S. Miller <[email protected] >
2019-09-06 15:12:33 +02:00
..
6lowpan
6lowpan: no need to check return value of debugfs_create functions
2019-07-06 12:50:01 +02:00
9p
9p pull request for inclusion in 5.13
2019-07-12 17:31:19 -07:00
802
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500
2019-06-19 17:09:55 +02:00
8021q
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
2019-06-22 08:59:24 -04:00
appletalk
atm
ax25
ax25: fix inconsistent lock state in ax25_destroy_timer
2019-06-16 14:22:37 -07:00
batman-adv
batman-adv: Only read OGM2 tvlv_len after buffer len check
2019-08-23 18:20:31 +02:00
bluetooth
Revert "Bluetooth: validate BLE connection interval updates"
2019-09-05 09:02:59 +03:00
bpf
bpfilter
Kbuild updates for v5.3
2019-07-12 16:03:16 -07:00
bridge
netfilter: bridge: Drops IPv6 packets if IPv6 module is not loaded
2019-09-02 23:19:27 +02:00
caif
can
can: gw: Fix error path of cgw_module_init
2019-07-24 11:19:03 +02:00
ceph
libceph: don't call crypto_free_sync_skcipher() on a NULL tfm
2019-08-28 12:33:46 +02:00
core
net: sock_map, fix missing ulp check in sock hash case
2019-09-05 11:56:19 +02:00
dcb
dccp
proc/sysctl: add shared variables for range check
2019-07-18 17:08:07 -07:00
decnet
dns_resolver
Revert "Merge tag 'keys-acl-20190703' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs"
2019-07-10 18:43:43 -07:00
dsa
net: dsa: tag_8021q: Future-proof the reserved fields in the custom VID
2019-08-27 20:31:12 -07:00
ethernet
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
2019-06-07 11:00:14 -07:00
hsr
hsr: switch ->dellink() to ->ndo_uninit()
2019-07-11 14:37:45 -07:00
ieee802154
Merge branch 'ieee802154-for-davem-2019-08-24' of git://git.kernel.org/pub/scm/linux/kernel/git/sschmidt/wpan
2019-08-24 13:46:57 -07:00
ife
ipv4
net: Properly update v4 routes with v6 nexthop
2019-09-05 12:35:58 +02:00
ipv6
net: Properly update v4 routes with v6 nexthop
2019-09-05 12:35:58 +02:00
iucv
net/af_iucv: mark expected switch fall-throughs
2019-07-29 10:26:14 -07:00
kcm
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500
2019-06-19 17:09:55 +02:00
key
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
2019-07-08 19:48:57 -07:00
l2tp
compat_ioctl: pppoe: fix PPPOEIOCSFWD handling
2019-07-30 14:42:13 -07:00
l3mdev
ipv6: convert major tx path to use RT6_LOOKUP_F_DST_NOREF
2019-06-23 13:24:17 -07:00
lapb
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
2019-06-17 20:20:36 -07:00
llc
mac80211
mac80211: Correctly set noencrypt for PAE frames
2019-08-29 16:40:00 +02:00
mac802154
mpls
ipv4: mpls: fix mpls_xmit for iptunnel
2019-08-25 14:34:08 -07:00
ncsi
net/ncsi: Fix the payload copying for the request coming from Netlink
2019-08-22 19:27:02 -07:00
netfilter
netfilter: nf_flow_table: set default timeout after successful insertion
2019-09-03 22:55:42 +02:00
netlabel
netlink
net: remove empty netlink_tap_exit_net
2019-06-14 19:50:33 -07:00
netrom
netrom: hold sock when setting skb->destructor
2019-07-24 15:49:05 -07:00
nfc
nfc: fix potential illegal memory access
2019-07-08 12:46:24 -07:00
nsh
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500
2019-06-19 17:09:55 +02:00
openvswitch
openvswitch: Clear the L4 portion of the key for "later" fragments.
2019-08-28 14:53:51 -07:00
packet
net/packet: fix race in tpacket_snd()
2019-08-15 13:59:48 -07:00
phonet
psample
net: sched: act_sample: fix psample group handling on overwrite
2019-08-28 15:53:51 -07:00
qrtr
rds
net/rds: Fix info leak in rds6_inc_info_copy()
2019-08-27 20:56:06 -07:00
rfkill
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500
2019-06-19 17:09:55 +02:00
rose
rxrpc
rxrpc: Fix misplaced traceline
2019-09-05 00:24:58 +02:00
sched
net: sched: fix reordering issues
2019-09-06 15:12:33 +02:00
sctp
sctp: use transport pf_retrans in sctp_do_8_2_transport_strike
2019-09-05 00:29:21 +02:00
smc
net/smc: make sure EPOLLOUT is raised
2019-08-20 12:25:14 -07:00
strparser
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
2019-06-22 08:59:24 -04:00
sunrpc
SUNRPC: Handle connection breakages correctly in call_status()
2019-08-26 15:31:29 -04:00
switchdev
tipc
tipc: add NULL pointer check before calling kfree_rcu
2019-09-05 09:58:49 +02:00
tls
net: tls, fix sk_write_space NULL write when tx disabled
2019-08-15 12:40:15 -07:00
unix
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
2019-06-07 11:00:14 -07:00
vmw_vsock
hv_sock: Fix hang when a connection is closed
2019-08-02 17:26:27 -07:00
wimax
wireless
Revert "cfg80211: fix processing world regdomain when non modular"
2019-08-21 10:43:03 +02:00
x25
xdp
xdp: unpin xdp umem pages in error path
2019-08-20 16:39:48 +02:00
xfrm
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/klassert/ipsec
2019-09-06 15:09:16 +02:00
compat.c
Kconfig
net: ipv4: move tcp_fastopen server side code to SipHash library
2019-06-17 13:56:26 -07:00
Makefile
socket.c
Merge branch 'work.mount0' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
2019-07-19 10:42:02 -07:00
sysctl_net.c