[PATCH 2/3] Revert "drm/i915/opregion: Cleanup opregion after errors during driver loading"
Imre Deak
imre.deak at intel.com
Mon Mar 13 15:48:10 UTC 2023
This reverts commit 3e226e4a21808e4582020f813b041504f316022f.
---
drivers/gpu/drm/i915/display/intel_opregion.c | 8 --------
drivers/gpu/drm/i915/display/intel_opregion.h | 1 -
drivers/gpu/drm/i915/i915_driver.c | 6 +-----
3 files changed, 1 insertion(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/i915/display/intel_opregion.c b/drivers/gpu/drm/i915/display/intel_opregion.c
index 8124c491a7aa9..b8dce0576512a 100644
--- a/drivers/gpu/drm/i915/display/intel_opregion.c
+++ b/drivers/gpu/drm/i915/display/intel_opregion.c
@@ -1221,14 +1221,6 @@ void intel_opregion_unregister(struct drm_i915_private *i915)
unregister_acpi_notifier(&opregion->acpi_notifier);
opregion->acpi_notifier.notifier_call = NULL;
}
-}
-
-void intel_opregion_cleanup(struct drm_i915_private *i915)
-{
- struct intel_opregion *opregion = &i915->display.opregion;
-
- if (!opregion->header)
- return;
/* just clear all opregion memory pointers now */
memunmap(opregion->header);
diff --git a/drivers/gpu/drm/i915/display/intel_opregion.h b/drivers/gpu/drm/i915/display/intel_opregion.h
index 181eb3e9abbf3..d02e6696a050e 100644
--- a/drivers/gpu/drm/i915/display/intel_opregion.h
+++ b/drivers/gpu/drm/i915/display/intel_opregion.h
@@ -60,7 +60,6 @@ struct intel_opregion {
#ifdef CONFIG_ACPI
int intel_opregion_setup(struct drm_i915_private *dev_priv);
-void intel_opregion_cleanup(struct drm_i915_private *i915);
void intel_opregion_register(struct drm_i915_private *dev_priv);
void intel_opregion_unregister(struct drm_i915_private *dev_priv);
diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
index da249337c23bd..a53fd339e2cc9 100644
--- a/drivers/gpu/drm/i915/i915_driver.c
+++ b/drivers/gpu/drm/i915/i915_driver.c
@@ -535,7 +535,7 @@ static int i915_driver_hw_probe(struct drm_i915_private *dev_priv)
ret = i915_pcode_init(dev_priv);
if (ret)
- goto err_opregion;
+ goto err_msi;
/*
* Fill the dram structure to get the system dram info. This will be
@@ -556,8 +556,6 @@ static int i915_driver_hw_probe(struct drm_i915_private *dev_priv)
return 0;
-err_opregion:
- intel_opregion_cleanup(dev_priv);
err_msi:
if (pdev->msi_enabled)
pci_disable_msi(pdev);
@@ -583,8 +581,6 @@ static void i915_driver_hw_remove(struct drm_i915_private *dev_priv)
i915_perf_fini(dev_priv);
- intel_opregion_cleanup(dev_priv);
-
if (pdev->msi_enabled)
pci_disable_msi(pdev);
--
2.37.1
More information about the Intel-gfx-trybot
mailing list