From owner-svn-src-head@FreeBSD.ORG Thu Apr 16 16:26:36 2009 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3324E10656FA; Thu, 16 Apr 2009 16:26:36 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 224878FC19; Thu, 16 Apr 2009 16:26:36 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n3GGQaJT085700; Thu, 16 Apr 2009 16:26:36 GMT (envelope-from rmacklem@svn.freebsd.org) Received: (from rmacklem@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n3GGQa8N085699; Thu, 16 Apr 2009 16:26:36 GMT (envelope-from rmacklem@svn.freebsd.org) Message-Id: <200904161626.n3GGQa8N085699@svn.freebsd.org> From: Rick Macklem Date: Thu, 16 Apr 2009 16:26:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r191145 - head/sys/rpc X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Apr 2009 16:26:37 -0000 Author: rmacklem Date: Thu Apr 16 16:26:35 2009 New Revision: 191145 URL: http://svn.freebsd.org/changeset/base/191145 Log: Added a field to the SVCXPRT structure that the nfsv4 server can use to identify if the socket is the same one that a cached request came in on. It is set by nfsrvd_addsock() to a unique value generated by incrementing an unsigned 64bit static variable for each assignment and then the value of xp_sockref is tested to see if it is equal to the value that was saved with the cached reply. Submitted by: rmacklem Reviewed by: dfr Approved by: kib (mentor) Modified: head/sys/rpc/svc.h Modified: head/sys/rpc/svc.h ============================================================================== --- head/sys/rpc/svc.h Thu Apr 16 14:43:59 2009 (r191144) +++ head/sys/rpc/svc.h Thu Apr 16 16:26:35 2009 (r191145) @@ -165,6 +165,7 @@ typedef struct __rpc_svcxprt { int xp_type; /* transport type */ int xp_idletimeout; /* idle time before closing */ time_t xp_lastactive; /* time of last RPC */ + u_int64_t xp_sockref; /* set by nfsv4 to identify socket */ #else int xp_fd; u_short xp_port; /* associated port number */