svn commit: r357383 - in head/sys: fs/devfs fs/pseudofs fs/tmpfs kern sys
Mateusz Guzik
mjg at FreeBSD.org
Sat Feb 1 20:34:45 UTC 2020
Author: mjg
Date: Sat Feb 1 20:34:43 2020
New Revision: 357383
URL: https://svnweb.freebsd.org/changeset/base/357383
Log:
vfs: consistently use size_t for buflen around VOP_VPTOCNP
Modified:
head/sys/fs/devfs/devfs_vnops.c
head/sys/fs/pseudofs/pseudofs_vnops.c
head/sys/fs/tmpfs/tmpfs_vnops.c
head/sys/kern/vfs_cache.c
head/sys/kern/vfs_default.c
head/sys/kern/vnode_if.src
head/sys/sys/vnode.h
Modified: head/sys/fs/devfs/devfs_vnops.c
==============================================================================
--- head/sys/fs/devfs/devfs_vnops.c Sat Feb 1 20:33:23 2020 (r357382)
+++ head/sys/fs/devfs/devfs_vnops.c Sat Feb 1 20:34:43 2020 (r357383)
@@ -274,7 +274,7 @@ devfs_vptocnp(struct vop_vptocnp_args *ap)
struct vnode **dvp = ap->a_vpp;
struct devfs_mount *dmp;
char *buf = ap->a_buf;
- int *buflen = ap->a_buflen;
+ size_t *buflen = ap->a_buflen;
struct devfs_dirent *dd, *de;
int i, error;
Modified: head/sys/fs/pseudofs/pseudofs_vnops.c
==============================================================================
--- head/sys/fs/pseudofs/pseudofs_vnops.c Sat Feb 1 20:33:23 2020 (r357382)
+++ head/sys/fs/pseudofs/pseudofs_vnops.c Sat Feb 1 20:34:43 2020 (r357383)
@@ -377,7 +377,7 @@ pfs_vptocnp(struct vop_vptocnp_args *ap)
struct pfs_node *pn;
struct mount *mp;
char *buf = ap->a_buf;
- int *buflen = ap->a_buflen;
+ size_t *buflen = ap->a_buflen;
char pidbuf[PFS_NAMELEN];
pid_t pid = pvd->pvd_pid;
int len, i, error, locked;
Modified: head/sys/fs/tmpfs/tmpfs_vnops.c
==============================================================================
--- head/sys/fs/tmpfs/tmpfs_vnops.c Sat Feb 1 20:33:23 2020 (r357382)
+++ head/sys/fs/tmpfs/tmpfs_vnops.c Sat Feb 1 20:34:43 2020 (r357383)
@@ -1491,7 +1491,7 @@ tmpfs_vptocnp_dir(struct tmpfs_node *tn, struct tmpfs_
static int
tmpfs_vptocnp_fill(struct vnode *vp, struct tmpfs_node *tn,
- struct tmpfs_node *tnp, char *buf, int *buflen, struct vnode **dvp)
+ struct tmpfs_node *tnp, char *buf, size_t *buflen, struct vnode **dvp)
{
struct tmpfs_dirent *de;
int error, i;
@@ -1531,7 +1531,7 @@ tmpfs_vptocnp(struct vop_vptocnp_args *ap)
struct tmpfs_dirent *de;
struct tmpfs_mount *tm;
char *buf;
- int *buflen;
+ size_t *buflen;
int error;
vp = ap->a_vp;
Modified: head/sys/kern/vfs_cache.c
==============================================================================
--- head/sys/kern/vfs_cache.c Sat Feb 1 20:33:23 2020 (r357382)
+++ head/sys/kern/vfs_cache.c Sat Feb 1 20:34:43 2020 (r357383)
@@ -388,7 +388,7 @@ STATNODE_COUNTER(shrinking_skipped,
static void cache_zap_locked(struct namecache *ncp, bool neg_locked);
static int vn_fullpath1(struct thread *td, struct vnode *vp, struct vnode *rdir,
- char *buf, char **retbuf, u_int buflen);
+ char *buf, char **retbuf, size_t buflen);
static MALLOC_DEFINE(M_VFSCACHE, "vfscache", "VFS name cache entries");
@@ -2293,7 +2293,7 @@ vn_fullpath_global(struct thread *td, struct vnode *vn
}
int
-vn_vptocnp(struct vnode **vp, struct ucred *cred, char *buf, u_int *buflen)
+vn_vptocnp(struct vnode **vp, struct ucred *cred, char *buf, size_t *buflen)
{
struct vnode *dvp;
struct namecache *ncp;
@@ -2359,7 +2359,7 @@ vn_vptocnp(struct vnode **vp, struct ucred *cred, char
*/
static int
vn_fullpath1(struct thread *td, struct vnode *vp, struct vnode *rdir,
- char *buf, char **retbuf, u_int buflen)
+ char *buf, char **retbuf, size_t buflen)
{
int error, slash_prefixed;
#ifdef KDTRACE_HOOKS
Modified: head/sys/kern/vfs_default.c
==============================================================================
--- head/sys/kern/vfs_default.c Sat Feb 1 20:33:23 2020 (r357382)
+++ head/sys/kern/vfs_default.c Sat Feb 1 20:34:43 2020 (r357383)
@@ -804,7 +804,7 @@ vop_stdvptocnp(struct vop_vptocnp_args *ap)
struct vnode **dvp = ap->a_vpp;
struct ucred *cred = ap->a_cred;
char *buf = ap->a_buf;
- int *buflen = ap->a_buflen;
+ size_t *buflen = ap->a_buflen;
char *dirbuf, *cpos;
int i, error, eofflag, dirbuflen, flags, locked, len, covered;
off_t off;
Modified: head/sys/kern/vnode_if.src
==============================================================================
--- head/sys/kern/vnode_if.src Sat Feb 1 20:33:23 2020 (r357382)
+++ head/sys/kern/vnode_if.src Sat Feb 1 20:34:43 2020 (r357383)
@@ -640,7 +640,7 @@ vop_vptocnp {
OUT struct vnode **vpp;
IN struct ucred *cred;
INOUT char *buf;
- INOUT int *buflen;
+ INOUT size_t *buflen;
};
Modified: head/sys/sys/vnode.h
==============================================================================
--- head/sys/sys/vnode.h Sat Feb 1 20:33:23 2020 (r357382)
+++ head/sys/sys/vnode.h Sat Feb 1 20:34:43 2020 (r357383)
@@ -631,7 +631,7 @@ int insmntque(struct vnode *vp, struct mount *mp);
u_quad_t init_va_filerev(void);
int speedup_syncer(void);
int vn_vptocnp(struct vnode **vp, struct ucred *cred, char *buf,
- u_int *buflen);
+ size_t *buflen);
int vn_fullpath(struct thread *td, struct vnode *vn,
char **retbuf, char **freebuf);
int vn_fullpath_global(struct thread *td, struct vnode *vn,
More information about the svn-src-all
mailing list