*** UNIX MANUAL PAGE BROWSER ***

A Nergahak database for man pages research.

Navigation

Directory Browser

1Browse 4.4BSD4.4BSD
1Browse Digital UNIXDigital UNIX 4.0e
1Browse FreeBSDFreeBSD 14.3
1Browse MINIXMINIX 3.4.0rc6-d5e4fc0
1Browse NetBSDNetBSD 10.1
1Browse OpenBSDOpenBSD 7.7
1Browse UNIX v7Version 7 UNIX
1Browse UNIX v10Version 10 UNIX

Manual Page Search

Manual Page Result

0 Command: vn_deallocate | Section: 9 | Source: FreeBSD | File: vn_deallocate.9.gz
VN_DEALLOCATE(9) FreeBSD Kernel Developer's Manual VN_DEALLOCATE(9) NAME vn_deallocate - zero and/or deallocate storage from a file SYNOPSIS #include <sys/param.h> #include <sys/vnode.h> int vn_deallocate(struct vnode *vp, off_t *offset, off_t *length, int flags, int ioflag, struct ucred *active_cred, struct ucred *file_cred); DESCRIPTION The vn_deallocate() function zeros and/or deallocates backing storage space from a file. This function only works on vnodes with VREG type. The arguments are: vp The vnode of the file. offset The starting offset of the operation range. length The length of the operation range. This must be greater than 0. flags The control flags of the operation. This should be set to 0 for now. ioflag Directives and hints to be given to the file system. active_cred The user credentials of the calling thread. file_cred The credentials installed on the file description pointing to the vnode or NOCRED. The ioflag() argument gives directives and hints to the file system. It may include one or more of the following flags: IO_NODELOCKED The vnode was locked before the call. IO_RANGELOCKED Rangelock was owned around the call. IO_NOMACCHECK Skip MAC checking in the call. IO_SYNC Do I/O synchronously. IO_DIRECT Attempt to bypass buffer cache. *offset and *length are updated to reflect the unprocessed operation range of the call. For a successful completion, *length is updated to be the value 0, and *offset is incremented by the number of bytes zeroed before the end-of-file. RETURN VALUES Upon successful completion, the value 0 is returned; otherwise the appropriate error is returned. SEE ALSO vnode(9), VOP_DEALLOCATE(9) AUTHORS vn_deallocate and this manual page was written by Ka Ho Ng <[email protected]> under sponsorship from the FreeBSD Foundation. FreeBSD 14.1-RELEASE-p8 August 25, 2021 FreeBSD 14.1-RELEASE-p8

Navigation Options