aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/infiniband/hw')
-rw-r--r--drivers/infiniband/hw/cxgb3/iwch_cm.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/infiniband/hw/cxgb3/iwch_cm.c b/drivers/infiniband/hw/cxgb3/iwch_cm.c
index e842c65a3f4..3b4b0acd707 100644
--- a/drivers/infiniband/hw/cxgb3/iwch_cm.c
+++ b/drivers/infiniband/hw/cxgb3/iwch_cm.c
@@ -821,7 +821,8 @@ static void process_mpa_reply(struct iwch_ep *ep, struct sk_buff *skb)
821 /* 821 /*
822 * copy the new data into our accumulation buffer. 822 * copy the new data into our accumulation buffer.
823 */ 823 */
824 memcpy(&(ep->mpa_pkt[ep->mpa_pkt_len]), skb->data, skb->len); 824 skb_copy_from_linear_data(skb, &(ep->mpa_pkt[ep->mpa_pkt_len]),
825 skb->len);
825 ep->mpa_pkt_len += skb->len; 826 ep->mpa_pkt_len += skb->len;
826 827
827 /* 828 /*
@@ -940,7 +941,8 @@ static void process_mpa_request(struct iwch_ep *ep, struct sk_buff *skb)
940 /* 941 /*
941 * Copy the new data into our accumulation buffer. 942 * Copy the new data into our accumulation buffer.
942 */ 943 */
943 memcpy(&(ep->mpa_pkt[ep->mpa_pkt_len]), skb->data, skb->len); 944 skb_copy_from_linear_data(skb, &(ep->mpa_pkt[ep->mpa_pkt_len]),
945 skb->len);
944 ep->mpa_pkt_len += skb->len; 946 ep->mpa_pkt_len += skb->len;
945 947
946 /* 948 /*
@@ -1619,7 +1621,8 @@ static int terminate(struct t3cdev *tdev, struct sk_buff *skb, void *ctx)
1619 PDBG("%s ep %p\n", __FUNCTION__, ep); 1621 PDBG("%s ep %p\n", __FUNCTION__, ep);
1620 skb_pull(skb, sizeof(struct cpl_rdma_terminate)); 1622 skb_pull(skb, sizeof(struct cpl_rdma_terminate));
1621 PDBG("%s saving %d bytes of term msg\n", __FUNCTION__, skb->len); 1623 PDBG("%s saving %d bytes of term msg\n", __FUNCTION__, skb->len);
1622 memcpy(ep->com.qp->attr.terminate_buffer, skb->data, skb->len); 1624 skb_copy_from_linear_data(skb, ep->com.qp->attr.terminate_buffer,
1625 skb->len);
1623 ep->com.qp->attr.terminate_msg_len = skb->len; 1626 ep->com.qp->attr.terminate_msg_len = skb->len;
1624 ep->com.qp->attr.is_terminate_local = 0; 1627 ep->com.qp->attr.is_terminate_local = 0;
1625 return CPL_RET_BUF_DONE; 1628 return CPL_RET_BUF_DONE;