From owner-trustedbsd-cvs@FreeBSD.ORG Sat Mar 18 17:06:07 2006 Return-Path: X-Original-To: trustedbsd-cvs@freebsd.org Delivered-To: trustedbsd-cvs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ED9BA16A425 for ; Sat, 18 Mar 2006 17:06:07 +0000 (UTC) (envelope-from owner-perforce@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [209.31.154.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id DA51C43D46 for ; Sat, 18 Mar 2006 17:06:06 +0000 (GMT) (envelope-from owner-perforce@freebsd.org) Received: from mx2.freebsd.org (mx2.freebsd.org [216.136.204.119]) by cyrus.watson.org (Postfix) with ESMTP id BB3A946C7D for ; Sat, 18 Mar 2006 12:05:40 -0500 (EST) Received: from hub.freebsd.org (hub.freebsd.org [216.136.204.18]) by mx2.freebsd.org (Postfix) with ESMTP id 997C655522; Sat, 18 Mar 2006 17:06:03 +0000 (GMT) (envelope-from owner-perforce@freebsd.org) Received: by hub.freebsd.org (Postfix, from userid 32767) id 9191116A422; Sat, 18 Mar 2006 17:06:03 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 70A4916A401 for ; Sat, 18 Mar 2006 17:06:03 +0000 (UTC) (envelope-from rwatson@FreeBSD.org) Received: from cyrus.watson.org (cyrus.watson.org [209.31.154.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id EFA3943D45 for ; Sat, 18 Mar 2006 17:06:02 +0000 (GMT) (envelope-from rwatson@FreeBSD.org) Received: from fledge.watson.org (fledge.watson.org [209.31.154.41]) by cyrus.watson.org (Postfix) with ESMTP id 358F146B98; Sat, 18 Mar 2006 12:05:37 -0500 (EST) Date: Sat, 18 Mar 2006 17:07:12 +0000 (GMT) From: Robert Watson X-X-Sender: robert@fledge.watson.org To: "Andrew R. Reiter" In-Reply-To: <20060318120450.C51324@fledge.watson.org> Message-ID: <20060318170636.E578@fledge.watson.org> References: <200603181701.k2IH1r5x004312@repoman.freebsd.org> <20060318120450.C51324@fledge.watson.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: Perforce Change Reviews Subject: Re: PERFORCE change 93511 for review X-BeenThere: trustedbsd-cvs@FreeBSD.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: TrustedBSD CVS and Perforce commit message list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 18 Mar 2006 17:06:08 -0000 On Sat, 18 Mar 2006, Andrew R. Reiter wrote: > Heh; you just read my mind (was about to email) If you get bored, you should come hang out in #trustedbsd on EFNet so that we can perform more feats of mind-reading :-). Robert N M Watson > > On Sat, 18 Mar 2006, Robert Watson wrote: > > :http://perforce.freebsd.org/chv.cgi?CH=93511 > : > :Change 93511 by rwatson@rwatson_peppercorn on 2006/03/18 17:01:32 > : > : When pulling the global audit queue's contents into a thread-local > : queue, generate one low water mark transition signal, rather than > : many, and generate it only if actually crossing the transition > : point, rather than every time we notice we're below it. > : > :Affected files ... > : > :.. //depot/projects/trustedbsd/audit3/sys/security/audit/audit.c#21 edit > : > :Differences ... > : > :==== //depot/projects/trustedbsd/audit3/sys/security/audit/audit.c#21 (text+ko) ==== > : > :@@ -555,7 +555,7 @@ > : struct ucred *audit_cred; > : struct thread *audit_td; > : struct vnode *audit_vp; > :- int error; > :+ int error, lowater_signal; > : > : AUDIT_PRINTF(("audit_worker starting\n")); > : > :@@ -607,13 +607,16 @@ > : * our own clustering, if the lower layers aren't doing it > : * automatically enough. > : */ > :+ lowater_signal = 0; > : while ((ar = TAILQ_FIRST(&audit_q))) { > : TAILQ_REMOVE(&audit_q, ar, k_q); > : audit_q_len--; > :- if (audit_q_len <= audit_qctrl.aq_lowater) > :- cv_broadcast(&audit_commit_cv); > :+ if (audit_q_len == audit_qctrl.aq_lowater) > :+ lowater_signal++; > : TAILQ_INSERT_TAIL(&ar_worklist, ar, k_q); > : } > :+ if (lowater_signal) > :+ cv_broadcast(&audit_commit_cv); > : > : mtx_unlock(&audit_mtx); > : while ((ar = TAILQ_FIRST(&ar_worklist))) { > : > : > > -- > arr@watson.org >