aboutsummaryrefslogtreecommitdiff
path: root/sys/contrib/dev/acpica/nssearch.c
diff options
context:
space:
mode:
authorMike Smith <msmith@FreeBSD.org>2001-01-31 09:17:50 +0000
committerMike Smith <msmith@FreeBSD.org>2001-01-31 09:17:50 +0000
commit838fd87dd9b819087519e35200f1a995d83772b0 (patch)
tree5ed7785feb928c9fe57c2d7175f89660521314a4 /sys/contrib/dev/acpica/nssearch.c
parent68466b467536ac87a2720c76b154664b014a9650 (diff)
Update to the 20010125 ACPI CA snapshot.
Notes
Notes: svn path=/vendor-sys/acpica/dist/; revision=71867
Diffstat (limited to 'sys/contrib/dev/acpica/nssearch.c')
-rw-r--r--sys/contrib/dev/acpica/nssearch.c40
1 files changed, 30 insertions, 10 deletions
diff --git a/sys/contrib/dev/acpica/nssearch.c b/sys/contrib/dev/acpica/nssearch.c
index 8c1995428595..3ecdf4ebb143 100644
--- a/sys/contrib/dev/acpica/nssearch.c
+++ b/sys/contrib/dev/acpica/nssearch.c
@@ -1,7 +1,7 @@
/*******************************************************************************
*
* Module Name: nssearch - Namespace search
- * $Revision: 61 $
+ * $Revision: 64 $
*
******************************************************************************/
@@ -9,7 +9,7 @@
*
* 1. Copyright Notice
*
- * Some or all of this work - Copyright (c) 1999, 2000, Intel Corp.
+ * Some or all of this work - Copyright (c) 1999, 2000, 2001, Intel Corp.
* All rights reserved.
*
* 2. License
@@ -164,16 +164,26 @@ AcpiNsSearchNode (
FUNCTION_TRACE ("NsSearchNode");
+
+#ifdef ACPI_DEBUG
+ if (TRACE_NAMES & AcpiDbgLevel)
{
- DEBUG_EXEC (NATIVE_CHAR *ScopeName = AcpiNsGetTablePathname (Node));
- DEBUG_PRINT (TRACE_NAMES,
- ("NsSearchNode: Searching %s [%p]\n",
- ScopeName, Node));
- DEBUG_PRINT (TRACE_NAMES,
- ("NsSearchNode: For %4.4s (type %X)\n",
- &TargetName, Type));
- DEBUG_EXEC (AcpiCmFree (ScopeName));
+ NATIVE_CHAR *ScopeName;
+
+ ScopeName = AcpiNsGetTablePathname (Node);
+ if (ScopeName)
+ {
+ DEBUG_PRINT (TRACE_NAMES,
+ ("NsSearchNode: Searching %s [%p]\n",
+ ScopeName, Node));
+ DEBUG_PRINT (TRACE_NAMES,
+ ("NsSearchNode: For %4.4s (type %X)\n",
+ &TargetName, Type));
+
+ AcpiCmFree (ScopeName);
+ }
}
+#endif
/*
@@ -440,6 +450,16 @@ AcpiNsSearchAndEnter (
if (Status != AE_NOT_FOUND)
{
/*
+ * If we found it AND the request specifies that a
+ * find is an error, return the error
+ */
+ if ((Status == AE_OK) &&
+ (Flags & NS_ERROR_IF_FOUND))
+ {
+ Status = AE_EXIST;
+ }
+
+ /*
* Either found it or there was an error
* -- finished either way
*/