actables.h
上传用户:jlfgdled
上传日期:2013-04-10
资源大小:33168k
文件大小:4k
源码类别:

Linux/Unix编程

开发平台:

Unix_Linux

  1. /******************************************************************************
  2.  *
  3.  * Name: actables.h - ACPI table management
  4.  *       $Revision: 32 $
  5.  *
  6.  *****************************************************************************/
  7. /*
  8.  *  Copyright (C) 2000, 2001 R. Byron Moore
  9.  *
  10.  *  This program is free software; you can redistribute it and/or modify
  11.  *  it under the terms of the GNU General Public License as published by
  12.  *  the Free Software Foundation; either version 2 of the License, or
  13.  *  (at your option) any later version.
  14.  *
  15.  *  This program is distributed in the hope that it will be useful,
  16.  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
  17.  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  18.  *  GNU General Public License for more details.
  19.  *
  20.  *  You should have received a copy of the GNU General Public License
  21.  *  along with this program; if not, write to the Free Software
  22.  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  23.  */
  24. #ifndef __ACTABLES_H__
  25. #define __ACTABLES_H__
  26. /* Used in Acpi_tb_map_acpi_table for size parameter if table header is to be used */
  27. #define SIZE_IN_HEADER          0
  28. acpi_status
  29. acpi_tb_handle_to_object (
  30. u16                     table_id,
  31. acpi_table_desc         **table_desc);
  32. /*
  33.  * tbconvrt - Table conversion routines
  34.  */
  35. acpi_status
  36. acpi_tb_convert_to_xsdt (
  37. acpi_table_desc         *table_info,
  38. u32                     *number_of_tables);
  39. acpi_status
  40. acpi_tb_convert_table_fadt (
  41. void);
  42. acpi_status
  43. acpi_tb_build_common_facs (
  44. acpi_table_desc         *table_info);
  45. u32
  46. acpi_tb_get_table_count (
  47. RSDP_DESCRIPTOR         *RSDP,
  48. acpi_table_header       *RSDT);
  49. /*
  50.  * tbget - Table "get" routines
  51.  */
  52. acpi_status
  53. acpi_tb_get_table_ptr (
  54. acpi_table_type         table_type,
  55. u32                     instance,
  56. acpi_table_header       **table_ptr_loc);
  57. acpi_status
  58. acpi_tb_get_table (
  59. ACPI_PHYSICAL_ADDRESS   physical_address,
  60. acpi_table_header       *buffer_ptr,
  61. acpi_table_desc         *table_info);
  62. acpi_status
  63. acpi_tb_verify_rsdp (
  64. ACPI_PHYSICAL_ADDRESS   RSDP_physical_address);
  65. acpi_status
  66. acpi_tb_get_table_facs (
  67. acpi_table_header       *buffer_ptr,
  68. acpi_table_desc         *table_info);
  69. ACPI_PHYSICAL_ADDRESS
  70. acpi_tb_get_rsdt_address (
  71. void);
  72. acpi_status
  73. acpi_tb_validate_rsdt (
  74. acpi_table_header       *table_ptr);
  75. acpi_status
  76. acpi_tb_get_table_pointer (
  77. ACPI_PHYSICAL_ADDRESS   physical_address,
  78. u32                     flags,
  79. u32                     *size,
  80. acpi_table_header       **table_ptr);
  81. /*
  82.  * tbgetall - Get all firmware ACPI tables
  83.  */
  84. acpi_status
  85. acpi_tb_get_all_tables (
  86. u32                     number_of_tables,
  87. acpi_table_header       *buffer_ptr);
  88. /*
  89.  * tbinstall - Table installation
  90.  */
  91. acpi_status
  92. acpi_tb_install_table (
  93. acpi_table_header       *table_ptr,
  94. acpi_table_desc         *table_info);
  95. acpi_status
  96. acpi_tb_recognize_table (
  97. acpi_table_header       *table_ptr,
  98. acpi_table_desc         *table_info);
  99. acpi_status
  100. acpi_tb_init_table_descriptor (
  101. acpi_table_type         table_type,
  102. acpi_table_desc         *table_info);
  103. /*
  104.  * tbremove - Table removal and deletion
  105.  */
  106. void
  107. acpi_tb_delete_acpi_tables (
  108. void);
  109. void
  110. acpi_tb_delete_acpi_table (
  111. acpi_table_type         type);
  112. void
  113. acpi_tb_delete_single_table (
  114. acpi_table_desc         *table_desc);
  115. acpi_table_desc *
  116. acpi_tb_uninstall_table (
  117. acpi_table_desc         *table_desc);
  118. void
  119. acpi_tb_free_acpi_tables_of_type (
  120. acpi_table_desc         *table_info);
  121. /*
  122.  * tbrsd - RSDP, RSDT utilities
  123.  */
  124. acpi_status
  125. acpi_tb_get_table_rsdt (
  126. u32                     *number_of_tables);
  127. u8 *
  128. acpi_tb_scan_memory_for_rsdp (
  129. u8                      *start_address,
  130. u32                     length);
  131. acpi_status
  132. acpi_tb_find_rsdp (
  133. acpi_table_desc         *table_info,
  134. u32                     flags);
  135. /*
  136.  * tbutils - common table utilities
  137.  */
  138. acpi_status
  139. acpi_tb_map_acpi_table (
  140. ACPI_PHYSICAL_ADDRESS   physical_address,
  141. u32                     *size,
  142. acpi_table_header       **logical_address);
  143. acpi_status
  144. acpi_tb_verify_table_checksum (
  145. acpi_table_header       *table_header);
  146. u8
  147. acpi_tb_checksum (
  148. void                    *buffer,
  149. u32                     length);
  150. acpi_status
  151. acpi_tb_validate_table_header (
  152. acpi_table_header       *table_header);
  153. #endif /* __ACTABLES_H__ */