[PATCH] drm/amdgpu: Need to disable msix when unloading driver

Deng, Emily Emily.Deng at amd.com
Wed Nov 6 06:28:38 UTC 2019


Hi all,
    Please help to review this. This is to fix driver reload issue.

Best wishes
Emily Deng


>-----Original Message-----
>From: Emily Deng <Emily.Deng at amd.com>
>Sent: Wednesday, November 6, 2019 2:24 PM
>To: amd-gfx at lists.freedesktop.org
>Cc: Deng, Emily <Emily.Deng at amd.com>
>Subject: [PATCH] drm/amdgpu: Need to disable msix when unloading driver
>
>For driver reload test, it will report "can't enable MSI (MSI-X already enabled)".
>
>Signed-off-by: Emily Deng <Emily.Deng at amd.com>
>---
> drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
>b/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
>index 6f3b03f..30d540d 100644
>--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
>+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c
>@@ -311,7 +311,7 @@ void amdgpu_irq_fini(struct amdgpu_device *adev)
> 		drm_irq_uninstall(adev->ddev);
> 		adev->irq.installed = false;
> 		if (adev->irq.msi_enabled)
>-			pci_disable_msi(adev->pdev);
>+			pci_free_irq_vectors(adev->pdev);
> 		if (!amdgpu_device_has_dc_support(adev))
> 			flush_work(&adev->hotplug_work);
> 	}
>--
>2.7.4



More information about the amd-gfx mailing list