From owner-freebsd-current Tue Sep 23 09:22:11 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id JAA19255 for current-outgoing; Tue, 23 Sep 1997 09:22:11 -0700 (PDT) Received: from usr01.primenet.com (tlambert@usr01.primenet.com [206.165.6.201]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id JAA19248 for ; Tue, 23 Sep 1997 09:22:01 -0700 (PDT) Received: (from tlambert@localhost) by usr01.primenet.com (8.8.5/8.8.5) id JAA10443; Tue, 23 Sep 1997 09:20:32 -0700 (MST) From: Terry Lambert Message-Id: <199709231620.JAA10443@usr01.primenet.com> Subject: Re: callouts in CAM (was Re: cvs commit:) To: gibbs@plutotech.com (Justin T. Gibbs) Date: Tue, 23 Sep 1997 16:20:31 +0000 (GMT) Cc: tlambert@primenet.com, gibbs@plutotech.com, nate@mt.sri.com, bde@zeta.org.au, current@FreeBSD.org In-Reply-To: <199709230634.AAA13555@pluto.plutotech.com> from "Justin T. Gibbs" at Sep 23, 97 00:34:32 am X-Mailer: ELM [version 2.4 PL23] Content-Type: text Sender: owner-freebsd-current@FreeBSD.org X-Loop: FreeBSD.org Precedence: bulk > >You stated before that you could simply block the request that would > >have made use of a newly allocated resource until such time as one of > >the existing entries becomes availble. I'd hate to see max allocation > >up front in all cases. 8-(. > > New work comes in. There are no CCBs/callouts available in the > free pool. An attempt is made to allocate a CCB and it's corresponding > callout. If that fails (malloc failure), I wait for an existing > CCB/callout to come free. Where does this contradict what I said > above? Nowhere. You didn't quote your original anti-watermarking sentiment when you quoted me. ;-). > Where is the max allocation up front? I allocate on demand. There is no reason not to watermark the free pool. It has the advantage that you can return memory to the system, and allocations can occur in page units. A failed allocation at a low watermark can be ignored until the pool is truly empty, at which time you can fail using the mthod you are already using. Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.