Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 04 Mar 2003 17:23:59 -0800
From:      Kirk McKusick <mckusick@beastie.mckusick.com>
To:        "Jeff Roberson" <jroberson@chesapeake.net>
Cc:        "Luoqi Chen" <lchen@briontech.com>, arch@FreeBSD.ORG
Subject:   Re: vtruncbuf() 
Message-ID:  <200303050123.h251NxFL088420@beastie.mckusick.com>
In-Reply-To: Your message of "Tue, 04 Mar 2003 15:43:25 PST." <AHEKICEOIHLOGINAFIINGENNCAAA.lchen@briontech.com> 

next in thread | previous in thread | raw e-mail | index | archive | help
	From: "Luoqi Chen" <lchen@briontech.com>
	To: "Jeff Roberson" <jroberson@chesapeake.net>
	Cc: <arch@FreeBSD.ORG>
	Subject: RE: vtruncbuf()
	Date: Tue, 4 Mar 2003 15:43:25 -0800
	X-ASK-Info: Whitelist match

	> There is also a really weird check to see if the buf's vp 
	> matches the vp

This check is left from the days before the logical block numbers
of metadata (indirect blocks) were stored as negative numbers
associated with the file vnode. Before that change, they were
stored as actual disk block numbers and associated with the
mounted special device vnode. So as to be able to find them
easily, they were temporarily moved from the special device
vnode to the file vnode dirty list when they were written,
then moved back to the special device vnode clean list when
they were written. Luckily all that nastyness ended when the
new logical block scheme got invented, but the check for
bp->b_vp == vp never got cleaned out of the code. Your historic
footnote for the day.

	Kirk McKusick

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-arch" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200303050123.h251NxFL088420>