]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
ACPI: processor: idle: Add module import namespace
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 13 Aug 2025 10:36:04 +0000 (12:36 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 2 Sep 2025 14:08:53 +0000 (16:08 +0200)
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.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Link: https://patch.msgid.link/3376499.aeNJFYEL58@rafael.j.wysocki
drivers/acpi/acpi_processor.c
drivers/acpi/processor_idle.c

index 2a99f5eb69629a476946dff0362cae4c817f0a34..7ec1dc04fd11b9cc82151e495220b3e15d7fe6f4 100644 (file)
@@ -815,7 +815,7 @@ bool acpi_processor_claim_cst_control(void)
        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 @@ end:
 
        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 */
index d8eb0b51518820e84ceba0d656cb53e2bfebae66..0c8a88aa055331a458079608c475a60e68e258e7 100644 (file)
@@ -1453,3 +1453,5 @@ int acpi_processor_power_exit(struct acpi_processor *pr)
        pr->flags.power_setup_done = 0;
        return 0;
 }
+
+MODULE_IMPORT_NS("ACPI_PROCESSOR_IDLE");