Re: [PATCH 1/2] nfsd: make NFSv4 lease time per net

2012-11-28 Thread Stanislav Kinsbursky
28.11.2012 19:09, J. Bruce Fields пишет: On Tue, Nov 27, 2012 at 02:11:44PM +0300, Stanislav Kinsbursky wrote: diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c index dab350d..4930981 100644 --- a/fs/nfsd/nfsctl.c +++ b/fs/nfsd/nfsctl.c @@ -912,7 +912,8 @@ static ssize_t nfsd4_write_time(struct

Re: [PATCH 1/2] nfsd: make NFSv4 lease time per net

2012-11-28 Thread Stanislav Kinsbursky
28.11.2012 19:15, J. Bruce Fields пишет: On Wed, Nov 28, 2012 at 07:12:03PM +0400, Stanislav Kinsbursky wrote: 28.11.2012 19:09, J. Bruce Fields пишет: On Tue, Nov 27, 2012 at 02:11:44PM +0300, Stanislav Kinsbursky wrote: diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c index dab350d..4930981

[PATCH] nfsd: remove redundant declarations

2012-11-27 Thread Stanislav Kinsbursky
This is a cleanup patch. Functions nfsd_pool_stats_open() and nfsd_pool_stats_release() are declared in fs/nfsd/nfsd.h. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfsctl.c |3 --- 1 files changed, 0 insertions(+), 3 deletions(-) diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c index

[PATCH 2/2] nfsd: make NFSv4 grace time per net

2012-11-27 Thread Stanislav Kinsbursky
Grace time is a part of NFSv4 state engine, which is constructed per network namespace. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c |9 +++-- fs/nfsd/nfsctl.c|4 +++- fs/nfsd/nfsd.h |2 -- 4 files changed, 7 insertions(+), 9

[PATCH 1/2] nfsd: make NFSv4 lease time per net

2012-11-27 Thread Stanislav Kinsbursky
Lease time is a part of NFSv4 state engine, which is constructed per network namespace. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h|2 ++ fs/nfsd/nfs4callback.c |8 +--- fs/nfsd/nfs4state.c| 11 +-- fs/nfsd/nfs4xdr.c |4 +++- fs/nfsd

[PATCH 0/2] NFSd: NFSv4 state - lease and grace times per net

2012-11-27 Thread Stanislav Kinsbursky
This two variables are parts of NFSv4 state and should be containerized too. The following series implements... --- Stanislav Kinsbursky (2): nfsd: make NFSv4 lease time per net nfsd: make NFSv4 grace time per net fs/nfsd/netns.h|3 +++ fs/nfsd/nfs4callback.c |8

[PATCH 1/2] nfsd: make NFSv4 lease time per net

2012-11-27 Thread Stanislav Kinsbursky
Lease time is a part of NFSv4 state engine, which is constructed per network namespace. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h|2 ++ fs/nfsd/nfs4callback.c |8 +--- fs/nfsd/nfs4state.c| 11 +-- fs/nfsd/nfs4xdr.c

[PATCH 0/2] NFSd: NFSv4 state - lease and grace times per net

2012-11-27 Thread Stanislav Kinsbursky
This two variables are parts of NFSv4 state and should be containerized too. The following series implements... --- Stanislav Kinsbursky (2): nfsd: make NFSv4 lease time per net nfsd: make NFSv4 grace time per net fs/nfsd/netns.h|3 +++ fs/nfsd/nfs4callback.c |8

[PATCH 2/2] nfsd: make NFSv4 grace time per net

2012-11-27 Thread Stanislav Kinsbursky
Grace time is a part of NFSv4 state engine, which is constructed per network namespace. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c |9 +++-- fs/nfsd/nfsctl.c|4 +++- fs/nfsd/nfsd.h |2 -- 4 files

[PATCH] nfsd: remove redundant declarations

2012-11-27 Thread Stanislav Kinsbursky
This is a cleanup patch. Functions nfsd_pool_stats_open() and nfsd_pool_stats_release() are declared in fs/nfsd/nfsd.h. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfsctl.c |3 --- 1 files changed, 0 insertions(+), 3 deletions(-) diff --git a/fs/nfsd/nfsctl.c b

[PATCH 2/2] nfsd: recovery - make in_grace per net

2012-11-26 Thread Stanislav Kinsbursky
Flag in_grace is a part of client tracking state, which is network namesapce aware. So let'a replace global static variable with per-net one. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4recover.c |9 - 2 files changed, 5 insertions(+), 5

[PATCH 1/2] nfsd: recovery - make rec_file per net

2012-11-26 Thread Stanislav Kinsbursky
Opening and closing of this file is done in client tracking init and exit operations. Client tracking is done in network namespace context already. So let's make this file opened and closed per network context - this will simlify it's management. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd

[PATCH 0/2] nfsd: containerise NFSv4 recovery state

2012-11-26 Thread Stanislav Kinsbursky
This patch set makes rec_file and in_grace global static variables allocated per network namespace. Both of them are a part of client tracking engine, which is containerised already. The following series implements... --- Stanislav Kinsbursky (2): nfsd: recovery - make rec_file per net

[PATCH 5/5] nfsd: call state init and shutdown twice

2012-11-26 Thread Stanislav Kinsbursky
Split NFSv4 state init and shutdown into two different calls: per-net one and generic one. Per-net cwinit/shutdown pair have to be called for any namespace, generic pair - only once on NSFd kthreads start and shutdown respectively. Refresh of diff-nfsd-call-state-init-twice ---

[PATCH 4/5] nfsd: cleanup NFSd state start a bit

2012-11-26 Thread Stanislav Kinsbursky
-by: Stanislav Kinsbursky --- fs/nfsd/nfs4state.c | 59 ++- 1 files changed, 35 insertions(+), 24 deletions(-) diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index edff2cc..72df721 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c

[PATCH 3/5] nfsd: cleanup NFSd state shutdown a bit

2012-11-26 Thread Stanislav Kinsbursky
This patch renames __nfs4_state_shutdown_net() into nfs4_state_shutdown_net(), __nfs4_state_shutdown() into nfs4_state_shutdown_net() and moves all network related shutdown operations to nfs4_state_shutdown_net(). Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4state.c | 19

[PATCH 2/5] nfsd: make delegations shutdown network namespace aware

2012-11-26 Thread Stanislav Kinsbursky
NFSv4 delegations are stored in global list. But they are nfs4_client dependent, which is network namespace aware already. State shutdown and laundromat are done per network namespace as well. So, delegations unhash have to be done in network namespace context. Signed-off-by: Stanislav Kinsbursky

[PATCH 1/5] nfsd: make client_lock per net

2012-11-26 Thread Stanislav Kinsbursky
This lock protects the client lru list and session hash table, which are allocated per network namespace already. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |3 ++ fs/nfsd/nfs4state.c | 73 ++- 2 files changed, 46 insertions

[PATCH 0/5] nfsd: more NFSv4 state containerization

2012-11-26 Thread Stanislav Kinsbursky
tdown". The following series implements... --- Stanislav Kinsbursky (5): nfsd: make client_lock per net nfsd: make delegations shutdown network namespace aware nfsd: cleanup NFSd state shutdown a bit nfsd: cleanup NFSd state start a bit nfsd: call state init and shutdown twice

[PATCH 0/5] nfsd: more NFSv4 state containerization

2012-11-26 Thread Stanislav Kinsbursky
series implements... --- Stanislav Kinsbursky (5): nfsd: make client_lock per net nfsd: make delegations shutdown network namespace aware nfsd: cleanup NFSd state shutdown a bit nfsd: cleanup NFSd state start a bit nfsd: call state init and shutdown twice fs/nfsd

[PATCH 1/5] nfsd: make client_lock per net

2012-11-26 Thread Stanislav Kinsbursky
This lock protects the client lru list and session hash table, which are allocated per network namespace already. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |3 ++ fs/nfsd/nfs4state.c | 73 ++- 2

[PATCH 2/5] nfsd: make delegations shutdown network namespace aware

2012-11-26 Thread Stanislav Kinsbursky
NFSv4 delegations are stored in global list. But they are nfs4_client dependent, which is network namespace aware already. State shutdown and laundromat are done per network namespace as well. So, delegations unhash have to be done in network namespace context. Signed-off-by: Stanislav Kinsbursky

[PATCH 3/5] nfsd: cleanup NFSd state shutdown a bit

2012-11-26 Thread Stanislav Kinsbursky
This patch renames __nfs4_state_shutdown_net() into nfs4_state_shutdown_net(), __nfs4_state_shutdown() into nfs4_state_shutdown_net() and moves all network related shutdown operations to nfs4_state_shutdown_net(). Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd

[PATCH 4/5] nfsd: cleanup NFSd state start a bit

2012-11-26 Thread Stanislav Kinsbursky
-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4state.c | 59 ++- 1 files changed, 35 insertions(+), 24 deletions(-) diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index edff2cc..72df721 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs

[PATCH 5/5] nfsd: call state init and shutdown twice

2012-11-26 Thread Stanislav Kinsbursky
Split NFSv4 state init and shutdown into two different calls: per-net one and generic one. Per-net cwinit/shutdown pair have to be called for any namespace, generic pair - only once on NSFd kthreads start and shutdown respectively. Refresh of diff-nfsd-call-state-init-twice ---

[PATCH 0/2] nfsd: containerise NFSv4 recovery state

2012-11-26 Thread Stanislav Kinsbursky
This patch set makes rec_file and in_grace global static variables allocated per network namespace. Both of them are a part of client tracking engine, which is containerised already. The following series implements... --- Stanislav Kinsbursky (2): nfsd: recovery - make rec_file per net

[PATCH 1/2] nfsd: recovery - make rec_file per net

2012-11-26 Thread Stanislav Kinsbursky
Opening and closing of this file is done in client tracking init and exit operations. Client tracking is done in network namespace context already. So let's make this file opened and closed per network context - this will simlify it's management. Signed-off-by: Stanislav Kinsbursky skinsbur

[PATCH 2/2] nfsd: recovery - make in_grace per net

2012-11-26 Thread Stanislav Kinsbursky
Flag in_grace is a part of client tracking state, which is network namesapce aware. So let'a replace global static variable with per-net one. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4recover.c |9 - 2 files changed

Re: [RFC PATCH v2 00/15] NFSd state containerization

2012-11-22 Thread Stanislav Kinsbursky
22.11.2012 00:44, J. Bruce Fields пишет: On Thu, Nov 15, 2012 at 01:34:08PM -0500, Jeff Layton wrote: On Wed, 14 Nov 2012 17:00:36 -0500 "J. Bruce Fields" wrote: On Wed, Nov 14, 2012 at 06:20:59PM +0300, Stanislav Kinsbursky wrote: This patch set is my first attempt to containe

Re: [RFC PATCH v2 00/15] NFSd state containerization

2012-11-22 Thread Stanislav Kinsbursky
22.11.2012 00:44, J. Bruce Fields пишет: On Thu, Nov 15, 2012 at 01:34:08PM -0500, Jeff Layton wrote: On Wed, 14 Nov 2012 17:00:36 -0500 J. Bruce Fields bfie...@fieldses.org wrote: On Wed, Nov 14, 2012 at 06:20:59PM +0300, Stanislav Kinsbursky wrote: This patch set is my first attempt

[PATCH] nfsd4: remove state lock from nfs4_state_shutdown

2012-11-21 Thread Stanislav Kinsbursky
t require state lock protection, because all NFSd kthreads are dead, and no race can happen with NFSd start, because "nfsd_up" flag is still set. Moreover, all Nfsd shutdown is protected with global nfsd_mutex. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4state.c |2 -- 1 files changed

[PATCH] nfsd4: remove state lock from nfs4_state_shutdown

2012-11-21 Thread Stanislav Kinsbursky
, because all NFSd kthreads are dead, and no race can happen with NFSd start, because nfsd_up flag is still set. Moreover, all Nfsd shutdown is protected with global nfsd_mutex. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4state.c |2 -- 1 files changed, 0

Re: [RFC PATCH v2 00/15] NFSd state containerization

2012-11-15 Thread Stanislav Kinsbursky
15.11.2012 02:00, J. Bruce Fields пишет: On Wed, Nov 14, 2012 at 06:20:59PM +0300, Stanislav Kinsbursky wrote: This patch set is my first attempt to containerize NFSv4 state - i.e. make it works in networks namespace context. I admit, that some of this new code could be partially rewritten

Re: [PATCH v3] SUNRPC: set desired file system root before connecting local transports

2012-11-15 Thread Stanislav Kinsbursky
15.11.2012 01:01, J. Bruce Fields пишет: On Mon, Nov 12, 2012 at 12:37:54PM +0400, Stanislav Kinsbursky wrote: 07.11.2012 22:33, J. Bruce Fields пишет: On Tue, Nov 06, 2012 at 08:36:05AM -0500, J. Bruce Fields wrote: On Tue, Nov 06, 2012 at 08:10:18AM -0500, Christoph Hellwig wrote: On Tue

Re: [PATCH v3] SUNRPC: set desired file system root before connecting local transports

2012-11-15 Thread Stanislav Kinsbursky
15.11.2012 01:01, J. Bruce Fields пишет: On Mon, Nov 12, 2012 at 12:37:54PM +0400, Stanislav Kinsbursky wrote: 07.11.2012 22:33, J. Bruce Fields пишет: On Tue, Nov 06, 2012 at 08:36:05AM -0500, J. Bruce Fields wrote: On Tue, Nov 06, 2012 at 08:10:18AM -0500, Christoph Hellwig wrote: On Tue

Re: [RFC PATCH v2 00/15] NFSd state containerization

2012-11-15 Thread Stanislav Kinsbursky
15.11.2012 02:00, J. Bruce Fields пишет: On Wed, Nov 14, 2012 at 06:20:59PM +0300, Stanislav Kinsbursky wrote: This patch set is my first attempt to containerize NFSv4 state - i.e. make it works in networks namespace context. I admit, that some of this new code could be partially rewritten

[PATCH v2 04/15] nfsd: make conf_id_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 75 +-- 2 files changed, 55 insertions(+), 21 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 49e5479..0cc85e9 100644 --- a/fs/nfsd/netns.h +++ b

[PATCH v2 10/15] nfsd: make sessionid_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
and thus don't waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |3 +++ fs/nfsd/nfs4state.c | 28 +--- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 2281f6d

[PATCH v2 09/15] nfsd: make lockowner_ino_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 27 --- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 46cca94..2281f6d 100644

[PATCH v2 01/15] nfsd: use service net instead of hard-coded net where possible

2012-11-14 Thread Stanislav Kinsbursky
Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4state.c | 10 +- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index 37b19f7..743c622 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c @@ -2281,7 +2281,7

[PATCH v2 15/15] nfsd: make laundromat network namespace aware

2012-11-14 Thread Stanislav Kinsbursky
This patch moves laundromat_work to nfsd per-net context, thus allowing to run multiple laundries. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |2 ++ fs/nfsd/nfs4state.c | 21 + 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/fs/nfsd

[PATCH v2 12/15] nfsd: make close_lru list per net

2012-11-14 Thread Stanislav Kinsbursky
This list holds nfs4 clients (open) stateowner queue for last close replay, which are network namespace aware. So let's make this list per network namespace too. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |6 ++ fs/nfsd/nfs4state.c | 20 +++- 2 files

[PATCH v2 14/15] nfsd: pass nfsd_net instead of net to grace enders

2012-11-14 Thread Stanislav Kinsbursky
Passing net context looks as overkill. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4recover.c | 14 ++ fs/nfsd/nfs4state.c |8 +++- fs/nfsd/state.h |2 +- 3 files changed, 10 insertions(+), 14 deletions(-) diff --git a/fs/nfsd/nfs4recover.c b/fs/nfsd

[PATCH v2 13/15] nfsd: use service net instead of hard-coded init_net

2012-11-14 Thread Stanislav Kinsbursky
This patch replaces init_net by SVC_NET(), where possible and also passes proper context to nested functions where required. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4proc.c | 13 +++ fs/nfsd/nfs4state.c | 63 +++ fs/nfsd

[PATCH v2 11/15] nfsd: make client_lru list per net

2012-11-14 Thread Stanislav Kinsbursky
This list holds nfs4 clients queue for lease renewal, which are network namespace aware. So let's make this list per network namespace too. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |5 + fs/nfsd/nfs4state.c | 16 2 files changed, 13 insertions(+), 8

[PATCH v2 07/15] nfsd: make unconf_name_tree per net

2012-11-14 Thread Stanislav Kinsbursky
This hash holds nfs4_clients info, which are network namespace aware. So let's make it allocated per network namespace. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 42 +++--- 2 files changed, 23 insertions

[PATCH v2 08/15] nfsd: make ownerstr_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 41 ++--- 2 files changed, 27 insertions(+), 15 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 1e76030

[PATCH v2 06/15] nfsd: make unconf_id_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 25 +++-- 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index afd9116..1ff781f 100644 --- a/fs/nfsd/netns.h +++ b/fs/nfsd/netns.h @@ -55,6

[PATCH v2 05/15] nfsd: make conf_name_tree per net

2012-11-14 Thread Stanislav Kinsbursky
This tree holds nfs4_clients info, which are network namespace aware. So let's make it per network namespace. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 31 --- 2 files changed, 20 insertions(+), 15 deletions

[PATCH v2 03/15] nfsd: make reclaim_str_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
This hash holds nfs4_clients info, which are network namespace aware. So let's make it allocated per network namespace. Note: this hash is used only by legacy tracker. So let's allocate hash in tracker init. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h | 12 ++ fs/nfsd

[PATCH v2 02/15] nfsd: make nfs4_client network namespace dependent

2012-11-14 Thread Stanislav Kinsbursky
And use it's net where possible. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4callback.c |2 +- fs/nfsd/nfs4recover.c |9 +++-- fs/nfsd/nfs4state.c| 15 +-- fs/nfsd/state.h|1 + 4 files changed, 14 insertions(+), 13 deletions(-) diff --git a/fs

[RFC PATCH v2 00/15] NFSd state containerization

2012-11-14 Thread Stanislav Kinsbursky
tracker stop. 4) Moving of client_lru and close_lru lists to per-net data. 5) Making lundromat network namespace aware. v2: 1) Rebased on current nfsd-next. 2) Legacy tracker init become clearer. The following series implements... --- Stanislav Kinsbursky (15): nfsd: use service net

Re: [PATCH 03/15] nfsd: make reclaim_str_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
14.11.2012 17:02, Jeff Layton пишет: On Tue, 13 Nov 2012 18:48:33 +0300 Stanislav Kinsbursky wrote: + +static int +nfs4_legacy_state_init(struct net *net) +{ + struct nfsd_net *nn = net_generic(net, nfsd_net_id); + int i; + + nn->reclaim_str_hashtbl = kmalloc(sizeof(str

Re: [PATCH 03/15] nfsd: make reclaim_str_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
14.11.2012 17:02, Jeff Layton пишет: On Tue, 13 Nov 2012 18:48:33 +0300 Stanislav Kinsbursky skinsbur...@parallels.com wrote: snip + +static int +nfs4_legacy_state_init(struct net *net) +{ + struct nfsd_net *nn = net_generic(net, nfsd_net_id); + int i; + + nn-reclaim_str_hashtbl

[RFC PATCH v2 00/15] NFSd state containerization

2012-11-14 Thread Stanislav Kinsbursky
tracker stop. 4) Moving of client_lru and close_lru lists to per-net data. 5) Making lundromat network namespace aware. v2: 1) Rebased on current nfsd-next. 2) Legacy tracker init become clearer. The following series implements... --- Stanislav Kinsbursky (15): nfsd: use service net

[PATCH v2 02/15] nfsd: make nfs4_client network namespace dependent

2012-11-14 Thread Stanislav Kinsbursky
And use it's net where possible. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4callback.c |2 +- fs/nfsd/nfs4recover.c |9 +++-- fs/nfsd/nfs4state.c| 15 +-- fs/nfsd/state.h|1 + 4 files changed, 14 insertions(+), 13

[PATCH v2 03/15] nfsd: make reclaim_str_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
This hash holds nfs4_clients info, which are network namespace aware. So let's make it allocated per network namespace. Note: this hash is used only by legacy tracker. So let's allocate hash in tracker init. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h

[PATCH v2 05/15] nfsd: make conf_name_tree per net

2012-11-14 Thread Stanislav Kinsbursky
This tree holds nfs4_clients info, which are network namespace aware. So let's make it per network namespace. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 31 --- 2 files changed, 20

[PATCH v2 06/15] nfsd: make unconf_id_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 25 +++-- 2 files changed, 16 insertions(+), 10 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index afd9116..1ff781f 100644 --- a/fs/nfsd/netns.h +++ b

[PATCH v2 08/15] nfsd: make ownerstr_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 41 ++--- 2 files changed, 27 insertions(+), 15 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd

[PATCH v2 07/15] nfsd: make unconf_name_tree per net

2012-11-14 Thread Stanislav Kinsbursky
This hash holds nfs4_clients info, which are network namespace aware. So let's make it allocated per network namespace. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 42 +++--- 2

[PATCH v2 11/15] nfsd: make client_lru list per net

2012-11-14 Thread Stanislav Kinsbursky
This list holds nfs4 clients queue for lease renewal, which are network namespace aware. So let's make this list per network namespace too. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |5 + fs/nfsd/nfs4state.c | 16 2 files

[PATCH v2 13/15] nfsd: use service net instead of hard-coded init_net

2012-11-14 Thread Stanislav Kinsbursky
This patch replaces init_net by SVC_NET(), where possible and also passes proper context to nested functions where required. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4proc.c | 13 +++ fs/nfsd/nfs4state.c | 63

[PATCH v2 14/15] nfsd: pass nfsd_net instead of net to grace enders

2012-11-14 Thread Stanislav Kinsbursky
Passing net context looks as overkill. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4recover.c | 14 ++ fs/nfsd/nfs4state.c |8 +++- fs/nfsd/state.h |2 +- 3 files changed, 10 insertions(+), 14 deletions(-) diff --git a/fs/nfsd

[PATCH v2 15/15] nfsd: make laundromat network namespace aware

2012-11-14 Thread Stanislav Kinsbursky
This patch moves laundromat_work to nfsd per-net context, thus allowing to run multiple laundries. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |2 ++ fs/nfsd/nfs4state.c | 21 + 2 files changed, 15 insertions(+), 8 deletions

[PATCH v2 12/15] nfsd: make close_lru list per net

2012-11-14 Thread Stanislav Kinsbursky
This list holds nfs4 clients (open) stateowner queue for last close replay, which are network namespace aware. So let's make this list per network namespace too. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |6 ++ fs/nfsd/nfs4state.c | 20

[PATCH v2 01/15] nfsd: use service net instead of hard-coded net where possible

2012-11-14 Thread Stanislav Kinsbursky
Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4state.c | 10 +- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index 37b19f7..743c622 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c

[PATCH v2 09/15] nfsd: make lockowner_ino_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 27 --- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h

[PATCH v2 10/15] nfsd: make sessionid_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
and thus don't waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |3 +++ fs/nfsd/nfs4state.c | 28 +--- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd

[PATCH v2 04/15] nfsd: make conf_id_hashtbl allocated per net

2012-11-14 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 75 +-- 2 files changed, 55 insertions(+), 21 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 49e5479..0cc85e9 100644

[PATCH 02/15] nfsd: make nfs4_client network namespace dependent

2012-11-13 Thread Stanislav Kinsbursky
And use it's net where possible. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4callback.c |2 +- fs/nfsd/nfs4recover.c |9 +++-- fs/nfsd/nfs4state.c| 15 +-- fs/nfsd/state.h|1 + 4 files changed, 14 insertions(+), 13 deletions(-) diff --git a/fs

