All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] drm/amdgpu: move amdgpu_gmc_noretry_set after ip_versions populated
@ 2022-03-01 13:05 Yifan Zhang
  2022-03-01 13:05 ` [PATCH 2/2] drm/amdgpu: add noretry=1 for gc 10.3.6 Yifan Zhang
  0 siblings, 1 reply; 3+ messages in thread
From: Yifan Zhang @ 2022-03-01 13:05 UTC (permalink / raw)
  To: amd-gfx; +Cc: Alexander.Deucher, Yifan Zhang, Ray.Huang

otherwise adev->ip_versions is still empty when amdgpu_gmc_noretry_set
is called.

Signed-off-by: Yifan Zhang <yifan1.zhang@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
index 6113ddc765a7..61a6a7920c76 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
@@ -1554,7 +1554,6 @@ static int amdgpu_device_check_arguments(struct amdgpu_device *adev)
 
 	amdgpu_gmc_tmz_set(adev);
 
-	amdgpu_gmc_noretry_set(adev);
 
 	return 0;
 }
@@ -3641,6 +3640,7 @@ int amdgpu_device_init(struct amdgpu_device *adev,
 	if (r)
 		return r;
 
+	amdgpu_gmc_noretry_set(adev);
 	/* Need to get xgmi info early to decide the reset behavior*/
 	if (adev->gmc.xgmi.supported) {
 		r = adev->gfxhub.funcs->get_xgmi_info(adev);
-- 
2.25.1


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

* [PATCH 2/2] drm/amdgpu: add noretry=1 for gc 10.3.6
  2022-03-01 13:05 [PATCH 1/2] drm/amdgpu: move amdgpu_gmc_noretry_set after ip_versions populated Yifan Zhang
@ 2022-03-01 13:05 ` Yifan Zhang
  2022-03-01 13:15   ` Christian König
  0 siblings, 1 reply; 3+ messages in thread
From: Yifan Zhang @ 2022-03-01 13:05 UTC (permalink / raw)
  To: amd-gfx; +Cc: Alexander.Deucher, Yifan Zhang, Ray.Huang, Aaron Liu

From: Aaron Liu <aaron.liu@amd.com>

By default, set noretry=1 for kfd exception test.

Signed-off-by: Aaron Liu <aaron.liu@amd.com>
Signed-off-by: Yifan Zhang <yifan1.zhang@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
index ab75e189bc0b..4bbd8501c6c1 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
@@ -595,6 +595,13 @@ void amdgpu_gmc_noretry_set(struct amdgpu_device *adev)
 			gmc->noretry = amdgpu_noretry;
 		break;
 	}
+
+	if (adev->ip_versions[GC_HWIP][0] == IP_VERSION(10, 3, 6)) {
+		if (amdgpu_noretry == -1)
+			gmc->noretry = 1;
+		else
+			gmc->noretry = amdgpu_noretry;
+	}
 }
 
 void amdgpu_gmc_set_vm_fault_masks(struct amdgpu_device *adev, int hub_type,
-- 
2.25.1


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

* Re: [PATCH 2/2] drm/amdgpu: add noretry=1 for gc 10.3.6
  2022-03-01 13:05 ` [PATCH 2/2] drm/amdgpu: add noretry=1 for gc 10.3.6 Yifan Zhang
@ 2022-03-01 13:15   ` Christian König
  0 siblings, 0 replies; 3+ messages in thread
From: Christian König @ 2022-03-01 13:15 UTC (permalink / raw)
  To: Yifan Zhang, amd-gfx; +Cc: Alexander.Deucher, Ray.Huang, Aaron Liu

Am 01.03.22 um 14:05 schrieb Yifan Zhang:
> From: Aaron Liu <aaron.liu@amd.com>
>
> By default, set noretry=1 for kfd exception test.
>
> Signed-off-by: Aaron Liu <aaron.liu@amd.com>
> Signed-off-by: Yifan Zhang <yifan1.zhang@amd.com>
> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c | 7 +++++++
>   1 file changed, 7 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
> index ab75e189bc0b..4bbd8501c6c1 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.c
> @@ -595,6 +595,13 @@ void amdgpu_gmc_noretry_set(struct amdgpu_device *adev)
>   			gmc->noretry = amdgpu_noretry;
>   		break;
>   	}
> +
> +	if (adev->ip_versions[GC_HWIP][0] == IP_VERSION(10, 3, 6)) {
> +		if (amdgpu_noretry == -1)
> +			gmc->noretry = 1;
> +		else
> +			gmc->noretry = amdgpu_noretry;
> +	}

You should probably move the whole switch case to version checks instead.

Christian.

>   }
>   
>   void amdgpu_gmc_set_vm_fault_masks(struct amdgpu_device *adev, int hub_type,


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

end of thread, other threads:[~2022-03-01 13:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-01 13:05 [PATCH 1/2] drm/amdgpu: move amdgpu_gmc_noretry_set after ip_versions populated Yifan Zhang
2022-03-01 13:05 ` [PATCH 2/2] drm/amdgpu: add noretry=1 for gc 10.3.6 Yifan Zhang
2022-03-01 13:15   ` Christian König

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.