> -----Original Message-----
> From: William Allen Simpson [mailto:william.allen.simp...@gmail.com]
> Sent: Wednesday, September 6, 2017 9:11 AM
> To: Frank Filz <ffilz...@mindspring.com>
> Cc: NFS Ganesha Developers <nfs-ganesha-devel@lists.sourceforge.net>
> Subject: xdr_free in nfs_worker_thread.c
> 
> In my most recent Napalm patch, I'd moved all the code that accesses the
> function_desc in nfs_worker_thread.c into nfs_worker_thread.c, hopefully
> making it easier to understand.
> 
> Looking at it today, I remember that I've had a long time question.
> Both uses of xdr_free() use xdr_decode_func().
> 
> Frank added a free_function() in 2014:
> 
> fdcd2f9e (Frank S. Filz                2014-03-07 18:27:37 -0500   78)
>       .service_function = nfs_null,
> fdcd2f9e (Frank S. Filz                2014-03-07 18:27:37 -0500   79)
>       .free_function = nfs_null_free,

That wasn't a new function, it was just renaming functions, and then sharing a 
single null handler with v4.

> There's xdr_decode_func() and xdr_encode_func().
> 
> 3d060451 (Jim Lieb                     2013-03-14 14:36:30 -0700   80)
>       .xdr_decode_func = (xdrproc_t) xdr_void,
> 3d060451 (Jim Lieb                     2013-03-14 14:36:30 -0700   81)
>       .xdr_encode_func = (xdrproc_t) xdr_void,
> 
> Should there be a xdr_free_func(), too?  Or instead?

There needs to be a service free function. I think there are different paths 
that call the xdr functions to free, I tried to follow some of that and 
couldn't find my way... I know the xdr primitives handle encode, decode, and 
free in a single function, but at Ganesha's protocol level, that seems to all 
be somewhat different...

Frank

> Yes, there's a method to my madness.  I'm hoping to make the decode and
> encode functions zero copy....


---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Nfs-ganesha-devel mailing list
Nfs-ganesha-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs-ganesha-devel

Reply via email to