summaryrefslogtreecommitdiffstats
path: root/fs/nfs
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>1998-08-25 09:12:35 +0000
committerRalf Baechle <ralf@linux-mips.org>1998-08-25 09:12:35 +0000
commitc7fc24dc4420057f103afe8fc64524ebc25c5d37 (patch)
tree3682407a599b8f9f03fc096298134cafba1c9b2f /fs/nfs
parent1d793fade8b063fde3cf275bf1a5c2d381292cd9 (diff)
o Merge with Linux 2.1.116.
o New Newport console code. o New G364 console code.
Diffstat (limited to 'fs/nfs')
-rw-r--r--fs/nfs/Makefile6
-rw-r--r--fs/nfs/dir.c2
-rw-r--r--fs/nfs/file.c2
-rw-r--r--fs/nfs/inode.c19
-rw-r--r--fs/nfs/write.c4
5 files changed, 24 insertions, 9 deletions
diff --git a/fs/nfs/Makefile b/fs/nfs/Makefile
index df7fe151d..3171e8adc 100644
--- a/fs/nfs/Makefile
+++ b/fs/nfs/Makefile
@@ -1,11 +1,11 @@
#
-# Makefile for the linux nfs-filesystem routines.
+# Makefile for the Linux nfs filesystem routines.
#
# Note! Dependencies are done automagically by 'make dep', which also
# removes any old dependencies. DON'T put your own dependencies here
-# unless it's something special (ie not a .c file).
+# unless it's something special (not a .c file).
#
-# Note 2! The CFLAGS definitions are now in the main makefile...
+# Note 2! The CFLAGS definitions are now in the main makefile.
O_TARGET := nfs.o
O_OBJS := inode.o file.o read.o write.o dir.o symlink.o proc.o \
diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c
index 8d75f3b85..66b33161f 100644
--- a/fs/nfs/dir.c
+++ b/fs/nfs/dir.c
@@ -1106,7 +1106,7 @@ nfs_link(struct dentry *old_dentry, struct inode *dir, struct dentry *dentry)
/*
* Drop the dentry in advance to force a new lookup.
- * Since nfs_proc_link doesn't return a filehandle,
+ * Since nfs_proc_link doesn't return a file handle,
* we can't use the existing dentry.
*/
d_drop(dentry);
diff --git a/fs/nfs/file.c b/fs/nfs/file.c
index 4a575c48c..9ec883aff 100644
--- a/fs/nfs/file.c
+++ b/fs/nfs/file.c
@@ -202,7 +202,7 @@ out:
return result;
out_swapfile:
- printk("NFS: attempt to write to active swap file!\n");
+ printk(KERN_ERR "NFS: attempt to write to active swap file!\n");
goto out;
}
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
index d56e4e7e6..e89abdbce 100644
--- a/fs/nfs/inode.c
+++ b/fs/nfs/inode.c
@@ -43,6 +43,7 @@ static void nfs_put_inode(struct inode *);
static void nfs_delete_inode(struct inode *);
static int nfs_notify_change(struct dentry *, struct iattr *);
static void nfs_put_super(struct super_block *);
+static void nfs_umount_begin(struct super_block *);
static int nfs_statfs(struct super_block *, struct statfs *, int);
static struct super_operations nfs_sops = {
@@ -54,7 +55,9 @@ static struct super_operations nfs_sops = {
nfs_put_super, /* put superblock */
NULL, /* write superblock */
nfs_statfs, /* stat filesystem */
- NULL
+ NULL, /* no remount */
+ NULL, /* no clear inode */
+ nfs_umount_begin /* umount attempt begin */
};
struct rpc_stat nfs_rpcstat = { &nfs_program };
@@ -142,6 +145,17 @@ nfs_put_super(struct super_block *sb)
MOD_DEC_USE_COUNT;
}
+void
+nfs_umount_begin(struct super_block *sb)
+{
+ struct nfs_server *server = &sb->u.nfs_sb.s_server;
+ struct rpc_clnt *rpc;
+
+ /* -EIO all pending I/O */
+ if ((rpc = server->client) != NULL)
+ rpc_killall_tasks(rpc);
+}
+
/*
* Compute and set NFS server blocksize
*/
@@ -448,7 +462,7 @@ nfs_fhget(struct dentry *dentry, struct nfs_fh *fhandle,
dentry->d_parent->d_name.name, dentry->d_name.name,
fattr->fileid);
- /* Install the filehandle in the dentry */
+ /* Install the file handle in the dentry */
*((struct nfs_fh *) dentry->d_fsdata) = *fhandle;
#ifdef CONFIG_NFS_SNAPSHOT
@@ -464,6 +478,7 @@ nfs_fhget(struct dentry *dentry, struct nfs_fh *fhandle,
goto out;
inode->i_sb = sb;
inode->i_dev = sb->s_dev;
+ inode->i_flags = sb->s_flags;
inode->i_ino = fattr->fileid;
nfs_read_inode(inode);
nfs_fill_inode(inode, fattr);
diff --git a/fs/nfs/write.c b/fs/nfs/write.c
index 71bdcf645..c317f330b 100644
--- a/fs/nfs/write.c
+++ b/fs/nfs/write.c
@@ -19,10 +19,10 @@
* from the writeback list to the writelock list.
*
* Note: we must make sure never to confuse the inode passed in the
- * write_page request with the one in page->inode. As far as I understant
+ * write_page request with the one in page->inode. As far as I understand
* it, these are different when doing a swap-out.
*
- * To understand everything that goes one here and in the nfs read code,
+ * To understand everything that goes on here and in the NFS read code,
* one should be aware that a page is locked in exactly one of the following
* cases:
*