Atomically update vm_object vnp_size, where atomic is available.
This will be used later, where it matters on 32bit arches. Reviewed by: markj Tested by: pho Sponsored by: The FreeBSD Foundation Differential revision: https://reviews.freebsd.org/D25968
This commit is contained in:
parent
37f253ed0f
commit
419e5698a0
@ -520,7 +520,11 @@ vnode_pager_setsize(struct vnode *vp, vm_ooffset_t nsize)
|
||||
vm_page_xunbusy(m);
|
||||
}
|
||||
out:
|
||||
#if defined(__powerpc__) && !defined(__powerpc64__)
|
||||
object->un_pager.vnp.vnp_size = nsize;
|
||||
#else
|
||||
atomic_store_64(&object->un_pager.vnp.vnp_size, nsize);
|
||||
#endif
|
||||
object->size = nobjsize;
|
||||
VM_OBJECT_WUNLOCK(object);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user