aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/inode.c
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2009-04-03 16:42:42 +0100
committerDavid Howells <dhowells@redhat.com>2009-04-03 16:42:42 +0100
commit8ec442ae4c6577ed181682e534d4eef524e30b3c (patch)
tree44fb9013929f7227781525d1904ac16d6723ce6e /fs/nfs/inode.c
parentNFS: Permit local filesystem caching to be enabled for NFS (diff)
downloadlinux-dev-8ec442ae4c6577ed181682e534d4eef524e30b3c.tar.xz
linux-dev-8ec442ae4c6577ed181682e534d4eef524e30b3c.zip
NFS: Register NFS for caching and retrieve the top-level index
Register NFS for caching and retrieve the top-level cache index object cookie. Signed-off-by: David Howells <dhowells@redhat.com> Acked-by: Steve Dickson <steved@redhat.com> Acked-by: Trond Myklebust <Trond.Myklebust@netapp.com> Acked-by: Al Viro <viro@zeniv.linux.org.uk> Tested-by: Daire Byrne <Daire.Byrne@framestore.com>
Diffstat (limited to 'fs/nfs/inode.c')
-rw-r--r--fs/nfs/inode.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
index a834d1d850b7..cd29f410e941 100644
--- a/fs/nfs/inode.c
+++ b/fs/nfs/inode.c
@@ -46,6 +46,7 @@
#include "delegation.h"
#include "iostat.h"
#include "internal.h"
+#include "fscache.h"
#define NFSDBG_FACILITY NFSDBG_VFS
@@ -1436,6 +1437,10 @@ static int __init init_nfs_fs(void)
{
int err;
+ err = nfs_fscache_register();
+ if (err < 0)
+ goto out7;
+
err = nfsiod_start();
if (err)
goto out6;
@@ -1488,6 +1493,8 @@ out4:
out5:
nfsiod_stop();
out6:
+ nfs_fscache_unregister();
+out7:
return err;
}
@@ -1498,6 +1505,7 @@ static void __exit exit_nfs_fs(void)
nfs_destroy_readpagecache();
nfs_destroy_inodecache();
nfs_destroy_nfspagecache();
+ nfs_fscache_unregister();
#ifdef CONFIG_PROC_FS
rpc_proc_unregister("nfs");
#endif