RE: [PATCH 1/3] drm/amd: Adjust legacy IP discovery for Picasso/Raven/Raven2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



[AMD Official Use Only - General]

Reviewed-by: Aaron Liu <aaron.liu@xxxxxxx>

> -----Original Message-----
> From: amd-gfx <amd-gfx-bounces@xxxxxxxxxxxxxxxxxxxxx> On Behalf Of Mario
> Limonciello
> Sent: Monday, January 16, 2023 3:22 AM
> To: amd-gfx@xxxxxxxxxxxxxxxxxxxxx
> Cc: Limonciello, Mario <Mario.Limonciello@xxxxxxx>
> Subject: [PATCH 1/3] drm/amd: Adjust legacy IP discovery for
> Picasso/Raven/Raven2
>
> The switch/case statement currently combines 10.0.0 and 10.0.1, but
> 10.0.1 is only used for Raven 2.  So split the two cases up to make this clearer.
>
> Signed-off-by: Mario Limonciello <mario.limonciello@xxxxxxx>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c | 12 ++++--------
>  1 file changed, 4 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c
> b/drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c
> index c03824d0311bd..0d950ae14b27c 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c
> @@ -1074,15 +1074,11 @@ static const char
> *amdgpu_ucode_legacy_naming(struct amdgpu_device *adev, int bl
>                       }
>                       break;
>               case IP_VERSION(10, 0, 0):
> +                     if (adev->apu_flags & AMD_APU_IS_PICASSO)
> +                             return "picasso";
> +                     return "raven";
>               case IP_VERSION(10, 0, 1):
> -                     if (adev->asic_type == CHIP_RAVEN) {
> -                             if (adev->apu_flags & AMD_APU_IS_RAVEN2)
> -                                     return "raven2";
> -                             else if (adev->apu_flags &
> AMD_APU_IS_PICASSO)
> -                                     return "picasso";
> -                             return "raven";
> -                     }
> -                     break;
> +                     return "raven2";
>               case IP_VERSION(11, 0, 0):
>                       return "navi10";
>               case IP_VERSION(11, 0, 2):
> --
> 2.25.1





[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux