We currently never open our receive window to more than 32 packets. If
we received a DATA packet for an unrecognized call with a seq of 33 or
more, the packet is almost certainly from a previously-running call
that we were restarted during.
As described in commit
7b204946 (rx: Avoid lastReceiveTime update for
invalid ACKs) and commit "rx: Avoid new server calls for non-DATA
packets", clients can get confused when we respond to calls in these
situations, so drop the packets instead.
Change-Id: I5b3a699bf245375e92ac97a24ad3638cbb3b8f3c
Reviewed-on: https://gerrit.openafs.org/13876
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
return NULL;
}
+ if (np->header.seq > rx_maxReceiveWindow) {
+ /*
+ * This is a DATA packet for further along in the call than is
+ * possible for a new call. This is probably from an existing call
+ * that was in the middle of running when we were restarted; ignore
+ * it to avoid confusing clients. (See above comment about non-DATA
+ * packets.)
+ */
+ MUTEX_EXIT(&conn->conn_call_lock);
+ if (rx_stats_active)
+ rx_atomic_inc(&rx_stats.spuriousPacketsRead);
+ return NULL;
+ }
+
if (rxi_AbortIfServerBusy(socket, conn, np)) {
MUTEX_EXIT(&conn->conn_call_lock);
return NULL;