drm/amdgpu: enable gfxoff in non-sriov and stutter mode by default
authorKenneth Feng <kenneth.feng@amd.com>
Thu, 6 Sep 2018 06:56:19 +0000 (14:56 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 14 Sep 2018 14:35:57 +0000 (09:35 -0500)
enable gfxoff in non-sriov and stutter mode by default

Signed-off-by: Kenneth Feng <kenneth.feng@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c

index 25e7e1cccaa117a47a8d366a7fe2837ea47bfd70..39fe66810d53285b3189555c5815242125c0c760 100644 (file)
@@ -1492,6 +1492,8 @@ static int amdgpu_device_ip_early_init(struct amdgpu_device *adev)
        }
 
        adev->powerplay.pp_feature = amdgpu_pp_feature_mask;
+       if (amdgpu_sriov_vf(adev))
+               adev->powerplay.pp_feature &= ~PP_GFXOFF_MASK;
 
        for (i = 0; i < adev->num_ip_blocks; i++) {
                if ((amdgpu_ip_block_mask & (1 << i)) == 0) {
index b575728ead074a5c691cadfde7f8aa5448ca51bf..33e1856fb8cc33ff40be146bfdf45bc2699476c5 100644 (file)
@@ -114,8 +114,8 @@ uint amdgpu_pg_mask = 0xffffffff;
 uint amdgpu_sdma_phase_quantum = 32;
 char *amdgpu_disable_cu = NULL;
 char *amdgpu_virtual_display = NULL;
-/* OverDrive(bit 14),gfxoff(bit 15),stutter mode(bit 17) disabled by default*/
-uint amdgpu_pp_feature_mask = 0xfffd3fff;
+/* OverDrive(bit 14) disabled by default*/
+uint amdgpu_pp_feature_mask = 0xffffbfff;
 int amdgpu_ngg = 0;
 int amdgpu_prim_buf_per_se = 0;
 int amdgpu_pos_buf_per_se = 0;