ACPICA: Abort downward walk on temporary node detection.
Enhancement to code that ignores temporary namespace nodes Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@intel.com> Signed-off-by: Len Brown <len.brown@intel.com>
This commit is contained in:
parent
3effba3206
commit
c1014629c0
1 changed files with 15 additions and 11 deletions
|
@ -194,24 +194,28 @@ acpi_ns_walk_namespace(acpi_object_type type,
|
||||||
child_node);
|
child_node);
|
||||||
if (child_node) {
|
if (child_node) {
|
||||||
|
|
||||||
/* Found node, Get the type if we are not searching for ANY */
|
/* Found next child, get the type if we are not searching for ANY */
|
||||||
|
|
||||||
if (type != ACPI_TYPE_ANY) {
|
if (type != ACPI_TYPE_ANY) {
|
||||||
child_type = child_node->type;
|
child_type = child_node->type;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* 1) Type must match
|
* Ignore all temporary namespace nodes (created during control
|
||||||
* 2) Permanent namespace nodes are OK
|
* method execution) unless told otherwise. These temporary nodes
|
||||||
* 3) Ignore temporary nodes unless told otherwise. Typically,
|
* can cause a race condition because they can be deleted during the
|
||||||
* the temporary nodes can cause a race condition where they can
|
* execution of the user function (if the namespace is unlocked before
|
||||||
* be deleted during the execution of the user function. Only the
|
* invocation of the user function.) Only the debugger namespace dump
|
||||||
* debugger namespace dump will examine the temporary nodes.
|
* will examine the temporary nodes.
|
||||||
*/
|
*/
|
||||||
if ((child_type == type) &&
|
if ((child_node->flags & ANOBJ_TEMPORARY) &&
|
||||||
(!(child_node->flags & ANOBJ_TEMPORARY) ||
|
!(flags & ACPI_NS_WALK_TEMP_NODES)) {
|
||||||
(child_node->flags & ANOBJ_TEMPORARY)
|
status = AE_CTRL_DEPTH;
|
||||||
&& (flags & ACPI_NS_WALK_TEMP_NODES))) {
|
}
|
||||||
|
|
||||||
|
/* Type must match requested type */
|
||||||
|
|
||||||
|
else if (child_type == type) {
|
||||||
/*
|
/*
|
||||||
* Found a matching node, invoke the user callback function.
|
* Found a matching node, invoke the user callback function.
|
||||||
* Unlock the namespace if flag is set.
|
* Unlock the namespace if flag is set.
|
||||||
|
|
Loading…
Reference in a new issue