From owner-svn-src-projects@FreeBSD.ORG Wed Oct 7 07:04:08 2009 Return-Path: Delivered-To: svn-src-projects@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C366E1065693; Wed, 7 Oct 2009 07:04:08 +0000 (UTC) (envelope-from lstewart@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B2D7B8FC1F; Wed, 7 Oct 2009 07:04:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n97748NV076704; Wed, 7 Oct 2009 07:04:08 GMT (envelope-from lstewart@svn.freebsd.org) Received: (from lstewart@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n977481S076703; Wed, 7 Oct 2009 07:04:08 GMT (envelope-from lstewart@svn.freebsd.org) Message-Id: <200910070704.n977481S076703@svn.freebsd.org> From: Lawrence Stewart Date: Wed, 7 Oct 2009 07:04:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-projects@freebsd.org X-SVN-Group: projects MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r197827 - projects/tcp_ffcaia2008_8.x/sys/kern X-BeenThere: svn-src-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the src " projects" tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Oct 2009 07:04:08 -0000 Author: lstewart Date: Wed Oct 7 07:04:08 2009 New Revision: 197827 URL: http://svn.freebsd.org/changeset/base/197827 Log: Consistently use the local wrapearly variable in alq_doio(). Sponsored by: FreeBSD Foundation Modified: projects/tcp_ffcaia2008_8.x/sys/kern/kern_alq.c Modified: projects/tcp_ffcaia2008_8.x/sys/kern/kern_alq.c ============================================================================== --- projects/tcp_ffcaia2008_8.x/sys/kern/kern_alq.c Wed Oct 7 05:38:44 2009 (r197826) +++ projects/tcp_ffcaia2008_8.x/sys/kern/kern_alq.c Wed Oct 7 07:04:08 2009 (r197827) @@ -300,6 +300,7 @@ alq_doio(struct alq *alq) td = curthread; totlen = 0; iov = 1; + wrapearly = alq->aq_wrapearly; bzero(&aiov, sizeof(aiov)); bzero(&auio, sizeof(auio)); @@ -313,7 +314,7 @@ alq_doio(struct alq *alq) } else if (alq->aq_writehead == 0) { /* Buffer not wrapped (special case to avoid an empty iov). */ totlen = aiov[0].iov_len = alq->aq_buflen - alq->aq_writetail - - alq->aq_wrapearly; + wrapearly; } else { /* * Buffer wrapped, requires 2 aiov entries: @@ -321,14 +322,13 @@ alq_doio(struct alq *alq) * - second is from start of buffer to writehead */ aiov[0].iov_len = alq->aq_buflen - alq->aq_writetail - - alq->aq_wrapearly; + wrapearly; iov++; aiov[1].iov_base = alq->aq_entbuf; aiov[1].iov_len = alq->aq_writehead; totlen = aiov[0].iov_len + aiov[1].iov_len; } - wrapearly = alq->aq_wrapearly; alq->aq_flags |= AQ_FLUSHING; ALQ_UNLOCK(alq);