[PATCH] drm/amd/powerplay: don't give up if DPM is already running

Zhu, Rex Rex.Zhu at amd.com
Thu Oct 20 08:41:32 UTC 2016


Hi Gražvydas,

In GPU passthrough case, I can't find better solution than yours from driver.
So will apply your patch and just update reproduce step.

Thanks.


Best Regards
Rex

-----Original Message-----
From: Zhu, Rex 
Sent: Wednesday, October 19, 2016 10:00 PM
To: 'Grazvydas Ignotas'
Cc: Alex Deucher; amd-gfx list; Maling list - DRI developers
Subject: RE: [PATCH] drm/amd/powerplay: don't give up if DPM is already running

Hi Gražvydas,

Sorry for so late response.

I can reproduce this issue in gpu passthrough case.

When we forced power off the VM or forced reset the VM without shutting down the Os, the rmmod will not be called. So dpm was still running.

If we skipped the enable dpm tasks, some clock tables were not be initialized, so kernel panic when we visited those tables in set power state.

I will send the fix patch for review tomorrow.

Thanks.

Best Regards
Rex

-----Original Message-----
From: Grazvydas Ignotas [mailto:notasas at gmail.com] 
Sent: Sunday, October 16, 2016 2:55 AM
To: Zhu, Rex
Cc: Alex Deucher; amd-gfx list; Maling list - DRI developers
Subject: Re: [PATCH] drm/amd/powerplay: don't give up if DPM is already running

Hi,

On Thu, Oct 13, 2016 at 10:45 AM, Zhu, Rex <Rex.Zhu at amd.com> wrote:
>
> The attached patches were also for this issue.
> Disable dpm when rmmod amdgpu.

It works for modprobe-rmmod-modprobe test, thanks.

However with GPU passthrough (giving control of the GPU to a Windows virtual machine using iommu, then shutting down the VM and loading
amdgpu) the problem is still there, same backtrace as in my commit message. It seems the Windows driver leaves DPM enabled on shutdown.
With my patch the crash goes away.

It would be nice to have GPU passthrough working, this is the only issue that breaks it. Windows can drive the GPU after amdgpu fine already, only amdgpu has problems to run after Windows.

Gražvydas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-drm-amd-powerplay-don-t-give-up-if-DPM-is-already-ru.patch
Type: application/octet-stream
Size: 1642 bytes
Desc: 0001-drm-amd-powerplay-don-t-give-up-if-DPM-is-already-ru.patch
URL: <https://lists.freedesktop.org/archives/amd-gfx/attachments/20161020/275e3a07/attachment-0001.obj>


More information about the amd-gfx mailing list