sctp: send the next probe immediately once the last one is acked
authorXin Long <lucien.xin@gmail.com>
Thu, 24 Jun 2021 15:48:09 +0000 (11:48 -0400)
committerDavid S. Miller <davem@davemloft.net>
Thu, 24 Jun 2021 19:58:03 +0000 (12:58 -0700)
These is no need to wait for 'interval' period for the next probe
if the last probe is already acked in search state. The 'interval'
period waiting should be only for probe failure timeout and the
current pmtu check when it's in search complete state.

This change will shorten the probe time a lot in search state, and
also fix the document accordingly.

Signed-off-by: Xin Long <lucien.xin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Documentation/networking/ip-sysctl.rst
net/sctp/sm_statefuns.c

index 8bff728..b3fa522 100644 (file)
@@ -2835,10 +2835,14 @@ encap_port - INTEGER
        Default: 0
 
 plpmtud_probe_interval - INTEGER
-        The time interval (in milliseconds) for sending PLPMTUD probe chunks.
-        These chunks are sent at the specified interval with a variable size
-        to probe the mtu of a given path between 2 endpoints. PLPMTUD will
-        be disabled when 0 is set, and other values for it must be >= 5000.
+        The time interval (in milliseconds) for the PLPMTUD probe timer,
+        which is configured to expire after this period to receive an
+        acknowledgment to a probe packet. This is also the time interval
+        between the probes for the current pmtu when the probe search
+        is done.
+
+        PLPMTUD will be disabled when 0 is set, and other values for it
+        must be >= 5000.
 
        Default: 0
 
index d29b579..09a8f23 100644 (file)
@@ -1275,7 +1275,10 @@ enum sctp_disposition sctp_sf_backbeat_8_3(struct net *net,
                        return SCTP_DISPOSITION_DISCARD;
 
                sctp_transport_pl_recv(link);
-               return SCTP_DISPOSITION_CONSUME;
+               if (link->pl.state == SCTP_PL_COMPLETE)
+                       return SCTP_DISPOSITION_CONSUME;
+
+               return sctp_sf_send_probe(net, ep, asoc, type, link, commands);
        }
 
        max_interval = link->hbinterval + link->rto;