Displaying 16 results from an estimated 16 matches for "bo_driver".
2019 Sep 09
5
[PATCH 0/4] Merge VRAM MM and GEM VRAM source files
VRAM MM and GEM VRAM are only used with each other. This patch set
moves VRAM MM into GEM VRAM source files and cleans up the helper's
public interface.
Thomas Zimmermann (4):
drm/vram: Move VRAM memory manager to GEM VRAM implementation
drm/vram: Have VRAM MM call GEM VRAM functions directly
drm/vram: Unexport internal functions of VRAM MM
drm/vram: Unconditonally set BO call-back
2019 Apr 24
0
[PATCH v2 05/17] drm: Add VRAM MM, a simple memory manager for dedicated VRAM
...ith &struct drm_gem_vram_object.
+ */
+
+/*
+ * TTM TT
+ */
+
+static void backend_func_destroy(struct ttm_tt *tt)
+{
+ ttm_tt_fini(tt);
+ kfree(tt);
+}
+
+static struct ttm_backend_func backend_func = {
+ .destroy = backend_func_destroy
+};
+
+/*
+ * TTM BO device
+ */
+
+static struct ttm_tt *bo_driver_ttm_tt_create(struct ttm_buffer_object *bo,
+ uint32_t page_flags)
+{
+ struct ttm_tt *tt;
+ int ret;
+
+ tt = kzalloc(sizeof(*tt), GFP_KERNEL);
+ if (!tt)
+ return NULL;
+
+ tt->func = &backend_func;
+
+ ret = ttm_tt_init(tt, bo, page_flags);
+ if (ret < 0)
+ goto err_ttm_tt_...
2020 Jul 15
3
[PATCH 1/4] drm: remove optional dummy function from drivers using TTM
...bo_device *bdev, struct ttm_mem_
return 0;
}
-static void amdgpu_ttm_io_mem_free(struct ttm_bo_device *bdev, struct ttm_mem_reg *mem)
-{
-}
-
static unsigned long amdgpu_ttm_io_mem_pfn(struct ttm_buffer_object *bo,
unsigned long page_offset)
{
@@ -1754,7 +1750,6 @@ static struct ttm_bo_driver amdgpu_bo_driver = {
.release_notify = &amdgpu_bo_release_notify,
.fault_reserve_notify = &amdgpu_bo_fault_reserve_notify,
.io_mem_reserve = &amdgpu_ttm_io_mem_reserve,
- .io_mem_free = &amdgpu_ttm_io_mem_free,
.io_mem_pfn = amdgpu_ttm_io_mem_pfn,
.access_memory = &amd...
2019 Sep 11
4
[PATCH v2 0/4] Merge VRAM MM and GEM VRAM source files
VRAM MM and GEM VRAM are only used with each other. This patch set
moves VRAM MM into GEM VRAM source files and cleans up the helper's
public interface.
Version 2 of the patch set doesn't contain functional changes. I'm
reposting due to the rebasing onto the debugfs patches.
v2:
* updated for debugfs support
* fixed typos in comments
Thomas Zimmermann (4):
drm/vram: Move VRAM
2019 Sep 05
1
[PATCH 1/8] drm/ttm: turn ttm_bo_device.vma_manager into a pointer
...ional vma_manager
argument which allows to initialize ttm with a different vma manager.
When passing NULL the embedded _vma_manager is used.
All callers are updated to pass NULL, so the behavior doesn't change.
Signed-off-by: Gerd Hoffmann <kraxel at redhat.com>
---
include/drm/ttm/ttm_bo_driver.h | 8 ++++++--
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 1 +
drivers/gpu/drm/drm_vram_mm_helper.c | 1 +
drivers/gpu/drm/nouveau/nouveau_ttm.c | 1 +
drivers/gpu/drm/qxl/qxl_ttm.c | 1 +
drivers/gpu/drm/radeon/radeon_ttm.c | 1 +
drivers/gpu/drm/ttm/ttm_bo.c...
2019 Sep 05
1
[PATCH 1/8] drm/ttm: turn ttm_bo_device.vma_manager into a pointer
...ional vma_manager
argument which allows to initialize ttm with a different vma manager.
When passing NULL the embedded _vma_manager is used.
All callers are updated to pass NULL, so the behavior doesn't change.
Signed-off-by: Gerd Hoffmann <kraxel at redhat.com>
---
include/drm/ttm/ttm_bo_driver.h | 8 ++++++--
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 1 +
drivers/gpu/drm/drm_vram_mm_helper.c | 1 +
drivers/gpu/drm/nouveau/nouveau_ttm.c | 1 +
drivers/gpu/drm/qxl/qxl_ttm.c | 1 +
drivers/gpu/drm/radeon/radeon_ttm.c | 1 +
drivers/gpu/drm/ttm/ttm_bo.c...
2019 Sep 05
1
[PATCH 1/8] drm/ttm: turn ttm_bo_device.vma_manager into a pointer
...ional vma_manager
argument which allows to initialize ttm with a different vma manager.
When passing NULL the embedded _vma_manager is used.
All callers are updated to pass NULL, so the behavior doesn't change.
Signed-off-by: Gerd Hoffmann <kraxel at redhat.com>
---
include/drm/ttm/ttm_bo_driver.h | 8 ++++++--
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 1 +
drivers/gpu/drm/drm_vram_mm_helper.c | 1 +
drivers/gpu/drm/nouveau/nouveau_ttm.c | 1 +
drivers/gpu/drm/qxl/qxl_ttm.c | 1 +
drivers/gpu/drm/radeon/radeon_ttm.c | 1 +
drivers/gpu/drm/ttm/ttm_bo.c...
2024 Oct 04
1
[PATCH v2 1/2] drm/ttm: Change ttm_device_init to use a struct instead of multiple bools
...4
> > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> > > @@ -1853,8 +1853,10 @@ int amdgpu_ttm_init(struct amdgpu_device
> > > *adev)
> > > ?? r = ttm_device_init(&adev->mman.bdev, &amdgpu_bo_driver,
> > > adev->dev,
> > > ?? ?????? adev_to_drm(adev)->anon_inode-
> > > > i_mapping,
> > > ?? ?????? adev_to_drm(adev)-
> > > > vma_offset_manager,
> > > - ?????? adev->need_swiotlb,
> > > - ?????? dma_addressing_l...
2024 Oct 05
1
[PATCH v2 1/2] drm/ttm: Change ttm_device_init to use a struct instead of multiple bools
...a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> > > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> > > > @@ -1853,8 +1853,10 @@ int amdgpu_ttm_init(struct amdgpu_device
> > > > *adev)
> > > > ?? r = ttm_device_init(&adev->mman.bdev, &amdgpu_bo_driver,
> > > > adev->dev,
> > > > ?? ?????? adev_to_drm(adev)->anon_inode-
> > > > > i_mapping,
> > > > ?? ?????? adev_to_drm(adev)-
> > > > > vma_offset_manager,
> > > > - ?????? adev->need_swiotlb,
> > &g...
2024 Oct 02
2
[PATCH v2 0/2] drm/ttm: Add an option to report graphics memory OOM
Some graphics APIs differentiate between out-of-graphics-memory and
out-of-host-memory (system memory). Add a device init flag to
have -ENOSPC propagated from the resource managers instead of being
converted to -ENOMEM, to aid driver stacks in determining what
error code to return or whether corrective action can be taken at
the driver level.
The first patch deals with a ttm_device_init()
2019 Apr 24
21
[PATCH v2 00/17] Share TTM code among DRM framebuffer drivers
...ent flags for public interface
* add drm_vram_mm_mmap() helper
* replace almost all of driver's TTM code with these helpers
* documentation fixes
Thomas Zimmermann (17):
drm: Add |struct drm_gem_vram_object| and helpers
drm: Add |struct drm_gem_vram_object| callbacks for |struct
ttm_bo_driver|
drm: Add |struct drm_gem_vram_object| callbacks for |struct
drm_driver|
drm: Add drm_gem_vram_fill_create_dumb() to create dumb buffers
drm: Add VRAM MM, a simple memory manager for dedicated VRAM
drm/ast: Convert AST driver to |struct drm_gem_vram_object|
drm/ast: Convert AST driver...
2019 May 06
25
[PATCH v4 00/19] Share TTM code among DRM framebuffer drivers
...ent flags for public interface
* add drm_vram_mm_mmap() helper
* replace almost all of driver's TTM code with these helpers
* documentation fixes
Thomas Zimmermann (19):
drm: Add |struct drm_gem_vram_object| and helpers
drm: Add |struct drm_gem_vram_object| callbacks for |struct
ttm_bo_driver|
drm: Add |struct drm_gem_vram_object| callbacks for |struct
drm_driver|
drm: Add drm_gem_vram_fill_create_dumb() to create dumb buffers
drm: Add VRAM MM, a simple memory manager for dedicated VRAM
drm: Add default instance for VRAM MM callback functions
drm: Integrate VRAM MM into st...
2019 May 06
25
[PATCH v4 00/19] Share TTM code among DRM framebuffer drivers
...ent flags for public interface
* add drm_vram_mm_mmap() helper
* replace almost all of driver's TTM code with these helpers
* documentation fixes
Thomas Zimmermann (19):
drm: Add |struct drm_gem_vram_object| and helpers
drm: Add |struct drm_gem_vram_object| callbacks for |struct
ttm_bo_driver|
drm: Add |struct drm_gem_vram_object| callbacks for |struct
drm_driver|
drm: Add drm_gem_vram_fill_create_dumb() to create dumb buffers
drm: Add VRAM MM, a simple memory manager for dedicated VRAM
drm: Add default instance for VRAM MM callback functions
drm: Integrate VRAM MM into st...
2019 May 08
22
[PATCH v5 00/20] Share TTM code among DRM framebuffer drivers
...ent flags for public interface
* add drm_vram_mm_mmap() helper
* replace almost all of driver's TTM code with these helpers
* documentation fixes
Thomas Zimmermann (20):
drm: Add |struct drm_gem_vram_object| and helpers
drm: Add |struct drm_gem_vram_object| callbacks for |struct
ttm_bo_driver|
drm: Add |struct drm_gem_vram_object| callbacks for |struct
drm_driver|
drm: Add drm_gem_vram_fill_create_dumb() to create dumb buffers
drm: Add simple PRIME helpers for GEM VRAM
drm: Add VRAM MM, a simple memory manager for dedicated VRAM
drm: Add default instance for VRAM MM callba...
2019 May 08
22
[PATCH v5 00/20] Share TTM code among DRM framebuffer drivers
...ent flags for public interface
* add drm_vram_mm_mmap() helper
* replace almost all of driver's TTM code with these helpers
* documentation fixes
Thomas Zimmermann (20):
drm: Add |struct drm_gem_vram_object| and helpers
drm: Add |struct drm_gem_vram_object| callbacks for |struct
ttm_bo_driver|
drm: Add |struct drm_gem_vram_object| callbacks for |struct
drm_driver|
drm: Add drm_gem_vram_fill_create_dumb() to create dumb buffers
drm: Add simple PRIME helpers for GEM VRAM
drm: Add VRAM MM, a simple memory manager for dedicated VRAM
drm: Add default instance for VRAM MM callba...
2019 Apr 29
21
[PATCH v3 00/19] Share TTM code among DRM framebuffer drivers
...ent flags for public interface
* add drm_vram_mm_mmap() helper
* replace almost all of driver's TTM code with these helpers
* documentation fixes
Thomas Zimmermann (19):
drm: Add |struct drm_gem_vram_object| and helpers
drm: Add |struct drm_gem_vram_object| callbacks for |struct
ttm_bo_driver|
drm: Add |struct drm_gem_vram_object| callbacks for |struct
drm_driver|
drm: Add drm_gem_vram_fill_create_dumb() to create dumb buffers
drm: Add VRAM MM, a simple memory manager for dedicated VRAM
drm: Add default instance for VRAM MM callback functions
drm: Integrate VRAM MM into st...