[PATCH 07/15] nfsd: make unconf_str_hastbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |3 +++ fs/nfsd/nfs4state.c | 27 ++- 2 files changed, 17 insertions(+), 13 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 0577780..ad08208 100644 --- a/fs/nfsd/netns.h +++ b/fs/nfsd/netns.h

[PATCH 10/15] nfsd: make sessionid_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
and thus don't waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |3 +++ fs/nfsd/nfs4state.c | 28 +--- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index f7a6b87

[PATCH 13/15] nfsd: use service net instead of hard-coded init_net

2012-11-13 Thread Stanislav Kinsbursky
This patch replaces init_net by SVC_NET(), where possible and also passes proper context to nested functions where required. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4proc.c | 13 +++ fs/nfsd/nfs4state.c | 63 +++ fs/nfsd

[PATCH 15/15] nfsd: make laundromat network namespace aware

2012-11-13 Thread Stanislav Kinsbursky
This patch moves laundromat_work to nfsd per-net context, thus allowing to run multiple laundries. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |2 ++ fs/nfsd/nfs4state.c | 21 + 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/fs/nfsd

[PATCH 14/15] nfsd: pass nfsd_net instead of net to grace enders

2012-11-13 Thread Stanislav Kinsbursky
Passing net context looks as overkill. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4recover.c | 12 +--- fs/nfsd/nfs4state.c |8 +++- fs/nfsd/state.h |2 +- 3 files changed, 9 insertions(+), 13 deletions(-) diff --git a/fs/nfsd/nfs4recover.c b/fs/nfsd

[PATCH 12/15] nfsd: make close_lru list per net

2012-11-13 Thread Stanislav Kinsbursky
This list holds nfs4 clients (open) stateowner queue for last close replay, which are network namespace aware. So let's make this list per network namespace too. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 18 +++--- 2 files

[PATCH 11/15] nfsd: make client_lru list per net

2012-11-13 Thread Stanislav Kinsbursky
This list holds nfs4 clients queue for lease renewal, which are network namespace aware. So let's make this list per network namespace too. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |5 + fs/nfsd/nfs4state.c | 16 2 files changed, 13 insertions(+), 8

[PATCH 09/15] nfsd: make lockowner_ino_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 27 --- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 70f28f1..f7a6b87 100644

[PATCH 06/15] nfsd: make unconf_str_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 34 +++--- 2 files changed, 20 insertions(+), 15 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 61f41c0..0577780 100644 --- a/fs/nfsd/netns.h +++ b/fs/nfsd/netns.h

[PATCH 08/15] nfsd: make ownerstr_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 41 ++--- 2 files changed, 27 insertions(+), 15 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index ad08208

[PATCH 05/15] nfsd: make conf_str_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |5 + fs/nfsd/nfs4recover.c |2 +- fs/nfsd/nfs4state.c | 40 fs/nfsd/state.h |2 +- 4 files changed, 31 insertions(+), 18 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd

[PATCH 04/15] nfsd: make conf_id_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 73 ++- 2 files changed, 56 insertions(+), 18 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 49e5479..0cc85e9 100644 --- a/fs/nfsd/netns.h +++ b

[PATCH 03/15] nfsd: make reclaim_str_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
This hash holds nfs4_clients info, which are network namespace aware. So let's make it allocated per network namespace. Note: this hash is used only by legacy tracker. So let's allocate hash in tracker init. Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/netns.h | 12 + fs

[PATCH 01/15] nfsd: use service net instead of hard-coded net where possible

2012-11-13 Thread Stanislav Kinsbursky
Signed-off-by: Stanislav Kinsbursky --- fs/nfsd/nfs4state.c | 10 +- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index d6b602a..6a3661b 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c @@ -2257,7 +2257,7

[RFC PATCH 00/15] NFSd state containerization

