Changeset View
Changeset View
Standalone View
Standalone View
share/man/man9/VOP_DEALLOCATE.9
Show All 21 Lines | |||||
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||||
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | ||||
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | ||||
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | ||||
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | ||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | ||||
.\" SUCH DAMAGE. | .\" SUCH DAMAGE. | ||||
.\" | .\" | ||||
.Dd May 11, 2021 | .Dd August 11, 2021 | ||||
.Dt VOP_DEALLOCATE 9 | .Dt VOP_DEALLOCATE 9 | ||||
.Os | .Os | ||||
.Sh NAME | .Sh NAME | ||||
.Nm VOP_DEALLOCATE | .Nm VOP_DEALLOCATE | ||||
.Nd zero and/or deallocate storage from a file | .Nd zero and/or deallocate storage from a file | ||||
.Sh SYNOPSIS | .Sh SYNOPSIS | ||||
.In sys/param.h | .In sys/param.h | ||||
.In sys/vnode.h | .In sys/vnode.h | ||||
.Ft int | .Ft int | ||||
.Fo VOP_DEALLOCATE | .Fo VOP_DEALLOCATE | ||||
.Fa "struct vnode *vp" | .Fa "struct vnode *vp" | ||||
.Fa "off_t *offset" | .Fa "off_t *offset" | ||||
.Fa "off_t *len" | .Fa "off_t *len" | ||||
.Fa "int flags" | .Fa "int flags" | ||||
.Fa "int ioflag" | |||||
.Fa "struct ucred *cred" | .Fa "struct ucred *cred" | ||||
.Fc | .Fc | ||||
.Sh DESCRIPTION | .Sh DESCRIPTION | ||||
This VOP call zeroes/deallocates storage for an offset range in a file. | This VOP call zeroes/deallocates storage for an offset range in a file. | ||||
It is used to implement the | It is used to implement the | ||||
.Xr fspacectl 2 | .Xr fspacectl 2 | ||||
system call. | system call. | ||||
.Pp | .Pp | ||||
Its arguments are: | Its arguments are: | ||||
.Bl -tag -width offset | .Bl -tag -width offset | ||||
.It Fa vp | .It Fa vp | ||||
The vnode of the file. | The vnode of the file. | ||||
.It Fa offset | .It Fa offset | ||||
The start of the range to deallocate storage in the file. | The start of the range to deallocate storage in the file. | ||||
.It Fa len | .It Fa len | ||||
The length of the range to deallocate storage in the file. | The length of the range to deallocate storage in the file. | ||||
.It Fa flags | .It Fa flags | ||||
The flags of this call. | The flags of this call. | ||||
This should be set to 0 for now. | This should be set to 0 for now. | ||||
.It Fa ioflag | |||||
Directives and hints to be given to the file system. | |||||
.It Fa cred | .It Fa cred | ||||
The credentials of the caller. | The credentials of the caller. | ||||
.El | .El | ||||
.Pp | .Pp | ||||
.Fa *offset | .Fa *offset | ||||
and | and | ||||
.Fa *len | .Fa *len | ||||
are updated to reflect the portion of the range that | are updated to reflect the portion of the range that | ||||
Show All 30 Lines |