Revision a8170e5e dma.h
b/dma.h | ||
---|---|---|
48 | 48 |
|
49 | 49 |
typedef int DMATranslateFunc(DMAContext *dma, |
50 | 50 |
dma_addr_t addr, |
51 |
target_phys_addr_t *paddr,
|
|
52 |
target_phys_addr_t *len,
|
|
51 |
hwaddr *paddr,
|
|
52 |
hwaddr *len,
|
|
53 | 53 |
DMADirection dir); |
54 | 54 |
typedef void* DMAMapFunc(DMAContext *dma, |
55 | 55 |
dma_addr_t addr, |
... | ... | |
177 | 177 |
DMADirection dir) |
178 | 178 |
{ |
179 | 179 |
if (!dma_has_iommu(dma)) { |
180 |
target_phys_addr_t xlen = *len;
|
|
180 |
hwaddr xlen = *len;
|
|
181 | 181 |
void *p; |
182 | 182 |
|
183 | 183 |
p = address_space_map(dma->as, addr, &xlen, dir == DMA_DIRECTION_FROM_DEVICE); |
... | ... | |
196 | 196 |
DMADirection dir, dma_addr_t access_len) |
197 | 197 |
{ |
198 | 198 |
if (!dma_has_iommu(dma)) { |
199 |
address_space_unmap(dma->as, buffer, (target_phys_addr_t)len,
|
|
199 |
address_space_unmap(dma->as, buffer, (hwaddr)len,
|
|
200 | 200 |
dir == DMA_DIRECTION_FROM_DEVICE, access_len); |
201 | 201 |
} else { |
202 | 202 |
iommu_dma_memory_unmap(dma, buffer, len, dir, access_len); |
Also available in: Unified diff