patch-2.1.78 linux/fs/ext2/symlink.c

Next file: linux/fs/fat/inode.c
Previous file: linux/fs/ext2/namei.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.77/linux/fs/ext2/symlink.c linux/fs/ext2/symlink.c
@@ -24,8 +24,8 @@
 #include <linux/mm.h>
 #include <linux/stat.h>
 
-static int ext2_readlink (struct inode *, char *, int);
-static struct dentry *ext2_follow_link(struct inode *, struct dentry *);
+static int ext2_readlink (struct dentry *, char *, int);
+static struct dentry *ext2_follow_link(struct dentry *, struct dentry *);
 
 /*
  * symlinks can't do much...
@@ -51,10 +51,12 @@
 	NULL			/* smap */
 };
 
-static struct dentry * ext2_follow_link(struct inode * inode, struct dentry *base)
+static struct dentry * ext2_follow_link(struct dentry * dentry,
+					struct dentry *base)
 {
-	int error;
+	struct inode *inode = dentry->d_inode;
 	struct buffer_head * bh = NULL;
+	int error;
 	char * link;
 
 	link = (char *) inode->u.ext2_i.i_data;
@@ -72,8 +74,9 @@
 	return base;
 }
 
-static int ext2_readlink (struct inode * inode, char * buffer, int buflen)
+static int ext2_readlink (struct dentry * dentry, char * buffer, int buflen)
 {
+	struct inode *inode = dentry->d_inode;
 	struct buffer_head * bh = NULL;
 	char * link;
 	int i;

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov