Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ACPICA: Add new ACPI 6.4 semantics for LoadTable() operator

ACPICA commit b32dde35e26a63a85d78d4dc0a7260b61e626ac1

DDB_HANDLE is gone, now LoadTable() returns a pass/fail integer.

Link: https://github.com/acpica/acpica/commit/b32dde35
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

authored by

Bob Moore and committed by
Rafael J. Wysocki
e468e39f 39ea1bbf

+17 -7
+17 -7
drivers/acpi/acpica/exconfig.c
··· 87 87 struct acpi_namespace_node *parent_node; 88 88 struct acpi_namespace_node *start_node; 89 89 struct acpi_namespace_node *parameter_node = NULL; 90 + union acpi_operand_object *return_obj; 90 91 union acpi_operand_object *ddb_handle; 91 92 u32 table_index; 92 93 93 94 ACPI_FUNCTION_TRACE(ex_load_table_op); 95 + 96 + /* Create the return object */ 97 + 98 + return_obj = acpi_ut_create_integer_object((u64)0); 99 + if (!return_obj) { 100 + return_ACPI_STATUS(AE_NO_MEMORY); 101 + } 102 + 103 + *return_desc = return_obj; 94 104 95 105 /* Find the ACPI table in the RSDT/XSDT */ 96 106 ··· 116 106 117 107 /* Table not found, return an Integer=0 and AE_OK */ 118 108 119 - ddb_handle = acpi_ut_create_integer_object((u64) 0); 120 - if (!ddb_handle) { 121 - return_ACPI_STATUS(AE_NO_MEMORY); 122 - } 123 - 124 - *return_desc = ddb_handle; 125 109 return_ACPI_STATUS(AE_OK); 126 110 } 127 111 ··· 202 198 } 203 199 } 204 200 205 - *return_desc = ddb_handle; 201 + /* Remove the reference to ddb_handle created by acpi_ex_add_table above */ 202 + 203 + acpi_ut_remove_reference(ddb_handle); 204 + 205 + /* Return -1 (non-zero) indicates success */ 206 + 207 + return_obj->integer.value = 0xFFFFFFFFFFFFFFFF; 206 208 return_ACPI_STATUS(status); 207 209 } 208 210