[PATCH 3/8] ACPI: acpi_tb_install_table supports inactive tables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



acpi_tb_install_table supports inactive tables.

Signed-off-by: Zhang Rui <rui.zhang@xxxxxxxxx>
---
 drivers/acpi/tables/tbutils.c |   14 +++++++++-----
 1 file changed, 9 insertions(+), 5 deletions(-)

Index: linux-2.6/drivers/acpi/tables/tbutils.c
===================================================================
--- linux-2.6.orig/drivers/acpi/tables/tbutils.c
+++ linux-2.6/drivers/acpi/tables/tbutils.c
@@ -295,6 +295,8 @@ acpi_tb_install_table(acpi_physical_addr
 		      u8 flags, char *signature, u32 table_index)
 {
 	struct acpi_table_header *table;
+	struct acpi_internal_rsdt *root_table_list =
+						get_root_table_list(flags);
 
 	if (!address) {
 		ACPI_ERROR((AE_INFO,
@@ -321,15 +323,16 @@ acpi_tb_install_table(acpi_physical_addr
 
 	/* Initialize the table entry */
 
-	acpi_gbl_root_table_list.tables[table_index].address = address;
-	acpi_gbl_root_table_list.tables[table_index].length = table->length;
-	acpi_gbl_root_table_list.tables[table_index].flags = flags;
+	root_table_list->tables[table_index].address = address;
+	root_table_list->tables[table_index].length = table->length;
+	root_table_list->tables[table_index].flags = flags;
 
 	ACPI_MOVE_32_TO_32(&
-			   (acpi_gbl_root_table_list.tables[table_index].
+			   (root_table_list->tables[table_index].
 			    signature), table->signature);
 
-	acpi_tb_print_table_header(address, table);
+	if (TABLE_IS_ACTIVE(flags))
+		acpi_tb_print_table_header(address, table);
 
 	if (table_index == ACPI_TABLE_INDEX_DSDT) {
 


--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux