diff options
| author | Chunming Zhou <[email protected]> | 2016-08-04 08:51:18 +0000 |
|---|---|---|
| committer | Alex Deucher <[email protected]> | 2016-08-22 17:47:18 +0000 |
| commit | 20f4eff1c8ba344d5c22234ac5611ff1489fbea6 (patch) | |
| tree | 5269d95537b47d5d33558888f9c66a2fb4f0fe13 /drivers/gpu/drm/amd/amdgpu/amdgpu_object.h | |
| parent | drm/amdgpu: add direct submision option for copy_buffer (diff) | |
| download | kernel-20f4eff1c8ba344d5c22234ac5611ff1489fbea6.tar.gz kernel-20f4eff1c8ba344d5c22234ac5611ff1489fbea6.zip | |
drm/amdgpu: sync bo and shadow V3
Use shadow flag to judge which direction to sync.
V2:
Don't need bo pin, so remove it.
V3:
1. Split to two functions, one is backup_to_shadow, another is
restore_from_shadow.
2. Clean up previous shadow direction difinitions.
Signed-off-by: Chunming Zhou <[email protected]>
Reviewed-by: Christian König <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_object.h')
| -rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_object.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h index d650b42279e5..b6a27390ef88 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.h @@ -155,6 +155,18 @@ int amdgpu_bo_fault_reserve_notify(struct ttm_buffer_object *bo); void amdgpu_bo_fence(struct amdgpu_bo *bo, struct fence *fence, bool shared); u64 amdgpu_bo_gpu_offset(struct amdgpu_bo *bo); +int amdgpu_bo_backup_to_shadow(struct amdgpu_device *adev, + struct amdgpu_ring *ring, + struct amdgpu_bo *bo, + struct reservation_object *resv, + struct fence **fence, bool direct); +int amdgpu_bo_restore_from_shadow(struct amdgpu_device *adev, + struct amdgpu_ring *ring, + struct amdgpu_bo *bo, + struct reservation_object *resv, + struct fence **fence, + bool direct); + /* * sub allocation |
