linux-stable/tools
Davide Caratti 7041101ff6 net/sched: sch_fq: fix integer overflow of "credit"
if sch_fq is configured with "initial quantum" having values greater than
INT_MAX, the first assignment of "credit" does signed integer overflow to
a very negative value.
In this situation, the syzkaller script provided by Cristoph triggers the
CPU soft-lockup warning even with few sockets. It's not an infinite loop,
but "credit" wasn't probably meant to be minus 2Gb for each new flow.
Capping "initial quantum" to INT_MAX proved to fix the issue.

v2: validation of "initial quantum" is done in fq_policy, instead of open
    coding in fq_change() _ suggested by Jakub Kicinski

Reported-by: Christoph Paasch <cpaasch@apple.com>
Link: https://github.com/multipath-tcp/mptcp_net-next/issues/377
Fixes: afe4fd0624 ("pkt_sched: fq: Fair Queue packet scheduler")
Reviewed-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Davide Caratti <dcaratti@redhat.com>
Link: https://lore.kernel.org/r/7b3a3c7e36d03068707a021760a194a8eb5ad41a.1682002300.git.dcaratti@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2023-04-21 20:24:29 -07:00
..
accounting
arch tools/loongarch: Use __SIZEOF_LONG__ to define __BITS_PER_LONG 2023-04-19 12:07:34 +08:00
bootconfig bootconfig: Fix testcase to increase max node 2023-03-22 01:00:28 +09:00
bpf bpftool: Use bpf_{btf,link,map,prog}_get_info_by_fd() 2023-02-16 15:32:45 -08:00
build tools build: Add test echo-cmd 2023-02-03 13:54:22 -03:00
certs
cgroup
counter
debugging
edid
firewire
firmware
gpio
hv
iio
include Including fixes from netfilter, wifi and ipsec. 2023-03-17 13:31:16 -07:00
io_uring
kvm/kvm_stat
laptop
leds
lib libbpf: Revert poisoning of strlcpy 2023-03-10 10:19:25 -08:00
memory-model
mm tools/mm/page_owner_sort.c: fix TGID output when cull=tg is used 2023-04-16 10:41:25 -07:00
net/ynl tools: ynl: Fix genlmsg header encoding formats 2023-03-22 20:40:04 -07:00
objtool Changes in this cycle were: 2023-03-02 09:45:34 -08:00
pci
pcmcia
perf perf tools fixes for v6.3: 2023-03-10 08:18:46 -08:00
power Power management fixes for 6.3-rc3 2023-03-17 11:02:26 -07:00
rcu
scripts tools: Add LoongArch build infrastructure 2023-02-25 22:12:18 +08:00
spi
testing net/sched: sch_fq: fix integer overflow of "credit" 2023-04-21 20:24:29 -07:00
thermal
time
tracing tracing updates for 6.3: 2023-02-23 10:20:49 -08:00
usb
verification tools/rv: Remove unneeded semicolon 2023-01-31 19:21:12 -05:00
virtio tools/virtio: fix typo in README instructions 2023-04-04 11:01:58 -04:00
wmi
Makefile tools/Makefile: do missed s/vm/mm/ 2023-04-18 14:22:12 -07:00