dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Alex Deucher <alexdeucher@gmail.com>
To: dri-devel@lists.freedesktop.org
Cc: Alex Deucher <alexander.deucher@amd.com>
Subject: [PATCH 05/12] drm/amdgpu: use PCI_D3hot for PX systems without dGPU power control
Date: Wed,  1 Jun 2016 16:53:18 -0400	[thread overview]
Message-ID: <1464814405-19729-6-git-send-email-alexander.deucher@amd.com> (raw)
In-Reply-To: <1464814405-19729-1-git-send-email-alexander.deucher@amd.com>

On PX systems without dGPU power control, use PCI_D3hot.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
index f122703..7e49bf4 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
@@ -417,7 +417,10 @@ static int amdgpu_pmops_runtime_suspend(struct device *dev)
 	pci_save_state(pdev);
 	pci_disable_device(pdev);
 	pci_ignore_hotplug(pdev);
-	pci_set_power_state(pdev, PCI_D3cold);
+	if (amdgpu_has_atpx_dgpu_power_cntl())
+		pci_set_power_state(pdev, PCI_D3cold);
+	else
+		pci_set_power_state(pdev, PCI_D3hot);
 	drm_dev->switch_power_state = DRM_SWITCH_POWER_DYNAMIC_OFF;
 
 	return 0;
-- 
2.5.5

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  parent reply	other threads:[~2016-06-01 20:53 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-01 20:53 [PATCH 00/12] Improve PX support in radeon and amdgpu Alex Deucher
2016-06-01 20:53 ` [PATCH 01/12] drm/amdgpu: disable power control on hybrid laptops Alex Deucher
2016-06-01 20:53 ` [PATCH 02/12] drm/amdgpu: clean up atpx power control handling Alex Deucher
2016-06-01 20:53 ` [PATCH 03/12] drm/amdgpu: add a delay after ATPX dGPU power off Alex Deucher
2016-06-01 20:53 ` [PATCH 04/12] drm/amdgpu/atpx: add a query for ATPX dGPU power control Alex Deucher
2016-06-01 20:53 ` Alex Deucher [this message]
2016-06-01 20:53 ` [PATCH 06/12] drm/amdgpu/atpx: drop forcing of " Alex Deucher
2016-06-01 20:53 ` [PATCH 07/12] drm/radeon: disable power control on hybrid laptops Alex Deucher
2016-06-01 20:53 ` [PATCH 08/12] drm/radeon: clean up atpx power control handling Alex Deucher
2016-06-01 20:53 ` [PATCH 09/12] drm/radeon: add a delay after ATPX dGPU power off Alex Deucher
2016-06-01 20:53 ` [PATCH 10/12] drm/radeon/atpx: add a query for ATPX dGPU power control Alex Deucher
2016-06-01 20:53 ` [PATCH 11/12] drm/radeon: use PCI_D3hot for PX systems without " Alex Deucher
2016-06-01 20:53 ` [PATCH 12/12] drm/radeon/atpx: drop forcing of " Alex Deucher
2016-06-02  0:02 ` [PATCH 00/12] Improve PX support in radeon and amdgpu Mike Lothian
2016-06-02 12:31   ` Alex Deucher
2016-06-02  7:17 ` Christian König

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1464814405-19729-6-git-send-email-alexander.deucher@amd.com \
    --to=alexdeucher@gmail.com \
    --cc=alexander.deucher@amd.com \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox