Skip to contentSkip to conversation

ACPI: processor: idle: Add module import namespace

PATCH New Rafael J. Wysocki 1 participant 1 message Aug 13, 2025 ACPI

lore
Share & tools
lore

Rafael J. Wysocki

author maintainer
#0 lore raw

PATCH 1/1 ACPI: processor: idle: Add module import namespace

From: Rafael J. Wysocki <[email protected]>

Add a new module import namespace called ACPI_PROCESSOR_IDLE for functions exported from the non-modular part of the ACPI processor driver to the modular part of it.

Export acpi_processor_claim_cst_control() and acpi_processor_evaluate_cst() in that namespace to hide them from unrelated modules.

They are also used by the intel_idle driver, but it is non-modular, so it can call them regardless of the way the symbols are exported.

---
 drivers/acpi/acpi_processor.c |    4 ++--
 drivers/acpi/processor_idle.c |    2 ++
 2 files changed, 4 insertions(+), 2 deletions(-)
drivers/acpi/acpi_processor.c +2 -2
@@ -815,7 +815,7 @@
 	cst_control_claimed = true;
 	return true;
 }
-EXPORT_SYMBOL_GPL(acpi_processor_claim_cst_control);
+EXPORT_SYMBOL_NS_GPL(acpi_processor_claim_cst_control, "ACPI_PROCESSOR_IDLE");
 
 /**
  * acpi_processor_evaluate_cst - Evaluate the processor _CST control method.
@@ -994,5 +994,5 @@
 
 	return ret;
 }
-EXPORT_SYMBOL_GPL(acpi_processor_evaluate_cst);
+EXPORT_SYMBOL_NS_GPL(acpi_processor_evaluate_cst, "ACPI_PROCESSOR_IDLE");
 #endif /* CONFIG_ACPI_PROCESSOR_CSTATE */
drivers/acpi/processor_idle.c +2 -0
@@ -1431,3 +1431,5 @@
 	pr->flags.power_setup_done = 0;
 	return 0;
 }
+
+MODULE_IMPORT_NS("ACPI_PROCESSOR_IDLE");