From: Jeffrey Altman Date: Thu, 30 Sep 2010 14:48:58 +0000 (-0400) Subject: Revert "Rx: When call receive is done, send ack all packet" X-Git-Tag: upstream/1.8.0_pre1^2~3602 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=358099b21c5c888c02bf3754702ae623378c507d;p=packages%2Fo%2Fopenafs.git Revert "Rx: When call receive is done, send ack all packet" This reverts commit 3cd3715e608b801b4848399e42cb47464e6e3cc3, which replaces an ack with an ackall; ackall processing does not actually mark all packets acked when it is received, so it is insufficient. Change-Id: I7ee90e1190688570cf3b268229972064480283cc Reviewed-on: http://gerrit.openafs.org/4837 Tested-by: BuildBot Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman --- diff --git a/src/rx/rx.c b/src/rx/rx.c index 5c7a68567..ba9583b81 100644 --- a/src/rx/rx.c +++ b/src/rx/rx.c @@ -4096,23 +4096,8 @@ rxi_ReceiveDataPacket(struct rx_call *call, * Send an ack when requested by the peer, or once every * rxi_SoftAckRate packets until the last packet has been * received. Always send a soft ack for the last packet in - * the server's reply. - * - * If there was more than one packet received for the call - * and we have received all of them, immediately send an - * RX_PACKET_TYPE_ACKALL packet so that the peer can empty - * its packet transmit queue and cancel all resend events. - * - * When there is only one packet in the call there is a - * chance that we can race with Ping ACKs sent as part of - * connection establishment if the udp packets are delivered - * out of order. When the race occurs, a two second delay - * will occur while waiting for a new Ping ACK to be sent. - */ - if (!isFirst && (call->flags & RX_CALL_RECEIVE_DONE)) { - rxevent_Cancel(call->delayedAckEvent, call, RX_CALL_REFCOUNT_DELAY); - rxi_AckAll(NULL, call, 0); - } else if (ackNeeded) { + * the server's reply. */ + if (ackNeeded) { rxevent_Cancel(call->delayedAckEvent, call, RX_CALL_REFCOUNT_DELAY); np = rxi_SendAck(call, np, serial, ackNeeded, istack); } else if (call->nSoftAcks > (u_short) rxi_SoftAckRate) { @@ -4136,6 +4121,8 @@ rxi_ReceiveDataPacket(struct rx_call *call, call->delayedAckEvent = rxevent_PostNow(&when, &now, rxi_SendDelayedAck, call, 0); } + } else if (call->flags & RX_CALL_RECEIVE_DONE) { + rxevent_Cancel(call->delayedAckEvent, call, RX_CALL_REFCOUNT_DELAY); } return np;