summaryrefslogtreecommitdiff
path: root/drivers/rapidio/devices/rio_mport_cdev.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/rapidio/devices/rio_mport_cdev.c')
-rw-r--r--drivers/rapidio/devices/rio_mport_cdev.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/rapidio/devices/rio_mport_cdev.c b/drivers/rapidio/devices/rio_mport_cdev.c
index 7df466e22282..2cdc054e53a5 100644
--- a/drivers/rapidio/devices/rio_mport_cdev.c
+++ b/drivers/rapidio/devices/rio_mport_cdev.c
@@ -915,7 +915,7 @@ rio_dma_transfer(struct file *filp, u32 transfer_mode,
goto err_req;
}
- if (xfer->length + xfer->offset > map->size) {
+ if (xfer->length + xfer->offset > req->map->size) {
ret = -EINVAL;
goto err_req;
}
@@ -927,7 +927,7 @@ rio_dma_transfer(struct file *filp, u32 transfer_mode,
}
sg_set_buf(req->sgt.sgl,
- map->virt_addr + (baddr - map->phys_addr) +
+ req->map->virt_addr + (baddr - req->map->phys_addr) +
xfer->offset, xfer->length);
}