From 8ec442ae4c6577ed181682e534d4eef524e30b3c Mon Sep 17 00:00:00 2001 From: David Howells Date: Fri, 3 Apr 2009 16:42:42 +0100 Subject: 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 Acked-by: Steve Dickson Acked-by: Trond Myklebust Acked-by: Al Viro Tested-by: Daire Byrne --- fs/nfs/fscache.h | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 fs/nfs/fscache.h (limited to 'fs/nfs/fscache.h') diff --git a/fs/nfs/fscache.h b/fs/nfs/fscache.h new file mode 100644 index 00000000000..ccfcdc58066 --- /dev/null +++ b/fs/nfs/fscache.h @@ -0,0 +1,35 @@ +/* NFS filesystem cache interface definitions + * + * Copyright (C) 2008 Red Hat, Inc. All Rights Reserved. + * Written by David Howells (dhowells@redhat.com) + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public Licence + * as published by the Free Software Foundation; either version + * 2 of the Licence, or (at your option) any later version. + */ + +#ifndef _NFS_FSCACHE_H +#define _NFS_FSCACHE_H + +#include +#include +#include +#include + +#ifdef CONFIG_NFS_FSCACHE + +/* + * fscache-index.c + */ +extern struct fscache_netfs nfs_fscache_netfs; + +extern int nfs_fscache_register(void); +extern void nfs_fscache_unregister(void); + +#else /* CONFIG_NFS_FSCACHE */ +static inline int nfs_fscache_register(void) { return 0; } +static inline void nfs_fscache_unregister(void) {} + +#endif /* CONFIG_NFS_FSCACHE */ +#endif /* _NFS_FSCACHE_H */ -- cgit v1.2.3-70-g09d2