From owner-freebsd-bugs Tue Jul 28 07:46:01 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id HAA21812 for freebsd-bugs-outgoing; Tue, 28 Jul 1998 07:46:01 -0700 (PDT) (envelope-from owner-freebsd-bugs@FreeBSD.ORG) Received: from chen.ml.org (luoqi.watermarkgroup.com [207.202.73.170]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id HAA21758; Tue, 28 Jul 1998 07:45:41 -0700 (PDT) (envelope-from luoqi@chen.ml.org) Received: (from luoqi@localhost) by chen.ml.org (8.8.8/8.8.8) id KAA19921; Tue, 28 Jul 1998 10:45:03 -0400 (EDT) (envelope-from luoqi) Date: Tue, 28 Jul 1998 10:45:03 -0400 (EDT) From: Luoqi Chen Message-Id: <199807281445.KAA19921@chen.ml.org> To: bde@zeta.org.au, freebsd-bugs@FreeBSD.ORG, luoqi@chen.ml.org, phk@FreeBSD.ORG Subject: Re: kern/7415 In-Reply-To: <199807281056.UAA30494@godzilla.zeta.org.au> Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org > >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