diff options
author | Christoph Hellwig <hch@lst.de> | 2016-05-03 16:01:04 (GMT) |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2016-05-13 17:37:11 (GMT) |
commit | ff2ba9936591a1364ae21adf18366dca7608395a (patch) | |
tree | 4bd33be266f57da2e8ccaaa5f9cc470315759d26 /drivers/infiniband/ulp | |
parent | 0691a286d59183c44b68defd398cb7af0354bd00 (diff) | |
download | linux-ff2ba9936591a1364ae21adf18366dca7608395a.tar.xz |
IB/core: Add passing an offset into the SG to ib_map_mr_sg
Signed-off-by: Christoph Hellwig <hch@lst.de>
Tested-by: Steve Wise <swise@opengridcomputing.com>
Reviewed-by: Bart Van Assche <bart.vanassche@sandisk.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/ulp')
-rw-r--r-- | drivers/infiniband/ulp/iser/iser_memory.c | 4 | ||||
-rw-r--r-- | drivers/infiniband/ulp/isert/ib_isert.c | 2 | ||||
-rw-r--r-- | drivers/infiniband/ulp/srp/ib_srp.c | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/drivers/infiniband/ulp/iser/iser_memory.c b/drivers/infiniband/ulp/iser/iser_memory.c index 9a391cc..44cc85f 100644 --- a/drivers/infiniband/ulp/iser/iser_memory.c +++ b/drivers/infiniband/ulp/iser/iser_memory.c @@ -236,7 +236,7 @@ int iser_fast_reg_fmr(struct iscsi_iser_task *iser_task, page_vec->npages = 0; page_vec->fake_mr.page_size = SIZE_4K; plen = ib_sg_to_pages(&page_vec->fake_mr, mem->sg, - mem->size, iser_set_page); + mem->size, 0, iser_set_page); if (unlikely(plen < mem->size)) { iser_err("page vec too short to hold this SG\n"); iser_data_buf_dump(mem, device->ib_device); @@ -446,7 +446,7 @@ static int iser_fast_reg_mr(struct iscsi_iser_task *iser_task, ib_update_fast_reg_key(mr, ib_inc_rkey(mr->rkey)); - n = ib_map_mr_sg(mr, mem->sg, mem->size, SIZE_4K); + n = ib_map_mr_sg(mr, mem->sg, mem->size, 0, SIZE_4K); if (unlikely(n != mem->size)) { iser_err("failed to map sg (%d/%d)\n", n, mem->size); diff --git a/drivers/infiniband/ulp/isert/ib_isert.c b/drivers/infiniband/ulp/isert/ib_isert.c index 411e446..a44a736 100644 --- a/drivers/infiniband/ulp/isert/ib_isert.c +++ b/drivers/infiniband/ulp/isert/ib_isert.c @@ -2461,7 +2461,7 @@ isert_fast_reg_mr(struct isert_conn *isert_conn, wr = &inv_wr; } - n = ib_map_mr_sg(mr, mem->sg, mem->nents, PAGE_SIZE); + n = ib_map_mr_sg(mr, mem->sg, mem->nents, 0, PAGE_SIZE); if (unlikely(n != mem->nents)) { isert_err("failed to map mr sg (%d/%d)\n", n, mem->nents); diff --git a/drivers/infiniband/ulp/srp/ib_srp.c b/drivers/infiniband/ulp/srp/ib_srp.c index 427dee3..412df56 100644 --- a/drivers/infiniband/ulp/srp/ib_srp.c +++ b/drivers/infiniband/ulp/srp/ib_srp.c @@ -1329,7 +1329,7 @@ static int srp_map_finish_fr(struct srp_map_state *state, rkey = ib_inc_rkey(desc->mr->rkey); ib_update_fast_reg_key(desc->mr, rkey); - n = ib_map_mr_sg(desc->mr, state->sg, sg_nents, dev->mr_page_size); + n = ib_map_mr_sg(desc->mr, state->sg, sg_nents, 0, dev->mr_page_size); if (unlikely(n < 0)) return n; |