Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 21 Sep 2013 22:10:03 +0000 (UTC)
From:      Rick Macklem <rmacklem@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org
Subject:   svn commit: r255770 - stable/9/sys/rpc
Message-ID:  <201309212210.r8LMA3fD004188@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rmacklem
Date: Sat Sep 21 22:10:02 2013
New Revision: 255770
URL: http://svnweb.freebsd.org/changeset/base/255770

Log:
  MFC: r255284
  It was reported via email that the cu_sent field used by the
  krpc client side UDP was observed as way out of range and
  caused the rpc.lockd daemon to hang trying to do an RPC.
  Inspection of the code found two places where the RPC request
  is re-queued, but the value of cu_sent was not incremented.
  Since cu_sent is always decremented when the RPC request is
  dequeued, I think this could have caused cu_sent to go out of
  range. This patch adds lines to increment cu_sent for these
  two cases.

Modified:
  stable/9/sys/rpc/clnt_dg.c
Directory Properties:
  stable/9/sys/   (props changed)

Modified: stable/9/sys/rpc/clnt_dg.c
==============================================================================
--- stable/9/sys/rpc/clnt_dg.c	Sat Sep 21 22:07:24 2013	(r255769)
+++ stable/9/sys/rpc/clnt_dg.c	Sat Sep 21 22:10:02 2013	(r255770)
@@ -682,6 +682,7 @@ get_reply:
 			next_sendtime += retransmit_time;
 			goto send_again;
 		}
+		cu->cu_sent += CWNDSCALE;
 		TAILQ_INSERT_TAIL(&cs->cs_pending, cr, cr_link);
 	}
 
@@ -733,6 +734,7 @@ got_reply:
 					 */
 					XDR_DESTROY(&xdrs);
 					mtx_lock(&cs->cs_lock);
+					cu->cu_sent += CWNDSCALE;
 					TAILQ_INSERT_TAIL(&cs->cs_pending,
 					    cr, cr_link);
 					cr->cr_mrep = NULL;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201309212210.r8LMA3fD004188>