drm/{i915, xe}: move opregion cleanup to intel_display_driver_remove_nogem()

The intel_opregion_cleanup() call should really be in display. Move it
at the end of intel_display_driver_probe_noirq().

For xe, this is a completely non-functional change now that the
noirq/nogem cleanup calls are in the right order.

For i915, this only changes the relative order of
intel_opregion_cleanup() and i915_perf_fini(), which should be of no
consequence.

Reviewed-by: Michał Grzelak <michal.grzelak@intel.com>
Link: https://patch.msgid.link/8ccd49a5945e0560ba22079d686db1268e8e9f7f.1781549229.git.jani.nikula@intel.com
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
Jani Nikula 2026-06-15 21:48:02 +03:00
parent 854d2c4092
commit a6ad0edf83
3 changed files with 2 additions and 4 deletions

View File

@ -662,6 +662,8 @@ void intel_display_driver_remove_nogem(struct intel_display *display)
intel_display_power_driver_remove(display);
intel_bios_driver_remove(display);
intel_opregion_cleanup(display);
}
void intel_display_driver_unregister(struct intel_display *display)

View File

@ -586,13 +586,10 @@ ALLOW_ERROR_INJECTION(i915_driver_hw_probe, ERRNO);
*/
static void i915_driver_hw_remove(struct drm_i915_private *dev_priv)
{
struct intel_display *display = dev_priv->display;
struct pci_dev *pdev = to_pci_dev(dev_priv->drm.dev);
i915_perf_fini(dev_priv);
intel_opregion_cleanup(display);
pci_disable_msi(pdev);
}

View File

@ -105,7 +105,6 @@ static void xe_display_fini_early(void *arg)
intel_hpd_cancel_work(display);
intel_display_driver_remove_noirq(display);
intel_display_driver_remove_nogem(display);
intel_opregion_cleanup(display);
intel_display_power_cleanup(display);
}