ACPI / PMIC: intel: Drop double removal of address space handler
Subsystems (2)
PATCH 1/1 ACPI / PMIC: intel: Drop double removal of address space handler
There is no need to remove address space handler twice, because removal is idempotent.
Signed-off-by Andy Shevchenko <[email protected]>
--- drivers/acpi/pmic/intel_pmic.c | 2 -- 1 file changed, 2 deletions(-)
drivers/acpi/pmic/intel_pmic.c +0 -2
@@ -284,8 +284,6 @@ int intel_pmic_install_opregion_handler(struct device *dev, acpi_handle handle, intel_pmic_thermal_handler, NULL, opregion);if (ACPI_FAILURE (status)) { -acpi_remove_address_space_handler (handle,PMIC_POWER_OPREGION_ID , - intel_pmic_power_handler); ret = -ENODEV ; goto out_remove_power_handler; }
Signature · 1 line
2.20.1
Hi,
Quoted 4 lines · Andy Shevchenko
There is no need to remove address space handler twice, because removal is idempotent.
Signed-off-by Andy Shevchenko <[email protected]>
Good catch:
Reviewed-by Hans de Goede <[email protected]>
Regards,
Hans
Quoted 18 lines
--- drivers/acpi/pmic/intel_pmic.c | 2 -- 1 file changed, 2 deletions(-)drivers/acpi/pmic/intel_pmic.c +0
-2@@ -284,8 +284,6 @@ int intel_pmic_install_opregion_handler(struct device *dev, acpi_handle handle, intel_pmic_thermal_handler, NULL, opregion);if (ACPI_FAILURE (status)) { -acpi_remove_address_space_handler (handle,PMIC_POWER_OPREGION_ID , - intel_pmic_power_handler); ret = -ENODEV ; goto out_remove_power_handler; }
Rafael J. Wysocki
AppliedQuoted 14 lines · CEST Andy Shevchenko
There is no need to remove address space handler twice, because removal is idempotent.
Signed-off-by Andy Shevchenko <[email protected]>--- drivers/acpi/pmic/intel_pmic.c | 2 -- 1 file changed, 2 deletions(-)drivers/acpi/pmic/intel_pmic.c +0
-0
drivers/acpi/pmic/intel_pmic.c int intel_pmic_install_opregion_handler(struct device *dev, acpi_handle handle, · line 289
Quoted 8 lines
drivers/acpi/pmic/intel_pmic.c +0
-2@@ -284,8 +284,6 @@ int intel_pmic_install_opregion_handler(struct device *dev, acpi_handle handle, intel_pmic_thermal_handler, NULL, opregion);if (ACPI_FAILURE (status)) { -acpi_remove_address_space_handler (handle,PMIC_POWER_OPREGION_ID , - intel_pmic_power_handler); ret = -ENODEV ; goto out_remove_power_handler; }
Applied, thanks!