Skip to contentSkip to conversation

drm/amdkfd: simplify cases

PATCH In review Alex Deucher 3 participants 3 messages Dec 27, 2022 – Jan 3, 2023

Subsystems (3)
lore
Share & tools
lore

Alex Deucher

author maintainer
#0 lore raw

PATCH 1/1 drm/amdkfd: simplify cases

A number of of the gfx8 cases where the same. Clean them up.

---
 drivers/gpu/drm/amd/amdkfd/kfd_device.c | 11 -----------
 1 file changed, 11 deletions(-)
drivers/gpu/drm/amd/amdkfd/kfd_device.c +0 -11
index 091fc2bb8ce5..521dfa88aad8 100644
@@ -263,23 +263,12 @@ struct kfd_dev *kgd2kfd_probe(struct amdgpu_device *adev, bool vf)
 			f2g = &gfx_v8_kfd2kgd;
 		break;
 	case CHIP_FIJI:
-		gfx_target_version = 80003;
-		f2g = &gfx_v8_kfd2kgd;
-		break;
 	case CHIP_POLARIS10:
 		gfx_target_version = 80003;
 		f2g = &gfx_v8_kfd2kgd;
 		break;
 	case CHIP_POLARIS11:
-		gfx_target_version = 80003;
-		if (!vf)
-			f2g = &gfx_v8_kfd2kgd;
-		break;
 	case CHIP_POLARIS12:
-		gfx_target_version = 80003;
-		if (!vf)
-			f2g = &gfx_v8_kfd2kgd;
-		break;
 	case CHIP_VEGAM:
 		gfx_target_version = 80003;
 		if (!vf)
Signature · 1 line
2.38.1
#1 lore raw
Quoted 3 lines · Alex Deucher

A number of of the gfx8 cases where the same. Clean them up.

typos here fixed up locally.

Alex

Quoted 37 lines
---
 drivers/gpu/drm/amd/amdkfd/kfd_device.c | 11 -----------
 1 file changed, 11 deletions(-)
drivers/gpu/drm/amd/amdkfd/kfd_device.c +0 -12
index 091fc2bb8ce5..521dfa88aad8 100644
@@ -263,23 +263,12 @@ struct kfd_dev *kgd2kfd_probe(struct amdgpu_device *adev, bool vf)
                        f2g = &gfx_v8_kfd2kgd;
                break;
        case CHIP_FIJI:
-               gfx_target_version = 80003;
-               f2g = &gfx_v8_kfd2kgd;
-               break;
        case CHIP_POLARIS10:
                gfx_target_version = 80003;
                f2g = &gfx_v8_kfd2kgd;
                break;
        case CHIP_POLARIS11:
-               gfx_target_version = 80003;
-               if (!vf)
-                       f2g = &gfx_v8_kfd2kgd;
-               break;
        case CHIP_POLARIS12:
-               gfx_target_version = 80003;
-               if (!vf)
-                       f2g = &gfx_v8_kfd2kgd;
-               break;
        case CHIP_VEGAM:
                gfx_target_version = 80003;
                if (!vf)
--

2.38.1

maintainer Reviewed-by
#2 lore raw

Am 2022-12-27 um 12:12 schrieb Alex Deucher:

Quoted 8 lines · Alex Deucher
Quoted 2 lines

A number of of the gfx8 cases where the same. Clean them up.

typos here fixed up locally.

Alex

Quoted 1 line
Quoted 35 lines
Quoted 35 lines
---
  drivers/gpu/drm/amd/amdkfd/kfd_device.c | 11 -----------
  1 file changed, 11 deletions(-)
drivers/gpu/drm/amd/amdkfd/kfd_device.c +0 -12
index 091fc2bb8ce5..521dfa88aad8 100644
@@ -263,23 +263,12 @@ struct kfd_dev *kgd2kfd_probe(struct amdgpu_device *adev, bool vf)
                         f2g = &gfx_v8_kfd2kgd;
                 break;
         case CHIP_FIJI:
-               gfx_target_version = 80003;
-               f2g = &gfx_v8_kfd2kgd;
-               break;
         case CHIP_POLARIS10:
                 gfx_target_version = 80003;
                 f2g = &gfx_v8_kfd2kgd;
                 break;
         case CHIP_POLARIS11:
-               gfx_target_version = 80003;
-               if (!vf)
-                       f2g = &gfx_v8_kfd2kgd;
-               break;
         case CHIP_POLARIS12:
-               gfx_target_version = 80003;
-               if (!vf)
-                       f2g = &gfx_v8_kfd2kgd;
-               break;
         case CHIP_VEGAM:
                 gfx_target_version = 80003;
                 if (!vf)
--

2.38.1