mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-08-05 16:54:27 +00:00
drm/amdgpu: add hdp invalidation for gfx7
Signed-off-by: Chunming Zhou <David1.Zhou@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
11afbde85e
commit
0955860b87
1 changed files with 21 additions and 0 deletions
|
@ -1924,6 +1924,25 @@ static void gfx_v7_0_ring_emit_hdp_flush(struct amdgpu_ring *ring)
|
||||||
amdgpu_ring_write(ring, 0x20); /* poll interval */
|
amdgpu_ring_write(ring, 0x20); /* poll interval */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* gfx_v7_0_ring_emit_hdp_invalidate - emit an hdp invalidate on the cp
|
||||||
|
*
|
||||||
|
* @adev: amdgpu_device pointer
|
||||||
|
* @ridx: amdgpu ring index
|
||||||
|
*
|
||||||
|
* Emits an hdp invalidate on the cp.
|
||||||
|
*/
|
||||||
|
static void gfx_v7_0_ring_emit_hdp_invalidate(struct amdgpu_ring *ring)
|
||||||
|
{
|
||||||
|
amdgpu_ring_write(ring, PACKET3(PACKET3_WRITE_DATA, 3));
|
||||||
|
amdgpu_ring_write(ring, (WRITE_DATA_ENGINE_SEL(0) |
|
||||||
|
WRITE_DATA_DST_SEL(0) |
|
||||||
|
WR_CONFIRM));
|
||||||
|
amdgpu_ring_write(ring, mmHDP_DEBUG0);
|
||||||
|
amdgpu_ring_write(ring, 0);
|
||||||
|
amdgpu_ring_write(ring, 1);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* gfx_v7_0_ring_emit_fence_gfx - emit a fence on the gfx ring
|
* gfx_v7_0_ring_emit_fence_gfx - emit a fence on the gfx ring
|
||||||
*
|
*
|
||||||
|
@ -5132,6 +5151,7 @@ static const struct amdgpu_ring_funcs gfx_v7_0_ring_funcs_gfx = {
|
||||||
.emit_vm_flush = gfx_v7_0_ring_emit_vm_flush,
|
.emit_vm_flush = gfx_v7_0_ring_emit_vm_flush,
|
||||||
.emit_gds_switch = gfx_v7_0_ring_emit_gds_switch,
|
.emit_gds_switch = gfx_v7_0_ring_emit_gds_switch,
|
||||||
.emit_hdp_flush = gfx_v7_0_ring_emit_hdp_flush,
|
.emit_hdp_flush = gfx_v7_0_ring_emit_hdp_flush,
|
||||||
|
.emit_hdp_invalidate = gfx_v7_0_ring_emit_hdp_invalidate,
|
||||||
.test_ring = gfx_v7_0_ring_test_ring,
|
.test_ring = gfx_v7_0_ring_test_ring,
|
||||||
.test_ib = gfx_v7_0_ring_test_ib,
|
.test_ib = gfx_v7_0_ring_test_ib,
|
||||||
.insert_nop = amdgpu_ring_insert_nop,
|
.insert_nop = amdgpu_ring_insert_nop,
|
||||||
|
@ -5148,6 +5168,7 @@ static const struct amdgpu_ring_funcs gfx_v7_0_ring_funcs_compute = {
|
||||||
.emit_vm_flush = gfx_v7_0_ring_emit_vm_flush,
|
.emit_vm_flush = gfx_v7_0_ring_emit_vm_flush,
|
||||||
.emit_gds_switch = gfx_v7_0_ring_emit_gds_switch,
|
.emit_gds_switch = gfx_v7_0_ring_emit_gds_switch,
|
||||||
.emit_hdp_flush = gfx_v7_0_ring_emit_hdp_flush,
|
.emit_hdp_flush = gfx_v7_0_ring_emit_hdp_flush,
|
||||||
|
.emit_hdp_invalidate = gfx_v7_0_ring_emit_hdp_invalidate,
|
||||||
.test_ring = gfx_v7_0_ring_test_ring,
|
.test_ring = gfx_v7_0_ring_test_ring,
|
||||||
.test_ib = gfx_v7_0_ring_test_ib,
|
.test_ib = gfx_v7_0_ring_test_ib,
|
||||||
.insert_nop = amdgpu_ring_insert_nop,
|
.insert_nop = amdgpu_ring_insert_nop,
|
||||||
|
|
Loading…
Add table
Reference in a new issue