On 9/20/17 10:08 AM, William Allen Simpson wrote:
My current expectation is that various fields of the Ganesha rpc_call_t should be merged/replaced by fields in the NTI_RPC struct svc_req so that async dispatch can handle the callback.
To be more concrete, there are currently 3 structs that handle clnt_call(): * Ganesha rpc_call_t * NTI-RPC rpc_ctx, not externally visible, has a lot of the same fields. They are copied via a long list of clnt_call() parameters from the rpc_call_t. * NTI-RPC svc_req, where all responses are received; then it passed the data back to the rpc_ctx, that in turn is then copied to the rpc_call_t. Lots of common redundant fields, data copied back and forth. In RDMA, there's another: the Call Back Context. It serves the same purpose as the rpc_ctx, but has a lot more data, and 2 XDRs. There's a pointer in the svc_req to the receiving XDR. I propose exposing the rpc_ctx in clnt.h (renamed clnt_req to parallel svc_req in svc.h) and merging various duplicate fields from svc_req. All the common fields between rpc_call_t and rpc_ctx can be merged. Like RDMA, it probably needs an XDR so that each can be handled independently. But then we need to decide how to call back. I've already added the new reply decoding xdr_pair (func and where) to the rpc_ctx. My guess is the easiest is another function in the rpc_ctx to callback after decoding. I'm hoping that the fridge thread call scheme would be simple to replace.... Or the reply function could be the callback, too. Thoughts? ------------------------------------------------------------------------------ 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