[prev in list] [next in list] [prev in thread] [next in thread]
List: freebsd-smp
Subject: Please test: -stable SMP locking fix
From: Thomas Moestl <tmm () FreeBSD ! ORG>
Date: 2001-07-26 22:39:29
[Download RAW message or body]
Hi,
I have attached a patch that should fix some panics (caused by
sleeping with a lock held) and lock-order reversals on -stable SMP
systems. These usually only seem to occur when using NFS.
I'd like to commit this fix before 4.4 is released (if I can make
it). Due to locking changes, this will need to be solved differently
on -current, so it will need to be directly committed to -stable.
Therefore, to anybody who uses stable on an SMP box (and dares ;):
please, please test this, and report back any problems! If you do,
please drop me a private mail so that I get an idea about the test
coverage that it got.
The risk should be relatively low (this removes a lock/unlock pair,
but all relevant code should also be protected by the mp_lock).
On UP machines, this patch does not change anything at all.
- thomas
["vinval.diff" (text/plain)]
Index: vfs_subr.c
===================================================================
RCS file: /home/ncvs/src/sys/kern/vfs_subr.c,v
retrieving revision 1.249.2.9
diff -u -r1.249.2.9 vfs_subr.c
--- vfs_subr.c 2001/06/26 04:20:08 1.249.2.9
+++ vfs_subr.c 2001/07/25 21:35:01
@@ -730,12 +730,10 @@
/*
* Destroy the copy in the VM cache, too.
*/
- simple_lock(&vp->v_interlock);
if (VOP_GETVOBJECT(vp, &object) == 0) {
vm_object_page_remove(object, 0, 0,
(flags & V_SAVE) ? TRUE : FALSE);
}
- simple_unlock(&vp->v_interlock);
if (!TAILQ_EMPTY(&vp->v_dirtyblkhd) || !TAILQ_EMPTY(&vp->v_cleanblkhd))
panic("vinvalbuf: flush failed");
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-smp" in the body of the message
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic