[pnfs] [PATCH] get state lock
Marc Eshel
eshel at almaden.ibm.com
Tue May 29 11:59:43 EDT 2007
Yes, only the first patch "no callback for DS" is required if you apply
the layout cache code. I just wanted to share the 2 patches with which I
was able to run pNFS again, including layout recall with the FSID option.
Marc.
Benny Halevy <bhalevy at panasas.com> wrote on 05/28/2007 10:35:20 PM:
> These locks are present in the nfsd_layout_cache patchset
> I sent out so no need for this patch if they are applied first.
>
> Benny
>
> Marc Eshel wrote:
> > From: Marc Eshel <eshel at almaden.ibm.com>
> >
> >
> > ---
> >
> > fs/nfsd/nfs4state.c | 4 ++++
> > 1 files changed, 4 insertions(+), 0 deletions(-)
> >
> > diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
> > index 3bfe338..08ca80e 100644
> > --- a/fs/nfsd/nfs4state.c
> > +++ b/fs/nfsd/nfs4state.c
> > @@ -4045,6 +4045,7 @@ int nfs4_pnfs_get_layout(struct super_bl
> >
> > dprintk("NFSD: nfs4_pnfs_get_layout\n");
> >
> > + nfs4_lock_state();
> > fp = find_file(ino);
> > if (!fp) {
> > fp = alloc_init_file(ino);
> > @@ -4113,6 +4114,7 @@ out:
> > if (fp)
> > put_nfs4_file(fp);
> >
> > + nfs4_unlock_state();
> > dprintk("pNFS %s: exit status %d \n", __FUNCTION__, status);
> > return status;
> > }
> > @@ -4128,6 +4130,7 @@ int nfs4_pnfs_return_layout(struct super
> >
> > dprintk("NFSD: nfs4_pnfs_return_layout\n");
> >
> > + nfs4_lock_state();
> > fp = find_file(ino);
> > if (!fp)
> > goto out;
> > @@ -4148,6 +4151,7 @@ int nfs4_pnfs_return_layout(struct super
> > }
> > put_nfs4_file(fp);
> > out:
> > + nfs4_unlock_state();
> > dprintk("pNFS %s: exit status %d \n", __FUNCTION__, status);
> > return status;
> > }
> > _______________________________________________
> > pNFS mailing list
> > pNFS at linux-nfs.org
> > http://linux-nfs.org/cgi-bin/mailman/listinfo/pnfs
>
More information about the pNFS
mailing list