Re: [PATCH] drm/xe/pm: do not warn about missing runtime PM protection after hot-unplug

Raag Jadav <[email protected]> Thu, 30 Jul 2026 14:31:05 +0200
Newsgroups org.freedesktop.lists.intel-xe
Message-ID <[email protected]>
On Thu, Jul 30, 2026 at 05:35:26PM +0530, Gote, Nitin R wrote:
> > From: Jadav, Raag <[email protected]>
> > On Thu, Jul 30, 2026 at 11:06:36AM +0530, Nitin Gote wrote:
> > > After hot-unplug, device_del() disables runtime PM. A deferred fd
> > > close can still run later during process exit and destroy remaining
> > > exec queues, which may call xe_pm_runtime_get_noresume().
> > 
> > This sounds like could cause many other side effects. Why not make sure the exec
> > queues are taken care of as part of hot-unplug path?
> > 
> 
> Here In igt@core_hotunplug@hotreplug-with-load and igt@core_hotunplug@hotunplug-rescan-with-load subtests, 
> the workload keeps the DRM fd open while the device is pci hot-unplugged. Later, fd close reaches 
> guc_exec_queue_destroy() -> guc_exec_queue_add_msg() -> xe_pm_runtime_get_noresume(), 
> after pci_remove/device_del() path has already called pm_runtime_disable() during pci hot-unplug. 
> 
> So the WARN is a false-positive for the already-unplugged device case.
> I will update the commit message to make this scope clearer.

I guess my question was, is it safe have the exec queues lying around until
fd close? Wouldn't it be more appropriate to have them cleaned up as part
of hot-unplug itself?

Raag