]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu: Use switch case for unique_id
authorKent Russell <kent.russell@amd.com>
Fri, 25 Mar 2022 14:11:36 +0000 (10:11 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 1 Apr 2022 03:05:54 +0000 (23:05 -0400)
commit8b35e61ecf843a0a2c73f84fd534fcdea71fff16
tree9d2f4b43d6db1454012d558a79d557799c19c8fd
parent3643d24196bc4811402990d91e9450a8f550f364
drm/amdgpu: Use switch case for unique_id

To ease readability, use switch to set unique_id as supported for the
supported IP_VERSIONs, and set it to unsupported by default for all
other ASICs.
This makes it easier to add IP_VERSIONs later on, and makes it obvious
that it is not supported by default, instead of the current logic that
assumes that it is supported unless it is not one of the specified
IP_VERSIONs.

v2: Rebase onto previous IP_VERSION change

Signed-off-by: Kent Russell <kent.russell@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Kevin Wang <KevinYang.Wang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/pm/amdgpu_pm.c