search for: memtype

Displaying 20 results from an estimated 115 matches for "memtype".

Did you mean: mem_type
2014 Feb 16
2
[PATCH] drm/nouveau: fix TTM_PL_TT memtype on pre-nv50
...6d..4aed171 100644 --- a/drivers/gpu/drm/nouveau/nouveau_bo.c +++ b/drivers/gpu/drm/nouveau/nouveau_bo.c @@ -1249,7 +1249,7 @@ nouveau_ttm_io_mem_reserve(struct ttm_bo_device *bdev, struct ttm_mem_reg *mem) mem->bus.is_iomem = !dev->agp->cant_use_aperture; } #endif - if (!node->memtype) + if (nv_device(drm->device)->card_type < NV_50 || !node->memtype) /* untiled */ break; /* fallthrough, tiled memory */ -- 1.8.3.2
2016 Mar 10
8
[PATCH mesa 0/3] tgsi and nouveau global / local / opencl-input mem support
Hi, Here are patches which implement the support for OpenCL kernel input parameters we discussed. They also add the tgsi parsing bits for adding support for global / local mem, but no implementation yet. Regards, Hans
2016 Mar 10
1
[Mesa-dev] [PATCH mesa 2/3] tgsi: Add support for global / local / input MEMORY
...src/gallium/auxiliary/tgsi/tgsi_build.c > +++ b/src/gallium/auxiliary/tgsi/tgsi_build.c > @@ -111,7 +111,7 @@ tgsi_default_declaration( void ) > declaration.Local = 0; > declaration.Array = 0; > declaration.Atomic = 0; > - declaration.Shared = 0; > + declaration.MemType = TGSI_MEMORY_TYPE_GLOBAL; > declaration.Padding = 0; > > return declaration; > @@ -128,7 +128,7 @@ tgsi_build_declaration( > unsigned local, > unsigned array, > unsigned atomic, > - unsigned shared, > + unsigned mem_type, > struct tgsi_head...
2010 Mar 18
0
[PATCH] drm/nouveau: Make use of TTM busy_placements.
...if (type & TTM_PL_FLAG_VRAM) + pl[(*n)++] = TTM_PL_FLAG_VRAM | flags; + if (type & TTM_PL_FLAG_TT) + pl[(*n)++] = TTM_PL_FLAG_TT | flags; + if (type & TTM_PL_FLAG_SYSTEM) + pl[(*n)++] = TTM_PL_FLAG_SYSTEM | flags; +} + void -nouveau_bo_placement_set(struct nouveau_bo *nvbo, uint32_t memtype) +nouveau_bo_placement_set(struct nouveau_bo *nvbo, uint32_t type, uint32_t busy) { - int n = 0; - - if (memtype & TTM_PL_FLAG_VRAM) - nvbo->placements[n++] = TTM_PL_FLAG_VRAM | TTM_PL_MASK_CACHING; - if (memtype & TTM_PL_FLAG_TT) - nvbo->placements[n++] = TTM_PL_FLAG_TT | TTM_PL_M...
2014 Mar 05
1
[PATCH] nv50, nvc0: choose storage type after ms has been initialized
...44 --- a/src/gallium/drivers/nouveau/nv50/nv50_miptree.c +++ b/src/gallium/drivers/nouveau/nv50/nv50_miptree.c @@ -329,13 +329,13 @@ nv50_miptree_create(struct pipe_screen *pscreen, if (pt->bind & PIPE_BIND_LINEAR) pt->flags |= NOUVEAU_RESOURCE_FLAG_LINEAR; - bo_config.nv50.memtype = nv50_mt_choose_storage_type(mt, TRUE); - if (!nv50_miptree_init_ms_mode(mt)) { FREE(mt); return NULL; } + bo_config.nv50.memtype = nv50_mt_choose_storage_type(mt, TRUE); + if (unlikely(pt->flags & NV50_RESOURCE_FLAG_VIDEO)) { nv50_miptree_init_layout_vi...
2016 Mar 16
5
[PATCH mesa v2 1/3] tgsi: Fix decl.Atomic and .Shared not propagating when parsing tgsi text
When support for decl.Atomic and .Shared was added, tgsi_build_declaration was not updated to propagate these properly. Signed-off-by: Hans de Goede <hdegoede at redhat.com> Reviewed-by: Ilia Mirkin <imirkin at alum.mit.edu> --- Changes in v2: -Add Reviewed-by: Ilia Mirkin <imirkin at alum.mit.edu> --- src/gallium/auxiliary/tgsi/tgsi_build.c | 6 ++++++ 1 file changed, 6
2016 Mar 10
0
[PATCH mesa 2/3] tgsi: Add support for global / local / input MEMORY
...ndex c420ae1..b108ade 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_build.c +++ b/src/gallium/auxiliary/tgsi/tgsi_build.c @@ -111,7 +111,7 @@ tgsi_default_declaration( void ) declaration.Local = 0; declaration.Array = 0; declaration.Atomic = 0; - declaration.Shared = 0; + declaration.MemType = TGSI_MEMORY_TYPE_GLOBAL; declaration.Padding = 0; return declaration; @@ -128,7 +128,7 @@ tgsi_build_declaration( unsigned local, unsigned array, unsigned atomic, - unsigned shared, + unsigned mem_type, struct tgsi_header *header ) { struct tgsi_declaration decl...
2016 Mar 16
0
[PATCH mesa v2 2/3] tgsi: Add support for global / private / input MEMORY
...ndex 1cb95b9..a3e659b 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_build.c +++ b/src/gallium/auxiliary/tgsi/tgsi_build.c @@ -111,7 +111,7 @@ tgsi_default_declaration( void ) declaration.Local = 0; declaration.Array = 0; declaration.Atomic = 0; - declaration.Shared = 0; + declaration.MemType = TGSI_MEMORY_TYPE_GLOBAL; declaration.Padding = 0; return declaration; @@ -128,7 +128,7 @@ tgsi_build_declaration( unsigned local, unsigned array, unsigned atomic, - unsigned shared, + unsigned mem_type, struct tgsi_header *header ) { struct tgsi_declaration decl...
2012 Jul 27
0
[PATCH] nouveau: apply storage type to gart objects
...vers/gpu/drm/nouveau/nouveau_mem.c @@ -1223,7 +1223,9 @@ nouveau_gart_manager_new(struct ttm_mem_type_manager *man, struct ttm_mem_reg *mem) { struct drm_nouveau_private *dev_priv = nouveau_bdev(bo->bdev); + struct nouveau_bo *nvbo = nouveau_bo(bo); struct nouveau_mem *node; + uint32_t memtype = nvbo->tile_flags >> 8; if (unlikely((mem->num_pages << PAGE_SHIFT) >= dev_priv->gart_info.aper_size)) @@ -1234,6 +1236,13 @@ nouveau_gart_manager_new(struct ttm_mem_type_manager *man, return -ENOMEM; node->page_shift = 12; + if (dev_priv->card_type...
2016 Mar 10
0
[Mesa-dev] [PATCH mesa 2/3] tgsi: Add support for global / local / input MEMORY
..._build.c >> +++ b/src/gallium/auxiliary/tgsi/tgsi_build.c >> @@ -111,7 +111,7 @@ tgsi_default_declaration( void ) >> declaration.Local = 0; >> declaration.Array = 0; >> declaration.Atomic = 0; >> - declaration.Shared = 0; >> + declaration.MemType = TGSI_MEMORY_TYPE_GLOBAL; >> declaration.Padding = 0; >> >> return declaration; >> @@ -128,7 +128,7 @@ tgsi_build_declaration( >> unsigned local, >> unsigned array, >> unsigned atomic, >> - unsigned shared, >> + uns...
2005 Sep 26
1
reading SAS data files
...~1\DSONNE~1\LOCALS~1\Temp\Rtmp3540\file26090'; NOTE: Libref RD was successfully assigned as follows: Engine: XPORT Physical Name: C:\DOCUME~1\DSONNE~1\LOCALS~1\Temp\Rtmp3540\file26090 3 proc copy in=src2rd out=rd; 4 select pcb ; ERROR: The file SRC2RD.PCB (memtype=ALL) was not found, but appears on a SELECT statement. ERROR: The file SRC2RD.PCB (memtype=ALL) was not found, but appears on a SELECT statement. ERROR: The file SRC2RD.PCB (memtype=ALL) was not found, but appears on a SELECT statement. WARNING: Input library SRC2RD is empty. NOTE: Statements not p...
2012 Feb 27
1
[PATCH] drm/nv50/vm: Prevent kernel freeze
...au/nv50_vm.c b/drivers/gpu/drm/nouveau/nv50_vm.c index f06f4ad..44fbac9 100644 --- a/drivers/gpu/drm/nouveau/nv50_vm.c +++ b/drivers/gpu/drm/nouveau/nv50_vm.c @@ -85,7 +85,7 @@ nv50_vm_map(struct nouveau_vma *vma, struct nouveau_gpuobj *pgt, target = 3; } - phys = vm_addr(vma, phys, mem->memtype, 0); + phys = vm_addr(vma, phys, mem->memtype, target); pte <<= 3; cnt <<= 3; -- 1.7.9.2
2014 May 30
0
[PATCH] drm/gk20a/fb: use dma_alloc_coherent() for VRAM
...>handle); - page = pfn_to_page(mem->pages[i] >> PAGE_SHIFT); - dma_release_from_contiguous(dev, page, 1); - } - - kfree(mem->pages); + kfree(mem->base.pages); kfree(mem); } @@ -58,11 +58,9 @@ gk20a_ram_get(struct nouveau_fb *pfb, u64 size, u32 align, u32 ncmin, u32 memtype, struct nouveau_mem **pmem) { struct device *dev = nv_device_base(nv_device(pfb)); - struct nouveau_mem *mem; - int type = memtype & 0xff; - dma_addr_t dma_addr; - int npages; - int order; + struct gk20a_mem *mem; + u32 type = memtype & 0xff; + u32 npages, order; int i; nv_debug(pf...
2015 Jun 15
4
[PATCH v2 0/2] drm/nouveau: option for staging ioctls and new GEM_SET_TILING ioctl
...ng ioctls is limited to 8 (range 0x98 to 0xa0) that are to be recycled as staging ioctls become stable and are assigned a final number. Changes since v1: - Use one module option per staging ioctl - Only allow GEM_SET_TILING to be called on dma-buf imported buffers - Move the code setting nvkm_mem::memtype into its own function to avoid duplicating code Alexandre Courbot (1): drm/nouveau: placeholders for staging ioctls Ari Hirvonen (1): drm/nouveau: add GEM_SET_TILING staging ioctl drm/nouveau/nouveau_bo.c | 18 ++++++++++++ drm/nouveau/nouveau_bo.h | 2 ++ drm/nouveau...
2013 Sep 02
0
[PATCH] drm/nv50-: fix tiled memory layout checks
...fset = old_node->vma[0].offset; + u64 dst_offset = old_node->vma[1].offset; u32 size; int ret; size = 18; - if (nouveau_bo_tile_layout(nvbo)) { - size += 6 * (old_mem->mem_type == TTM_PL_VRAM); - size += 6 * (new_mem->mem_type == TTM_PL_VRAM); - } + size += 6 * (!!old_node->memtype + !!new_node->memtype); size *= (length + (4 * 1024 * 1024) - 1) / (4 * 1024 * 1024); ret = RING_SPACE(chan, size); if (ret) @@ -859,8 +859,7 @@ nv50_bo_move_m2mf(struct nouveau_channel *chan, struct ttm_buffer_object *bo, stride = 16 * 4; height = amount / stride; - if (old_mem...
2013 Mar 27
3
[PATCH 1/4] drm/nvc0: implement VRAM compression
...0, 0, 0, 0, 0, 0, 3, - 3, 3, 3, 1, 0, 0, 0, 0, 0, 0, 0, 0, 3, 3, 3, 3, - 3, 3, 0, 0, 0, 0, 0, 0, 3, 0, 0, 3, 0, 3, 0, 3, - 3, 0, 3, 3, 3, 3, 3, 0, 0, 3, 0, 3, 0, 3, 3, 0, - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 0, 1, 1, 0 -}; +extern const u8 nvc0_pte_storage_type_map[256]; + static bool nvc0_fb_memtype_valid(struct nouveau_fb *pfb, u32 tile_flags) { u8 memtype = (tile_flags & 0x0000ff00) >> 8; - return likely((types[memtype] == 1)); + return likely((nvc0_pte_storage_type_map[memtype] != 0xff)); } static int @@ -130,6 +111,7 @@ nvc0_fb_vram_new(struct nouveau_fb *pfb, u64 size, u3...
2014 Sep 09
1
[PATCH 1/2] accel_common: do not initialise the flags twice
Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com> --- src/nv_accel_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nv_accel_common.c b/src/nv_accel_common.c index 4484c1c..eebb0ab 100644 --- a/src/nv_accel_common.c +++ b/src/nv_accel_common.c @@ -37,7 +37,7 @@ nouveau_allocate_surface(ScrnInfoPtr scrn, int width, int height, int bpp, Bool tiled =
2014 Oct 27
0
[PATCH] drm: warn when moving a pinned object
...om> --- drm/nouveau_bo.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/drm/nouveau_bo.c b/drm/nouveau_bo.c index 3d474ac03f88..9a8adeec80cd 100644 --- a/drm/nouveau_bo.c +++ b/drm/nouveau_bo.c @@ -323,8 +323,8 @@ nouveau_bo_pin(struct nouveau_bo *nvbo, uint32_t memtype) goto out; } - if (nvbo->pin_refcnt++) - goto out; + if (nvbo->pin_refcnt) + goto ref_inc; nouveau_bo_placement_set(nvbo, memtype, 0); @@ -341,6 +341,10 @@ nouveau_bo_pin(struct nouveau_bo *nvbo, uint32_t memtype) break; } } + +ref_inc: + nvbo->pin_refcnt++; + out:...
2015 Jun 15
2
[PATCH v2 2/2] drm/nouveau: add GEM_SET_TILING staging ioctl
...ZE); > } > > +void > +nouveau_bo_update_tiling(struct nouveau_drm *drm, struct nouveau_bo *nvbo, > + struct nvkm_mem *mem) > +{ > + switch (drm->device.info.family) { > + case NV_DEVICE_INFO_V0_TESLA: > + if (drm->device.info.chipset != 0x50) > + mem->memtype = (nvbo->tile_flags & 0x7f00) >> 8; > + break; > + case NV_DEVICE_INFO_V0_FERMI: > + case NV_DEVICE_INFO_V0_KEPLER: > + mem->memtype = (nvbo->tile_flags & 0xff00) >> 8; > + break; > + default: > + break; > + } > +} > + > int > n...
2014 May 19
3
[PATCH 0/2] drm/gk20a: FB fixes
Fix a very shameful memory leak and a compilation error due to the use of non-exported CMA functions. The workaround for the latter is not really elegant (replace the CMA functions by a runtime failure if we are compiled as a module), but is temporary and still an improvement over the current situation (compile error). Alexandre Courbot (2): drm/gk20a/fb: fix huge memory leak drm/gk20a/fb: