[pnfs] CVS: nfsv4
Iyer, Rahul
Rahul.Iyer at netapp.com
Tue Aug 1 16:26:12 EDT 2006
Using the rpc_clnt struct gets the a reference to the counter, but the
rpc shutdown code forcefully causes the task to exit with -EIO.
Unfortunately, having a referennce does not help.
Incidentally, returning of delegations is also done in a similar fashion
(async call followed by a wait for its completion)
Regards
Rahul
-----Original Message-----
From: William A.(Andy) Adamson [mailto:andros at citi.umich.edu]
Sent: Tuesday, August 01, 2006 12:55 PM
To: Iyer, Rahul
Cc: Marc Eshel; Rahul Iyer (NetApp); pnfs at linux-nfs.org;
andros at citi.umich.edu
Subject: Re: [pnfs] CVS: nfsv4
> Hi,
> I mean the inode freeing routines, not the free_layout () call. Here's
> the problem...
> The xdr encode routine takes the inode as part of the arguments. It
> uses this to get the file handle for the PUTFH in the compound
> containing the LAYOUTRETURN. I agree, we could get the file handle
> earlier and then pass this down instead of the inode.
>
> But the other problem is that we need the rpc_clnt struct too. This is
> also present in the inode. We could extract this also, but we wind up
> in a race with umount. During umount, the rpc_shutdown_clients kills
> all outstanding rpc_clnt structs.
>
> So, here's my plan. I plan to make ir sort of async, but not exactly.
> I will issue the rpc asynchronously, but wait for it to complete.
> While this is not truly asynchronous, it avoids the races we have. It
> however, is slightly better than synchronous because the user can now
> interrupt it.
can't you hold a reference to the structures that you need while the
async rpc is in flight?
-->Andy
> Thanks
> Regards
> Rahul
>
>
> -----Original Message-----
> From: Marc Eshel [mailto:eshel at almaden.ibm.com]
> Sent: Tuesday, August 01, 2006 9:20 AM
> To: Iyer, Rahul
> Cc: Rahul Iyer (NetApp); pnfs at linux-nfs.org
> Subject: RE: [pnfs] CVS: nfsv4
>
> What exactly is the problem? Can't you remove the pointer
> current_layout from the inode (set it to NULL) and than you can either
> free it even before the async call or if you need it for some reason
> free it in rpc_call_done ?
> I think that this call should be async.
> Marc.
>
> pnfs-bounces at linux-nfs.org wrote on 07/31/2006 10:29:22 PM:
>
> > PFA the patch for the following commit.
> > Regards
> > Rahul
> >
> >
> > -----Original Message-----
> > From: Rahul Iyer (NetApp) [mailto:iyer at citi.umich.edu]
> > Sent: Monday, July 31, 2006 10:28 PM
> > To: pnfs at linux-nfs.org
> > Subject: [pnfs] CVS: nfsv4
> >
> > CVSROOT: /cvs
> > Module name: nfsv4
> > Changes by: iyer at citi. 2006/08/01 01:28:20
> >
> > Modified files:
> > cvs/pnfs/fs/nfs: nfs4proc.c
> >
> > Log message:
> > Making LAYOUTRETURN synchronous. Having LAYOUTRETURN be asynchronous
> > causes race condition between LAYOUTRETURN and the inode freeing
> > routines.
> >
> > _______________________________________________
> > pNFS mailing list
> > pNFS at linux-nfs.org
> > http://linux-nfs.org/cgi-bin/mailman/listinfo/pnfs
> > [attachment "diff" deleted by Marc Eshel/Almaden/IBM]
> > _______________________________________________
> > pNFS mailing list
> > pNFS at linux-nfs.org
> > http://linux-nfs.org/cgi-bin/mailman/listinfo/pnfs
> _______________________________________________
> pNFS mailing list
> pNFS at linux-nfs.org
> http://linux-nfs.org/cgi-bin/mailman/listinfo/pnfs
More information about the pNFS
mailing list