1f08c3bdfSopenharmony_ci- ACPI testcase -
2f08c3bdfSopenharmony_ci        ACPI must be enabled in the kernel. Since ACPI will control devices and possibly put them to sleep,
3f08c3bdfSopenharmony_ci        it's not recommended that any other tests be run concurrently with these tests since you may
4f08c3bdfSopenharmony_ci        get unexpected results.
5f08c3bdfSopenharmony_ci        These tests are currently ONLY supported on the 2.5 kernels. 2.4 kernels probably won't even build much
6f08c3bdfSopenharmony_ci        less run.
7f08c3bdfSopenharmony_ci        run ltpacpi.sh -r run  to execute the tests
8f08c3bdfSopenharmony_ci
9f08c3bdfSopenharmony_ci3.a. A function "acpi_get_object_info" has been added to the LtpAcpiCmds.c file of LTP project.
10f08c3bdfSopenharmony_ci        (\ltp\testcases\kernel\device-drivers\acpi\LtpAcpiCmds.c)
11f08c3bdfSopenharmony_ci         This function returns information about an object as seen from the namespace node.
12f08c3bdfSopenharmony_ci
13f08c3bdfSopenharmony_ci3.b. A function "acpi_install_fixed_event_handler" has been added to the LtpAcpiCmds.c file of LTP project.
14f08c3bdfSopenharmony_ci        This function saves the pointer to the handler function and then enables the event.
15f08c3bdfSopenharmony_ci
16f08c3bdfSopenharmony_ci3.c. A function "acpi_remove_fixed_event_handler" has been added to the LtpAcpiCmds.c file.
17f08c3bdfSopenharmony_ci        Disables the event and unregisters the event handler.
18f08c3bdfSopenharmony_ci
19f08c3bdfSopenharmony_ci3.d. A function "acpi_acquire_global_lock" has been added to LtpAcpiCmds.c file.
20f08c3bdfSopenharmony_ci        Acquire the ACPI Global Lock
21f08c3bdfSopenharmony_ci
22f08c3bdfSopenharmony_ci3.e. A function "acpi_release_global_lock" has been added to LtpAcpiCmds.c file.
23f08c3bdfSopenharmony_ci        Release the ACPI Global Lock
24f08c3bdfSopenharmony_ci
25f08c3bdfSopenharmony_ci3.f. A function "acpi_bus_find_driver" has been added to LtpAcpiCmds.c file.
26f08c3bdfSopenharmony_ci        Parses the list of registered drivers looking for a driver applicable for the specified device.
27f08c3bdfSopenharmony_ci
28f08c3bdfSopenharmony_ci3.g. A function "acpi_bus_get_power" has been added to LtpAcpiCmds.c file.
29f08c3bdfSopenharmony_ci        Get the device's power state either directly (via _PSC) or indirectly (via power resources).
30f08c3bdfSopenharmony_ci
31f08c3bdfSopenharmony_ci3.h. A function "acpi_evaluate_integer" has been added to LtpAcpiCmds.c file.
32f08c3bdfSopenharmony_ci        Looks for _GPE object (an integer). If _GPE evaluates to an integer,
33f08c3bdfSopenharmony_cithe value is the bit assignment of the SCI interrupt within the GPEx_STS register of a GPE
34f08c3bdfSopenharmony_ciblock described in the FADT that the embedded controller will trigger.
35f08c3bdfSopenharmony_ci
36f08c3bdfSopenharmony_ci4. Including ACPI support into the kernel
37f08c3bdfSopenharmony_ci
38f08c3bdfSopenharmony_ci By default, the kernel may not enable ACPI feature. A kernel configuration option must be selected
39f08c3bdfSopenharmony_ci to enable ACPI support.
40f08c3bdfSopenharmony_ci
41f08c3bdfSopenharmony_ci5. FAQ
42f08c3bdfSopenharmony_ci
43f08c3bdfSopenharmony_ciQ.5.1. Are there any limitations on using this patch?
44f08c3bdfSopenharmony_ci
45f08c3bdfSopenharmony_ciA.5.1. If the device supports ACPI feature and the ACPI feature is enabled in the kernel,
46f08c3bdfSopenharmony_cithen only a user will be able to use these scripts.
47f08c3bdfSopenharmony_ci
48