From: Trond Myklebust <trond.myklebust@xxxxxxxxxxxxxxx> If there is a localio error, we want to manage the boot verifier in a similar fashion to how it is done on the server. Signed-off-by: Trond Myklebust <trond.myklebust@xxxxxxxxxxxxxxx> Signed-off-by: Mike Snitzer <snitzer@xxxxxxxxxx> --- fs/nfs/client.c | 3 +++ include/linux/nfs_fs_sb.h | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/fs/nfs/client.c b/fs/nfs/client.c index de77848ae654..dd3278dcfca8 100644 --- a/fs/nfs/client.c +++ b/fs/nfs/client.c @@ -178,6 +178,9 @@ struct nfs_client *nfs_alloc_client(const struct nfs_client_initdata *cl_init) clp->cl_max_connect = cl_init->max_connect ? cl_init->max_connect : 1; clp->cl_net = get_net(cl_init->net); + seqlock_init(&clp->cl_boot_lock); + ktime_get_real_ts64(&clp->cl_nfssvc_boot); + clp->cl_principal = "*"; clp->cl_xprtsec = cl_init->xprtsec; return clp; diff --git a/include/linux/nfs_fs_sb.h b/include/linux/nfs_fs_sb.h index 92de074e63b9..82a6f66fe1d0 100644 --- a/include/linux/nfs_fs_sb.h +++ b/include/linux/nfs_fs_sb.h @@ -125,6 +125,10 @@ struct nfs_client { struct net *cl_net; struct list_head pending_cb_stateids; struct rcu_head rcu; + + /* localio */ + struct timespec64 cl_nfssvc_boot; + seqlock_t cl_boot_lock; }; /* -- 2.44.0