2012-11-13 Thread Stanislav Kinsbursky
tracker stop. 4) Moving of client_lru and close_lru lists to per-net data. 5) Making lundromat network namespace aware. The following series implements... --- Stanislav Kinsbursky (15): nfsd: use service net instead of hard-coded net where possible nfsd: make nfs4_client network

[RFC PATCH 00/15] NFSd state containerization

2012-11-13 Thread Stanislav Kinsbursky
tracker stop. 4) Moving of client_lru and close_lru lists to per-net data. 5) Making lundromat network namespace aware. The following series implements... --- Stanislav Kinsbursky (15): nfsd: use service net instead of hard-coded net where possible nfsd: make nfs4_client network

[PATCH 01/15] nfsd: use service net instead of hard-coded net where possible

2012-11-13 Thread Stanislav Kinsbursky
Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4state.c | 10 +- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index d6b602a..6a3661b 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c

[PATCH 03/15] nfsd: make reclaim_str_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
This hash holds nfs4_clients info, which are network namespace aware. So let's make it allocated per network namespace. Note: this hash is used only by legacy tracker. So let's allocate hash in tracker init. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h

[PATCH 04/15] nfsd: make conf_id_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 73 ++- 2 files changed, 56 insertions(+), 18 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 49e5479..0cc85e9 100644

[PATCH 05/15] nfsd: make conf_str_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |5 + fs/nfsd/nfs4recover.c |2 +- fs/nfsd/nfs4state.c | 40 fs/nfsd/state.h |2 +- 4 files changed, 31 insertions(+), 18 deletions(-) diff --git a/fs

[PATCH 06/15] nfsd: make unconf_str_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 34 +++--- 2 files changed, 20 insertions(+), 15 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h index 61f41c0..0577780 100644 --- a/fs/nfsd

[PATCH 08/15] nfsd: make ownerstr_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |1 + fs/nfsd/nfs4state.c | 41 ++--- 2 files changed, 27 insertions(+), 15 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd

[PATCH 09/15] nfsd: make lockowner_ino_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 27 --- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd/netns.h

[PATCH 11/15] nfsd: make client_lru list per net

2012-11-13 Thread Stanislav Kinsbursky
This list holds nfs4 clients queue for lease renewal, which are network namespace aware. So let's make this list per network namespace too. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |5 + fs/nfsd/nfs4state.c | 16 2 files

[PATCH 12/15] nfsd: make close_lru list per net

2012-11-13 Thread Stanislav Kinsbursky
This list holds nfs4 clients (open) stateowner queue for last close replay, which are network namespace aware. So let's make this list per network namespace too. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |4 fs/nfsd/nfs4state.c | 18

[PATCH 15/15] nfsd: make laundromat network namespace aware

2012-11-13 Thread Stanislav Kinsbursky
This patch moves laundromat_work to nfsd per-net context, thus allowing to run multiple laundries. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |2 ++ fs/nfsd/nfs4state.c | 21 + 2 files changed, 15 insertions(+), 8 deletions

[PATCH 13/15] nfsd: use service net instead of hard-coded init_net

2012-11-13 Thread Stanislav Kinsbursky
This patch replaces init_net by SVC_NET(), where possible and also passes proper context to nested functions where required. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4proc.c | 13 +++ fs/nfsd/nfs4state.c | 63

[PATCH 10/15] nfsd: make sessionid_hashtbl allocated per net

2012-11-13 Thread Stanislav Kinsbursky
and thus don't waste resources if server is not running. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/netns.h |3 +++ fs/nfsd/nfs4state.c | 28 +--- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/fs/nfsd/netns.h b/fs/nfsd

[PATCH 14/15] nfsd: pass nfsd_net instead of net to grace enders

2012-11-13 Thread Stanislav Kinsbursky
Passing net context looks as overkill. Signed-off-by: Stanislav Kinsbursky skinsbur...@parallels.com --- fs/nfsd/nfs4recover.c | 12 +--- fs/nfsd/nfs4state.c |8 +++- fs/nfsd/state.h |2 +- 3 files changed, 9 insertions(+), 13 deletions(-) diff --git a/fs/nfsd

<    1   2   3   4   5   6   7   8   >