Displaying 20 results from an estimated 284 matches for "tbo".
Did you mean:
tbd
2019 Sep 27
5
[PATCH 1/2] drm/qxl: stop abusing TTM to call driver internal functions
...--- a/drivers/gpu/drm/qxl/qxl_object.c
+++ b/drivers/gpu/drm/qxl/qxl_object.c
@@ -148,7 +148,6 @@ int qxl_bo_kmap(struct qxl_bo *bo, void **ptr)
void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
struct qxl_bo *bo, int page_offset)
{
- struct ttm_mem_type_manager *man = &bo->tbo.bdev->man[bo->tbo.mem.mem_type];
void *rptr;
int ret;
struct io_mapping *map;
@@ -160,9 +159,7 @@ void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
else
goto fallback;
- (void) ttm_mem_io_lock(man, false);
- ret = ttm_mem_io_reserve(bo->tbo.bdev, &bo->tbo.mem);
- t...
2019 Jun 20
0
[PATCH 3/6] drm/qxl: use embedded gem object
.../gpu/drm/qxl/qxl_drv.h b/drivers/gpu/drm/qxl/qxl_drv.h
index 2896bb6fdbf4..b80d4a4361cd 100644
--- a/drivers/gpu/drm/qxl/qxl_drv.h
+++ b/drivers/gpu/drm/qxl/qxl_drv.h
@@ -72,12 +72,13 @@ extern int qxl_max_ioctls;
QXL_INTERRUPT_CLIENT_MONITORS_CONFIG)
struct qxl_bo {
+ struct ttm_buffer_object tbo;
+
/* Protected by gem.mutex */
struct list_head list;
/* Protected by tbo.reserved */
struct ttm_place placements[3];
struct ttm_placement placement;
- struct ttm_buffer_object tbo;
struct ttm_bo_kmap_obj kmap;
unsigned int pin_count;
void *kptr;
@@ -85,7 +86,6 @@ struct qxl...
2019 Jun 21
0
[PATCH v2 03/18] drm/qxl: use embedded gem object
.../gpu/drm/qxl/qxl_drv.h b/drivers/gpu/drm/qxl/qxl_drv.h
index 2896bb6fdbf4..b80d4a4361cd 100644
--- a/drivers/gpu/drm/qxl/qxl_drv.h
+++ b/drivers/gpu/drm/qxl/qxl_drv.h
@@ -72,12 +72,13 @@ extern int qxl_max_ioctls;
QXL_INTERRUPT_CLIENT_MONITORS_CONFIG)
struct qxl_bo {
+ struct ttm_buffer_object tbo;
+
/* Protected by gem.mutex */
struct list_head list;
/* Protected by tbo.reserved */
struct ttm_place placements[3];
struct ttm_placement placement;
- struct ttm_buffer_object tbo;
struct ttm_bo_kmap_obj kmap;
unsigned int pin_count;
void *kptr;
@@ -85,7 +86,6 @@ struct qxl...
2019 Jun 28
0
[PATCH v3 03/18] drm/qxl: use embedded gem object
.../gpu/drm/qxl/qxl_drv.h b/drivers/gpu/drm/qxl/qxl_drv.h
index 2896bb6fdbf4..b80d4a4361cd 100644
--- a/drivers/gpu/drm/qxl/qxl_drv.h
+++ b/drivers/gpu/drm/qxl/qxl_drv.h
@@ -72,12 +72,13 @@ extern int qxl_max_ioctls;
QXL_INTERRUPT_CLIENT_MONITORS_CONFIG)
struct qxl_bo {
+ struct ttm_buffer_object tbo;
+
/* Protected by gem.mutex */
struct list_head list;
/* Protected by tbo.reserved */
struct ttm_place placements[3];
struct ttm_placement placement;
- struct ttm_buffer_object tbo;
struct ttm_bo_kmap_obj kmap;
unsigned int pin_count;
void *kptr;
@@ -85,7 +86,6 @@ struct qxl...
2019 Aug 02
0
[PATCH v4 03/17] drm/qxl: use embedded gem object
.../gpu/drm/qxl/qxl_drv.h b/drivers/gpu/drm/qxl/qxl_drv.h
index ae82e5fab09c..9e034c5fa87d 100644
--- a/drivers/gpu/drm/qxl/qxl_drv.h
+++ b/drivers/gpu/drm/qxl/qxl_drv.h
@@ -71,12 +71,13 @@ extern int qxl_max_ioctls;
QXL_INTERRUPT_CLIENT_MONITORS_CONFIG)
struct qxl_bo {
+ struct ttm_buffer_object tbo;
+
/* Protected by gem.mutex */
struct list_head list;
/* Protected by tbo.reserved */
struct ttm_place placements[3];
struct ttm_placement placement;
- struct ttm_buffer_object tbo;
struct ttm_bo_kmap_obj kmap;
unsigned int pin_count;
void *kptr;
@@ -84,7 +85,6 @@ struct qxl...
2019 Aug 05
0
[PATCH v5 03/18] drm/qxl: use embedded gem object
.../gpu/drm/qxl/qxl_drv.h b/drivers/gpu/drm/qxl/qxl_drv.h
index ae82e5fab09c..9e034c5fa87d 100644
--- a/drivers/gpu/drm/qxl/qxl_drv.h
+++ b/drivers/gpu/drm/qxl/qxl_drv.h
@@ -71,12 +71,13 @@ extern int qxl_max_ioctls;
QXL_INTERRUPT_CLIENT_MONITORS_CONFIG)
struct qxl_bo {
+ struct ttm_buffer_object tbo;
+
/* Protected by gem.mutex */
struct list_head list;
/* Protected by tbo.reserved */
struct ttm_place placements[3];
struct ttm_placement placement;
- struct ttm_buffer_object tbo;
struct ttm_bo_kmap_obj kmap;
unsigned int pin_count;
void *kptr;
@@ -84,7 +85,6 @@ struct qxl...
2019 Aug 05
0
[PATCH v6 03/17] drm/qxl: use embedded gem object
.../gpu/drm/qxl/qxl_drv.h b/drivers/gpu/drm/qxl/qxl_drv.h
index ae82e5fab09c..9e034c5fa87d 100644
--- a/drivers/gpu/drm/qxl/qxl_drv.h
+++ b/drivers/gpu/drm/qxl/qxl_drv.h
@@ -71,12 +71,13 @@ extern int qxl_max_ioctls;
QXL_INTERRUPT_CLIENT_MONITORS_CONFIG)
struct qxl_bo {
+ struct ttm_buffer_object tbo;
+
/* Protected by gem.mutex */
struct list_head list;
/* Protected by tbo.reserved */
struct ttm_place placements[3];
struct ttm_placement placement;
- struct ttm_buffer_object tbo;
struct ttm_bo_kmap_obj kmap;
unsigned int pin_count;
void *kptr;
@@ -84,7 +85,6 @@ struct qxl...
2019 Sep 30
2
[Spice-devel] [PATCH 1/2] drm/qxl: stop abusing TTM to call driver internal functions
.../drm/qxl/qxl_object.c
>> @@ -148,7 +148,6 @@ int qxl_bo_kmap(struct qxl_bo *bo, void **ptr)
>> void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
>> struct qxl_bo *bo, int page_offset)
>> {
>> - struct ttm_mem_type_manager *man =
>> &bo->tbo.bdev->man[bo->tbo.mem.mem_type];
>> void *rptr;
>> int ret;
>> struct io_mapping *map;
>> @@ -160,9 +159,7 @@ void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
>> else
>> goto fallback;
>>
>> - (void) ttm_mem_io_lock(man,...
2019 Sep 30
2
[Spice-devel] [PATCH 1/2] drm/qxl: stop abusing TTM to call driver internal functions
.../drm/qxl/qxl_object.c
>> @@ -148,7 +148,6 @@ int qxl_bo_kmap(struct qxl_bo *bo, void **ptr)
>> void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
>> struct qxl_bo *bo, int page_offset)
>> {
>> - struct ttm_mem_type_manager *man =
>> &bo->tbo.bdev->man[bo->tbo.mem.mem_type];
>> void *rptr;
>> int ret;
>> struct io_mapping *map;
>> @@ -160,9 +159,7 @@ void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
>> else
>> goto fallback;
>>
>> - (void) ttm_mem_io_lock(man,...
2019 Sep 30
1
[Spice-devel] [PATCH 1/2] drm/qxl: stop abusing TTM to call driver internal functions
...48,6 @@ int qxl_bo_kmap(struct qxl_bo *bo, void **ptr)
>>>> void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
>>>> struct qxl_bo *bo, int page_offset)
>>>> {
>>>> - struct ttm_mem_type_manager *man =
>>>> &bo->tbo.bdev->man[bo->tbo.mem.mem_type];
>>>> void *rptr;
>>>> int ret;
>>>> struct io_mapping *map;
>>>> @@ -160,9 +159,7 @@ void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
>>>> else
>>>> goto fallbac...
2019 Sep 27
0
[Spice-devel] [PATCH 1/2] drm/qxl: stop abusing TTM to call driver internal functions
...ct.c
> +++ b/drivers/gpu/drm/qxl/qxl_object.c
> @@ -148,7 +148,6 @@ int qxl_bo_kmap(struct qxl_bo *bo, void **ptr)
> void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
> struct qxl_bo *bo, int page_offset)
> {
> - struct ttm_mem_type_manager *man =
> &bo->tbo.bdev->man[bo->tbo.mem.mem_type];
> void *rptr;
> int ret;
> struct io_mapping *map;
> @@ -160,9 +159,7 @@ void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
> else
> goto fallback;
>
> - (void) ttm_mem_io_lock(man, false);
> - ret = ttm_mem_io_reser...
2019 Sep 30
0
[Spice-devel] [PATCH 1/2] drm/qxl: stop abusing TTM to call driver internal functions
...;> @@ -148,7 +148,6 @@ int qxl_bo_kmap(struct qxl_bo *bo, void **ptr)
> >> void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
> >> struct qxl_bo *bo, int page_offset)
> >> {
> >> - struct ttm_mem_type_manager *man =
> >> &bo->tbo.bdev->man[bo->tbo.mem.mem_type];
> >> void *rptr;
> >> int ret;
> >> struct io_mapping *map;
> >> @@ -160,9 +159,7 @@ void *qxl_bo_kmap_atomic_page(struct qxl_device *qdev,
> >> else
> >> goto fallback;
> >>
>...
2019 Jul 02
2
[PATCH v6 11/18] drm/virtio: switch from ttm to gem shmem helpers
...rtio_gpu_object {
- struct drm_gem_object gem_base;
+ struct drm_gem_shmem_object base;
uint32_t hw_res_handle;
struct sg_table *pages;
uint32_t mapped;
- void *vmap;
bool dumb;
- struct ttm_place placement_code;
- struct ttm_placement placement;
- struct ttm_buffer_object tbo;
- struct ttm_bo_kmap_obj kmap;
bool created;
};
#define gem_to_virtio_gpu_obj(gobj) \
- container_of((gobj), struct virtio_gpu_object, gem_base)
+ container_of((gobj), struct virtio_gpu_object, base.base)
struct virtio_gpu_object_array {
struct ww_acquire_ctx ticket;
@@ -153,10 +145,6 @@...
2019 Jun 20
2
[PATCH v4 11/12] drm/virtio: switch from ttm to gem shmem helpers
...rtio_gpu_object {
- struct drm_gem_object gem_base;
+ struct drm_gem_shmem_object base;
uint32_t hw_res_handle;
struct sg_table *pages;
uint32_t mapped;
- void *vmap;
bool dumb;
- struct ttm_place placement_code;
- struct ttm_placement placement;
- struct ttm_buffer_object tbo;
- struct ttm_bo_kmap_obj kmap;
bool created;
};
#define gem_to_virtio_gpu_obj(gobj) \
- container_of((gobj), struct virtio_gpu_object, gem_base)
+ container_of((gobj), struct virtio_gpu_object, base.base)
struct virtio_gpu_object_array {
u32 nents;
@@ -152,10 +144,6 @@ struct virtio_gpu_...
2019 Jun 20
2
[PATCH v4 11/12] drm/virtio: switch from ttm to gem shmem helpers
...rtio_gpu_object {
- struct drm_gem_object gem_base;
+ struct drm_gem_shmem_object base;
uint32_t hw_res_handle;
struct sg_table *pages;
uint32_t mapped;
- void *vmap;
bool dumb;
- struct ttm_place placement_code;
- struct ttm_placement placement;
- struct ttm_buffer_object tbo;
- struct ttm_bo_kmap_obj kmap;
bool created;
};
#define gem_to_virtio_gpu_obj(gobj) \
- container_of((gobj), struct virtio_gpu_object, gem_base)
+ container_of((gobj), struct virtio_gpu_object, base.base)
struct virtio_gpu_object_array {
u32 nents;
@@ -152,10 +144,6 @@ struct virtio_gpu_...
2019 Jun 18
0
[PATCH v2 10/12] drm/virtio: switch from ttm to gem shmem helpers
...rtio_gpu_object {
- struct drm_gem_object gem_base;
+ struct drm_gem_shmem_object base;
uint32_t hw_res_handle;
struct sg_table *pages;
uint32_t mapped;
- void *vmap;
bool dumb;
- struct ttm_place placement_code;
- struct ttm_placement placement;
- struct ttm_buffer_object tbo;
- struct ttm_bo_kmap_obj kmap;
bool created;
};
#define gem_to_virtio_gpu_obj(gobj) \
- container_of((gobj), struct virtio_gpu_object, gem_base)
+ container_of((gobj), struct virtio_gpu_object, base.base)
struct virtio_gpu_vbuffer;
struct virtio_gpu_device;
@@ -147,10 +139,6 @@ struct vir...
2019 Jun 28
0
[PATCH v5 11/12] drm/virtio: switch from ttm to gem shmem helpers
...rtio_gpu_object {
- struct drm_gem_object gem_base;
+ struct drm_gem_shmem_object base;
uint32_t hw_res_handle;
struct sg_table *pages;
uint32_t mapped;
- void *vmap;
bool dumb;
- struct ttm_place placement_code;
- struct ttm_placement placement;
- struct ttm_buffer_object tbo;
- struct ttm_bo_kmap_obj kmap;
bool created;
};
#define gem_to_virtio_gpu_obj(gobj) \
- container_of((gobj), struct virtio_gpu_object, gem_base)
+ container_of((gobj), struct virtio_gpu_object, base.base)
struct virtio_gpu_object_array {
u32 nents;
@@ -152,10 +144,6 @@ struct virtio_gpu_...
2019 Jun 19
1
[PATCH v3 11/12] drm/virtio: switch from ttm to gem shmem helpers
...rtio_gpu_object {
- struct drm_gem_object gem_base;
+ struct drm_gem_shmem_object base;
uint32_t hw_res_handle;
struct sg_table *pages;
uint32_t mapped;
- void *vmap;
bool dumb;
- struct ttm_place placement_code;
- struct ttm_placement placement;
- struct ttm_buffer_object tbo;
- struct ttm_bo_kmap_obj kmap;
bool created;
};
#define gem_to_virtio_gpu_obj(gobj) \
- container_of((gobj), struct virtio_gpu_object, gem_base)
+ container_of((gobj), struct virtio_gpu_object, base.base)
struct virtio_gpu_vbuffer;
struct virtio_gpu_device;
@@ -148,10 +140,6 @@ struct vir...
2023 Jan 25
4
[PATCH v3 1/4] drm/amdgpu: Use cursor start instead of ttm resource start
...74039c82eb 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
@@ -1491,9 +1491,11 @@ u64 amdgpu_bo_gpu_offset(struct amdgpu_bo *bo)
u64 amdgpu_bo_gpu_offset_no_check(struct amdgpu_bo *bo)
{
struct amdgpu_device *adev = amdgpu_ttm_adev(bo->tbo.bdev);
+ struct amdgpu_res_cursor cursor;
uint64_t offset;
- offset = (bo->tbo.resource->start << PAGE_SHIFT) +
+ amdgpu_res_first(bo->tbo.resource, 0, bo->tbo.resource->size, &cursor);
+ offset = cursor.start +
amdgpu_ttm_domain_start(adev, bo->tbo.resource->...
2019 Jun 27
0
[PATCH v4 11/12] drm/virtio: switch from ttm to gem shmem helpers
...t hw_res_handle;
>
> struct sg_table *pages;
> uint32_t mapped;
> - void *vmap;
> bool dumb;
> - struct ttm_place placement_code;
> - struct ttm_placement placement;
> - struct ttm_buffer_object tbo;
> - struct ttm_bo_kmap_obj kmap;
> bool created;
> };
> #define gem_to_virtio_gpu_obj(gobj) \
> - container_of((gobj), struct virtio_gpu_object, gem_base)
> + container_of((gobj), struct virtio_gpu_object, base.base)
>
> struct virtio_g...