search for: nouveau_addmap_agp

Displaying 3 results from an estimated 3 matches for "nouveau_addmap_agp".

2008 Mar 09
0
[PATCH 4/4] nouveau: clean up nouveau_mem_alloc function
...+++++++++++++++++++---------------- 1 file changed, 117 insertions(+), 57 deletions(-) Index: drm/shared-core/nouveau_mem.c =================================================================== --- drm.orig/shared-core/nouveau_mem.c +++ drm/shared-core/nouveau_mem.c @@ -567,13 +567,91 @@ static int nouveau_addmap_agp(struct drm return nouveau_addmap(dev, block, block->start, type); } +static struct mem_block * +__nouveau_mem_alloc(struct drm_device *dev, int type, struct mem_block *heap, + uint64_t size, int alignment, int flags, + struct drm_file *file_priv) +{ + struct mem_block *block; + in...
2008 Mar 09
0
[PATCH 1/4] nouveau: add nouveau_addmap_{agp, fb, pci} functions
...+} + +static int nouveau_addmap_fb(struct drm_device *dev, struct mem_block *block) +{ + struct drm_nouveau_private *dev_priv = dev->dev_private; + unsigned long offset = block->start + dev_priv->fb_phys; + + return nouveau_addmap(dev, block, offset, _DRM_SCATTER_GATHER); +} + +static int nouveau_addmap_agp(struct drm_device *dev, struct mem_block *block) +{ + struct drm_nouveau_private *dev_priv = dev->dev_private; + enum drm_map_type type; + + if (dev_priv->gart_info.type == NOUVEAU_GART_SGDMA) + type = _DRM_SCATTER_GATHER; + else + type = _DRM_AGP; + + return nouveau_addmap(dev, block, bloc...
2008 Mar 09
0
[PATCH 2/4] nouveau: add nouveau_map_block function
...drm_device *dev, struct mem_block *block, unsigned long offset, enum drm_map_type type) { @@ -619,9 +633,7 @@ alloc_ok: if (flags&NOUVEAU_MEM_MAPPED) { - struct drm_map_list *entry; int ret = 0; - block->flags|=NOUVEAU_MEM_MAPPED; if (type == NOUVEAU_MEM_AGP) ret = nouveau_addmap_agp(dev, block); @@ -635,12 +647,10 @@ alloc_ok: return NULL; } - entry = drm_find_matching_map(dev, block->map); - if (!entry) { + if (!nouveau_map_block(dev, block)) { nouveau_mem_free_block(block); return NULL; } - block->map_handle = entry->user_token; } DRM_D...