From owner-freebsd-hackers Wed Apr 18 12:22:59 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from bingnet2.cc.binghamton.edu (bingnet2.cc.binghamton.edu [128.226.1.18]) by hub.freebsd.org (Postfix) with ESMTP id 38A8637B42C for ; Wed, 18 Apr 2001 12:22:54 -0700 (PDT) (envelope-from zzhang@cs.binghamton.edu) Received: from onyx (onyx.cs.binghamton.edu [128.226.140.171]) by bingnet2.cc.binghamton.edu (8.11.2/8.11.2) with ESMTP id f3IJMq503572; Wed, 18 Apr 2001 15:22:52 -0400 (EDT) Date: Wed, 18 Apr 2001 15:22:50 -0400 (EDT) From: Zhihui Zhang X-Sender: zzhang@onyx To: Alfred Perlstein Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Buffer emergence reserve In-Reply-To: <20010418115820.R976@fw.wintelcom.net> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Thanks! I am wondering whether the free VM page reserve has similar reason to exist, i.e., to clean dirty pages you need more pages. Probably not, that is for interrupt routines that can not block. On Wed, 18 Apr 2001, Alfred Perlstein wrote: > * Zhihui Zhang [010418 09:18] wrote: > > > > While looking at the code in vfs_bio.c, I notice the existence of low and > > high free buffer counters. The comments say they are there to give some > > special process like buf daemon access to emergence reserve. I just > > don't get the reason for having this emergence reserve. Do we allocate > > buffer in an interrupt environment? Do we need extra buffers in order to > > free buffers? Please shed a light on this for me. Thanks. > > It's really a simple issue of: > > "sometimes to clean a buffer we need one or more buffers" > > Think of some random data block at the far end of a large file. > > If the indirect blocks aren't in memory you will need to bring > them in to lookup the location of the buffer you're writing > because buffers use logical offsets rather than physical ones. > > -- > -Alfred Perlstein - [bright@wintelcom.net|alfred@freebsd.org] > Represent yourself, show up at BABUG http://www.babug.org/ > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message