drm/radeon: work around lack of upstream ACPI support for D3cold
authorAlex Deucher <alexander.deucher@amd.com>
Fri, 3 Jun 2016 21:10:33 +0000 (17:10 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 7 Jul 2016 18:51:13 +0000 (14:51 -0400)
Until Dave's patch to support the new hybrid gfx ACPI method goes
upstream, we can fallback to the old ATPX method which seems to
still work.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/radeon/radeon_atpx_handler.c

index de17b5ed3ea4099d248f03541ceda9086be250f4..86dcdf38b732176ec94865d213648953e344cf04 100644 (file)
@@ -198,7 +198,16 @@ static int radeon_atpx_validate(struct radeon_atpx *atpx)
        atpx->is_hybrid = false;
        if (valid_bits & ATPX_MS_HYBRID_GFX_SUPPORTED) {
                printk("ATPX Hybrid Graphics\n");
+#if 1
+               /* This is a temporary hack until the D3 cold support
+                * makes it upstream.  The ATPX power_control method seems
+                * to still work on even if the system should be using
+                * the new standardized hybrid D3 cold ACPI interface.
+                */
+               atpx->functions.power_cntl = true;
+#else
                atpx->functions.power_cntl = false;
+#endif
                atpx->is_hybrid = true;
        }