svcrdma: Set rqstp transport address in rdma_read_complete function
authorTom Tucker <tom@opengridcomputing.com>
Wed, 7 May 2008 18:49:58 +0000 (13:49 -0500)
committerTom Tucker <tom@opengridcomputing.com>
Mon, 19 May 2008 12:33:59 +0000 (07:33 -0500)
The rdma_read_complete function needs to copy the rqstp transport address
from the transport. Failure to do so can result in using the wrong
authentication method for the RPC or bug checking if the rqstp address
is not valid.

Signed-off-by: Tom Tucker <tom@opengridcomputing.com>
net/sunrpc/xprtrdma/svc_rdma_recvfrom.c

index 21a1e625ef0305837585eaa43d4405b00bf0f66e..c016f5ca0ce5b644929f8405e9b65c8d4b9d8ab6 100644 (file)
@@ -416,6 +416,7 @@ static int rdma_read_complete(struct svc_rqst *rqstp,
 
        /* XXX: What should this be? */
        rqstp->rq_prot = IPPROTO_MAX;
+       svc_xprt_copy_addrs(rqstp, rqstp->rq_xprt);
 
        ret = rqstp->rq_arg.head[0].iov_len
                + rqstp->rq_arg.page_len