Commit c3cca41e authored by Christian König's avatar Christian König Committed by Alex Deucher

drm/amdgpu: cleanup amdgpu_cs_parser structure

Remove unused user_ptr field, group fields by usage.
Signed-off-by: default avatarChristian König <christian.koenig@amd.com>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 25cfc3c2
...@@ -1247,29 +1247,30 @@ struct amdgpu_cs_chunk { ...@@ -1247,29 +1247,30 @@ struct amdgpu_cs_chunk {
uint32_t chunk_id; uint32_t chunk_id;
uint32_t length_dw; uint32_t length_dw;
uint32_t *kdata; uint32_t *kdata;
void __user *user_ptr;
}; };
struct amdgpu_cs_parser { struct amdgpu_cs_parser {
struct amdgpu_device *adev; struct amdgpu_device *adev;
struct drm_file *filp; struct drm_file *filp;
struct amdgpu_ctx *ctx; struct amdgpu_ctx *ctx;
struct amdgpu_bo_list *bo_list;
/* chunks */ /* chunks */
unsigned nchunks; unsigned nchunks;
struct amdgpu_cs_chunk *chunks; struct amdgpu_cs_chunk *chunks;
/* relocations */
/* indirect buffers */
uint32_t num_ibs;
struct amdgpu_ib *ibs;
/* buffer objects */
struct ww_acquire_ctx ticket;
struct amdgpu_bo_list *bo_list;
struct amdgpu_bo_list_entry vm_pd; struct amdgpu_bo_list_entry vm_pd;
struct list_head validated; struct list_head validated;
struct fence *fence; struct fence *fence;
uint64_t bytes_moved_threshold; uint64_t bytes_moved_threshold;
uint64_t bytes_moved; uint64_t bytes_moved;
struct amdgpu_ib *ibs;
uint32_t num_ibs;
struct ww_acquire_ctx ticket;
/* user fence */ /* user fence */
struct amdgpu_user_fence uf; struct amdgpu_user_fence uf;
struct amdgpu_bo_list_entry uf_entry; struct amdgpu_bo_list_entry uf_entry;
......
...@@ -217,7 +217,6 @@ int amdgpu_cs_parser_init(struct amdgpu_cs_parser *p, void *data) ...@@ -217,7 +217,6 @@ int amdgpu_cs_parser_init(struct amdgpu_cs_parser *p, void *data)
size = p->chunks[i].length_dw; size = p->chunks[i].length_dw;
cdata = (void __user *)(unsigned long)user_chunk.chunk_data; cdata = (void __user *)(unsigned long)user_chunk.chunk_data;
p->chunks[i].user_ptr = cdata;
p->chunks[i].kdata = drm_malloc_ab(size, sizeof(uint32_t)); p->chunks[i].kdata = drm_malloc_ab(size, sizeof(uint32_t));
if (p->chunks[i].kdata == NULL) { if (p->chunks[i].kdata == NULL) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment