Skip to contentSkip to conversation

Revert "drm/amdgpu/gfx9: put queue resets behind a debug option"

PATCH In review Alex Deucher 3 participants 3 messages Oct 15, 2024 – Oct 16, 2024

Subsystems (3)
lore
Share & tools
lore

Alex Deucher

author maintainer
#0 lore raw

PATCH 1/1 Revert "drm/amdgpu/gfx9: put queue resets behind a debug option"

This reverts commit 7c1a2d8aba6cadde0cc542b2d805edc0be667e79.

Extended validation has completed successfully, so enable these features by default.

Cc Jonathan Kim <[email protected]>
Cc Jiadong Zhu <[email protected]>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c | 4 ----
 drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c             | 4 ----
 drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c           | 6 ------
 3 files changed, 14 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c +0 -4
index 2817198d4b55..740525407154 100644
@@ -1132,10 +1132,6 @@ uint64_t kgd_gfx_v9_hqd_get_pq_addr(struct amdgpu_device *adev,
 	uint32_t low, high;
 	uint64_t queue_addr = 0;
 
-	if (!adev->debug_exp_resets &&
-	    !adev->gfx.num_gfx_rings)
-		return 0;
-
 	kgd_gfx_v9_acquire_queue(adev, pipe_id, queue_id, inst);
 	amdgpu_gfx_rlc_enter_safe_mode(adev, inst);
 
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +0 -4
index b5102da25798..508a2dcc0b1a 100644
@@ -7260,10 +7260,6 @@ static int gfx_v9_0_reset_kcq(struct amdgpu_ring *ring,
 	unsigned long flags;
 	int i, r;
 
-	if (!adev->debug_exp_resets &&
-	    !adev->gfx.num_gfx_rings)
-		return -EINVAL;
-
 	if (amdgpu_sriov_vf(adev))
 		return -EINVAL;
 
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +0 -6
index ccd17dca0396..4fd7e9c5856c 100644
@@ -3055,9 +3055,6 @@ static void gfx_v9_4_3_ring_soft_recovery(struct amdgpu_ring *ring,
 	struct amdgpu_device *adev = ring->adev;
 	uint32_t value = 0;
 
-	if (!adev->debug_exp_resets)
-		return;
-
 	value = REG_SET_FIELD(value, SQ_CMD, CMD, 0x03);
 	value = REG_SET_FIELD(value, SQ_CMD, MODE, 0x01);
 	value = REG_SET_FIELD(value, SQ_CMD, CHECK_VMID, 1);
@@ -3573,9 +3570,6 @@ static int gfx_v9_4_3_reset_kcq(struct amdgpu_ring *ring,
 	unsigned long flags;
 	int r;
 
-	if (!adev->debug_exp_resets)
-		return -EINVAL;
-
 	if (amdgpu_sriov_vf(adev))
 		return -EINVAL;
 
Signature · 1 line
2.46.2
Acked-by on v1 1/1
#1 lore raw

[AMD Official Use Only - AMD Internal Distribution Only]

Quoted 85 lines

-----Original Message-----
From: Deucher, Alexander <[email protected]>
Sent: Wednesday, October 16, 2024 4:00 AM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>; Kim, Jonathan <[email protected]>; Zhu, Jiadong <[email protected]>
Subject: [PATCH] Revert "drm/amdgpu/gfx9: put queue resets behind a debug option"

This reverts commit 7c1a2d8aba6cadde0cc542b2d805edc0be667e79.

Extended validation has completed successfully, so enable these features by default.

Cc Jonathan Kim <[email protected]>
Cc Jiadong Zhu <[email protected]>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c | 4 ----
 drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c             | 4 ----
 drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c           | 6 ------
 3 files changed, 14 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c +0 -4
index 2817198d4b55..740525407154 100644
@@ -1132,10 +1132,6 @@ uint64_t kgd_gfx_v9_hqd_get_pq_addr(struct
 amdgpu_device *adev,
      uint32_t low, high;
      uint64_t queue_addr = 0;
 
-     if (!adev->debug_exp_resets &&
-         !adev->gfx.num_gfx_rings)
-             return 0;
-
      kgd_gfx_v9_acquire_queue(adev, pipe_id, queue_id, inst);
      amdgpu_gfx_rlc_enter_safe_mode(adev, inst);
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +0 -4
index b5102da25798..508a2dcc0b1a 100644
@@ -7260,10 +7260,6 @@ static int gfx_v9_0_reset_kcq(struct amdgpu_ring
 *ring,
      unsigned long flags;
      int i, r;
 
-     if (!adev->debug_exp_resets &&
-         !adev->gfx.num_gfx_rings)
-             return -EINVAL;
-
      if (amdgpu_sriov_vf(adev))
              return -EINVAL;
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +0 -3
index ccd17dca0396..4fd7e9c5856c 100644
@@ -3055,9 +3055,6 @@ static void gfx_v9_4_3_ring_soft_recovery(struct
 amdgpu_ring *ring,
      struct amdgpu_device *adev = ring->adev;
      uint32_t value = 0;
 
-     if (!adev->debug_exp_resets)
-             return;
-
      value = REG_SET_FIELD(value, SQ_CMD, CMD, 0x03);
      value = REG_SET_FIELD(value, SQ_CMD, MODE, 0x01);
      value = REG_SET_FIELD(value, SQ_CMD, CHECK_VMID, 1); @@ -
3573,9 +3570,6 @@ static int gfx_v9_4_3_reset_kcq(struct amdgpu_ring *ring,
      unsigned long flags;
      int r;
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +0 -4
-     if (!adev->debug_exp_resets)
-             return -EINVAL;
-
      if (amdgpu_sriov_vf(adev))
              return -EINVAL;
 
--

2.46.2

Reviewed-by on v1 1/1
#2 lore raw
In reply to Alex Deucher

[Public]

Quoted 9 lines

-----Original Message-----
From: Deucher, Alexander <[email protected]>
Sent: Tuesday, October 15, 2024 4:00 PM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>; Kim, Jonathan <[email protected]>; Zhu, Jiadong <[email protected]>
Subject: [PATCH] Revert "drm/amdgpu/gfx9: put queue resets behind a debug option"

Quoted 8 lines

This reverts commit 7c1a2d8aba6cadde0cc542b2d805edc0be667e79.

Extended validation has completed successfully, so enable these features by default.

Cc Jonathan Kim <[email protected]>
Cc Jiadong Zhu <[email protected]>
Quoted 67 lines
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c | 4 ----
 drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c             | 4 ----
 drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c           | 6 ------
 3 files changed, 14 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c +0 -4
index 2817198d4b55..740525407154 100644
@@ -1132,10 +1132,6 @@ uint64_t kgd_gfx_v9_hqd_get_pq_addr(struct
 amdgpu_device *adev,
      uint32_t low, high;
      uint64_t queue_addr = 0;
 
-     if (!adev->debug_exp_resets &&
-         !adev->gfx.num_gfx_rings)
-             return 0;
-
      kgd_gfx_v9_acquire_queue(adev, pipe_id, queue_id, inst);
      amdgpu_gfx_rlc_enter_safe_mode(adev, inst);
drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c +0 -4
index b5102da25798..508a2dcc0b1a 100644
@@ -7260,10 +7260,6 @@ static int gfx_v9_0_reset_kcq(struct amdgpu_ring *ring,
      unsigned long flags;
      int i, r;
 
-     if (!adev->debug_exp_resets &&
-         !adev->gfx.num_gfx_rings)
-             return -EINVAL;
-
      if (amdgpu_sriov_vf(adev))
              return -EINVAL;
 
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +0 -3
index ccd17dca0396..4fd7e9c5856c 100644
@@ -3055,9 +3055,6 @@ static void gfx_v9_4_3_ring_soft_recovery(struct
 amdgpu_ring *ring,
      struct amdgpu_device *adev = ring->adev;
      uint32_t value = 0;
 
-     if (!adev->debug_exp_resets)
-             return;
-
      value = REG_SET_FIELD(value, SQ_CMD, CMD, 0x03);
      value = REG_SET_FIELD(value, SQ_CMD, MODE, 0x01);
      value = REG_SET_FIELD(value, SQ_CMD, CHECK_VMID, 1);
drivers/gpu/drm/amd/amdgpu/gfx_v9_4_3.c +0 -4
@@ -3573,9 +3570,6 @@ static int gfx_v9_4_3_reset_kcq(struct amdgpu_ring *ring,
      unsigned long flags;
      int r;
 
-     if (!adev->debug_exp_resets)
-             return -EINVAL;
-
      if (amdgpu_sriov_vf(adev))
              return -EINVAL;
 
--

2.46.2