kern/111831: [nfs] page fault while in kernel mode with samba in
vfs_vmio_release
Steve Sears
sjs at netapp.com
Thu Jul 19 18:23:27 UTC 2007
I hit this bug and fixed it thusly in nfsclient/nfs_bio.c, around line 1735:
} else {
if (error) {
bp->b_ioflags |= BIO_ERROR;
/* Mark buffer invalid which will result in invalidating
* its pages and other buffer cleanup in brelse().
* Cannot set BIO_ERROR without marking buffer B_INVAL.
*/
+++ bp->b_flags |= B_INVAL;
bp->b_error = np->n_error = error;
np->n_flag |= NWRITEERR;
+++ np->n_attrstamp = 0;
}
bp->b_dirtyoff = bp->b_dirtyend = 0;
Part of the problem is that the transport is returning an error that is not
being dealt with gracefully. In my case it was EAGAIN. I also fixed the
socket code to retry in the session layer if it gets EAGAIN. I'm using a
specialized transport, so that part of the fix is not relevant.
I just looked at the file in the CVS repository and version 1.152.2.5,
2007/07/17 21:02:08, is the same fix. If this change is MFC'd to 6.2, the
submitter should be happy.
-Steve
More information about the freebsd-bugs
mailing list