Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F148053136
D51730.1785228550.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
745 B
Referenced Files
None
Subscribers
None
D51730.1785228550.diff
View Options
diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c
--- a/sys/kern/vfs_subr.c
+++ b/sys/kern/vfs_subr.c
@@ -5897,6 +5897,8 @@
static void
vop_fsync_debugprepost(struct vnode *vp, const char *name)
{
+ struct mount *mp;
+
if (vp->v_type == VCHR)
;
/*
@@ -5914,10 +5916,16 @@
* should still be caught when the stacked filesystem
* invokes VOP_FSYNC() on the underlying filesystem.
*/
- else if (MNT_SHARED_WRITES(vp->v_mount))
- ASSERT_VOP_LOCKED(vp, name);
- else
- ASSERT_VOP_ELOCKED(vp, name);
+ else {
+ mp = NULL;
+ VOP_GETWRITEMOUNT(vp, &mp);
+ if (vn_lktype_write(mp, vp) == LK_SHARED)
+ ASSERT_VOP_LOCKED(vp, name);
+ else
+ ASSERT_VOP_ELOCKED(vp, name);
+ if (mp != NULL)
+ vfs_rel(mp);
+ }
}
void
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Jul 28, 8:49 AM (7 h, 11 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
29288823
Default Alt Text
D51730.1785228550.diff (745 B)
Attached To
Mode
D51730: vop_fsync_debugprepost(): take account of nullfs
Attached
Detach File
Event Timeline
Log In to Comment