diff options
| author | Santosh Shilimkar <[email protected]> | 2018-06-14 18:52:34 +0000 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2018-06-15 02:01:49 +0000 |
| commit | f1693c63ab133d16994cc50f773982b5905af264 (patch) | |
| tree | 42a65ff20c3536040cd60c52a1e40b199e34db6e /net/rds/recv.c | |
| parent | Merge branch 'l2tp-fixes' (diff) | |
| download | kernel-f1693c63ab133d16994cc50f773982b5905af264.tar.gz kernel-f1693c63ab133d16994cc50f773982b5905af264.zip | |
rds: avoid unenecessary cong_update in loop transport
Loop transport which is self loopback, remote port congestion
update isn't relevant. Infact the xmit path already ignores it.
Receive path needs to do the same.
Reported-by: [email protected]
Reviewed-by: Sowmini Varadhan <[email protected]>
Signed-off-by: Santosh Shilimkar <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/rds/recv.c')
| -rw-r--r-- | net/rds/recv.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/net/rds/recv.c b/net/rds/recv.c index dc67458b52f0..192ac6f78ded 100644 --- a/net/rds/recv.c +++ b/net/rds/recv.c @@ -103,6 +103,11 @@ static void rds_recv_rcvbuf_delta(struct rds_sock *rs, struct sock *sk, rds_stats_add(s_recv_bytes_added_to_socket, delta); else rds_stats_add(s_recv_bytes_removed_from_socket, -delta); + + /* loop transport doesn't send/recv congestion updates */ + if (rs->rs_transport->t_type == RDS_TRANS_LOOP) + return; + now_congested = rs->rs_rcv_bytes > rds_sk_rcvbuf(rs); rdsdebug("rs %p (%pI4:%u) recv bytes %d buf %d " |
