diff options
author | alc <alc@FreeBSD.org> | 2003-10-04 09:20:00 +0000 |
---|---|---|
committer | alc <alc@FreeBSD.org> | 2003-10-04 09:20:00 +0000 |
commit | ab85e7e0652dee01dbffb638e28012b750ab28c5 (patch) | |
tree | 28d031d649a0ef7715499c87a2b42f9712bcbd0d /sys/fs/specfs | |
parent | 849854f24022fe42e014122837d80edcee73b5b0 (diff) | |
download | FreeBSD-src-ab85e7e0652dee01dbffb638e28012b750ab28c5.zip FreeBSD-src-ab85e7e0652dee01dbffb638e28012b750ab28c5.tar.gz |
Synchronize access to a page's valid field by using the lock from its
containing object.
Diffstat (limited to 'sys/fs/specfs')
-rw-r--r-- | sys/fs/specfs/spec_vnops.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/fs/specfs/spec_vnops.c b/sys/fs/specfs/spec_vnops.c index f13a36a..ff09a7a 100644 --- a/sys/fs/specfs/spec_vnops.c +++ b/sys/fs/specfs/spec_vnops.c @@ -821,7 +821,6 @@ spec_getpages(ap) } } vm_page_unlock_queues(); - VM_OBJECT_UNLOCK(ap->a_m[ap->a_reqpage]->object); if (!gotreqpage) { m = ap->a_m[ap->a_reqpage]; printf( @@ -833,12 +832,14 @@ spec_getpages(ap) printf( " nread: %d, reqpage: %d, pindex: %lu, pcount: %d\n", nread, ap->a_reqpage, (u_long)m->pindex, pcount); + VM_OBJECT_UNLOCK(m->object); /* * Free the buffer header back to the swap buffer pool. */ relpbuf(bp, NULL); return VM_PAGER_ERROR; } + VM_OBJECT_UNLOCK(ap->a_m[ap->a_reqpage]->object); /* * Free the buffer header back to the swap buffer pool. */ |