OSDN Git Service

net_sched: sch_fq: properly set sk->sk_pacing_status
authorEric Dumazet <edumazet@google.com>
Mon, 23 Dec 2019 19:13:24 +0000 (11:13 -0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 26 Dec 2019 23:35:09 +0000 (15:35 -0800)
commitbb3d0b8bf5be61ab1d6f472c43cbf34de17e796b
tree18c1af1d9239b2145670c8e0d55834c45913d29d
parent4e55a11aa30fd9a6ee1e7f536ee562e1b0b22512
net_sched: sch_fq: properly set sk->sk_pacing_status

If fq_classify() recycles a struct fq_flow because
a socket structure has been reallocated, we do not
set sk->sk_pacing_status immediately, but later if the
flow becomes detached.

This means that any flow requiring pacing (BBR, or SO_MAX_PACING_RATE)
might fallback to TCP internal pacing, which requires a per-socket
high resolution timer, and therefore more cpu cycles.

Fixes: 218af599fa63 ("tcp: internal implementation for pacing")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Soheil Hassas Yeganeh <soheil@google.com>
Cc: Neal Cardwell <ncardwell@google.com>
Acked-by: Soheil Hassas Yeganeh <soheil@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/sch_fq.c