Date: 03 Mar 2004 16:38:49 -0500 From: "David E. Cross" <crossd@cs.rpi.edu> To: freebsd-fs@freebsd.org Subject: struct buf * and journaled-UFS help Message-ID: <1078349927.454.5.camel@rexx.cs.rpi.edu>
next in thread | raw e-mail | index | archive | help
As some are aware I have been working with a computer science graduate student to bring jounralling to the UFS(2) filesystem. Right now we have it so that operations are journaled to an in-core memory structure (comprised of BLKSIZE * number amount of memory, which is obtained by malloc(9)). When this in-core journal gets full we need to flush it to disk. Previously we had used VOP_WRITE() for this, but it was suggested, and I agree that we should use either VOP_STRATEGY or brwite/bread for our IO work. Both of these require a "struct buf" to do their work. What is the appropriate way to get such a structure? I have seen gbincore() used in similar cases, but it seems that gbincore(), like many of the other buf(9) routines are for getting an already allocated struct buf from the system pool; for example gbincore checks that the lblkno of what is requested is the name as the block already allocated in either the clean or dirty block trees. -- David E. Cross
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1078349927.454.5.camel>