svcrdma: Remove superfluous line from rdma_read_chunks()
authorChuck Lever <chuck.lever@oracle.com>
Wed, 4 May 2016 14:53:14 +0000 (10:53 -0400)
committerJ. Bruce Fields <bfields@redhat.com>
Fri, 13 May 2016 19:53:05 +0000 (15:53 -0400)
Clean up: svc_rdma_get_read_chunk() already returns a pointer
to the Read list. No need to set "ch" again to the value it
already contains.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
net/sunrpc/xprtrdma/svc_rdma_recvfrom.c

index 234be9de621011072f6c09135d0986a2940fb3f8..12e78997bf19d31bd05456d5e8f24047ae9c9748 100644 (file)
@@ -447,10 +447,8 @@ static int rdma_read_chunks(struct svcxprt_rdma *xprt,
        head->arg.len = rqstp->rq_arg.len;
        head->arg.buflen = rqstp->rq_arg.buflen;
 
-       ch = (struct rpcrdma_read_chunk *)&rmsgp->rm_body.rm_chunks[0];
-       position = be32_to_cpu(ch->rc_position);
-
        /* RDMA_NOMSG: RDMA READ data should land just after RDMA RECV data */
+       position = be32_to_cpu(ch->rc_position);
        if (position == 0) {
                head->arg.pages = &head->pages[0];
                page_offset = head->byte_len;