@@ -563,6 +563,8 @@ void intel_display_driver_register(struct drm_i915_private *i915)
DISPLAY_RUNTIME_INFO(i915), &p);
intel_power_domains_enable(i915);
+
+ intel_register_dsm_handler();
}
void intel_display_driver_cleanup(struct drm_i915_private *i915)
@@ -645,6 +647,8 @@ void intel_display_driver_unregister(struct drm_i915_private *i915)
if (!HAS_DISPLAY(i915))
return;
+ intel_unregister_dsm_handler();
+
intel_power_domains_disable(i915);
drm_client_dev_unregister(&i915->drm);
@@ -46,7 +46,6 @@
#include <drm/drm_probe_helper.h>
#include "display/i9xx_display_sr.h"
-#include "display/intel_acpi.h"
#include "display/intel_bw.h"
#include "display/intel_cdclk.h"
#include "display/intel_crtc.h"
@@ -636,8 +635,6 @@ static void i915_driver_register(struct drm_i915_private *dev_priv)
intel_runtime_pm_enable(&dev_priv->runtime_pm);
- intel_register_dsm_handler();
-
if (i915_switcheroo_register(dev_priv))
drm_err(&dev_priv->drm, "Failed to register vga switcheroo!\n");
}
@@ -653,8 +650,6 @@ static void i915_driver_unregister(struct drm_i915_private *dev_priv)
i915_switcheroo_unregister(dev_priv);
- intel_unregister_dsm_handler();
-
intel_runtime_pm_disable(&dev_priv->runtime_pm);
intel_display_driver_unregister(dev_priv);
@@ -14,7 +14,6 @@
#include <uapi/drm/xe_drm.h>
#include "soc/intel_dram.h"
-#include "intel_acpi.h"
#include "intel_audio.h"
#include "intel_bw.h"
#include "intel_display.h"
@@ -219,7 +218,6 @@ void xe_display_register(struct xe_device *xe)
return;
intel_display_driver_register(xe);
- intel_register_dsm_handler();
}
void xe_display_unregister(struct xe_device *xe)
@@ -227,7 +225,6 @@ void xe_display_unregister(struct xe_device *xe)
if (!xe->info.probe_display)
return;
- intel_unregister_dsm_handler();
intel_display_driver_unregister(xe);
}