Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 74960
b: refs/heads/master
c: 50e1092
h: refs/heads/master
v: v3
  • Loading branch information
James Lentini authored and Trond Myklebust committed Dec 12, 2007
1 parent af27bcc commit f1aa98e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5cef338b30c110daf547fb13d99f0c77f2a79fbc
refs/heads/master: 50e1092b3a119bb4660bb6bd2e1749dc2d8ac62e
9 changes: 1 addition & 8 deletions trunk/net/sunrpc/xprtrdma/rpc_rdma.c
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ rpcrdma_convert_iovs(struct xdr_buf *xdrbuf, int pos,
seg[n].mr_page = NULL;
seg[n].mr_offset = xdrbuf->head[0].iov_base;
seg[n].mr_len = xdrbuf->head[0].iov_len;
pos += xdrbuf->head[0].iov_len;
++n;
}

Expand All @@ -104,7 +103,6 @@ rpcrdma_convert_iovs(struct xdr_buf *xdrbuf, int pos,
seg[n].mr_len = min_t(u32,
PAGE_SIZE - xdrbuf->page_base, xdrbuf->page_len);
len = xdrbuf->page_len - seg[n].mr_len;
pos += len;
++n;
p = 1;
while (len > 0) {
Expand All @@ -119,20 +117,15 @@ rpcrdma_convert_iovs(struct xdr_buf *xdrbuf, int pos,
}
}

if (pos < xdrbuf->len && xdrbuf->tail[0].iov_len) {
if (xdrbuf->tail[0].iov_len) {
if (n == nsegs)
return 0;
seg[n].mr_page = NULL;
seg[n].mr_offset = xdrbuf->tail[0].iov_base;
seg[n].mr_len = xdrbuf->tail[0].iov_len;
pos += xdrbuf->tail[0].iov_len;
++n;
}

if (pos < xdrbuf->len)
dprintk("RPC: %s: marshaled only %d of %d\n",
__func__, pos, xdrbuf->len);

return n;
}

Expand Down

0 comments on commit f1aa98e

Please sign in to comment.