X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/2d21ac55c334faf3a56e5634905ed6987fc787d4..0a7de7458d150b5d4dffc935ba399be265ef0a1a:/bsd/man/man2/mount.2 diff --git a/bsd/man/man2/mount.2 b/bsd/man/man2/mount.2 index dc70c857a..586707fa6 100644 --- a/bsd/man/man2/mount.2 +++ b/bsd/man/man2/mount.2 @@ -39,6 +39,7 @@ .Os BSD 4 .Sh NAME .Nm mount , +.Nm fmount, .Nm unmount .Nd mount or dismount a filesystem .Sh SYNOPSIS @@ -47,6 +48,8 @@ .Ft int .Fn mount "const char *type" "const char *dir" "int flags" "void *data" .Ft int +.Fn fmount "const char *type" "int fd" "int flags" "void *data" +.Ft int .Fn unmount "const char *dir" "int flags" .Sh DESCRIPTION The @@ -92,6 +95,8 @@ Do not interpret special files on the filesystem. Union with underlying filesystem instead of obscuring it. .It Dv MNT_SYNCHRONOUS All I/O to the filesystem should be done synchronously. +.It Dv MNT_CPROTECT +Enable data protection on the filesystem if the filesystem is configured for it. .El .Pp The flag @@ -120,7 +125,16 @@ The format for these argument structures is described in the manual page for each filesystem. .Pp The -.Fn umount +.Fn fmount +function call is equivalent to the +.Fn mount +function call, except in the use of the second argument. +It takes an open file descriptor representing mount point +instead of the string literal containing full path to the mount +point in the filesystem hierarchy. +.Pp +The +.Fn unmount function call disassociates the filesystem from the specified mount point .Fa dir . @@ -137,18 +151,22 @@ even if the filesystem is later remounted. .Sh RETURN VALUES The .Fn mount -returns the value 0 if the mount was successful, otherwise -1 is returned +and +.Fn fmount +return the value 0 if the mount was successful, otherwise -1 is returned and the variable .Va errno is set to indicate the error. .Pp -.Nm Umount -returns the value 0 if the umount succeeded; otherwise -1 is returned +.Nm unmount +returns the value 0 if the unmount succeeded; otherwise -1 is returned and the variable .Va errno is set to indicate the error. .Sh ERRORS -.Fn Mount +.Fn mount +and +.Fn fmount will fail when one of the following occurs: .Bl -tag -width [ENAMETOOLONG] .It Bq Er EPERM @@ -183,7 +201,7 @@ Another process currently holds a reference to points outside the process's allocated address space. .El .Pp -.Nm Umount +.Nm unmount may fail with one of the following errors: .Bl -tag -width [ENAMETOOLONG] .It Bq Er EPERM @@ -215,12 +233,15 @@ points outside the process's allocated address space. .El .Sh SEE ALSO .Xr mount 8 , -.Xr umount 8 +.Xr unmount 8 , +.Xr open 2 .Sh BUGS Some of the error codes need translation to more obvious messages. .Sh HISTORY -.Fn Mount +.Fn mount and -.Fn umount +.Fn unmount function calls appeared in .At v6 . +.Fn fmount +function call first appeared in macOS version 10.13.