]> git.karo-electronics.de Git - linux-beck.git/commitdiff
drm/amdgpu: disable power control on hybrid laptops
authorAlex Deucher <alexander.deucher@amd.com>
Wed, 1 Jun 2016 16:28:13 +0000 (12:28 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 7 Jul 2016 18:50:59 +0000 (14:50 -0400)
Windows 10 (and some 8.1) systems use standardized
ACPI calls for hybrid laptops to control dGPU power.
Detect those cases and disable the AMD specific ATPX
power control.

Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Acked-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_atpx_handler.c

index 35a1248aaa7778a04fa64957d4d2b65a3911ab9c..3af1c3aceab39b8db9567a0ae1c72a25c549853d 100644 (file)
@@ -183,6 +183,11 @@ static int amdgpu_atpx_validate(struct amdgpu_atpx *atpx)
                                  ATPX_DFP_SIGNAL_MUXED))
                        atpx->functions.disp_mux_cntl = true;
 
+               if (valid_bits & ATPX_MS_HYBRID_GFX_SUPPORTED) {
+                       printk("Hybrid Graphics, ATPX dGPU power cntl disabled\n");
+                       atpx->functions.power_cntl = false;
+               }
+
                kfree(info);
        }
        return 0;