Re: [PATCH 5/5] NFS: Combine nfs4_call_sync() with nfs4_call_sync_sequence()

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

 



On Fri, 2018-05-04 at 16:22 -0400, schumaker.anna@xxxxxxxxx wrote:
> From: Anna Schumaker <Anna.Schumaker@xxxxxxxxxx>
> 
> The nfs4_call_sync_sequence() version only hase a single user,
> nfs4_call_sync(), so let's just add in a call to nfs4_init_sequence()
> instead of needing to have another function just to do this.
> 
> Signed-off-by: Anna Schumaker <Anna.Schumaker@xxxxxxxxxx>
> ---
>  fs/nfs/nfs4proc.c | 25 ++++++++-----------------
>  1 file changed, 8 insertions(+), 17 deletions(-)
> 
> diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
> index 505f605dcac2..99d77f6e7e40 100644
> --- a/fs/nfs/nfs4proc.c
> +++ b/fs/nfs/nfs4proc.c
> @@ -993,11 +993,13 @@ static const struct rpc_call_ops
> nfs40_call_sync_ops = {
>  	.rpc_call_done = nfs40_call_sync_done,
>  };
>  
> -static int nfs4_call_sync_sequence(struct rpc_clnt *clnt,
> -				   struct nfs_server *server,
> -				   struct rpc_message *msg,
> -				   struct nfs4_sequence_args *args,
> -				   struct nfs4_sequence_res *res)
> +int nfs4_call_sync(struct rpc_clnt *clnt,
> +		   struct nfs_server *server,
> +		   struct rpc_message *msg,
> +		   struct nfs4_sequence_args *args,
> +		   struct nfs4_sequence_res *res,
> +		   int cache_reply,
> +		   int privileged)


Hmm.... 7 function arguments? That's almost deserving of its own
structure...

Let's not go down this path. It's easier to initialise the sequence
args/res first, and that is precisely why I chose to do things the way
they are today.

-- 
Trond Myklebust
CTO, Hammerspace Inc
4300 El Camino Real, Suite 105
Los Altos, CA 94022
www.hammer.space id="-x-evo-selection-end-marker">��.n��������+%������w��{.n�����{��w���jg��������ݢj����G�������j:+v���w�m������w�������h�����٥




[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