Lines Matching refs:dma
45 drm_device_dma_t *dma = dev->dma; in radeon_addbufs_agp() local
60 if (!dma) return -EINVAL; in radeon_addbufs_agp()
96 entry = &dma->bufs[order]; in radeon_addbufs_agp()
129 buf->idx = dma->buf_count + entry->buf_count; in radeon_addbufs_agp()
133 buf->offset = (dma->byte_count + offset); in radeon_addbufs_agp()
166 dma->buflist = drm_realloc(dma->buflist, in radeon_addbufs_agp()
167 dma->buf_count * sizeof(*dma->buflist), in radeon_addbufs_agp()
168 (dma->buf_count + entry->buf_count) in radeon_addbufs_agp()
169 * sizeof(*dma->buflist), in radeon_addbufs_agp()
171 for (i = dma->buf_count; i < dma->buf_count + entry->buf_count; i++) in radeon_addbufs_agp()
172 dma->buflist[i] = &entry->buflist[i - dma->buf_count]; in radeon_addbufs_agp()
174 dma->buf_count += entry->buf_count; in radeon_addbufs_agp()
175 dma->byte_count += byte_count; in radeon_addbufs_agp()
190 dma->flags = _DRM_DMA_USE_AGP; in radeon_addbufs_agp()
224 drm_device_dma_t *dma = dev->dma; in radeon_mapbufs() local
232 if (!dma || !dev_priv || dev_priv->is_pci) return -EINVAL; in radeon_mapbufs()
247 if (request.count >= dma->buf_count) { in radeon_mapbufs()
248 if (dma->flags & _DRM_DMA_USE_AGP) { in radeon_mapbufs()
265 virtual = do_mmap(filp, 0, dma->byte_count, in radeon_mapbufs()
276 for (i = 0; i < dma->buf_count; i++) { in radeon_mapbufs()
278 &dma->buflist[i]->idx, in radeon_mapbufs()
284 &dma->buflist[i]->total, in radeon_mapbufs()
295 address = virtual + dma->buflist[i]->offset; in radeon_mapbufs()
305 request.count = dma->buf_count; in radeon_mapbufs()