Commit 258fa17d authored by Alex Deucher's avatar Alex Deucher
Browse files

drm/amdgpu/athub2.1: convert to IP version checking



Use IP versions rather than asic_type to differentiate
IP version specific features.

Acked-by: default avatarChristian König <christian.koenig@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 13ebe284
Loading
Loading
Loading
Loading
+4 −5
Original line number Original line Diff line number Diff line
@@ -70,11 +70,10 @@ int athub_v2_1_set_clockgating(struct amdgpu_device *adev,
	if (amdgpu_sriov_vf(adev))
	if (amdgpu_sriov_vf(adev))
		return 0;
		return 0;


	switch (adev->asic_type) {
	switch (adev->ip_versions[ATHUB_HWIP]) {
	case CHIP_SIENNA_CICHLID:
	case IP_VERSION(2, 1, 0):
	case CHIP_NAVY_FLOUNDER:
	case IP_VERSION(2, 1, 1):
	case CHIP_DIMGREY_CAVEFISH:
	case IP_VERSION(2, 1, 2):
	case CHIP_BEIGE_GOBY:
		athub_v2_1_update_medium_grain_clock_gating(adev, state == AMD_CG_STATE_GATE);
		athub_v2_1_update_medium_grain_clock_gating(adev, state == AMD_CG_STATE_GATE);
		athub_v2_1_update_medium_grain_light_sleep(adev, state == AMD_CG_STATE_GATE);
		athub_v2_1_update_medium_grain_light_sleep(adev, state == AMD_CG_STATE_GATE);
		break;
		break;