ACPICA: Implement simplified Table Manager

The Table Manager component has been completely
redesigned and reimplemented. The new design is much
simpler, and reduces the overall code and data size of
the kernel-resident ACPICA by approximately 5%. Also,
it is now possible to obtain the ACPI tables very early
during kernel initialization, even before dynamic memory
management is initialized.

Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
This commit is contained in:
Bob Moore
2007-02-02 19:48:18 +03:00
committed by Len Brown
parent 2e42005bcd
commit f3d2e7865c
42 changed files with 2262 additions and 4243 deletions

View File

@@ -44,105 +44,62 @@
#ifndef __ACTABLES_H__
#define __ACTABLES_H__
/* Used in acpi_tb_map_acpi_table for size parameter if table header is to be used */
#define SIZE_IN_HEADER 0
/*
* tbconvrt - Table conversion routines
*/
acpi_status acpi_tb_convert_to_xsdt(struct acpi_table_desc *table_info);
acpi_status acpi_tb_convert_table_fadt(void);
acpi_status acpi_tb_build_common_facs(struct acpi_table_desc *table_info);
u32
acpi_tb_get_table_count(struct rsdp_descriptor *RSDP,
struct acpi_table_header *RSDT);
/*
* tbget - Table "get" routines
*/
acpi_status
acpi_tb_get_table(struct acpi_pointer *address,
struct acpi_table_desc *table_info);
acpi_status
acpi_tb_get_table_header(struct acpi_pointer *address,
struct acpi_table_header *return_header);
acpi_status
acpi_tb_get_table_body(struct acpi_pointer *address,
struct acpi_table_header *header,
struct acpi_table_desc *table_info);
acpi_status
acpi_tb_get_table_ptr(acpi_table_type table_type,
u32 instance, struct acpi_table_header **table_ptr_loc);
acpi_status acpi_tb_verify_rsdp(struct acpi_pointer *address);
void acpi_tb_get_rsdt_address(struct acpi_pointer *out_address);
acpi_status acpi_tb_validate_rsdt(struct acpi_table_header *table_ptr);
/*
* tbgetall - get multiple required tables
*/
acpi_status acpi_tb_get_required_tables(void);
/*
* tbinstall - Table installation
*/
acpi_status acpi_tb_install_table(struct acpi_table_desc *table_info);
acpi_status
acpi_tb_recognize_table(struct acpi_table_desc *table_info, u8 search_type);
acpi_status
acpi_tb_init_table_descriptor(acpi_table_type table_type,
struct acpi_table_desc *table_info);
/*
* tbremove - Table removal and deletion
*/
void acpi_tb_delete_all_tables(void);
void acpi_tb_delete_tables_by_type(acpi_table_type type);
void acpi_tb_delete_single_table(struct acpi_table_desc *table_desc);
struct acpi_table_desc *acpi_tb_uninstall_table(struct acpi_table_desc
*table_desc);
/*
* tbxfroot - RSDP, RSDT utilities
* tbfind - find ACPI table
*/
acpi_status
acpi_tb_find_table(char *signature,
char *oem_id,
char *oem_table_id, struct acpi_table_header **table_ptr);
acpi_status acpi_tb_get_table_rsdt(void);
acpi_status acpi_tb_validate_rsdp(struct rsdp_descriptor *rsdp);
char *oem_table_id, acpi_native_uint * table_index);
/*
* tbutils - common table utilities
* tbinstal - Table removal and deletion
*/
acpi_status acpi_tb_is_table_installed(struct acpi_table_desc *new_table_desc);
acpi_status acpi_tb_resize_root_table_list(void);
acpi_status acpi_tb_verify_table(struct acpi_table_desc *table_desc);
acpi_status
acpi_tb_verify_table_checksum(struct acpi_table_header *table_header);
u8 acpi_tb_sum_table(void *buffer, u32 length);
u8 acpi_tb_generate_checksum(struct acpi_table_header *table);
void acpi_tb_set_checksum(struct acpi_table_header *table);
acpi_tb_add_table(struct acpi_table_header *table,
acpi_native_uint * table_index);
acpi_status
acpi_tb_validate_table_header(struct acpi_table_header *table_header);
acpi_tb_store_table(acpi_physical_address address,
struct acpi_table_header *table,
u32 length, u8 flags, acpi_native_uint * table_index);
void acpi_tb_delete_table(acpi_native_uint table_index);
void acpi_tb_terminate(void);
void acpi_tb_delete_namespace_by_owner(acpi_native_uint table_index);
acpi_status acpi_tb_allocate_owner_id(acpi_native_uint table_index);
acpi_status acpi_tb_release_owner_id(acpi_native_uint table_index);
acpi_status
acpi_tb_get_owner_id(acpi_native_uint table_index, acpi_owner_id * owner_id);
u8 acpi_tb_is_table_loaded(acpi_native_uint table_index);
void acpi_tb_set_table_loaded_flag(acpi_native_uint table_index, u8 is_loaded);
/*
* tbutils - table manager utilities
*/
void
acpi_tb_print_table_header(acpi_physical_address address,
struct acpi_table_header *header);
u8 acpi_tb_checksum(u8 * buffer, acpi_native_uint length);
void acpi_tb_convert_fadt(struct acpi_table_fadt *fadt);
acpi_status acpi_tb_parse_root_table(struct acpi_table_rsdp *rsdp, u8 flags);
void *acpi_tb_map(acpi_physical_address address, u32 length, u32 flags);
void acpi_tb_unmap(void *pointer, u32 length, u32 flags);
#endif /* __ACTABLES_H__ */