summaryrefslogtreecommitdiff
path: root/amdgpu
diff options
context:
space:
mode:
authorMarek Olšák <marek.olsak@amd.com>2015-06-02 13:05:41 +0200
committerAlex Deucher <alexander.deucher@amd.com>2015-08-05 13:47:51 -0400
commit76af5c249fa438d8466b7e7dbda318da8f829eac (patch)
tree7a013b36fa601f853a8aff057ba198d67ba580a5 /amdgpu
parent646f5411cf36413c903eb6db48b5e7febd893ec5 (diff)
downloadlibdrm-76af5c249fa438d8466b7e7dbda318da8f829eac.tar.gz
libdrm-76af5c249fa438d8466b7e7dbda318da8f829eac.tar.bz2
libdrm-76af5c249fa438d8466b7e7dbda318da8f829eac.zip
amdgpu: remove bo_handle from amdgpu_cs_ib_info, IBs should be in buffer list
Reviewed-by: Christian König <christian.koenig@amd.com>
Diffstat (limited to 'amdgpu')
-rw-r--r--amdgpu/amdgpu.h7
-rw-r--r--amdgpu/amdgpu_cs.c5
2 files changed, 4 insertions, 8 deletions
diff --git a/amdgpu/amdgpu.h b/amdgpu/amdgpu.h
index 451437da..70b488e3 100644
--- a/amdgpu/amdgpu.h
+++ b/amdgpu/amdgpu.h
@@ -283,8 +283,8 @@ struct amdgpu_cs_ib_info {
/** Special flags */
uint64_t flags;
- /** Handle of command buffer */
- amdgpu_bo_handle bo_handle;
+ /** Virtual MC address of the command buffer */
+ uint64_t ib_mc_address;
/**
* Size of Command Buffer to be submitted.
@@ -293,9 +293,6 @@ struct amdgpu_cs_ib_info {
* - Could be 0
*/
uint32_t size;
-
- /** Offset in the IB buffer object (in unit of dwords) */
- uint32_t offset_dw;
};
/**
diff --git a/amdgpu/amdgpu_cs.c b/amdgpu/amdgpu_cs.c
index 2a039d6d..a1e68f85 100644
--- a/amdgpu/amdgpu_cs.c
+++ b/amdgpu/amdgpu_cs.c
@@ -224,9 +224,8 @@ static int amdgpu_cs_submit_one(amdgpu_context_handle context,
ib = &ibs_request->ibs[i];
- chunk_data[i].ib_data.handle = ib->bo_handle->handle;
- chunk_data[i].ib_data.va_start = ib->bo_handle->virtual_mc_base_address
- + ib->offset_dw * 4;
+ chunk_data[i].ib_data._pad = 0;
+ chunk_data[i].ib_data.va_start = ib->ib_mc_address;
chunk_data[i].ib_data.ib_bytes = ib->size * 4;
chunk_data[i].ib_data.ip_type = ibs_request->ip_type;
chunk_data[i].ib_data.ip_instance = ibs_request->ip_instance;