summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon
diff options
context:
space:
mode:
authorKyleMahlkuch <kmahlkuc@linux.vnet.ibm.com>2019-07-31 17:10:14 -0500
committerAlex Deucher <alexander.deucher@amd.com>2019-08-02 10:30:15 -0500
commit6f7fe9a93e6c09bf988c5059403f5f88e17e21e6 (patch)
tree89a472071197219949fb0dae00d341119905b287 /drivers/gpu/drm/radeon
parent5145d57ec5f5cf7dadaa6ccd9c9f1e4dae82570b (diff)
downloadlinux-6f7fe9a93e6c09bf988c5059403f5f88e17e21e6.tar.bz2
drm/radeon: Fix EEH during kexec
During kexec some adapters hit an EEH since they are not properly shut down in the radeon_pci_shutdown() function. Adding radeon_suspend_kms() fixes this issue. Signed-off-by: KyleMahlkuch <kmahlkuc@linux.vnet.ibm.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/radeon')
-rw-r--r--drivers/gpu/drm/radeon/radeon_drv.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c
index b2bb74d5bffb..66ff84ec665b 100644
--- a/drivers/gpu/drm/radeon/radeon_drv.c
+++ b/drivers/gpu/drm/radeon/radeon_drv.c
@@ -349,11 +349,19 @@ radeon_pci_remove(struct pci_dev *pdev)
static void
radeon_pci_shutdown(struct pci_dev *pdev)
{
+ struct drm_device *ddev = pci_get_drvdata(pdev);
+
/* if we are running in a VM, make sure the device
* torn down properly on reboot/shutdown
*/
if (radeon_device_is_virtual())
radeon_pci_remove(pdev);
+
+ /* Some adapters need to be suspended before a
+ * shutdown occurs in order to prevent an error
+ * during kexec.
+ */
+ radeon_suspend_kms(ddev, true, true, false);
}
static int radeon_pmops_suspend(struct device *dev)