> -----Original Message----- > From: Andy Adamson [mailto:androsadamson@xxxxxxxxx] > Sent: Thursday, October 11, 2012 1:51 PM > To: Myklebust, Trond > Cc: linux-nfs@xxxxxxxxxxxxxxx > Subject: Re: [PATCH] NFSv4.1: Kill nfs4_ds_disconnect() > > On Thu, Oct 11, 2012 at 12:51 PM, Trond Myklebust > <Trond.Myklebust@xxxxxxxxxx> wrote: > > There is nothing to prevent another thread from dereferencing > > ds->ds_clp during or after the call to nfs4_ds_disconnect(), and > > Oopsing due to the resulting NULL pointer. > > Yes. > > > > > Instead, we should just rely on filelayout_mark_devid_invalid() to > > keep us out of trouble by avoiding that deviceid. > > Why do we want to keep the connection and the nfs_client? For connection > retry? > The deviceid doesn't really want to keep the nfs_client, but I don't see how you can remove it safely in the current code. There is too much that relies on being able to dereference ds->ds_clp without any locking. As for the TCP connection: that is a property of the nfs_client and its RPC client, and as such should not be manipulated by pNFS. If there are other users, then they may be waiting for it to reconnect... -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html