diff options
author | Alexey Starikovskiy <astarikovskiy@suse.de> | 2010-05-25 23:53:07 -0400 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2010-07-06 22:33:56 -0400 |
commit | c45b5c097001480e66d4c523eb715ad317a4ef77 (patch) | |
tree | 5b9415840b97a724537273db99b2c66975c63347 /drivers/acpi/acpica/evrgnini.c | |
parent | 5821f75421aa7c7bafdec291223153597f649934 (diff) |
ACPICA: Performance enhancement for namespace search and access
This change enhances the performance of namespace searches and
walks by adding a backpointer to the parent in each namespace
node. On large namespaces, this change can improve overall ACPI
performance by up to 9X. Adding a pointer to each namespace node
increases the overall size of the internal namespace by about 5%,
since each namespace entry usually consists of both a namespace
node and an ACPI operand object.
Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/acpica/evrgnini.c')
-rw-r--r-- | drivers/acpi/acpica/evrgnini.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/acpi/acpica/evrgnini.c b/drivers/acpi/acpica/evrgnini.c index 2e3b0334072f..f40d271bf568 100644 --- a/drivers/acpi/acpica/evrgnini.c +++ b/drivers/acpi/acpica/evrgnini.c | |||
@@ -199,7 +199,7 @@ acpi_ev_pci_config_region_setup(acpi_handle handle, | |||
199 | return_ACPI_STATUS(status); | 199 | return_ACPI_STATUS(status); |
200 | } | 200 | } |
201 | 201 | ||
202 | parent_node = acpi_ns_get_parent_node(region_obj->region.node); | 202 | parent_node = region_obj->region.node->parent; |
203 | 203 | ||
204 | /* | 204 | /* |
205 | * Get the _SEG and _BBN values from the device upon which the handler | 205 | * Get the _SEG and _BBN values from the device upon which the handler |
@@ -248,7 +248,7 @@ acpi_ev_pci_config_region_setup(acpi_handle handle, | |||
248 | break; | 248 | break; |
249 | } | 249 | } |
250 | 250 | ||
251 | pci_root_node = acpi_ns_get_parent_node(pci_root_node); | 251 | pci_root_node = pci_root_node->parent; |
252 | } | 252 | } |
253 | 253 | ||
254 | /* PCI root bridge not found, use namespace root node */ | 254 | /* PCI root bridge not found, use namespace root node */ |
@@ -280,7 +280,7 @@ acpi_ev_pci_config_region_setup(acpi_handle handle, | |||
280 | */ | 280 | */ |
281 | pci_device_node = region_obj->region.node; | 281 | pci_device_node = region_obj->region.node; |
282 | while (pci_device_node && (pci_device_node->type != ACPI_TYPE_DEVICE)) { | 282 | while (pci_device_node && (pci_device_node->type != ACPI_TYPE_DEVICE)) { |
283 | pci_device_node = acpi_ns_get_parent_node(pci_device_node); | 283 | pci_device_node = pci_device_node->parent; |
284 | } | 284 | } |
285 | 285 | ||
286 | if (!pci_device_node) { | 286 | if (!pci_device_node) { |
@@ -521,7 +521,7 @@ acpi_ev_initialize_region(union acpi_operand_object *region_obj, | |||
521 | return_ACPI_STATUS(AE_NOT_EXIST); | 521 | return_ACPI_STATUS(AE_NOT_EXIST); |
522 | } | 522 | } |
523 | 523 | ||
524 | node = acpi_ns_get_parent_node(region_obj->region.node); | 524 | node = region_obj->region.node->parent; |
525 | space_id = region_obj->region.space_id; | 525 | space_id = region_obj->region.space_id; |
526 | 526 | ||
527 | /* Setup defaults */ | 527 | /* Setup defaults */ |
@@ -654,7 +654,7 @@ acpi_ev_initialize_region(union acpi_operand_object *region_obj, | |||
654 | 654 | ||
655 | /* This node does not have the handler we need; Pop up one level */ | 655 | /* This node does not have the handler we need; Pop up one level */ |
656 | 656 | ||
657 | node = acpi_ns_get_parent_node(node); | 657 | node = node->parent; |
658 | } | 658 | } |
659 | 659 | ||
660 | /* If we get here, there is no handler for this region */ | 660 | /* If we get here, there is no handler for this region */ |