aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nfs/client.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nfs/client.c')
-rw-r--r--fs/nfs/client.c22
1 files changed, 9 insertions, 13 deletions
diff --git a/fs/nfs/client.c b/fs/nfs/client.c
index 0870d0d4efc0..855add62abc1 100644
--- a/fs/nfs/client.c
+++ b/fs/nfs/client.c
@@ -170,21 +170,17 @@ error_0:
170} 170}
171 171
172#ifdef CONFIG_NFS_V4 172#ifdef CONFIG_NFS_V4
173/*
174 * Clears/puts all minor version specific parts from an nfs_client struct
175 * reverting it to minorversion 0.
176 */
177static void nfs4_clear_client_minor_version(struct nfs_client *clp)
178{
179#ifdef CONFIG_NFS_V4_1 173#ifdef CONFIG_NFS_V4_1
180 if (nfs4_has_session(clp)) { 174static void nfs4_shutdown_session(struct nfs_client *clp)
175{
176 if (nfs4_has_session(clp))
181 nfs4_destroy_session(clp->cl_session); 177 nfs4_destroy_session(clp->cl_session);
182 clp->cl_session = NULL;
183 }
184
185 clp->cl_mvops = nfs_v4_minor_ops[0];
186#endif /* CONFIG_NFS_V4_1 */
187} 178}
179#else /* CONFIG_NFS_V4_1 */
180static void nfs4_shutdown_session(struct nfs_client *clp)
181{
182}
183#endif /* CONFIG_NFS_V4_1 */
188 184
189/* 185/*
190 * Destroy the NFS4 callback service 186 * Destroy the NFS4 callback service
@@ -199,7 +195,7 @@ static void nfs4_shutdown_client(struct nfs_client *clp)
199{ 195{
200 if (__test_and_clear_bit(NFS_CS_RENEWD, &clp->cl_res_state)) 196 if (__test_and_clear_bit(NFS_CS_RENEWD, &clp->cl_res_state))
201 nfs4_kill_renewd(clp); 197 nfs4_kill_renewd(clp);
202 nfs4_clear_client_minor_version(clp); 198 nfs4_shutdown_session(clp);
203 nfs4_destroy_callback(clp); 199 nfs4_destroy_callback(clp);
204 if (__test_and_clear_bit(NFS_CS_IDMAP, &clp->cl_res_state)) 200 if (__test_and_clear_bit(NFS_CS_IDMAP, &clp->cl_res_state))
205 nfs_idmap_delete(clp); 201 nfs_idmap_delete(clp);