Re: [RFC 05/11] nfsd: skip clients marked for renewal

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Dec 16, 2009 at 07:41:25PM +0200, Benny Halevy wrote:
> Signed-off-by: Benny Halevy <bhalevy@xxxxxxxxxxx>
> ---
>  fs/nfsd/nfs4state.c |    3 +++
>  1 files changed, 3 insertions(+), 0 deletions(-)
> 
> diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c
> index 16ccab3..15f4b63 100644
> --- a/fs/nfsd/nfs4state.c
> +++ b/fs/nfsd/nfs4state.c
> @@ -2613,6 +2613,9 @@ nfs4_laundromat(void)
>  				clientid_val = t;
>  			break;
>  		}
> +		/* skip clients marked for renewal */
> +		if (atomic_read(&clp->cl_state) == CL_STATE_RENEW)
> +			continue;

I may just not understand your locking scheme.

But how are concurrent expiriry and renewal handled?  Couldn't the state
be marked CL_STATE_RENEW after this check but before CL_STATE_EXPIRED is
set in the following expire_client()?  What happens then?

--b.

>  		dprintk("NFSD: purging unused client (clientid %08x)\n",
>  			clp->cl_clientid.cl_id);
>  		nfsd4_remove_clid_dir(clp);
> -- 
> 1.6.5.1
> 
--
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

[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux