diff options
author | Andy Adamson <andros@netapp.com> | 2009-04-01 09:23:18 -0400 |
---|---|---|
committer | Benny Halevy <bhalevy@panasas.com> | 2009-06-17 17:11:34 -0400 |
commit | 5a0ffe544c54f62be99751e369f4d0f44bd5ee19 (patch) | |
tree | 893bfed85d389220b404f5fabcb4d15aa36c9624 /fs | |
parent | 343952fa5aac888934ffc203abed26a823400eb6 (diff) |
nfs41: Release backchannel resources associated with session
Frees the preallocated backchannel resources that are associated with
this session when the session is destroyed.
A backchannel is currently created once per session. Destroy the backchannel
only when the session is destroyed.
Signed-off-by: Ricardo Labiaga <ricardo.labiaga@netapp.com>
Signed-off-by: Andy Adamson<andros@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/nfs/nfs4proc.c | 6 | ||||
-rw-r--r-- | fs/nfs/super.c | 1 |
2 files changed, 6 insertions, 1 deletions
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 4213c8814997..5da939d577d5 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c | |||
@@ -49,6 +49,7 @@ | |||
49 | #include <linux/namei.h> | 49 | #include <linux/namei.h> |
50 | #include <linux/mount.h> | 50 | #include <linux/mount.h> |
51 | #include <linux/module.h> | 51 | #include <linux/module.h> |
52 | #include <linux/sunrpc/bc_xprt.h> | ||
52 | 53 | ||
53 | #include "nfs4_fs.h" | 54 | #include "nfs4_fs.h" |
54 | #include "delegation.h" | 55 | #include "delegation.h" |
@@ -4481,6 +4482,11 @@ struct nfs4_session *nfs4_alloc_session(struct nfs_client *clp) | |||
4481 | 4482 | ||
4482 | void nfs4_destroy_session(struct nfs4_session *session) | 4483 | void nfs4_destroy_session(struct nfs4_session *session) |
4483 | { | 4484 | { |
4485 | nfs4_proc_destroy_session(session); | ||
4486 | dprintk("%s Destroy backchannel for xprt %p\n", | ||
4487 | __func__, session->clp->cl_rpcclient->cl_xprt); | ||
4488 | xprt_destroy_backchannel(session->clp->cl_rpcclient->cl_xprt, | ||
4489 | NFS41_BC_MIN_CALLBACKS); | ||
4484 | nfs4_destroy_slot_table(session); | 4490 | nfs4_destroy_slot_table(session); |
4485 | kfree(session); | 4491 | kfree(session); |
4486 | } | 4492 | } |
diff --git a/fs/nfs/super.c b/fs/nfs/super.c index 73db6f8c145a..69804a8245f6 100644 --- a/fs/nfs/super.c +++ b/fs/nfs/super.c | |||
@@ -2488,7 +2488,6 @@ static void nfs4_kill_super(struct super_block *sb) | |||
2488 | dprintk("--> %s\n", __func__); | 2488 | dprintk("--> %s\n", __func__); |
2489 | nfs_super_return_all_delegations(sb); | 2489 | nfs_super_return_all_delegations(sb); |
2490 | kill_anon_super(sb); | 2490 | kill_anon_super(sb); |
2491 | |||
2492 | nfs4_renewd_prepare_shutdown(server); | 2491 | nfs4_renewd_prepare_shutdown(server); |
2493 | nfs_fscache_release_super_cookie(sb); | 2492 | nfs_fscache_release_super_cookie(sb); |
2494 | nfs_free_server(server); | 2493 | nfs_free_server(server); |