All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] drm/amdgpu/sdma5.0: enable ctxempty interrupt
@ 2020-12-01 23:18 Alex Deucher
  2020-12-01 23:18 ` [PATCH 2/2] drm/amdgpu/sdma5.2: " Alex Deucher
  0 siblings, 1 reply; 2+ messages in thread
From: Alex Deucher @ 2020-12-01 23:18 UTC (permalink / raw)
  To: amd-gfx; +Cc: Alex Deucher

This is may be required for proper gfxoff operation with
SDMA workloads.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c b/drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c
index b208b81005bb..2699b8ea82ed 100644
--- a/drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c
@@ -810,6 +810,15 @@ static int sdma_v5_0_gfx_resume(struct amdgpu_device *adev)
  */
 static int sdma_v5_0_rlc_resume(struct amdgpu_device *adev)
 {
+	int i;
+	u32 sdma_cntl;
+
+	for (i = 0; i < adev->sdma.num_instances; i++) {
+		sdma_cntl = RREG32(sdma_v5_0_get_reg_offset(adev, i, mmSDMA0_CNTL));
+		sdma_cntl = REG_SET_FIELD(sdma_cntl, SDMA0_CNTL, CTXEMPTY_INT_ENABLE, 1);
+		WREG32(sdma_v5_0_get_reg_offset(adev, i, mmSDMA0_CNTL), sdma_cntl);
+	}
+
 	return 0;
 }
 
-- 
2.25.4

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [PATCH 2/2] drm/amdgpu/sdma5.2: enable ctxempty interrupt
  2020-12-01 23:18 [PATCH 1/2] drm/amdgpu/sdma5.0: enable ctxempty interrupt Alex Deucher
@ 2020-12-01 23:18 ` Alex Deucher
  0 siblings, 0 replies; 2+ messages in thread
From: Alex Deucher @ 2020-12-01 23:18 UTC (permalink / raw)
  To: amd-gfx; +Cc: Alex Deucher

This is may be required for proper gfxoff operation with
SDMA workloads.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c b/drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c
index ca8d93ebd7f9..3043569665c5 100644
--- a/drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c
+++ b/drivers/gpu/drm/amd/amdgpu/sdma_v5_2.c
@@ -760,6 +760,15 @@ static int sdma_v5_2_gfx_resume(struct amdgpu_device *adev)
  */
 static int sdma_v5_2_rlc_resume(struct amdgpu_device *adev)
 {
+	int i;
+	u32 sdma_cntl;
+
+	for (i = 0; i < adev->sdma.num_instances; i++) {
+		sdma_cntl = RREG32(sdma_v5_2_get_reg_offset(adev, i, mmSDMA0_CNTL));
+		sdma_cntl = REG_SET_FIELD(sdma_cntl, SDMA0_CNTL, CTXEMPTY_INT_ENABLE, 1);
+		WREG32(sdma_v5_2_get_reg_offset(adev, i, mmSDMA0_CNTL), sdma_cntl);
+	}
+
 	return 0;
 }
 
-- 
2.25.4

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-12-01 23:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-01 23:18 [PATCH 1/2] drm/amdgpu/sdma5.0: enable ctxempty interrupt Alex Deucher
2020-12-01 23:18 ` [PATCH 2/2] drm/amdgpu/sdma5.2: " Alex Deucher

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.