All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] nfsd: use nfs->ns.inum as net ID
@ 2017-11-06 13:46 Vasily Averin
  2017-11-06 14:51 ` J. Bruce Fields
  0 siblings, 1 reply; 2+ messages in thread
From: Vasily Averin @ 2017-11-06 13:46 UTC (permalink / raw)
  To: linux-nfs; +Cc: Jeff Layton, J. Bruce Fields

Publishing of net pointer is not safe,
let's use nfs->ns.inum instead

Signed-off-by: Vasily Averin <vvs@virtuozzo.com>
---
 fs/nfsd/nfs4state.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
index 0c04f81..e0bb0c6 100644
--- a/fs/nfsd/nfs4state.c
+++ b/fs/nfsd/nfs4state.c
@@ -7006,8 +7006,8 @@ nfs4_state_start_net(struct net *net)
 	nn->nfsd4_manager.block_opens = true;
 	locks_start_grace(net, &nn->nfsd4_manager);
 	nfsd4_client_tracking_init(net);
-	printk(KERN_INFO "NFSD: starting %ld-second grace period (net %p)\n",
-	       nn->nfsd4_grace, net);
+	printk(KERN_INFO "NFSD: starting %ld-second grace period (net %x)\n",
+	       nn->nfsd4_grace, net->ns.inum);
 	queue_delayed_work(laundry_wq, &nn->laundromat_work, nn->nfsd4_grace * HZ);
 	return 0;
 }
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] nfsd: use nfs->ns.inum as net ID
  2017-11-06 13:46 [PATCH] nfsd: use nfs->ns.inum as net ID Vasily Averin
@ 2017-11-06 14:51 ` J. Bruce Fields
  0 siblings, 0 replies; 2+ messages in thread
From: J. Bruce Fields @ 2017-11-06 14:51 UTC (permalink / raw)
  To: Vasily Averin; +Cc: linux-nfs, Jeff Layton

Thanks, applying for 4.15.--b.

On Mon, Nov 06, 2017 at 04:46:04PM +0300, Vasily Averin wrote:
> Publishing of net pointer is not safe,
> let's use nfs->ns.inum instead
> 
> Signed-off-by: Vasily Averin <vvs@virtuozzo.com>
> ---
>  fs/nfsd/nfs4state.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
> index 0c04f81..e0bb0c6 100644
> --- a/fs/nfsd/nfs4state.c
> +++ b/fs/nfsd/nfs4state.c
> @@ -7006,8 +7006,8 @@ nfs4_state_start_net(struct net *net)
>  	nn->nfsd4_manager.block_opens = true;
>  	locks_start_grace(net, &nn->nfsd4_manager);
>  	nfsd4_client_tracking_init(net);
> -	printk(KERN_INFO "NFSD: starting %ld-second grace period (net %p)\n",
> -	       nn->nfsd4_grace, net);
> +	printk(KERN_INFO "NFSD: starting %ld-second grace period (net %x)\n",
> +	       nn->nfsd4_grace, net->ns.inum);
>  	queue_delayed_work(laundry_wq, &nn->laundromat_work, nn->nfsd4_grace * HZ);
>  	return 0;
>  }
> -- 
> 2.7.4

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-11-06 14:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-11-06 13:46 [PATCH] nfsd: use nfs->ns.inum as net ID Vasily Averin
2017-11-06 14:51 ` J. Bruce Fields

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.