[1/2] drm/amdgpu: always apply pci shutdown callbacks

Submitted by Alex Deucher on Sept. 22, 2016, 6:47 p.m.

Details

Message ID 1474570055-28109-1-git-send-email-alexander.deucher@amd.com
State New
Headers show
Series "Series without cover letter" ( rev: 1 ) in AMD X.Org drivers

Not browsing as part of any series.

Commit Message

Alex Deucher Sept. 22, 2016, 6:47 p.m.
We can't properly detect all hypervisors and we
need this to properly tear down the hardware.

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

Patch hide | download patch | download mbox

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
index e7ae6723..5b592af 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
@@ -484,10 +484,11 @@  amdgpu_pci_shutdown(struct pci_dev *pdev)
 	struct amdgpu_device *adev = dev->dev_private;
 
 	/* if we are running in a VM, make sure the device
-	 * torn down properly on reboot/shutdown
+	 * torn down properly on reboot/shutdown.
+	 * unfortunately we can't detect certain
+	 * hypervisors so just do this all the time.
 	 */
-	if (amdgpu_passthrough(adev))
-		amdgpu_pci_remove(pdev);
+	amdgpu_pci_remove(pdev);
 }
 
 static int amdgpu_pmops_suspend(struct device *dev)