aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/vfs_vnops.c
diff options
context:
space:
mode:
authorKa Ho Ng <khng@FreeBSD.org>2021-08-11 09:45:47 +0000
committerKa Ho Ng <khng@FreeBSD.org>2021-08-11 09:45:47 +0000
commit4a9b832a2ad7acafaa16c858ab6e517f2fd83a0c (patch)
tree92a47905c2cc734dc66ed19217fcef702fa5f65d /sys/kern/vfs_vnops.c
parent4f3a0cfbde03db19bd2c075eadc73e0efbf93820 (diff)
downloadsrc-4a9b832a2ad7acafaa16c858ab6e517f2fd83a0c.tar.gz
src-4a9b832a2ad7acafaa16c858ab6e517f2fd83a0c.zip
vfs: Rename ioflg to ioflag in vn_deallocate
This includes a style fix around ioflag checking as well. Sponsored by: The FreeBSD Foundation Reviewed by: kib, bcr Differential Revision: https://reviews.freebsd.org/D31505
Diffstat (limited to 'sys/kern/vfs_vnops.c')
-rw-r--r--sys/kern/vfs_vnops.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c
index 832ade5d800e..015a13c1c385 100644
--- a/sys/kern/vfs_vnops.c
+++ b/sys/kern/vfs_vnops.c
@@ -3447,7 +3447,7 @@ vn_fallocate(struct file *fp, off_t offset, off_t len, struct thread *td)
static int
vn_deallocate_impl(struct vnode *vp, off_t *offset, off_t *length, int flags,
- int ioflg, struct ucred *active_cred, struct ucred *file_cred)
+ int ioflag, struct ucred *active_cred, struct ucred *file_cred)
{
struct mount *mp;
void *rl_cookie;
@@ -3463,7 +3463,7 @@ vn_deallocate_impl(struct vnode *vp, off_t *offset, off_t *length, int flags,
off = *offset;
len = *length;
- if ((ioflg & (IO_NODELOCKED|IO_RANGELOCKED)) == 0)
+ if ((ioflag & (IO_NODELOCKED | IO_RANGELOCKED)) == 0)
rl_cookie = vn_rangelock_wlock(vp, off, off + len);
while (len > 0 && error == 0) {
/*
@@ -3473,7 +3473,7 @@ vn_deallocate_impl(struct vnode *vp, off_t *offset, off_t *length, int flags,
* pass.
*/
- if ((ioflg & IO_NODELOCKED) == 0) {
+ if ((ioflag & IO_NODELOCKED) == 0) {
bwillwrite();
if ((error = vn_start_write(vp, &mp,
V_WAIT | PCATCH)) != 0)
@@ -3488,7 +3488,7 @@ vn_deallocate_impl(struct vnode *vp, off_t *offset, off_t *length, int flags,
#endif
#ifdef MAC
- if ((ioflg & IO_NOMACCHECK) == 0)
+ if ((ioflag & IO_NOMACCHECK) == 0)
error = mac_vnode_check_write(active_cred, file_cred,
vp);
#endif
@@ -3496,7 +3496,7 @@ vn_deallocate_impl(struct vnode *vp, off_t *offset, off_t *length, int flags,
error = VOP_DEALLOCATE(vp, &off, &len, flags,
active_cred);
- if ((ioflg & IO_NODELOCKED) == 0) {
+ if ((ioflag & IO_NODELOCKED) == 0) {
VOP_UNLOCK(vp);
if (mp != NULL) {
vn_finished_write(mp);
@@ -3514,7 +3514,7 @@ out:
int
vn_deallocate(struct vnode *vp, off_t *offset, off_t *length, int flags,
- int ioflg, struct ucred *active_cred, struct ucred *file_cred)
+ int ioflag, struct ucred *active_cred, struct ucred *file_cred)
{
if (*offset < 0 || *length <= 0 || *length > OFF_MAX - *offset ||
flags != 0)
@@ -3522,7 +3522,7 @@ vn_deallocate(struct vnode *vp, off_t *offset, off_t *length, int flags,
if (vp->v_type != VREG)
return (ENODEV);
- return (vn_deallocate_impl(vp, offset, length, flags, ioflg,
+ return (vn_deallocate_impl(vp, offset, length, flags, ioflag,
active_cred, file_cred));
}