On Mon, Jan 26, 2026 at 1:37 AM Yifan Zhang <[email protected]> wrote: > > amdgpu_irq_disable_all touchs GC registers, keep GC awake inside > the amdgpu_irq_disable_all function. Otherwise IMU may be stuck due > to invalid GC regsters access.
I took a look and there appears to be two cases where things are not protected, amdgpu_irq_disable_all() and amdgpu_fence_driver_hw_fini() in amdgpu_device_fini_hw(). amdgpu_fence_driver_hw_init() also gets called in the unwind paths in suspend failures which look to be handled correctly. In amdgpu_device_fini_hw(), amdgpu_fence_driver_hw_fini() gets called after amdgpu_irq_disable_all() so the interrupt should already be disabled. So patch is: Reviewed-by: Alex Deucher <[email protected]> > > Signed-off-by: Yifan Zhang <[email protected]> > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c > b/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c > index 82bc6d657e5a..85e5399fccad 100644 > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_irq.c > @@ -162,6 +162,7 @@ void amdgpu_irq_disable_all(struct amdgpu_device *adev) > unsigned int i, j, k; > int r; > > + amdgpu_gfx_off_ctrl(adev, false); > spin_lock_irqsave(&adev->irq.lock, irqflags); > for (i = 0; i < AMDGPU_IRQ_CLIENTID_MAX; ++i) { > if (!adev->irq.client[i].sources) > @@ -184,6 +185,7 @@ void amdgpu_irq_disable_all(struct amdgpu_device *adev) > } > } > spin_unlock_irqrestore(&adev->irq.lock, irqflags); > + amdgpu_gfx_off_ctrl(adev, true); > } > > /** > -- > 2.43.0 >
