summaryrefslogtreecommitdiffstats
path: root/fs/msdos/namei.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>1995-11-14 08:00:00 +0000
committer <ralf@linux-mips.org>1995-11-14 08:00:00 +0000
commite7c2a72e2680827d6a733931273a93461c0d8d1b (patch)
treec9abeda78ef7504062bb2e816bcf3e3c9d680112 /fs/msdos/namei.c
parentec6044459060a8c9ce7f64405c465d141898548c (diff)
Import of Linux/MIPS 1.3.0
Diffstat (limited to 'fs/msdos/namei.c')
-rw-r--r--fs/msdos/namei.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/fs/msdos/namei.c b/fs/msdos/namei.c
index ad3b9c8bc..ee7a14e36 100644
--- a/fs/msdos/namei.c
+++ b/fs/msdos/namei.c
@@ -4,6 +4,10 @@
* Written 1992,1993 by Werner Almesberger
*/
+#ifdef MODULE
+#include <linux/module.h>
+#endif
+
#include <asm/segment.h>
#include <linux/sched.h>
@@ -13,6 +17,8 @@
#include <linux/string.h>
#include <linux/stat.h>
+#include "msbuffer.h"
+
#define PRINTK(x)
/* MS-DOS "device special files" */
@@ -107,6 +113,7 @@ static int msdos_find(struct inode *dir,const char *name,int len,
int msdos_lookup(struct inode *dir,const char *name,int len,
struct inode **result)
{
+ struct super_block *sb = dir->i_sb;
int ino,res;
struct msdos_dir_entry *de;
struct buffer_head *bh;
@@ -173,6 +180,7 @@ int msdos_lookup(struct inode *dir,const char *name,int len,
static int msdos_create_entry(struct inode *dir,char *name,int is_dir,
struct inode **result)
{
+ struct super_block *sb = dir->i_sb;
struct buffer_head *bh;
struct msdos_dir_entry *de;
int res,ino;
@@ -209,6 +217,7 @@ static int msdos_create_entry(struct inode *dir,char *name,int is_dir,
int msdos_create(struct inode *dir,const char *name,int len,int mode,
struct inode **result)
{
+ struct super_block *sb = dir->i_sb;
struct buffer_head *bh;
struct msdos_dir_entry *de;
char msdos_name[MSDOS_NAME];
@@ -256,6 +265,7 @@ static void dump_fat(struct super_block *sb,int start)
int msdos_mkdir(struct inode *dir,const char *name,int len,int mode)
{
+ struct super_block *sb = dir->i_sb;
struct buffer_head *bh;
struct msdos_dir_entry *de;
struct inode *inode,*dot;
@@ -313,6 +323,7 @@ mkdir_error:
static int msdos_empty(struct inode *dir)
{
+ struct super_block *sb = dir->i_sb;
loff_t pos;
struct buffer_head *bh;
struct msdos_dir_entry *de;
@@ -338,6 +349,7 @@ static int msdos_empty(struct inode *dir)
int msdos_rmdir(struct inode *dir,const char *name,int len)
{
+ struct super_block *sb = dir->i_sb;
int res,ino;
struct buffer_head *bh;
struct msdos_dir_entry *de;
@@ -379,6 +391,7 @@ static int msdos_unlinkx(
int len,
int nospc) /* Flag special file ? */
{
+ struct super_block *sb = dir->i_sb;
int res,ino;
struct buffer_head *bh;
struct msdos_dir_entry *de;
@@ -425,6 +438,7 @@ static int rename_same_dir(struct inode *old_dir,char *old_name,
struct inode *new_dir,char *new_name,struct buffer_head *old_bh,
struct msdos_dir_entry *old_de,int old_ino)
{
+ struct super_block *sb = old_dir->i_sb;
struct buffer_head *new_bh;
struct msdos_dir_entry *new_de;
struct inode *new_inode,*old_inode;
@@ -476,6 +490,7 @@ static int rename_diff_dir(struct inode *old_dir,char *old_name,
struct inode *new_dir,char *new_name,struct buffer_head *old_bh,
struct msdos_dir_entry *old_de,int old_ino)
{
+ struct super_block *sb = old_dir->i_sb;
struct buffer_head *new_bh,*free_bh,*dotdot_bh;
struct msdos_dir_entry *new_de,*free_de,*dotdot_de;
struct inode *old_inode,*new_inode,*free_inode,*dotdot_inode,*walk;
@@ -594,6 +609,7 @@ rename_done:
int msdos_rename(struct inode *old_dir,const char *old_name,int old_len,
struct inode *new_dir,const char *new_name,int new_len)
{
+ struct super_block *sb = old_dir->i_sb;
char old_msdos_name[MSDOS_NAME],new_msdos_name[MSDOS_NAME];
struct buffer_head *old_bh;
struct msdos_dir_entry *old_de;