Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F97616015
D42554.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1017 B
Referenced Files
None
Subscribers
None
D42554.diff
View Options
diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c
--- a/sys/kern/vfs_vnops.c
+++ b/sys/kern/vfs_vnops.c
@@ -3046,6 +3046,7 @@
off_t *outoffp, size_t *lenp, unsigned int flags, struct ucred *incred,
struct ucred *outcred, struct thread *fsize_td)
{
+ struct mount *inmp, *outmp;
int error;
size_t len;
uint64_t uval;
@@ -3075,15 +3076,17 @@
if (len == 0)
goto out;
+ inmp = invp->v_mount;
+ outmp = outvp->v_mount;
+
/*
* If the two vnodes are for the same file system type, call
* VOP_COPY_FILE_RANGE(), otherwise call vn_generic_copy_file_range()
* which can handle copies across multiple file system types.
*/
*lenp = len;
- if (invp->v_mount == outvp->v_mount ||
- strcmp(invp->v_mount->mnt_vfc->vfc_name,
- outvp->v_mount->mnt_vfc->vfc_name) == 0)
+ if (inmp == outmp || strcmp(inmp->mnt_vfc->vfc_name,
+ outmp->mnt_vfc->vfc_name) == 0)
error = VOP_COPY_FILE_RANGE(invp, inoffp, outvp, outoffp,
lenp, flags, incred, outcred, fsize_td);
else
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Oct 1, 9:28 AM (21 h, 52 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
13243082
Default Alt Text
D42554.diff (1017 B)
Attached To
Mode
D42554: vn_copy_file_range(): busy both in and out mp around call to VOP_COPY_FILE_RANGE()
Attached
Detach File
Event Timeline
Log In to Comment