summaryrefslogtreecommitdiffstats
path: root/arch/sparc64/kernel/sys_sparc32.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2000-05-12 21:05:59 +0000
committerRalf Baechle <ralf@linux-mips.org>2000-05-12 21:05:59 +0000
commitba2dacab305c598cd4c34a604f8e276bf5bab5ff (patch)
tree78670a0139bf4d5ace617b29b7eba82bbc74d602 /arch/sparc64/kernel/sys_sparc32.c
parentb77bf69998121e689c5e86cc5630d39a0a9ee6ca (diff)
Merge with Linux 2.3.99-pre7 and various other bits.
Diffstat (limited to 'arch/sparc64/kernel/sys_sparc32.c')
-rw-r--r--arch/sparc64/kernel/sys_sparc32.c30
1 files changed, 13 insertions, 17 deletions
diff --git a/arch/sparc64/kernel/sys_sparc32.c b/arch/sparc64/kernel/sys_sparc32.c
index 7bb75f4ae..657ceacaa 100644
--- a/arch/sparc64/kernel/sys_sparc32.c
+++ b/arch/sparc64/kernel/sys_sparc32.c
@@ -1,4 +1,4 @@
-/* $Id: sys_sparc32.c,v 1.145 2000/04/13 07:30:34 jj Exp $
+/* $Id: sys_sparc32.c,v 1.146 2000/05/09 04:48:34 davem Exp $
* sys_sparc32.c: Conversion between 32bit and 64bit native syscalls.
*
* Copyright (C) 1997,1998 Jakub Jelinek (jj@sunsite.mff.cuni.cz)
@@ -1584,25 +1584,23 @@ static int cp_new_stat32(struct inode *inode, struct stat32 *statbuf)
asmlinkage int sys32_newstat(char * filename, struct stat32 *statbuf)
{
- struct dentry *dentry;
+ struct nameidata nd;
int error;
lock_kernel();
- dentry = namei(filename);
-
- error = PTR_ERR(dentry);
- if (!IS_ERR(dentry)) {
- struct inode *inode = dentry->d_inode;
+ error = user_path_walk(filename, &nd);
+ if (!error) {
+ struct inode *inode = nd.dentry->d_inode;
if (inode->i_op &&
inode->i_op->revalidate)
- error = inode->i_op->revalidate(dentry);
+ error = inode->i_op->revalidate(nd.dentry);
else
error = 0;
if (!error)
error = cp_new_stat32(inode, statbuf);
- dput(dentry);
+ path_release(&nd);
}
unlock_kernel();
return error;
@@ -1610,25 +1608,23 @@ asmlinkage int sys32_newstat(char * filename, struct stat32 *statbuf)
asmlinkage int sys32_newlstat(char * filename, struct stat32 *statbuf)
{
- struct dentry *dentry;
+ struct nameidata nd;
int error;
lock_kernel();
- dentry = lnamei(filename);
-
- error = PTR_ERR(dentry);
- if (!IS_ERR(dentry)) {
- struct inode *inode = dentry->d_inode;
+ error = user_path_walk_link(filename, &nd);
+ if (!error) {
+ struct inode *inode = nd.dentry->d_inode;
if (inode->i_op &&
inode->i_op->revalidate)
- error = inode->i_op->revalidate(dentry);
+ error = inode->i_op->revalidate(nd.dentry);
else
error = 0;
if (!error)
error = cp_new_stat32(inode, statbuf);
- dput(dentry);
+ path_release(&nd);
}
unlock_kernel();
return error;