diff options
author | Ralph Campbell <ralph.campbell@qlogic.com> | 2006-12-12 17:28:28 -0500 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2006-12-12 17:28:28 -0500 |
commit | f2cbb660ed37294e3eeb98c045de6890079ccb01 (patch) | |
tree | 860d7fcf838dd0937d59a420f2018ee6f2f9935e /drivers/infiniband/hw/ipath/ipath_keys.c | |
parent | 9b513090a3c5e4964f9ac09016c1586988abb3d5 (diff) |
IB/ipath: Implement new verbs DMA mapping functions
This patch implements the interposing DMA mapping functions to allow
support for IOMMUs and remove the dependence on phys_to_virt() and
bus_to_virt().
Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband/hw/ipath/ipath_keys.c')
-rw-r--r-- | drivers/infiniband/hw/ipath/ipath_keys.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/infiniband/hw/ipath/ipath_keys.c b/drivers/infiniband/hw/ipath/ipath_keys.c index 9a6cbd05adcd..851763d7d2db 100644 --- a/drivers/infiniband/hw/ipath/ipath_keys.c +++ b/drivers/infiniband/hw/ipath/ipath_keys.c | |||
@@ -134,7 +134,7 @@ int ipath_lkey_ok(struct ipath_qp *qp, struct ipath_sge *isge, | |||
134 | */ | 134 | */ |
135 | if (sge->lkey == 0) { | 135 | if (sge->lkey == 0) { |
136 | isge->mr = NULL; | 136 | isge->mr = NULL; |
137 | isge->vaddr = bus_to_virt(sge->addr); | 137 | isge->vaddr = (void *) sge->addr; |
138 | isge->length = sge->length; | 138 | isge->length = sge->length; |
139 | isge->sge_length = sge->length; | 139 | isge->sge_length = sge->length; |
140 | ret = 1; | 140 | ret = 1; |
@@ -202,12 +202,12 @@ int ipath_rkey_ok(struct ipath_qp *qp, struct ipath_sge_state *ss, | |||
202 | int ret; | 202 | int ret; |
203 | 203 | ||
204 | /* | 204 | /* |
205 | * We use RKEY == zero for physical addresses | 205 | * We use RKEY == zero for kernel virtual addresses |
206 | * (see ipath_get_dma_mr). | 206 | * (see ipath_get_dma_mr and ipath_dma.c). |
207 | */ | 207 | */ |
208 | if (rkey == 0) { | 208 | if (rkey == 0) { |
209 | sge->mr = NULL; | 209 | sge->mr = NULL; |
210 | sge->vaddr = phys_to_virt(vaddr); | 210 | sge->vaddr = (void *) vaddr; |
211 | sge->length = len; | 211 | sge->length = len; |
212 | sge->sge_length = len; | 212 | sge->sge_length = len; |
213 | ss->sg_list = NULL; | 213 | ss->sg_list = NULL; |