summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/isofs/cd9660/cd9660_node.c5
-rw-r--r--sys/msdosfs/msdosfs_denode.c5
-rw-r--r--sys/msdosfs/msdosfs_vnops.c22
-rw-r--r--sys/ntfs/ntfs_subr.c27
-rw-r--r--sys/ntfs/ntfs_subr.h10
-rw-r--r--sys/ntfs/ntfs_vfsops.c20
-rw-r--r--sys/ntfs/ntfs_vfsops.h4
-rw-r--r--sys/ntfs/ntfs_vnops.c10
-rw-r--r--sys/ufs/ext2fs/ext2fs_inode.c5
-rw-r--r--sys/ufs/ext2fs/ext2fs_vnops.c17
-rw-r--r--sys/ufs/ffs/ffs_vnops.c4
-rw-r--r--sys/ufs/ufs/ufs_extern.h4
-rw-r--r--sys/ufs/ufs/ufs_inode.c7
-rw-r--r--sys/ufs/ufs/ufs_vnops.c18
14 files changed, 64 insertions, 94 deletions
diff --git a/sys/isofs/cd9660/cd9660_node.c b/sys/isofs/cd9660/cd9660_node.c
index fb75945b676..25c652b1f9b 100644
--- a/sys/isofs/cd9660/cd9660_node.c
+++ b/sys/isofs/cd9660/cd9660_node.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cd9660_node.c,v 1.34 2018/05/27 06:02:14 visa Exp $ */
+/* $OpenBSD: cd9660_node.c,v 1.35 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: cd9660_node.c,v 1.17 1997/05/05 07:13:57 mycroft Exp $ */
/*-
@@ -182,7 +182,6 @@ cd9660_inactive(v)
{
struct vop_inactive_args *ap = v;
struct vnode *vp = ap->a_vp;
- struct proc *p = ap->a_p;
register struct iso_node *ip = VTOI(vp);
int error = 0;
@@ -198,7 +197,7 @@ cd9660_inactive(v)
* so that it can be reused immediately.
*/
if (ip->inode.iso_mode == 0)
- vrecycle(vp, p);
+ vrecycle(vp, ap->a_p);
return (error);
}
diff --git a/sys/msdosfs/msdosfs_denode.c b/sys/msdosfs/msdosfs_denode.c
index fff83726424..466ac47a0bc 100644
--- a/sys/msdosfs/msdosfs_denode.c
+++ b/sys/msdosfs/msdosfs_denode.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: msdosfs_denode.c,v 1.65 2020/01/20 23:21:56 claudio Exp $ */
+/* $OpenBSD: msdosfs_denode.c,v 1.66 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: msdosfs_denode.c,v 1.23 1997/10/17 11:23:58 ws Exp $ */
/*-
@@ -620,7 +620,6 @@ msdosfs_inactive(void *v)
struct vop_inactive_args *ap = v;
struct vnode *vp = ap->a_vp;
struct denode *dep = VTODE(vp);
- struct proc *p = ap->a_p;
int error;
#ifdef DIAGNOSTIC
extern int prtactive;
@@ -669,6 +668,6 @@ out:
vp->v_usecount, dep->de_Name[0]);
#endif
if (dep->de_Name[0] == SLOT_DELETED)
- vrecycle(vp, p);
+ vrecycle(vp, ap->a_p);
return (error);
}
diff --git a/sys/msdosfs/msdosfs_vnops.c b/sys/msdosfs/msdosfs_vnops.c
index c57265e3834..3d0ba67a31e 100644
--- a/sys/msdosfs/msdosfs_vnops.c
+++ b/sys/msdosfs/msdosfs_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: msdosfs_vnops.c,v 1.129 2020/02/20 16:56:52 visa Exp $ */
+/* $OpenBSD: msdosfs_vnops.c,v 1.130 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: msdosfs_vnops.c,v 1.63 1997/10/17 11:24:19 ws Exp $ */
/*-
@@ -185,15 +185,6 @@ msdosfs_mknod(void *v)
int
msdosfs_open(void *v)
{
-#if 0
- struct vop_open_args /* {
- struct vnode *a_vp;
- int a_mode;
- struct ucred *a_cred;
- struct proc *a_p;
- } */ *ap;
-#endif
-
return (0);
}
@@ -778,17 +769,6 @@ out:
int
msdosfs_ioctl(void *v)
{
-#if 0
- struct vop_ioctl_args /* {
- struct vnode *a_vp;
- uint32_t a_command;
- caddr_t a_data;
- int a_fflag;
- struct ucred *a_cred;
- struct proc *a_p;
- } */ *ap;
-#endif
-
return (ENOTTY);
}
diff --git a/sys/ntfs/ntfs_subr.c b/sys/ntfs/ntfs_subr.c
index 4e9a071b158..ad8f2af824f 100644
--- a/sys/ntfs/ntfs_subr.c
+++ b/sys/ntfs/ntfs_subr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ntfs_subr.c,v 1.50 2017/04/11 14:43:49 dhill Exp $ */
+/* $OpenBSD: ntfs_subr.c,v 1.51 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ntfs_subr.c,v 1.4 2003/04/10 21:37:32 jdolecek Exp $ */
/*-
@@ -218,7 +218,7 @@ ntfs_ntvattrget(struct ntfsmount *ntmp, struct ntnode *ip, u_int32_t type,
vget() */
error = ntfs_vgetex(ntmp->ntm_mountp, aalp->al_inumber,
NTFS_A_DATA, NULL, LK_EXCLUSIVE,
- VG_EXT, curproc, &newvp);
+ VG_EXT, &newvp);
if (error) {
printf("ntfs_ntvattrget: CAN'T VGET INO: %d\n",
aalp->al_inumber);
@@ -362,7 +362,7 @@ out:
* ntfs_ntput().
*/
int
-ntfs_ntget(struct ntnode *ip, struct proc *p)
+ntfs_ntget(struct ntnode *ip)
{
DPRINTF("ntfs_ntget: get ntnode %u: %p, usecount: %d\n",
ip->i_number, ip, ip->i_usecount);
@@ -382,8 +382,7 @@ ntfs_ntget(struct ntnode *ip, struct proc *p)
* ntnode returned locked
*/
int
-ntfs_ntlookup(struct ntfsmount *ntmp, ntfsino_t ino, struct ntnode **ipp,
- struct proc *p)
+ntfs_ntlookup(struct ntfsmount *ntmp, ntfsino_t ino, struct ntnode **ipp)
{
struct ntnode *ip;
@@ -391,7 +390,7 @@ ntfs_ntlookup(struct ntfsmount *ntmp, ntfsino_t ino, struct ntnode **ipp,
do {
if ((ip = ntfs_nthashlookup(ntmp->ntm_dev, ino)) != NULL) {
- ntfs_ntget(ip, p);
+ ntfs_ntget(ip);
DPRINTF("ntfs_ntlookup: ntnode %u: %p, usecount: %d\n",
ino, ip, ip->i_usecount);
*ipp = ip;
@@ -413,7 +412,7 @@ ntfs_ntlookup(struct ntfsmount *ntmp, ntfsino_t ino, struct ntnode **ipp,
/* init lock and lock the newborn ntnode */
rw_init(&ip->i_lock, "ntnode");
- ntfs_ntget(ip, p);
+ ntfs_ntget(ip);
ntfs_nthashins(ip);
@@ -434,7 +433,7 @@ ntfs_ntlookup(struct ntfsmount *ntmp, ntfsino_t ino, struct ntnode **ipp,
* ntnode should be locked on entry, and unlocked on return.
*/
void
-ntfs_ntput(struct ntnode *ip, struct proc *p)
+ntfs_ntput(struct ntnode *ip)
{
struct ntfsmount *ntmp = ip->i_mp;
struct ntvattr *vap;
@@ -823,7 +822,7 @@ ntfs_ntlookupattr(struct ntfsmount *ntmp, const char *name, int namelen,
*/
int
ntfs_ntlookupfile(struct ntfsmount *ntmp, struct vnode *vp,
- struct componentname *cnp, struct vnode **vpp, struct proc *p)
+ struct componentname *cnp, struct vnode **vpp)
{
struct fnode *fp = VTOF(vp);
struct ntnode *ip = FTONT(fp);
@@ -844,7 +843,7 @@ ntfs_ntlookupfile(struct ntfsmount *ntmp, struct vnode *vp,
int fullscan = 0;
struct ntfs_lookup_ctx *lookup_ctx = NULL, *tctx;
- error = ntfs_ntget(ip, p);
+ error = ntfs_ntget(ip);
if (error)
return (error);
@@ -961,7 +960,7 @@ ntfs_ntlookupfile(struct ntfsmount *ntmp, struct vnode *vp,
error = ntfs_vgetex(ntmp->ntm_mountp,
iep->ie_number, attrtype, attrname,
LK_EXCLUSIVE, VG_DONTLOADIN | VG_DONTVALIDFN,
- curproc, &nvp);
+ &nvp);
if (error)
goto fail;
@@ -1086,7 +1085,7 @@ fail:
free(tctx, M_TEMP, 0);
}
}
- ntfs_ntput(ip, p);
+ ntfs_ntput(ip);
return (error);
}
@@ -1142,7 +1141,7 @@ ntfs_ntreaddir(struct ntfsmount *ntmp, struct fnode *fp, u_int32_t num,
u_int32_t aoff, cnum;
DPRINTF("ntfs_ntreaddir: read ino: %u, num: %u\n", ip->i_number, num);
- error = ntfs_ntget(ip, p);
+ error = ntfs_ntget(ip);
if (error)
return (error);
@@ -1277,7 +1276,7 @@ fail:
ntfs_ntvattrrele(iavap);
if (bmp)
free(bmp, M_TEMP, 0);
- ntfs_ntput(ip, p);
+ ntfs_ntput(ip);
return (error);
}
diff --git a/sys/ntfs/ntfs_subr.h b/sys/ntfs/ntfs_subr.h
index ab342c69c25..3a7f22b0411 100644
--- a/sys/ntfs/ntfs_subr.h
+++ b/sys/ntfs/ntfs_subr.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: ntfs_subr.h,v 1.10 2016/09/01 08:40:39 natano Exp $ */
+/* $OpenBSD: ntfs_subr.h,v 1.11 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ntfs_subr.h,v 1.1 2002/12/23 17:38:33 jdolecek Exp $ */
/*-
@@ -94,10 +94,10 @@ int ntfs_loadntnode( struct ntfsmount *, struct ntnode * );
int ntfs_fget(struct ntfsmount *, struct ntnode *, int, char *, struct fnode **);
void ntfs_frele(struct fnode *);
int ntfs_ntreaddir(struct ntfsmount *, struct fnode *, u_int32_t, struct attr_indexentry **, struct proc *);
-int ntfs_ntlookupfile(struct ntfsmount *, struct vnode *, struct componentname *, struct vnode **, struct proc *);
-int ntfs_ntlookup(struct ntfsmount *, ntfsino_t, struct ntnode **, struct proc *);
-int ntfs_ntget(struct ntnode *, struct proc *);
-void ntfs_ntput(struct ntnode *, struct proc *);
+int ntfs_ntlookupfile(struct ntfsmount *, struct vnode *, struct componentname *, struct vnode **);
+int ntfs_ntlookup(struct ntfsmount *, ntfsino_t, struct ntnode **);
+int ntfs_ntget(struct ntnode *);
+void ntfs_ntput(struct ntnode *);
int ntfs_toupper_use(struct mount *, struct ntfsmount *, struct proc *);
void ntfs_toupper_unuse(struct proc *);
diff --git a/sys/ntfs/ntfs_vfsops.c b/sys/ntfs/ntfs_vfsops.c
index edeba10d332..efec7c0c741 100644
--- a/sys/ntfs/ntfs_vfsops.c
+++ b/sys/ntfs/ntfs_vfsops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ntfs_vfsops.c,v 1.63 2019/12/26 13:28:49 bluhm Exp $ */
+/* $OpenBSD: ntfs_vfsops.c,v 1.64 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ntfs_vfsops.c,v 1.7 2003/04/24 07:50:19 christos Exp $ */
/*-
@@ -628,7 +628,7 @@ ntfs_fhtovp(struct mount *mp, struct fid *fhp, struct vnode **vpp)
mp->mnt_stat.f_mntonname, ntfhp->ntfid_ino);
error = ntfs_vgetex(mp, ntfhp->ntfid_ino, ntfhp->ntfid_attr, NULL,
- LK_EXCLUSIVE | LK_RETRY, 0, curproc, vpp); /* XXX */
+ LK_EXCLUSIVE | LK_RETRY, 0, vpp); /* XXX */
if (error != 0) {
*vpp = NULLVP;
return (error);
@@ -663,7 +663,7 @@ ntfs_vptofh(struct vnode *vp, struct fid *fhp)
int
ntfs_vgetex(struct mount *mp, ntfsino_t ino, u_int32_t attrtype, char *attrname,
- u_long lkflags, u_long flags, struct proc *p, struct vnode **vpp)
+ u_long lkflags, u_long flags, struct vnode **vpp)
{
int error;
struct ntfsmount *ntmp;
@@ -679,7 +679,7 @@ ntfs_vgetex(struct mount *mp, ntfsino_t ino, u_int32_t attrtype, char *attrname,
*vpp = NULL;
/* Get ntnode */
- error = ntfs_ntlookup(ntmp, ino, &ip, p);
+ error = ntfs_ntlookup(ntmp, ino, &ip);
if (error) {
printf("ntfs_vget: ntfs_ntget failed\n");
return (error);
@@ -691,7 +691,7 @@ ntfs_vgetex(struct mount *mp, ntfsino_t ino, u_int32_t attrtype, char *attrname,
if(error) {
printf("ntfs_vget: CAN'T LOAD ATTRIBUTES FOR INO: %d\n",
ip->i_number);
- ntfs_ntput(ip, p);
+ ntfs_ntput(ip);
return (error);
}
@@ -700,7 +700,7 @@ ntfs_vgetex(struct mount *mp, ntfsino_t ino, u_int32_t attrtype, char *attrname,
error = ntfs_fget(ntmp, ip, attrtype, attrname, &fp);
if (error) {
printf("ntfs_vget: ntfs_fget failed\n");
- ntfs_ntput(ip, p);
+ ntfs_ntput(ip);
return (error);
}
@@ -718,7 +718,7 @@ ntfs_vgetex(struct mount *mp, ntfsino_t ino, u_int32_t attrtype, char *attrname,
error = ntfs_filesize(ntmp, fp,
&fp->f_size, &fp->f_allocated);
if (error) {
- ntfs_ntput(ip, p);
+ ntfs_ntput(ip);
return (error);
}
@@ -734,7 +734,7 @@ ntfs_vgetex(struct mount *mp, ntfsino_t ino, u_int32_t attrtype, char *attrname,
* ntfs_fget() bumped ntnode usecount, so ntnode won't be recycled
* prematurely.
*/
- ntfs_ntput(ip, p);
+ ntfs_ntput(ip);
if (FTOV(fp)) {
/* vget() returns error if the vnode has been recycled */
@@ -747,7 +747,7 @@ ntfs_vgetex(struct mount *mp, ntfsino_t ino, u_int32_t attrtype, char *attrname,
error = getnewvnode(VT_NTFS, ntmp->ntm_mountp, &ntfs_vops, &vp);
if(error) {
ntfs_frele(fp);
- ntfs_ntput(ip, p);
+ ntfs_ntput(ip);
return (error);
}
@@ -778,7 +778,7 @@ ntfs_vget(struct mount *mp, ino_t ino, struct vnode **vpp)
if (ino > (ntfsino_t)-1)
panic("ntfs_vget: alien ino_t %llu", (unsigned long long)ino);
return ntfs_vgetex(mp, ino, NTFS_A_DATA, NULL,
- LK_EXCLUSIVE | LK_RETRY, 0, curproc, vpp); /* XXX */
+ LK_EXCLUSIVE | LK_RETRY, 0, vpp); /* XXX */
}
const struct vfsops ntfs_vfsops = {
diff --git a/sys/ntfs/ntfs_vfsops.h b/sys/ntfs/ntfs_vfsops.h
index 0e8f46a4cb1..c06bf9473b6 100644
--- a/sys/ntfs/ntfs_vfsops.h
+++ b/sys/ntfs/ntfs_vfsops.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: ntfs_vfsops.h,v 1.3 2013/05/30 20:11:06 guenther Exp $ */
+/* $OpenBSD: ntfs_vfsops.h,v 1.4 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ntfs_vfsops.h,v 1.1 2002/12/23 17:38:34 jdolecek Exp $ */
/*-
@@ -36,5 +36,5 @@
#define VG_EXT 0x0004 /* This is not main record */
int ntfs_vgetex(struct mount *, ntfsino_t, u_int32_t, char *, u_long, u_long,
- struct proc *, struct vnode **);
+ struct vnode **);
int ntfs_calccfree(struct ntfsmount *, cn_t *);
diff --git a/sys/ntfs/ntfs_vnops.c b/sys/ntfs/ntfs_vnops.c
index dd83aea37e0..fa334e23c17 100644
--- a/sys/ntfs/ntfs_vnops.c
+++ b/sys/ntfs/ntfs_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ntfs_vnops.c,v 1.45 2020/01/20 23:21:56 claudio Exp $ */
+/* $OpenBSD: ntfs_vnops.c,v 1.46 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ntfs_vnops.c,v 1.6 2003/04/10 21:57:26 jdolecek Exp $ */
/*
@@ -208,7 +208,6 @@ ntfs_reclaim(void *v)
struct vnode *vp = ap->a_vp;
struct fnode *fp = VTOF(vp);
struct ntnode *ip = FTONT(fp);
- struct proc *p = ap->a_p;
int error;
DPRINTF("ntfs_reclaim: vnode: %p, ntnode: %u\n", vp, ip->i_number);
@@ -218,14 +217,14 @@ ntfs_reclaim(void *v)
vprint("ntfs_reclaim: pushing active", vp);
#endif
- if ((error = ntfs_ntget(ip, p)) != 0)
+ if ((error = ntfs_ntget(ip)) != 0)
return (error);
/* Purge old data structures associated with the inode. */
cache_purge(vp);
ntfs_frele(fp);
- ntfs_ntput(ip, p);
+ ntfs_ntput(ip);
vp->v_data = NULL;
@@ -531,7 +530,6 @@ ntfs_lookup(void *v)
struct ucred *cred = cnp->cn_cred;
int error;
int lockparent = cnp->cn_flags & LOCKPARENT;
- struct proc *p = cnp->cn_proc;
#if NTFS_DEBUG
int wantparent = cnp->cn_flags & (LOCKPARENT|WANTPARENT);
#endif
@@ -598,7 +596,7 @@ ntfs_lookup(void *v)
cnp->cn_flags &= ~PDIRUNLOCK;
}
} else {
- error = ntfs_ntlookupfile(ntmp, dvp, cnp, ap->a_vpp, p);
+ error = ntfs_ntlookupfile(ntmp, dvp, cnp, ap->a_vpp);
if (error) {
DPRINTF("ntfs_ntlookupfile: returned %d\n", error);
return (error);
diff --git a/sys/ufs/ext2fs/ext2fs_inode.c b/sys/ufs/ext2fs/ext2fs_inode.c
index dd025156d5e..f39f0bbe770 100644
--- a/sys/ufs/ext2fs/ext2fs_inode.c
+++ b/sys/ufs/ext2fs/ext2fs_inode.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ext2fs_inode.c,v 1.62 2019/07/25 01:43:21 cheloha Exp $ */
+/* $OpenBSD: ext2fs_inode.c,v 1.63 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ext2fs_inode.c,v 1.24 2001/06/19 12:59:18 wiz Exp $ */
/*
@@ -104,7 +104,6 @@ ext2fs_inactive(void *v)
struct vop_inactive_args *ap = v;
struct vnode *vp = ap->a_vp;
struct inode *ip = VTOI(vp);
- struct proc *p = ap->a_p;
struct timespec ts;
int error = 0;
#ifdef DIAGNOSTIC
@@ -138,7 +137,7 @@ out:
* so that it can be reused immediately.
*/
if (ip->i_e2din == NULL || ip->i_e2fs_dtime != 0)
- vrecycle(vp, p);
+ vrecycle(vp, ap->a_p);
return (error);
}
diff --git a/sys/ufs/ext2fs/ext2fs_vnops.c b/sys/ufs/ext2fs/ext2fs_vnops.c
index 273a59d0ffb..879518c071f 100644
--- a/sys/ufs/ext2fs/ext2fs_vnops.c
+++ b/sys/ufs/ext2fs/ext2fs_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ext2fs_vnops.c,v 1.86 2020/01/20 23:21:56 claudio Exp $ */
+/* $OpenBSD: ext2fs_vnops.c,v 1.87 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ext2fs_vnops.c,v 1.1 1997/06/11 09:34:09 bouyer Exp $ */
/*
@@ -70,8 +70,8 @@
#include <uvm/uvm_extern.h>
-static int ext2fs_chmod(struct vnode *, mode_t, struct ucred *, struct proc *);
-static int ext2fs_chown(struct vnode *, uid_t, gid_t, struct ucred *, struct proc *);
+static int ext2fs_chmod(struct vnode *, mode_t, struct ucred *);
+static int ext2fs_chown(struct vnode *, uid_t, gid_t, struct ucred *);
/*
* Create a regular file
@@ -218,7 +218,6 @@ ext2fs_setattr(void *v)
struct vnode *vp = ap->a_vp;
struct inode *ip = VTOI(vp);
struct ucred *cred = ap->a_cred;
- struct proc *p = ap->a_p;
int error;
/*
@@ -266,7 +265,7 @@ ext2fs_setattr(void *v)
if (vap->va_uid != (uid_t)VNOVAL || vap->va_gid != (gid_t)VNOVAL) {
if (vp->v_mount->mnt_flag & MNT_RDONLY)
return (EROFS);
- error = ext2fs_chown(vp, vap->va_uid, vap->va_gid, cred, p);
+ error = ext2fs_chown(vp, vap->va_uid, vap->va_gid, cred);
if (error)
return (error);
}
@@ -298,7 +297,7 @@ ext2fs_setattr(void *v)
if (cred->cr_uid != ip->i_e2fs_uid &&
(error = suser_ucred(cred)) &&
((vap->va_vaflags & VA_UTIMES_NULL) == 0 ||
- (error = VOP_ACCESS(vp, VWRITE, cred, p))))
+ (error = VOP_ACCESS(vp, VWRITE, cred, ap->a_p))))
return (error);
if (vap->va_mtime.tv_nsec != VNOVAL)
ip->i_flag |= IN_CHANGE | IN_UPDATE;
@@ -322,7 +321,7 @@ ext2fs_setattr(void *v)
if (vap->va_mode != (mode_t)VNOVAL) {
if (vp->v_mount->mnt_flag & MNT_RDONLY)
return (EROFS);
- error = ext2fs_chmod(vp, vap->va_mode, cred, p);
+ error = ext2fs_chmod(vp, vap->va_mode, cred);
}
return (error);
}
@@ -332,7 +331,7 @@ ext2fs_setattr(void *v)
* Inode must be locked before calling.
*/
static int
-ext2fs_chmod(struct vnode *vp, mode_t mode, struct ucred *cred, struct proc *p)
+ext2fs_chmod(struct vnode *vp, mode_t mode, struct ucred *cred)
{
struct inode *ip = VTOI(vp);
int error;
@@ -358,7 +357,7 @@ ext2fs_chmod(struct vnode *vp, mode_t mode, struct ucred *cred, struct proc *p)
* inode must be locked prior to call.
*/
static int
-ext2fs_chown(struct vnode *vp, uid_t uid, gid_t gid, struct ucred *cred, struct proc *p)
+ext2fs_chown(struct vnode *vp, uid_t uid, gid_t gid, struct ucred *cred)
{
struct inode *ip = VTOI(vp);
uid_t ouid;
diff --git a/sys/ufs/ffs/ffs_vnops.c b/sys/ufs/ffs/ffs_vnops.c
index 3c21187cf3c..82bde4d4256 100644
--- a/sys/ufs/ffs/ffs_vnops.c
+++ b/sys/ufs/ffs/ffs_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ffs_vnops.c,v 1.97 2020/01/24 13:01:29 kurt Exp $ */
+/* $OpenBSD: ffs_vnops.c,v 1.98 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ffs_vnops.c,v 1.7 1996/05/11 18:27:24 mycroft Exp $ */
/*
@@ -533,7 +533,7 @@ ffs_reclaim(void *v)
struct inode *ip = VTOI(vp);
int error;
- if ((error = ufs_reclaim(vp, ap->a_p)) != 0)
+ if ((error = ufs_reclaim(vp)) != 0)
return (error);
if (ip->i_din1 != NULL) {
diff --git a/sys/ufs/ufs/ufs_extern.h b/sys/ufs/ufs/ufs_extern.h
index 229d3c25501..967d6ab1e45 100644
--- a/sys/ufs/ufs/ufs_extern.h
+++ b/sys/ufs/ufs/ufs_extern.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: ufs_extern.h,v 1.36 2016/08/10 08:04:57 natano Exp $ */
+/* $OpenBSD: ufs_extern.h,v 1.37 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ufs_extern.h,v 1.5 1996/02/09 22:36:03 christos Exp $ */
/*-
@@ -106,7 +106,7 @@ void ufs_ihashrem(struct inode *);
/* ufs_inode.c */
int ufs_init(struct vfsconf *);
-int ufs_reclaim(struct vnode *, struct proc *);
+int ufs_reclaim(struct vnode *);
/* ufs_lookup.c */
void ufs_dirbad(struct inode *, doff_t, char *);
diff --git a/sys/ufs/ufs/ufs_inode.c b/sys/ufs/ufs/ufs_inode.c
index 7ac354e9316..cc3b8b83229 100644
--- a/sys/ufs/ufs/ufs_inode.c
+++ b/sys/ufs/ufs/ufs_inode.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ufs_inode.c,v 1.43 2018/04/28 03:13:05 visa Exp $ */
+/* $OpenBSD: ufs_inode.c,v 1.44 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ufs_inode.c,v 1.7 1996/05/11 18:27:52 mycroft Exp $ */
/*
@@ -62,7 +62,6 @@ ufs_inactive(void *v)
struct vop_inactive_args *ap = v;
struct vnode *vp = ap->a_vp;
struct inode *ip = VTOI(vp);
- struct proc *p = ap->a_p;
mode_t mode;
int error = 0;
#ifdef DIAGNOSTIC
@@ -118,7 +117,7 @@ out:
* so that it can be reused immediately.
*/
if (ip->i_din1 == NULL || DIP(ip, mode) == 0)
- vrecycle(vp, p);
+ vrecycle(vp, ap->a_p);
return (error);
}
@@ -127,7 +126,7 @@ out:
* Reclaim an inode so that it can be used for other purposes.
*/
int
-ufs_reclaim(struct vnode *vp, struct proc *p)
+ufs_reclaim(struct vnode *vp)
{
struct inode *ip;
#ifdef DIAGNOSTIC
diff --git a/sys/ufs/ufs/ufs_vnops.c b/sys/ufs/ufs/ufs_vnops.c
index 30f55bcf060..c623c9ba2a0 100644
--- a/sys/ufs/ufs/ufs_vnops.c
+++ b/sys/ufs/ufs/ufs_vnops.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ufs_vnops.c,v 1.148 2020/02/20 16:56:53 visa Exp $ */
+/* $OpenBSD: ufs_vnops.c,v 1.149 2020/02/27 09:10:31 mpi Exp $ */
/* $NetBSD: ufs_vnops.c,v 1.18 1996/05/11 18:28:04 mycroft Exp $ */
/*
@@ -72,8 +72,8 @@
#include <uvm/uvm_extern.h>
-int ufs_chmod(struct vnode *, int, struct ucred *, struct proc *);
-int ufs_chown(struct vnode *, uid_t, gid_t, struct ucred *, struct proc *);
+int ufs_chmod(struct vnode *, int, struct ucred *);
+int ufs_chown(struct vnode *, uid_t, gid_t, struct ucred *);
int filt_ufsread(struct knote *, long);
int filt_ufswrite(struct knote *, long);
int filt_ufsvnode(struct knote *, long);
@@ -339,7 +339,6 @@ ufs_setattr(void *v)
struct vnode *vp = ap->a_vp;
struct inode *ip = VTOI(vp);
struct ucred *cred = ap->a_cred;
- struct proc *p = ap->a_p;
int error;
long hint = NOTE_ATTRIB;
u_quad_t oldsize;
@@ -384,7 +383,7 @@ ufs_setattr(void *v)
if (vap->va_uid != (uid_t)VNOVAL || vap->va_gid != (gid_t)VNOVAL) {
if (vp->v_mount->mnt_flag & MNT_RDONLY)
return (EROFS);
- error = ufs_chown(vp, vap->va_uid, vap->va_gid, cred, p);
+ error = ufs_chown(vp, vap->va_uid, vap->va_gid, cred);
if (error)
return (error);
}
@@ -420,7 +419,7 @@ ufs_setattr(void *v)
!vnoperm(vp) &&
(error = suser_ucred(cred)) &&
((vap->va_vaflags & VA_UTIMES_NULL) == 0 ||
- (error = VOP_ACCESS(vp, VWRITE, cred, p))))
+ (error = VOP_ACCESS(vp, VWRITE, cred, ap->a_p))))
return (error);
if (vap->va_mtime.tv_nsec != VNOVAL)
ip->i_flag |= IN_CHANGE | IN_UPDATE;
@@ -448,7 +447,7 @@ ufs_setattr(void *v)
if (vap->va_mode != (mode_t)VNOVAL) {
if (vp->v_mount->mnt_flag & MNT_RDONLY)
return (EROFS);
- error = ufs_chmod(vp, (int)vap->va_mode, cred, p);
+ error = ufs_chmod(vp, (int)vap->va_mode, cred);
}
VN_KNOTE(vp, hint);
return (error);
@@ -459,7 +458,7 @@ ufs_setattr(void *v)
* Inode must be locked before calling.
*/
int
-ufs_chmod(struct vnode *vp, int mode, struct ucred *cred, struct proc *p)
+ufs_chmod(struct vnode *vp, int mode, struct ucred *cred)
{
struct inode *ip = VTOI(vp);
int error;
@@ -487,8 +486,7 @@ ufs_chmod(struct vnode *vp, int mode, struct ucred *cred, struct proc *p)
* inode must be locked prior to call.
*/
int
-ufs_chown(struct vnode *vp, uid_t uid, gid_t gid, struct ucred *cred,
- struct proc *p)
+ufs_chown(struct vnode *vp, uid_t uid, gid_t gid, struct ucred *cred)
{
struct inode *ip = VTOI(vp);
uid_t ouid;