acpi.h 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
  4. */
  5. #ifndef __ASM_ACPI_H__
  6. #define __ASM_ACPI_H__
  7. struct acpi_fadt;
  8. /**
  9. * acpi_find_fadt() - find ACPI FADT table in the system memory
  10. *
  11. * This routine parses the ACPI table to locate the ACPI FADT table.
  12. *
  13. * @return: a pointer to the ACPI FADT table in the system memory
  14. */
  15. struct acpi_fadt *acpi_find_fadt(void);
  16. /**
  17. * acpi_find_wakeup_vector() - find OS installed wake up vector address
  18. *
  19. * This routine parses the ACPI table to locate the wake up vector installed
  20. * by the OS previously.
  21. *
  22. * @fadt: a pointer to the ACPI FADT table in the system memory
  23. * @return: wake up vector address installed by the OS
  24. */
  25. void *acpi_find_wakeup_vector(struct acpi_fadt *fadt);
  26. /**
  27. * enter_acpi_mode() - enter into ACPI mode
  28. *
  29. * This programs the ACPI-defined PM1_CNT register to enable SCI interrupt
  30. * so that the whole system swiches to ACPI mode.
  31. *
  32. * @pm1_cnt: PM1_CNT register I/O address
  33. */
  34. void enter_acpi_mode(int pm1_cnt);
  35. #endif /* __ASM_ACPI_H__ */