projects
/
unix-history
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
first cut for new proc & user structs (still need to put in new vnode calling
[unix-history]
/
usr
/
src
/
sys
/
ufs
/
ffs
/
ufs_vfsops.c
diff --git
a/usr/src/sys/ufs/ffs/ufs_vfsops.c
b/usr/src/sys/ufs/ffs/ufs_vfsops.c
index
73d8ccc
..
e8174fa
100644
(file)
--- a/
usr/src/sys/ufs/ffs/ufs_vfsops.c
+++ b/
usr/src/sys/ufs/ffs/ufs_vfsops.c
@@
-4,12
+4,12
@@
*
* %sccs.include.redist.c%
*
*
* %sccs.include.redist.c%
*
- * @(#)ufs_vfsops.c 7.5
0
(Berkeley) %G%
+ * @(#)ufs_vfsops.c 7.5
1
(Berkeley) %G%
*/
#include "param.h"
#include "systm.h"
*/
#include "param.h"
#include "systm.h"
-#include "
user
.h"
+#include "
namei
.h"
#include "proc.h"
#include "kernel.h"
#include "vnode.h"
#include "proc.h"
#include "kernel.h"
#include "vnode.h"
@@
-21,14
+21,15
@@
#include "ioctl.h"
#include "errno.h"
#include "malloc.h"
#include "ioctl.h"
#include "errno.h"
#include "malloc.h"
-#include "../ufs/quota.h"
-#include "../ufs/fs.h"
-#include "../ufs/ufsmount.h"
-#include "../ufs/inode.h"
#include "ioctl.h"
#include "disklabel.h"
#include "stat.h"
#include "ioctl.h"
#include "disklabel.h"
#include "stat.h"
+#include "quota.h"
+#include "fs.h"
+#include "ufsmount.h"
+#include "inode.h"
+
/*
* ufs vfs operations.
*/
/*
* ufs vfs operations.
*/
@@
-402,26
+403,25
@@
ufs_quotactl(mp, cmds, uid, arg)
uid_t uid;
caddr_t arg;
{
uid_t uid;
caddr_t arg;
{
- register struct nameidata *ndp = &u.u_nd;
struct ufsmount *ump = VFSTOUFS(mp);
struct ufsmount *ump = VFSTOUFS(mp);
- struct proc *p =
u.u_procp;
/* XXX */
+ struct proc *p =
curproc;
/* XXX */
int cmd, type, error;
#ifndef QUOTA
return (EOPNOTSUPP);
#else
if (uid == -1)
int cmd, type, error;
#ifndef QUOTA
return (EOPNOTSUPP);
#else
if (uid == -1)
- uid = p->p_ruid;
+ uid = p->p_
cred->p_
ruid;
cmd = cmds >> SUBCMDSHIFT;
switch (cmd) {
case Q_GETQUOTA:
case Q_SYNC:
cmd = cmds >> SUBCMDSHIFT;
switch (cmd) {
case Q_GETQUOTA:
case Q_SYNC:
- if (uid == p->p_ruid)
+ if (uid == p->p_
cred->p_
ruid)
break;
/* fall through */
default:
break;
/* fall through */
default:
- if (error = suser(
ndp->ni_cred, &u.u
_acflag))
+ if (error = suser(
p->p_ucred, &p->p
_acflag))
return (error);
}
return (error);
}
@@
-432,7
+432,7
@@
ufs_quotactl(mp, cmds, uid, arg)
switch (cmd) {
case Q_QUOTAON:
switch (cmd) {
case Q_QUOTAON:
- return (quotaon(
nd
p, mp, type, arg));
+ return (quotaon(p, mp, type, arg));
case Q_QUOTAOFF:
if (vfs_busy(mp))
case Q_QUOTAOFF:
if (vfs_busy(mp))
@@
-737,7
+737,7
@@
getmdev(devvpp, fname, ndp)
ndp->ni_nameiop = LOOKUP | FOLLOW;
ndp->ni_segflg = UIO_USERSPACE;
ndp->ni_dirp = fname;
ndp->ni_nameiop = LOOKUP | FOLLOW;
ndp->ni_segflg = UIO_USERSPACE;
ndp->ni_dirp = fname;
- if (error = namei(ndp
))
+ if (error = namei(ndp
, curproc)) /* XXX */
return (error);
vp = ndp->ni_vp;
if (vp->v_type != VBLK) {
return (error);
vp = ndp->ni_vp;
if (vp->v_type != VBLK) {