aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs
diff options
context:
space:
mode:
authorChuck Lever <chuck.lever@oracle.com>2013-10-17 14:12:39 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2013-10-28 15:23:17 -0400
commitec011fe847347b40c60fdb5085f65227762e2e08 (patch)
treed3d19248060c1ff219013c10fa9cf5419fd4974c /fs/nfs
parent800c06a5bf497e0587ba8382a761f31a7825e2cd (diff)
NFS: Introduce a vector of migration recovery ops
The differences between minor version 0 and minor version 1 migration will be abstracted by the addition of a set of migration recovery ops. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs')
-rw-r--r--fs/nfs/nfs4_fs.h4
-rw-r--r--fs/nfs/nfs4proc.c10
2 files changed, 14 insertions, 0 deletions
diff --git a/fs/nfs/nfs4_fs.h b/fs/nfs/nfs4_fs.h
index fcae7289d557..4f48000b2b97 100644
--- a/fs/nfs/nfs4_fs.h
+++ b/fs/nfs/nfs4_fs.h
@@ -50,6 +50,7 @@ struct nfs4_minor_version_ops {
50 const struct nfs4_state_recovery_ops *reboot_recovery_ops; 50 const struct nfs4_state_recovery_ops *reboot_recovery_ops;
51 const struct nfs4_state_recovery_ops *nograce_recovery_ops; 51 const struct nfs4_state_recovery_ops *nograce_recovery_ops;
52 const struct nfs4_state_maintenance_ops *state_renewal_ops; 52 const struct nfs4_state_maintenance_ops *state_renewal_ops;
53 const struct nfs4_mig_recovery_ops *mig_recovery_ops;
53}; 54};
54 55
55#define NFS_SEQID_CONFIRMED 1 56#define NFS_SEQID_CONFIRMED 1
@@ -203,6 +204,9 @@ struct nfs4_state_maintenance_ops {
203 int (*renew_lease)(struct nfs_client *, struct rpc_cred *); 204 int (*renew_lease)(struct nfs_client *, struct rpc_cred *);
204}; 205};
205 206
207struct nfs4_mig_recovery_ops {
208};
209
206extern const struct dentry_operations nfs4_dentry_operations; 210extern const struct dentry_operations nfs4_dentry_operations;
207 211
208/* dir.c */ 212/* dir.c */
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index 259f8beb96a3..2aacd1357dc5 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -7881,6 +7881,14 @@ static const struct nfs4_state_maintenance_ops nfs41_state_renewal_ops = {
7881}; 7881};
7882#endif 7882#endif
7883 7883
7884static const struct nfs4_mig_recovery_ops nfs40_mig_recovery_ops = {
7885};
7886
7887#if defined(CONFIG_NFS_V4_1)
7888static const struct nfs4_mig_recovery_ops nfs41_mig_recovery_ops = {
7889};
7890#endif /* CONFIG_NFS_V4_1 */
7891
7884static const struct nfs4_minor_version_ops nfs_v4_0_minor_ops = { 7892static const struct nfs4_minor_version_ops nfs_v4_0_minor_ops = {
7885 .minor_version = 0, 7893 .minor_version = 0,
7886 .init_caps = NFS_CAP_READDIRPLUS 7894 .init_caps = NFS_CAP_READDIRPLUS
@@ -7896,6 +7904,7 @@ static const struct nfs4_minor_version_ops nfs_v4_0_minor_ops = {
7896 .reboot_recovery_ops = &nfs40_reboot_recovery_ops, 7904 .reboot_recovery_ops = &nfs40_reboot_recovery_ops,
7897 .nograce_recovery_ops = &nfs40_nograce_recovery_ops, 7905 .nograce_recovery_ops = &nfs40_nograce_recovery_ops,
7898 .state_renewal_ops = &nfs40_state_renewal_ops, 7906 .state_renewal_ops = &nfs40_state_renewal_ops,
7907 .mig_recovery_ops = &nfs40_mig_recovery_ops,
7899}; 7908};
7900 7909
7901#if defined(CONFIG_NFS_V4_1) 7910#if defined(CONFIG_NFS_V4_1)
@@ -7916,6 +7925,7 @@ static const struct nfs4_minor_version_ops nfs_v4_1_minor_ops = {
7916 .reboot_recovery_ops = &nfs41_reboot_recovery_ops, 7925 .reboot_recovery_ops = &nfs41_reboot_recovery_ops,
7917 .nograce_recovery_ops = &nfs41_nograce_recovery_ops, 7926 .nograce_recovery_ops = &nfs41_nograce_recovery_ops,
7918 .state_renewal_ops = &nfs41_state_renewal_ops, 7927 .state_renewal_ops = &nfs41_state_renewal_ops,
7928 .mig_recovery_ops = &nfs41_mig_recovery_ops,
7919}; 7929};
7920#endif 7930#endif
7921 7931