Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Dec 2001 19:04:19 -0800
From:      Terry Lambert <tlambert2@mindspring.com>
To:        Matthew Dillon <dillon@apollo.backplane.com>
Cc:        David Greenman <dg@root.com>, Jordan Hubbard <jkh@winston.freebsd.org>, Peter Wemm <peter@wemm.org>, Mike Smith <msmith@FreeBSD.ORG>, hackers@FreeBSD.ORG, msmith@mass.dis.org
Subject:   Re: NFS Patch #4 -- survived overnight test. (was Re: Found NFS data  corruption bug... (was Re:...))
Message-ID:  <3C196C33.2A3A6BD0@mindspring.com>
References:  <58885.1008217148@winston.freebsd.org> <200112130608.fBD689K49906@apollo.backplane.com> <20011212224927.A73226@nexus.root.com> <200112131835.fBDIZuL70031@apollo.backplane.com> <3C18FAC9.E743DAA5@mindspring.com> <200112140042.fBE0gBa61696@apollo.backplane.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Matthew Dillon wrote:
>     Hmm.  Well, my code is definitely broken.  My 'adj' calculation is
>     all wrong.  However, my size calculation appears to be correct.
>     (size - adj) is the size of the block after the base has been adjusted
>     to the next full chunk.  The number of chunks we then generate bits
>     for must be fully enclosed by size and (new_size & ~(DEV_BSIZE - 1))
>     gives that to us.  e.g. if new_size is less then DEV_BSIZE we get 0,
>     correctly indicating that we cannot clear any dirty bits at all.

I missed the size of the operand to the twiddle; mea culpa.  I
thought you were (effectively) getting a "mod" operation on a
"div"'ed value, not the total value.

Never mind.  8^).

-- Terry

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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3C196C33.2A3A6BD0>