InitACPICall: Difference between revisions
Appearance
No edit summary |
mNo edit summary |
||
Line 1: | Line 1: | ||
Find PSD and get pointer to ACPI function. | Find PSD and get pointer to ACPI function. | ||
PACPIFUNCTION APIENTRY InitACPICall (char *Component) | PACPIFUNCTION APIENTRY InitACPICall (char *Component) | ||
Line 21: | Line 16: | ||
#include <acpifun.h> | #include <acpifun.h> | ||
PACPIFUNCTION PSD = NULL; | PACPIFUNCTION PSD = NULL; // Pointer to ACPI function | ||
void | void MyInitDriver(void){ | ||
MyInitDriver( | |||
{ | |||
PSD = (PACPIFUNCTION)InitACPICall("MyDriver"); | PSD = (PACPIFUNCTION)InitACPICall("MyDriver"); | ||
if (PSD) | if (PSD) | ||
Line 37: | Line 29: | ||
==Links== | ==Links== | ||
* [http://www2.ecomstation.ru/doku.php/en:acpi ACPI Toolkit Web Site] | * [http://www2.ecomstation.ru/doku.php/en:acpi ACPI Toolkit Web Site] | ||
Revision as of 15:24, 14 June 2019
Find PSD and get pointer to ACPI function.
PACPIFUNCTION APIENTRY InitACPICall (char *Component)
Parameters
- Component
- ASCIIZ name for print in debug log
Return
- return
- Pointer to ACPI function if success, else NULL
Sample
#include <psd.h> #include <acpi.h> #include <acpiapi.h> #include <ipdc.h> #include <acpifun.h> PACPIFUNCTION PSD = NULL; // Pointer to ACPI function void MyInitDriver(void){ PSD = (PACPIFUNCTION)InitACPICall("MyDriver"); if (PSD) { PSD->AcpiOsPrintf("MyDriver can work with ACPI\n"); } }