Skip to contentSkip to conversation

drm/amdgpu: Initialize xcc mask

PATCH In review Lijo Lazar 2 participants 2 messages May 30, 2023

Subsystems (2)
lore
Share & tools
lore

Lijo Lazar

author
#0 lore raw

PATCH 1/1 drm/amdgpu: Initialize xcc mask

For ASICs which are not initialized through discovery, initialize GFX cluster as 1.

---
 drivers/gpu/drm/amd/amdgpu/gfx_v6_0.c | 1 +
 drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 1 +
 drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 1 +
 3 files changed, 3 insertions(+)
drivers/gpu/drm/amd/amdgpu/gfx_v6_0.c +1 -0
index 809558c718e3..da6caff78c22 100644
@@ -3028,6 +3028,7 @@ static int gfx_v6_0_early_init(void *handle)
 {
 	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
+	adev->gfx.xcc_mask = 1;
 	adev->gfx.num_gfx_rings = GFX6_NUM_GFX_RINGS;
 	adev->gfx.num_compute_rings = min(amdgpu_gfx_get_num_kcq(adev),
 					  GFX6_NUM_COMPUTE_RINGS);
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c +1 -0
index 0f0c12bbe228..20fcd86a3e79 100644
@@ -4179,6 +4179,7 @@ static int gfx_v7_0_early_init(void *handle)
 {
 	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
+	adev->gfx.xcc_mask = 1;
 	adev->gfx.num_gfx_rings = GFX7_NUM_GFX_RINGS;
 	adev->gfx.num_compute_rings = min(amdgpu_gfx_get_num_kcq(adev),
 					  AMDGPU_MAX_COMPUTE_RINGS);
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +1 -0
index 2f1ef75e126c..51c1745c8369 100644
@@ -5262,6 +5262,7 @@ static int gfx_v8_0_early_init(void *handle)
 {
 	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
+	adev->gfx.xcc_mask = 1;
 	adev->gfx.num_gfx_rings = GFX8_NUM_GFX_RINGS;
 	adev->gfx.num_compute_rings = min(amdgpu_gfx_get_num_kcq(adev),
 					  AMDGPU_MAX_COMPUTE_RINGS);
Signature · 1 line
2.25.1
Reviewed-by on v1 1/1
#1 lore raw

[AMD Official Use Only - General]

Regards,
Hawking
-----Original Message-----
From: Lazar, Lijo <[email protected]>
Sent: Tuesday, May 30, 2023 14:51
To: [email protected]
Cc: Zhang, Hawking <[email protected]>; Deucher, Alexander <[email protected]>
Subject: [PATCH] drm/amdgpu: Initialize xcc mask

For ASICs which are not initialized through discovery, initialize GFX cluster as 1.

---
 drivers/gpu/drm/amd/amdgpu/gfx_v6_0.c | 1 +  drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c | 1 +  drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 1 +
 3 files changed, 3 insertions(+)
drivers/gpu/drm/amd/amdgpu/gfx_v6_0.c +1 -0
index 809558c718e3..da6caff78c22 100644
@@ -3028,6 +3028,7 @@ static int gfx_v6_0_early_init(void *handle)  {
        struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
+       adev->gfx.xcc_mask = 1;
        adev->gfx.num_gfx_rings = GFX6_NUM_GFX_RINGS;
        adev->gfx.num_compute_rings = min(amdgpu_gfx_get_num_kcq(adev),
                                          GFX6_NUM_COMPUTE_RINGS);
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c +1 -0
index 0f0c12bbe228..20fcd86a3e79 100644
@@ -4179,6 +4179,7 @@ static int gfx_v7_0_early_init(void *handle)  {
        struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
+       adev->gfx.xcc_mask = 1;
        adev->gfx.num_gfx_rings = GFX7_NUM_GFX_RINGS;
        adev->gfx.num_compute_rings = min(amdgpu_gfx_get_num_kcq(adev),
                                          AMDGPU_MAX_COMPUTE_RINGS);
drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c +1 -1
index 2f1ef75e126c..51c1745c8369 100644
@@ -5262,6 +5262,7 @@ static int gfx_v8_0_early_init(void *handle)  {
        struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
+       adev->gfx.xcc_mask = 1;
        adev->gfx.num_gfx_rings = GFX8_NUM_GFX_RINGS;
        adev->gfx.num_compute_rings = min(amdgpu_gfx_get_num_kcq(adev),
                                          AMDGPU_MAX_COMPUTE_RINGS);
--

2.25.1