Date: Tue, 28 Jul 1998 10:45:03 -0400 (EDT) From: Luoqi Chen <luoqi@chen.ml.org> To: bde@zeta.org.au, freebsd-bugs@FreeBSD.ORG, luoqi@chen.ml.org, phk@FreeBSD.ORG Subject: Re: kern/7415 Message-ID: <199807281445.KAA19921@chen.ml.org> In-Reply-To: <199807281056.UAA30494@godzilla.zeta.org.au>
index | next in thread | previous in thread | raw e-mail
> >it sounds to me like the simple solution would be to either:
> >A) have ufs clear the vmio flag agan
> >B) have msdosfs (and other similar fs) clear the flag before they start.
>
> Simple and wrong. File systems know nothing of the vmio flag. Either
> vm should clear it and be more careful about setting it (it only works
> now for ufs because ufs never requests a misaligned block), or it should
> always be set for block devices and fixes like the ones in the patch
> should be applied.
>
> >Could you explain what your patch does ?
>
> It attempts to make misaligned buffers (ones whose size and file offsets
> are multiples of PAGE_SIZE) actually work. It isn't clear whether they
^
not
> were intended to work, but they will need to work if the buffer cache
> and vm are ever fully merged.
>
> Bruce
>
Bruce explained it very well (much better than I could). I'd like make one
comment, I believe the misaligned buffers are intended to work. The evidence
is at around line 1830 of vfs_bio.c the statement,
((vm_offset_t) bp->b_data) |= off & PAGE_MASK;
and in numerous other places statements like
pmap_qenter(trunc_page(bp->b_data), bp->b_pages, bp->b_npages);
the original author were aware of these misaligned buffers and attempted to
make them work.
-lq
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199807281445.KAA19921>
