Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
a6817928
Commit
a6817928
authored
Aug 15, 2002
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Plain Diff
Merge
http://linux-acpi.bkbits.net/linux-acpi
into home.transmeta.com:/home/torvalds/v2.5/linux
parents
1c01cb01
a969f910
Changes
86
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
86 changed files
with
626 additions
and
717 deletions
+626
-717
arch/i386/kernel/acpi.c
arch/i386/kernel/acpi.c
+1
-4
drivers/acpi/Makefile
drivers/acpi/Makefile
+1
-1
drivers/acpi/acpi_ksyms.c
drivers/acpi/acpi_ksyms.c
+1
-0
drivers/acpi/bus.c
drivers/acpi/bus.c
+1
-1
drivers/acpi/debugger/dbcmds.c
drivers/acpi/debugger/dbcmds.c
+4
-4
drivers/acpi/debugger/dbdisply.c
drivers/acpi/debugger/dbdisply.c
+4
-4
drivers/acpi/debugger/dbexec.c
drivers/acpi/debugger/dbexec.c
+6
-6
drivers/acpi/debugger/dbfileio.c
drivers/acpi/debugger/dbfileio.c
+5
-5
drivers/acpi/debugger/dbhistry.c
drivers/acpi/debugger/dbhistry.c
+4
-4
drivers/acpi/debugger/dbinput.c
drivers/acpi/debugger/dbinput.c
+4
-4
drivers/acpi/debugger/dbstats.c
drivers/acpi/debugger/dbstats.c
+5
-15
drivers/acpi/debugger/dbutils.c
drivers/acpi/debugger/dbutils.c
+4
-4
drivers/acpi/debugger/dbxface.c
drivers/acpi/debugger/dbxface.c
+5
-5
drivers/acpi/dispatcher/dsfield.c
drivers/acpi/dispatcher/dsfield.c
+1
-1
drivers/acpi/dispatcher/dsmethod.c
drivers/acpi/dispatcher/dsmethod.c
+1
-1
drivers/acpi/dispatcher/dsmthdat.c
drivers/acpi/dispatcher/dsmthdat.c
+32
-15
drivers/acpi/dispatcher/dsobject.c
drivers/acpi/dispatcher/dsobject.c
+1
-1
drivers/acpi/dispatcher/dsopcode.c
drivers/acpi/dispatcher/dsopcode.c
+1
-1
drivers/acpi/dispatcher/dswexec.c
drivers/acpi/dispatcher/dswexec.c
+1
-1
drivers/acpi/dispatcher/dswload.c
drivers/acpi/dispatcher/dswload.c
+13
-13
drivers/acpi/dispatcher/dswstate.c
drivers/acpi/dispatcher/dswstate.c
+20
-3
drivers/acpi/events/evevent.c
drivers/acpi/events/evevent.c
+2
-2
drivers/acpi/events/evmisc.c
drivers/acpi/events/evmisc.c
+50
-1
drivers/acpi/events/evregion.c
drivers/acpi/events/evregion.c
+1
-1
drivers/acpi/events/evrgnini.c
drivers/acpi/events/evrgnini.c
+1
-1
drivers/acpi/events/evxface.c
drivers/acpi/events/evxface.c
+1
-1
drivers/acpi/events/evxfevnt.c
drivers/acpi/events/evxfevnt.c
+19
-16
drivers/acpi/executer/exdump.c
drivers/acpi/executer/exdump.c
+2
-2
drivers/acpi/executer/exfldio.c
drivers/acpi/executer/exfldio.c
+1
-1
drivers/acpi/executer/exmisc.c
drivers/acpi/executer/exmisc.c
+1
-1
drivers/acpi/executer/exoparg1.c
drivers/acpi/executer/exoparg1.c
+1
-1
drivers/acpi/executer/exoparg2.c
drivers/acpi/executer/exoparg2.c
+1
-1
drivers/acpi/executer/exprep.c
drivers/acpi/executer/exprep.c
+1
-1
drivers/acpi/executer/exregion.c
drivers/acpi/executer/exregion.c
+1
-1
drivers/acpi/executer/exresop.c
drivers/acpi/executer/exresop.c
+1
-1
drivers/acpi/executer/exstore.c
drivers/acpi/executer/exstore.c
+1
-1
drivers/acpi/executer/exutils.c
drivers/acpi/executer/exutils.c
+3
-2
drivers/acpi/hardware/hwacpi.c
drivers/acpi/hardware/hwacpi.c
+22
-1
drivers/acpi/hardware/hwgpe.c
drivers/acpi/hardware/hwgpe.c
+1
-1
drivers/acpi/hardware/hwregs.c
drivers/acpi/hardware/hwregs.c
+1
-1
drivers/acpi/hardware/hwsleep.c
drivers/acpi/hardware/hwsleep.c
+1
-1
drivers/acpi/include/acconfig.h
drivers/acpi/include/acconfig.h
+3
-3
drivers/acpi/include/acdisasm.h
drivers/acpi/include/acdisasm.h
+1
-1
drivers/acpi/include/acglobal.h
drivers/acpi/include/acglobal.h
+9
-5
drivers/acpi/include/aclocal.h
drivers/acpi/include/aclocal.h
+3
-3
drivers/acpi/include/acmacros.h
drivers/acpi/include/acmacros.h
+9
-9
drivers/acpi/include/acobject.h
drivers/acpi/include/acobject.h
+1
-1
drivers/acpi/include/acoutput.h
drivers/acpi/include/acoutput.h
+11
-7
drivers/acpi/include/acparser.h
drivers/acpi/include/acparser.h
+5
-4
drivers/acpi/include/acresrc.h
drivers/acpi/include/acresrc.h
+1
-1
drivers/acpi/include/actbl2.h
drivers/acpi/include/actbl2.h
+2
-2
drivers/acpi/include/acutils.h
drivers/acpi/include/acutils.h
+3
-3
drivers/acpi/include/amlcode.h
drivers/acpi/include/amlcode.h
+1
-1
drivers/acpi/include/amlresrc.h
drivers/acpi/include/amlresrc.h
+1
-168
drivers/acpi/include/platform/acenv.h
drivers/acpi/include/platform/acenv.h
+6
-6
drivers/acpi/namespace/nsaccess.c
drivers/acpi/namespace/nsaccess.c
+94
-29
drivers/acpi/namespace/nsdump.c
drivers/acpi/namespace/nsdump.c
+2
-2
drivers/acpi/namespace/nsdumpdv.c
drivers/acpi/namespace/nsdumpdv.c
+2
-2
drivers/acpi/namespace/nseval.c
drivers/acpi/namespace/nseval.c
+1
-1
drivers/acpi/namespace/nsinit.c
drivers/acpi/namespace/nsinit.c
+2
-2
drivers/acpi/namespace/nsload.c
drivers/acpi/namespace/nsload.c
+1
-1
drivers/acpi/namespace/nsnames.c
drivers/acpi/namespace/nsnames.c
+2
-2
drivers/acpi/namespace/nssearch.c
drivers/acpi/namespace/nssearch.c
+4
-4
drivers/acpi/namespace/nsutils.c
drivers/acpi/namespace/nsutils.c
+7
-4
drivers/acpi/namespace/nsxfeval.c
drivers/acpi/namespace/nsxfeval.c
+1
-1
drivers/acpi/parser/psargs.c
drivers/acpi/parser/psargs.c
+98
-189
drivers/acpi/parser/psopcode.c
drivers/acpi/parser/psopcode.c
+12
-12
drivers/acpi/parser/psparse.c
drivers/acpi/parser/psparse.c
+60
-77
drivers/acpi/parser/pstree.c
drivers/acpi/parser/pstree.c
+1
-1
drivers/acpi/resources/rsdump.c
drivers/acpi/resources/rsdump.c
+2
-2
drivers/acpi/system.c
drivers/acpi/system.c
+3
-2
drivers/acpi/tables.c
drivers/acpi/tables.c
+3
-3
drivers/acpi/tables/tbconvrt.c
drivers/acpi/tables/tbconvrt.c
+1
-1
drivers/acpi/tables/tbget.c
drivers/acpi/tables/tbget.c
+1
-1
drivers/acpi/tables/tbgetall.c
drivers/acpi/tables/tbgetall.c
+1
-1
drivers/acpi/tables/tbinstal.c
drivers/acpi/tables/tbinstal.c
+1
-1
drivers/acpi/tables/tbrsdt.c
drivers/acpi/tables/tbrsdt.c
+1
-1
drivers/acpi/tables/tbutils.c
drivers/acpi/tables/tbutils.c
+3
-3
drivers/acpi/thermal.c
drivers/acpi/thermal.c
+17
-13
drivers/acpi/utilities/utdebug.c
drivers/acpi/utilities/utdebug.c
+2
-2
drivers/acpi/utilities/uteval.c
drivers/acpi/utilities/uteval.c
+1
-1
drivers/acpi/utilities/utglobal.c
drivers/acpi/utilities/utglobal.c
+8
-4
drivers/acpi/utilities/utinit.c
drivers/acpi/utilities/utinit.c
+5
-5
drivers/acpi/utilities/utmisc.c
drivers/acpi/utilities/utmisc.c
+2
-2
drivers/acpi/utilities/utxface.c
drivers/acpi/utilities/utxface.c
+4
-2
include/linux/acpi.h
include/linux/acpi.h
+1
-1
No files found.
arch/i386/kernel/acpi.c
View file @
a6817928
...
...
@@ -32,7 +32,6 @@
#include <linux/slab.h>
#include <linux/pci.h>
#include <linux/bootmem.h>
#include <linux/slab.h>
#include <linux/irq.h>
#include <linux/acpi.h>
#include <asm/mpspec.h>
...
...
@@ -53,11 +52,9 @@
Boot-time Configuration
-------------------------------------------------------------------------- */
#ifdef CONFIG_ACPI_BOOT
enum
acpi_irq_model_id
acpi_irq_model
;
#ifdef CONFIG_ACPI_BOOT
/*
* Use reserved fixmap pages for physical-to-virtual mappings of ACPI tables.
* Note that the same range is used for each table, so tables that need to
...
...
drivers/acpi/Makefile
View file @
a6817928
...
...
@@ -7,7 +7,7 @@ export ACPI_CFLAGS
ACPI_CFLAGS
:=
-D_LINUX
-I
$(CURDIR)
/include
ifdef
CONFIG_ACPI_DEBUG
ACPI_CFLAGS
+=
-DACPI_DEBUG
ACPI_CFLAGS
+=
-DACPI_DEBUG
_OUTPUT
endif
EXTRA_CFLAGS
+=
$(ACPI_CFLAGS)
...
...
drivers/acpi/acpi_ksyms.c
View file @
a6817928
...
...
@@ -62,6 +62,7 @@ EXPORT_SYMBOL(acpi_get_object_info);
EXPORT_SYMBOL
(
acpi_get_next_object
);
EXPORT_SYMBOL
(
acpi_evaluate_object
);
EXPORT_SYMBOL
(
acpi_get_table
);
EXPORT_SYMBOL
(
acpi_get_firmware_table
);
EXPORT_SYMBOL
(
acpi_install_notify_handler
);
EXPORT_SYMBOL
(
acpi_remove_notify_handler
);
EXPORT_SYMBOL
(
acpi_install_gpe_handler
);
...
...
drivers/acpi/bus.c
View file @
a6817928
...
...
@@ -2052,7 +2052,7 @@ acpi_bus_init (void)
/* Mimic structured exception handling */
error4:
remove_proc_entry
(
"ACPI"
,
NULL
);
remove_proc_entry
(
ACPI_BUS_FILE_ROOT
,
NULL
);
error3:
acpi_bus_remove
(
acpi_root
,
ACPI_BUS_REMOVAL_NORMAL
);
error2:
...
...
drivers/acpi/debugger/dbcmds.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: dbcmds - debug commands and output routines
* $Revision: 8
5
$
* $Revision: 8
7
$
*
******************************************************************************/
...
...
@@ -33,9 +33,9 @@
#include "acresrc.h"
#include "acdisasm.h"
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbcmds"
)
...
...
@@ -1111,4 +1111,4 @@ acpi_db_check_integrity (void)
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/debugger/dbdisply.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: dbdisply - debug display commands
* $Revision: 7
6
$
* $Revision: 7
8
$
*
******************************************************************************/
...
...
@@ -33,10 +33,10 @@
#include "acdebug.h"
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbdisply"
)
...
...
@@ -855,5 +855,5 @@ acpi_db_display_argument_object (
acpi_db_display_internal_object
(
obj_desc
,
walk_state
);
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/debugger/dbexec.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: dbexec - debugger control method execution
* $Revision: 4
2
$
* $Revision: 4
4
$
*
******************************************************************************/
...
...
@@ -27,9 +27,9 @@
#include "acpi.h"
#include "acdebug.h"
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbexec"
)
...
...
@@ -209,7 +209,7 @@ acpi_db_execute (
acpi_buffer
return_obj
;
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
u32
previous_allocations
;
u32
allocations
;
...
...
@@ -236,7 +236,7 @@ acpi_db_execute (
acpi_os_sleep
(
0
,
10
);
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
/* Memory allocation tracking */
...
...
@@ -400,6 +400,6 @@ acpi_db_create_execution_threads (
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/debugger/dbfileio.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
*
* Module Name: dbfileio - Debugger file I/O commands. These can't usually
* be used when running the debugger in Ring 0 (Kernel mode)
* $Revision: 6
7
$
* $Revision: 6
8
$
*
******************************************************************************/
...
...
@@ -30,9 +30,9 @@
#include "acnamesp.h"
#include "actables.h"
#if (defined
ENABLE
_DEBUGGER || defined ACPI_DISASSEMBLER)
#if (defined
ACPI
_DEBUGGER || defined ACPI_DISASSEMBLER)
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbfileio"
)
...
...
@@ -86,7 +86,7 @@ acpi_db_match_argument (
}
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
/*******************************************************************************
*
* FUNCTION: Acpi_db_close_debug_file
...
...
@@ -395,5 +395,5 @@ acpi_db_load_acpi_table (
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/debugger/dbhistry.c
View file @
a6817928
/******************************************************************************
*
* Module Name: dbhistry - debugger HISTORY command
* $Revision: 2
4
$
* $Revision: 2
5
$
*
*****************************************************************************/
...
...
@@ -27,9 +27,9 @@
#include "acpi.h"
#include "acdebug.h"
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbhistry"
)
...
...
@@ -185,5 +185,5 @@ acpi_db_get_from_history (
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/debugger/dbinput.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: dbinput - user front-end to the AML debugger
* $Revision: 8
6
$
* $Revision: 8
7
$
*
******************************************************************************/
...
...
@@ -28,9 +28,9 @@
#include "acdebug.h"
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbinput"
)
...
...
@@ -888,5 +888,5 @@ acpi_db_user_commands (
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/debugger/dbstats.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: dbstats - Generation and display of ACPI table statistics
* $Revision: 6
0
$
* $Revision: 6
1
$
*
******************************************************************************/
...
...
@@ -28,9 +28,9 @@
#include <acdebug.h>
#include <acnamesp.h>
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbstats"
)
/*
...
...
@@ -148,8 +148,6 @@ acpi_db_enumerate_object (
}
#ifndef PARSER_ONLY
/*******************************************************************************
*
* FUNCTION: Acpi_db_classify_one_object
...
...
@@ -254,8 +252,6 @@ acpi_db_count_namespace_objects (
FALSE
,
acpi_db_classify_one_object
,
NULL
,
NULL
);
}
#endif
/*******************************************************************************
*
...
...
@@ -303,13 +299,11 @@ acpi_db_display_statistics (
switch
(
type
)
{
#ifndef PARSER_ONLY
case
CMD_STAT_ALLOCATIONS
:
#ifdef ACPI_DBG_TRACK_ALLOCATIONS
acpi_ut_dump_allocation_info
();
#endif
break
;
#endif
case
CMD_STAT_TABLES
:
...
...
@@ -322,8 +316,6 @@ acpi_db_display_statistics (
case
CMD_STAT_OBJECTS
:
#ifndef PARSER_ONLY
acpi_db_count_namespace_objects
();
acpi_os_printf
(
"
\n
Objects defined in the current namespace:
\n\n
"
);
...
...
@@ -340,8 +332,6 @@ acpi_db_display_statistics (
acpi_os_printf
(
"%16.16s % 10ld% 10ld
\n
"
,
"TOTALS:"
,
acpi_gbl_num_nodes
,
acpi_gbl_num_objects
);
#endif
break
;
case
CMD_STAT_MEMORY
:
...
...
@@ -445,7 +435,7 @@ acpi_db_display_statistics (
case
CMD_STAT_STACK
:
#if defined(ACPI_DEBUG)
#if defined(ACPI_DEBUG
_OUTPUT
)
size
=
(
u32
)
(
acpi_gbl_entry_stack_pointer
-
acpi_gbl_lowest_stack_pointer
);
...
...
@@ -466,4 +456,4 @@ acpi_db_display_statistics (
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/debugger/dbutils.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: dbutils - AML debugger utilities
* $Revision: 5
5
$
* $Revision: 5
6
$
*
******************************************************************************/
...
...
@@ -32,9 +32,9 @@
#include "acdispat.h"
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbutils"
)
...
...
@@ -375,6 +375,6 @@ acpi_db_local_ns_lookup (
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/debugger/dbxface.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: dbxface - AML Debugger external interfaces
* $Revision: 6
1
$
* $Revision: 6
4
$
*
******************************************************************************/
...
...
@@ -30,9 +30,9 @@
#include "acdisasm.h"
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define _COMPONENT ACPI_DEBUGGER
#define _COMPONENT ACPI_
CA_
DEBUGGER
ACPI_MODULE_NAME
(
"dbxface"
)
...
...
@@ -184,7 +184,7 @@ acpi_db_single_step (
/* Restore everything */
op
->
common
.
next
=
next
;
acpi_os_printf
(
"
\n
"
);
acpi_os_printf
(
"
\n
\n
"
);
acpi_dbg_level
=
original_debug_level
;
}
...
...
@@ -385,4 +385,4 @@ acpi_db_terminate (void)
}
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
drivers/acpi/dispatcher/dsfield.c
View file @
a6817928
/******************************************************************************
*
* Module Name: dsfield - Dispatcher field routines
* $Revision: 6
5
$
* $Revision: 6
6
$
*
*****************************************************************************/
...
...
drivers/acpi/dispatcher/dsmethod.c
View file @
a6817928
/******************************************************************************
*
* Module Name: dsmethod - Parser/Interpreter interface - control method parsing
* $Revision: 8
7
$
* $Revision: 8
8
$
*
*****************************************************************************/
...
...
drivers/acpi/dispatcher/dsmthdat.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: dsmthdat - control method arguments and local variables
* $Revision: 6
2
$
* $Revision: 6
3
$
*
******************************************************************************/
...
...
@@ -587,24 +587,41 @@ acpi_ds_store_object_to_local (
*
* Weird, but true.
*/
if
((
opcode
==
AML_ARG_OP
)
&&
(
ACPI_GET_DESCRIPTOR_TYPE
(
current_obj_desc
)
==
ACPI_DESC_TYPE_NAMED
))
{
if
(
opcode
==
AML_ARG_OP
)
{
/*
* Make sure that the object is the correct type. This may be overkill, but
* it is here because references were NS nodes in the past. Now they are
* operand objects of type Reference.
*/
if
(
ACPI_GET_DESCRIPTOR_TYPE
(
current_obj_desc
)
!=
ACPI_DESC_TYPE_OPERAND
)
{
ACPI_REPORT_ERROR
((
"Invalid descriptor type while storing to method arg: %X
\n
"
,
current_obj_desc
->
common
.
type
));
return_ACPI_STATUS
(
AE_AML_INTERNAL
);
}
/*
* If we have a valid reference object that came from Ref_of(), do the
* indirect store
*/
if
((
current_obj_desc
->
common
.
type
==
INTERNAL_TYPE_REFERENCE
)
&&
(
current_obj_desc
->
reference
.
opcode
==
AML_REF_OF_OP
))
{
ACPI_DEBUG_PRINT
((
ACPI_DB_EXEC
,
"Arg (%p) is an Obj_ref(Node), storing in node %p
\n
"
,
obj_desc
,
current_obj_desc
));
/* Detach an existing object from the
Node */
/* Detach an existing object from the referenced
Node */
acpi_ns_detach_object
((
acpi_namespace_node
*
)
current_obj_desc
);
acpi_ns_detach_object
(
current_obj_desc
->
reference
.
object
);
/*
* Store this object into the Node
* (perform the indirect store)
*/
status
=
acpi_ns_attach_object
((
acpi_namespace_node
*
)
current_obj_desc
,
status
=
acpi_ns_attach_object
(
current_obj_desc
->
reference
.
object
,
obj_desc
,
ACPI_GET_OBJECT_TYPE
(
obj_desc
));
return_ACPI_STATUS
(
status
);
}
}
/*
* Delete the existing object
...
...
drivers/acpi/dispatcher/dsobject.c
View file @
a6817928
/******************************************************************************
*
* Module Name: dsobject - Dispatcher object management routines
* $Revision: 10
5
$
* $Revision: 10
6
$
*
*****************************************************************************/
...
...
drivers/acpi/dispatcher/dsopcode.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
*
* Module Name: dsopcode - Dispatcher Op Region support and handling of
* "control" opcodes
* $Revision: 8
0
$
* $Revision: 8
1
$
*
*****************************************************************************/
...
...
drivers/acpi/dispatcher/dswexec.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
*
* Module Name: dswexec - Dispatcher method execution callbacks;
* dispatch to interpreter.
* $Revision: 9
4
$
* $Revision: 9
5
$
*
*****************************************************************************/
...
...
drivers/acpi/dispatcher/dswload.c
View file @
a6817928
/******************************************************************************
*
* Module Name: dswload - Dispatcher namespace load callbacks
* $Revision:
69
$
* $Revision:
70
$
*
*****************************************************************************/
...
...
@@ -296,7 +296,7 @@ acpi_ds_load2_begin_op (
NATIVE_CHAR
*
buffer_ptr
;
ACPI_FUNCTION_
NAM
E
(
"Ds_load2_begin_op"
);
ACPI_FUNCTION_
TRAC
E
(
"Ds_load2_begin_op"
);
op
=
walk_state
->
op
;
...
...
@@ -307,7 +307,7 @@ acpi_ds_load2_begin_op (
if
((
!
(
walk_state
->
op_info
->
flags
&
AML_NSOPCODE
)
&&
(
walk_state
->
opcode
!=
AML_INT_NAMEPATH_OP
))
||
(
!
(
walk_state
->
op_info
->
flags
&
AML_NAMED
)))
{
return
(
AE_OK
);
return
_ACPI_STATUS
(
AE_OK
);
}
/*
...
...
@@ -320,7 +320,7 @@ acpi_ds_load2_begin_op (
if
(
!
buffer_ptr
)
{
/* No name, just exit */
return
(
AE_OK
);
return
_ACPI_STATUS
(
AE_OK
);
}
}
else
{
...
...
@@ -368,11 +368,11 @@ acpi_ds_load2_begin_op (
if
(
acpi_ns_opens_scope
(
object_type
))
{
status
=
acpi_ds_scope_stack_push
(
node
,
object_type
,
walk_state
);
if
(
ACPI_FAILURE
(
status
))
{
return
(
status
);
return
_ACPI_STATUS
(
status
);
}
}
return
(
AE_OK
);
return
_ACPI_STATUS
(
AE_OK
);
}
/*
...
...
@@ -390,7 +390,7 @@ acpi_ds_load2_begin_op (
op
=
acpi_ps_alloc_op
(
walk_state
->
opcode
);
if
(
!
op
)
{
return
(
AE_NO_MEMORY
);
return
_ACPI_STATUS
(
AE_NO_MEMORY
);
}
/* Initialize the new op */
...
...
@@ -410,7 +410,7 @@ acpi_ds_load2_begin_op (
op
->
common
.
node
=
node
;
}
return
(
status
);
return
_ACPI_STATUS
(
status
);
}
...
...
@@ -444,7 +444,7 @@ acpi_ds_load2_end_op (
#endif
ACPI_FUNCTION_
NAM
E
(
"Ds_load2_end_op"
);
ACPI_FUNCTION_
TRAC
E
(
"Ds_load2_end_op"
);
op
=
walk_state
->
op
;
ACPI_DEBUG_PRINT
((
ACPI_DB_DISPATCH
,
"Opcode [%s] Op %p State %p
\n
"
,
...
...
@@ -453,7 +453,7 @@ acpi_ds_load2_end_op (
/* Only interested in opcodes that have namespace objects */
if
(
!
(
walk_state
->
op_info
->
flags
&
AML_NSOBJECT
))
{
return
(
AE_OK
);
return
_ACPI_STATUS
(
AE_OK
);
}
if
(
op
->
common
.
aml_opcode
==
AML_SCOPE_OP
)
{
...
...
@@ -479,13 +479,13 @@ acpi_ds_load2_end_op (
/* Pop the scope stack */
if
(
acpi_ns_opens_scope
(
object_type
))
{
if
(
acpi_ns_opens_scope
(
object_type
)
&&
(
op
->
common
.
aml_opcode
!=
AML_INT_METHODCALL_OP
)
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_DISPATCH
,
"(%s) Popping scope for Op %p
\n
"
,
acpi_ut_get_type_name
(
object_type
),
op
));
status
=
acpi_ds_scope_stack_pop
(
walk_state
);
if
(
ACPI_FAILURE
(
status
))
{
return
(
status
);
return
_ACPI_STATUS
(
status
);
}
}
...
...
@@ -730,7 +730,7 @@ acpi_ds_load2_end_op (
walk_state
->
operands
[
0
]
=
NULL
;
walk_state
->
num_operands
=
0
;
return
(
status
);
return
_ACPI_STATUS
(
status
);
}
drivers/acpi/dispatcher/dswstate.c
View file @
a6817928
/******************************************************************************
*
* Module Name: dswstate - Dispatcher parse tree walk management routines
* $Revision: 6
7
$
* $Revision: 6
8
$
*
*****************************************************************************/
...
...
@@ -835,6 +835,8 @@ acpi_ds_create_walk_state (
walk_state
->
method_desc
=
mth_desc
;
walk_state
->
thread
=
thread
;
walk_state
->
parser_state
.
start_op
=
origin
;
/* Init the method args/local */
#if (!defined (ACPI_NO_METHOD_EXECUTION) && !defined (ACPI_CONSTANT_EVAL_ONLY))
...
...
@@ -883,6 +885,7 @@ acpi_ds_init_aml_walk (
{
acpi_status
status
;
acpi_parse_state
*
parser_state
=
&
walk_state
->
parser_state
;
acpi_parse_object
*
extra_op
;
ACPI_FUNCTION_TRACE
(
"Ds_init_aml_walk"
);
...
...
@@ -925,9 +928,23 @@ acpi_ds_init_aml_walk (
}
}
else
{
/* Setup the current scope */
/*
* Setup the current scope.
* Find a Named Op that has a namespace node associated with it.
* search upwards from this Op. Current scope is the first
* Op with a namespace node.
*/
extra_op
=
parser_state
->
start_op
;
while
(
extra_op
&&
!
extra_op
->
common
.
node
)
{
extra_op
=
extra_op
->
common
.
parent
;
}
if
(
!
extra_op
)
{
parser_state
->
start_node
=
NULL
;
}
else
{
parser_state
->
start_node
=
extra_op
->
common
.
node
;
}
parser_state
->
start_node
=
parser_state
->
start_op
->
common
.
node
;
if
(
parser_state
->
start_node
)
{
/* Push start scope on scope stack and make it current */
...
...
drivers/acpi/events/evevent.c
View file @
a6817928
/******************************************************************************
*
* Module Name: evevent - Fixed and General Purpose Even handling and dispatch
* $Revision:
88
$
* $Revision:
90
$
*
*****************************************************************************/
...
...
@@ -104,7 +104,7 @@ acpi_ev_handler_initialize (
acpi_status
status
;
ACPI_FUNCTION_TRACE
(
"Ev_initialize"
);
ACPI_FUNCTION_TRACE
(
"Ev_
handler_
initialize"
);
/* Install the SCI handler */
...
...
drivers/acpi/events/evmisc.c
View file @
a6817928
/******************************************************************************
*
* Module Name: evmisc - Miscellaneous event manager support functions
* $Revision: 5
3
$
* $Revision: 5
6
$
*
*****************************************************************************/
...
...
@@ -442,11 +442,13 @@ acpi_ev_acquire_global_lock (
ACPI_FUNCTION_TRACE
(
"Ev_acquire_global_lock"
);
#ifndef ACPI_APPLICATION
/* Make sure that we actually have a global lock */
if
(
!
acpi_gbl_global_lock_present
)
{
return_ACPI_STATUS
(
AE_NO_GLOBAL_LOCK
);
}
#endif
/* One more thread wants the global lock */
...
...
@@ -552,9 +554,56 @@ acpi_ev_release_global_lock (void)
void
acpi_ev_terminate
(
void
)
{
NATIVE_UINT_MAX32
i
;
acpi_status
status
;
ACPI_FUNCTION_TRACE
(
"Ev_terminate"
);
/*
* Disable all event-related functionality.
* In all cases, on error, print a message but obviously we don't abort.
*/
/*
* Disable all fixed events
*/
for
(
i
=
0
;
i
<
ACPI_NUM_FIXED_EVENTS
;
i
++
)
{
status
=
acpi_disable_event
(
i
,
ACPI_EVENT_FIXED
,
0
);
if
(
ACPI_FAILURE
(
status
))
{
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"Failed to disable fixed event %d.
\n
"
,
i
));
}
}
/*
* Disable all GPEs
*/
for
(
i
=
0
;
i
<
acpi_gbl_gpe_number_max
;
i
++
)
{
if
(
acpi_ev_get_gpe_number_index
(
i
)
!=
ACPI_GPE_INVALID
)
{
status
=
acpi_hw_disable_gpe
(
i
);
if
(
ACPI_FAILURE
(
status
))
{
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"Failed to disable GPE %d.
\n
"
,
i
));
}
}
}
/*
* Remove SCI handler
*/
status
=
acpi_ev_remove_sci_handler
();
if
(
ACPI_FAILURE
(
status
))
{
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"Unable to remove SCI handler.
\n
"
));
}
/*
* Return to original mode if necessary
*/
if
(
acpi_gbl_original_mode
==
ACPI_SYS_MODE_LEGACY
)
{
status
=
acpi_disable
();
if
(
ACPI_FAILURE
(
status
))
{
ACPI_DEBUG_PRINT
((
ACPI_DB_WARN
,
"Acpi_disable failed.
\n
"
));
}
}
/*
* Free global tables, etc.
...
...
drivers/acpi/events/evregion.c
View file @
a6817928
/******************************************************************************
*
* Module Name: evregion - ACPI Address_space (Op_region) handler dispatch
* $Revision: 13
4
$
* $Revision: 13
5
$
*
*****************************************************************************/
...
...
drivers/acpi/events/evrgnini.c
View file @
a6817928
/******************************************************************************
*
* Module Name: evrgnini- ACPI Address_space (Op_region) init
* $Revision: 6
2
$
* $Revision: 6
3
$
*
*****************************************************************************/
...
...
drivers/acpi/events/evxface.c
View file @
a6817928
/******************************************************************************
*
* Module Name: evxface - External interfaces for ACPI events
* $Revision: 1
29
$
* $Revision: 1
30
$
*
*****************************************************************************/
...
...
drivers/acpi/events/evxfevnt.c
View file @
a6817928
/******************************************************************************
*
* Module Name: evxfevnt - External Interfaces, ACPI event disable/enable
* $Revision: 5
5
$
* $Revision: 5
7
$
*
*****************************************************************************/
...
...
@@ -52,16 +52,14 @@ acpi_enable (void)
ACPI_FUNCTION_TRACE
(
"Acpi_enable"
);
/* Make sure we have
ACPI tables
*/
/* Make sure we have
the FADT
*/
if
(
!
acpi_gbl_
DS
DT
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_WARN
,
"No
ACPI tables
present!
\n
"
));
if
(
!
acpi_gbl_
FA
DT
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_WARN
,
"No
FADT information
present!
\n
"
));
return_ACPI_STATUS
(
AE_NO_ACPI_TABLES
);
}
acpi_gbl_original_mode
=
acpi_hw_get_mode
();
if
(
acpi_gbl_original_mode
==
ACPI_SYS_MODE_ACPI
)
{
if
(
acpi_hw_get_mode
()
==
ACPI_SYS_MODE_ACPI
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_OK
,
"Already in ACPI mode.
\n
"
));
}
else
{
...
...
@@ -88,8 +86,7 @@ acpi_enable (void)
*
* RETURN: Status
*
* DESCRIPTION: Returns the system to original ACPI/legacy mode, and
* uninstalls the SCI interrupt handler.
* DESCRIPTION: Transfers the system into LEGACY mode.
*
******************************************************************************/
...
...
@@ -101,20 +98,26 @@ acpi_disable (void)
ACPI_FUNCTION_TRACE
(
"Acpi_disable"
);
if
(
!
acpi_gbl_FADT
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_WARN
,
"No FADT information present!
\n
"
));
return_ACPI_STATUS
(
AE_NO_ACPI_TABLES
);
}
if
(
acpi_hw_get_mode
()
!=
acpi_gbl_original_mode
)
{
/* Restore original mode */
if
(
acpi_hw_get_mode
()
==
ACPI_SYS_MODE_LEGACY
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_OK
,
"Already in LEGACY mode.
\n
"
));
}
else
{
/* Transition to LEGACY mode */
status
=
acpi_hw_set_mode
(
ACPI_SYS_MODE_LEGACY
);
status
=
acpi_hw_set_mode
(
acpi_gbl_original_mode
);
if
(
ACPI_FAILURE
(
status
))
{
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"
Unable to transition to original mode
"
));
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"
Could not transition to LEGACY mode.
"
));
return_ACPI_STATUS
(
status
);
}
}
/* Unload the SCI interrupt handler */
ACPI_DEBUG_PRINT
((
ACPI_DB_OK
,
"Transition to LEGACY mode successful
\n
"
));
}
status
=
acpi_ev_remove_sci_handler
();
return_ACPI_STATUS
(
status
);
}
...
...
drivers/acpi/executer/exdump.c
View file @
a6817928
/******************************************************************************
*
* Module Name: exdump - Interpreter debug output routines
* $Revision: 15
7
$
* $Revision: 15
9
$
*
*****************************************************************************/
...
...
@@ -38,7 +38,7 @@
* The following routines are used for debug output only
*/
#if defined(ACPI_DEBUG
) || defined(ENABLE
_DEBUGGER)
#if defined(ACPI_DEBUG
_OUTPUT) || defined(ACPI
_DEBUGGER)
/*****************************************************************************
*
...
...
drivers/acpi/executer/exfldio.c
View file @
a6817928
/******************************************************************************
*
* Module Name: exfldio - Aml Field I/O
* $Revision: 8
7
$
* $Revision: 8
8
$
*
*****************************************************************************/
...
...
drivers/acpi/executer/exmisc.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: exmisc - ACPI AML (p-code) execution - specific opcodes
* $Revision: 10
7
$
* $Revision: 10
8
$
*
*****************************************************************************/
...
...
drivers/acpi/executer/exoparg1.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: exoparg1 - AML execution - opcodes with 1 argument
* $Revision: 14
1
$
* $Revision: 14
2
$
*
*****************************************************************************/
...
...
drivers/acpi/executer/exoparg2.c
View file @
a6817928
/******************************************************************************
*
* Module Name: exoparg2 - AML execution - opcodes with 2 arguments
* $Revision: 1
09
$
* $Revision: 1
10
$
*
*****************************************************************************/
...
...
drivers/acpi/executer/exprep.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: exprep - ACPI AML (p-code) execution - field prep utilities
* $Revision: 11
8
$
* $Revision: 11
9
$
*
*****************************************************************************/
...
...
drivers/acpi/executer/exregion.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: exregion - ACPI default Op_region (address space) handlers
* $Revision:
79
$
* $Revision:
80
$
*
*****************************************************************************/
...
...
drivers/acpi/executer/exresop.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: exresop - AML Interpreter operand/object resolution
* $Revision: 5
4
$
* $Revision: 5
5
$
*
*****************************************************************************/
...
...
drivers/acpi/executer/exstore.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: exstore - AML Interpreter object store support
* $Revision: 16
8
$
* $Revision: 16
9
$
*
*****************************************************************************/
...
...
drivers/acpi/executer/exutils.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: exutils - interpreter/scanner utilities
* $Revision: 10
2
$
* $Revision: 10
3
$
*
*****************************************************************************/
...
...
@@ -261,7 +261,8 @@ acpi_ex_release_global_lock (
if
(
ACPI_FAILURE
(
status
))
{
/* Report the error, but there isn't much else we can do */
ACPI_REPORT_ERROR
((
"Could not release ACPI Global Lock
\n
"
));
ACPI_REPORT_ERROR
((
"Could not release ACPI Global Lock, %s
\n
"
,
acpi_format_exception
(
status
)));
}
}
...
...
drivers/acpi/hardware/hwacpi.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: hwacpi - ACPI Hardware Initialization/Mode Interface
* $Revision:
58
$
* $Revision:
60
$
*
*****************************************************************************/
...
...
@@ -96,6 +96,27 @@ acpi_hw_set_mode (
ACPI_FUNCTION_TRACE
(
"Hw_set_mode"
);
/*
* ACPI 2.0 clarified that if SMI_CMD in FADT is zero,
* system does not support mode transition.
*/
if
(
!
acpi_gbl_FADT
->
smi_cmd
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"No SMI_CMD in FADT, mode transition failed.
\n
"
));
return_ACPI_STATUS
(
AE_NO_HARDWARE_RESPONSE
);
}
/*
* ACPI 2.0 clarified the meaning of ACPI_ENABLE and ACPI_DISABLE
* in FADT: If it is zero, enabling or disabling is not supported.
* As old systems may have used zero for mode transition,
* we make sure both the numbers are zero to determine these
* transitions are not supported.
*/
if
(
!
acpi_gbl_FADT
->
acpi_enable
&&
!
acpi_gbl_FADT
->
acpi_disable
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_INFO
,
"No mode transition supported in this system.
\n
"
));
return_ACPI_STATUS
(
AE_OK
);
}
switch
(
mode
)
{
case
ACPI_SYS_MODE_ACPI
:
...
...
drivers/acpi/hardware/hwgpe.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: hwgpe - Low level GPE enable/disable/clear functions
* $Revision: 4
1
$
* $Revision: 4
2
$
*
*****************************************************************************/
...
...
drivers/acpi/hardware/hwregs.c
View file @
a6817928
...
...
@@ -3,7 +3,7 @@
*
* Module Name: hwregs - Read/write access functions for the various ACPI
* control and status registers.
* $Revision: 13
3
$
* $Revision: 13
4
$
*
******************************************************************************/
...
...
drivers/acpi/hardware/hwsleep.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Name: hwsleep.c - ACPI Hardware Sleep/Wake Interface
* $Revision: 4
5
$
* $Revision: 4
6
$
*
*****************************************************************************/
...
...
drivers/acpi/include/acconfig.h
View file @
a6817928
/******************************************************************************
*
* Name: acconfig.h - Global configuration constants
* $Revision: 10
7
$
* $Revision: 10
9
$
*
*****************************************************************************/
...
...
@@ -34,7 +34,7 @@
*****************************************************************************/
/*
* ACPI_DEBUG
- This switch enables all the debug facilities of the
* ACPI_DEBUG
_OUTPUT
- This switch enables all the debug facilities of the
* ACPI subsystem. This includes the DEBUG_PRINT output
* statements. When disabled, all DEBUG_PRINT
* statements are compiled out.
...
...
@@ -54,7 +54,7 @@
/* Version string */
#define ACPI_CA_VERSION 0x20020
72
5
#define ACPI_CA_VERSION 0x20020
81
5
/* Version of ACPI supported */
...
...
drivers/acpi/include/acdisasm.h
View file @
a6817928
/******************************************************************************
*
* Name: acdisasm.h - AML disassembler
* $Revision:
2
$
* $Revision:
3
$
*
*****************************************************************************/
...
...
drivers/acpi/include/acglobal.h
View file @
a6817928
/******************************************************************************
*
* Name: acglobal.h - Declarations for global variables
* $Revision: 1
28
$
* $Revision: 1
30
$
*
*****************************************************************************/
...
...
@@ -152,8 +152,12 @@ extern const NATIVE_CHAR *acpi_gbl_region_types[ACPI_NUM_PREDEFINE
****************************************************************************/
#define NUM_NS_TYPES INTERNAL_TYPE_INVALID+1
#define NUM_PREDEFINED_NAMES 9
#if defined (ACPI_NO_METHOD_EXECUTION) || defined (ACPI_CONSTANT_EVAL_ONLY)
#define NUM_PREDEFINED_NAMES 10
#else
#define NUM_PREDEFINED_NAMES 9
#endif
ACPI_EXTERN
acpi_namespace_node
acpi_gbl_root_node_struct
;
ACPI_EXTERN
acpi_namespace_node
*
acpi_gbl_root_node
;
...
...
@@ -161,7 +165,7 @@ ACPI_EXTERN acpi_namespace_node *acpi_gbl_root_node;
extern
const
u8
acpi_gbl_ns_properties
[
NUM_NS_TYPES
];
extern
const
acpi_predefined_names
acpi_gbl_pre_defined_names
[
NUM_PREDEFINED_NAMES
];
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
ACPI_EXTERN
u32
acpi_gbl_current_node_count
;
ACPI_EXTERN
u32
acpi_gbl_current_node_size
;
ACPI_EXTERN
u32
acpi_gbl_max_concurrent_node_count
;
...
...
@@ -245,7 +249,7 @@ ACPI_EXTERN u8 acpi_gbl_db_opt_verbose;
#endif
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
extern
u8
acpi_gbl_method_executing
;
extern
u8
acpi_gbl_db_terminate_threads
;
...
...
@@ -287,7 +291,7 @@ ACPI_EXTERN u32 acpi_gbl_size_of_method_trees;
ACPI_EXTERN
u32
acpi_gbl_size_of_node_entries
;
ACPI_EXTERN
u32
acpi_gbl_size_of_acpi_objects
;
#endif
/*
ENABLE
_DEBUGGER */
#endif
/*
ACPI
_DEBUGGER */
#endif
/* __ACGLOBAL_H__ */
drivers/acpi/include/aclocal.h
View file @
a6817928
/******************************************************************************
*
* Name: aclocal.h - Internal data types used across the ACPI subsystem
* $Revision: 17
3
$
* $Revision: 17
5
$
*
*****************************************************************************/
...
...
@@ -73,7 +73,7 @@ typedef u32 ACPI_MUTEX_HANDLE;
#define NUM_MTX MAX_MTX+1
#if defined(ACPI_DEBUG
) || defined(ENABLE
_DEBUGGER)
#if defined(ACPI_DEBUG
_OUTPUT) || defined(ACPI
_DEBUGGER)
#ifdef DEFINE_ACPI_GLOBALS
/* Names for the mutexes used in the subsystem */
...
...
@@ -567,7 +567,7 @@ acpi_status (*ACPI_EXECUTE_OP) (
*/
typedef
struct
acpi_opcode_info
{
#if defined(ACPI_DISASSEMBLER) || defined(ACPI_DEBUG)
#if defined(ACPI_DISASSEMBLER) || defined(ACPI_DEBUG
_OUTPUT
)
NATIVE_CHAR
*
name
;
/* Opcode name (disassembler/debug only) */
#endif
u32
parse_args
;
/* Grammar/Parse time arguments */
...
...
drivers/acpi/include/acmacros.h
View file @
a6817928
/******************************************************************************
*
* Name: acmacros.h - C macros for the entire subsystem.
* $Revision: 12
6
$
* $Revision: 12
8
$
*
*****************************************************************************/
...
...
@@ -287,7 +287,7 @@
/*
* Macros for the master AML opcode table
*/
#if defined(ACPI_DISASSEMBLER) || defined (ACPI_DEBUG)
#if defined(ACPI_DISASSEMBLER) || defined (ACPI_DEBUG
_OUTPUT
)
#define ACPI_OP(name,Pargs,Iargs,obj_type,class,type,flags) {name,Pargs,Iargs,flags,obj_type,class,type}
#else
#define ACPI_OP(name,Pargs,Iargs,obj_type,class,type,flags) {Pargs,Iargs,flags,obj_type,class,type}
...
...
@@ -353,11 +353,11 @@
/*
* Error reporting. These versions add callers module and line#. Since
* _THIS_MODULE gets compiled out when ACPI_DEBUG isn't defined, only
* _THIS_MODULE gets compiled out when ACPI_DEBUG
_OUTPUT
isn't defined, only
* use it in debug mode.
*/
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
#define ACPI_REPORT_INFO(fp) {acpi_ut_report_info(_THIS_MODULE,__LINE__,_COMPONENT); \
acpi_os_printf ACPI_PARAM_LIST(fp);}
...
...
@@ -390,7 +390,7 @@
* Debug macros that are conditionally compiled
*/
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
#define ACPI_MODULE_NAME(name) static char *_THIS_MODULE = name;
...
...
@@ -525,9 +525,9 @@
/*
* Some code only gets executed when the debugger is built in.
* Note that this is entirely independent of whether the
* DEBUG_PRINT stuff (set by ACPI_DEBUG) is on, or not.
* DEBUG_PRINT stuff (set by ACPI_DEBUG
_OUTPUT
) is on, or not.
*/
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
#define ACPI_DEBUGGER_EXEC(a) a
#else
#define ACPI_DEBUGGER_EXEC(a)
...
...
@@ -536,7 +536,7 @@
/*
* For 16-bit code, we want to shrink some things even though
* we are using ACPI_DEBUG to get the debug output
* we are using ACPI_DEBUG
_OUTPUT
to get the debug output
*/
#if ACPI_MACHINE_WIDTH == 16
#undef ACPI_DEBUG_ONLY_MEMBERS
...
...
@@ -545,7 +545,7 @@
#endif
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
/*
* 1) Set name to blanks
* 2) Copy the object name
...
...
drivers/acpi/include/acobject.h
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Name: acobject.h - Definition of acpi_operand_object (Internal object only)
* $Revision: 11
2
$
* $Revision: 11
3
$
*
*****************************************************************************/
...
...
drivers/acpi/include/acoutput.h
View file @
a6817928
/******************************************************************************
*
* Name: acoutput.h -- debug output
* $Revision:
87
$
* $Revision:
90
$
*
*****************************************************************************/
...
...
@@ -43,18 +43,20 @@
#define ACPI_DISPATCHER 0x00000040
#define ACPI_EXECUTER 0x00000080
#define ACPI_RESOURCES 0x00000100
#define ACPI_
DEBUGGER
0x00000200
#define ACPI_
CA_DEBUGGER
0x00000200
#define ACPI_OS_SERVICES 0x00000400
#define ACPI_ALL_COMPONENTS 0x00000FFF
#define ACPI_COMPONENT_DEFAULT (ACPI_ALL_COMPONENTS)
#define ACPI_CA_DISASSEMBLER 0x00000800
/* Component IDs for ACPI tools and utilities */
#define ACPI_COMPILER 0x00001000
#define ACPI_TOOLS 0x00002000
#define ACPI_ALL_COMPONENTS 0x00003FFF
#define ACPI_COMPONENT_DEFAULT (ACPI_ALL_COMPONENTS)
/* Component IDs reserved for ACPI drivers */
#define ACPI_ALL_DRIVERS 0xFFFF0000
...
...
@@ -94,7 +96,8 @@
#define ACPI_LV_ALLOCATIONS 0x00100000
#define ACPI_LV_FUNCTIONS 0x00200000
#define ACPI_LV_VERBOSITY2 0x00300000 | ACPI_LV_VERBOSITY1
#define ACPI_LV_OPTIMIZATIONS 0x00400000
#define ACPI_LV_VERBOSITY2 0x00700000 | ACPI_LV_VERBOSITY1
#define ACPI_LV_ALL ACPI_LV_VERBOSITY2
/* Trace verbosity level 3 [Threading, I/O, and Interrupts] */
...
...
@@ -144,6 +147,7 @@
#define ACPI_DB_BFIELD ACPI_DEBUG_LEVEL (ACPI_LV_BFIELD)
#define ACPI_DB_TABLES ACPI_DEBUG_LEVEL (ACPI_LV_TABLES)
#define ACPI_DB_FUNCTIONS ACPI_DEBUG_LEVEL (ACPI_LV_FUNCTIONS)
#define ACPI_DB_OPTIMIZATIONS ACPI_DEBUG_LEVEL (ACPI_LV_OPTIMIZATIONS)
#define ACPI_DB_VALUES ACPI_DEBUG_LEVEL (ACPI_LV_VALUES)
#define ACPI_DB_OBJECTS ACPI_DEBUG_LEVEL (ACPI_LV_OBJECTS)
#define ACPI_DB_ALLOCATIONS ACPI_DEBUG_LEVEL (ACPI_LV_ALLOCATIONS)
...
...
drivers/acpi/include/acparser.h
View file @
a6817928
/******************************************************************************
*
* Module Name: acparser.h - AML Parser subcomponent prototypes and defines
* $Revision: 6
0
$
* $Revision: 6
1
$
*
*****************************************************************************/
...
...
@@ -86,7 +86,7 @@ acpi_ps_get_next_simple_arg (
u32
arg_type
,
acpi_parse_object
*
arg
);
void
acpi_status
acpi_ps_get_next_namepath
(
acpi_parse_state
*
parser_state
,
acpi_parse_object
*
arg
,
...
...
@@ -97,11 +97,12 @@ acpi_parse_object *
acpi_ps_get_next_field
(
acpi_parse_state
*
parser_state
);
acpi_
parse_object
*
acpi_
status
acpi_ps_get_next_arg
(
acpi_parse_state
*
parser_state
,
u32
arg_type
,
u32
*
arg_count
);
u32
*
arg_count
,
acpi_parse_object
**
return_arg
);
/* psfind */
...
...
drivers/acpi/include/acresrc.h
View file @
a6817928
/******************************************************************************
*
* Name: acresrc.h - Resource Manager function prototypes
* $Revision: 3
3
$
* $Revision: 3
4
$
*
*****************************************************************************/
...
...
drivers/acpi/include/actbl2.h
View file @
a6817928
...
...
@@ -139,8 +139,8 @@ typedef struct
u16
plvl3_lat
;
/* Worst case HW latency to enter/exit C3 state */
u16
flush_size
;
/* Number of flush strides that need to be read */
u16
flush_stride
;
/* Processor's memory cache line width, in bytes */
u8
duty_offset
;
/* Processor
_
s duty cycle index in processor's P_CNT reg*/
u8
duty_width
;
/* Processor
_
s duty cycle value bit width in P_CNT register.*/
u8
duty_offset
;
/* Processors duty cycle index in processor's P_CNT reg*/
u8
duty_width
;
/* Processors duty cycle value bit width in P_CNT register.*/
u8
day_alrm
;
/* Index to day-of-month alarm in RTC CMOS RAM */
u8
mon_alrm
;
/* Index to month-of-year alarm in RTC CMOS RAM */
u8
century
;
/* Index to century in RTC CMOS RAM */
...
...
drivers/acpi/include/acutils.h
View file @
a6817928
/******************************************************************************
*
* Name: acutils.h -- prototypes for the common (subsystem-wide) procedures
* $Revision: 14
2
$
* $Revision: 14
3
$
*
*****************************************************************************/
...
...
@@ -94,7 +94,7 @@ acpi_ut_validate_fadt (
* Ut_global - Global data structures and procedures
*/
#if defined(ACPI_DEBUG
) || defined(ENABLE
_DEBUGGER)
#if defined(ACPI_DEBUG
_OUTPUT) || defined(ACPI
_DEBUGGER)
NATIVE_CHAR
*
acpi_ut_get_mutex_name
(
...
...
@@ -686,7 +686,7 @@ void
acpi_ut_set_integer_width
(
u8
revision
);
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
void
acpi_ut_display_init_pathname
(
acpi_handle
obj_handle
,
...
...
drivers/acpi/include/amlcode.h
View file @
a6817928
...
...
@@ -3,7 +3,7 @@
* Name: amlcode.h - Definitions for AML, as included in "definition blocks"
* Declarations and definitions contained herein are derived
* directly from the ACPI specification.
* $Revision:
69
$
* $Revision:
70
$
*
*****************************************************************************/
...
...
drivers/acpi/include/amlresrc.h
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
/******************************************************************************
*
* Module Name: amlresrc.h - AML resource descriptors
* $Revision: 2
0
$
* $Revision: 2
2
$
*
*****************************************************************************/
...
...
@@ -328,172 +328,5 @@ typedef union asl_resource_desc
}
ASL_RESOURCE_DESC
;
#define NEXT_RESOURCE_DESC(a,b) (ASL_RESOURCE_DESC *) (((char *) (a)) + sizeof(b))
#define DEFAULT_RESOURCE_DESC_SIZE (sizeof (ASL_RESOURCE_DESC) + sizeof (ASL_END_TAG_DESC))
/*
* Resource utilities
*/
ASL_RESOURCE_NODE
*
rs_allocate_resource_node
(
u32
size
);
void
rs_create_bit_field
(
acpi_parse_object
*
op
,
char
*
name
,
u32
byte_offset
,
u32
bit_offset
);
void
rs_create_byte_field
(
acpi_parse_object
*
op
,
char
*
name
,
u32
byte_offset
);
void
rs_set_flag_bits
(
u8
*
flags
,
acpi_parse_object
*
op
,
u8
position
,
u8
default
);
acpi_parse_object
*
rs_complete_node_and_get_next
(
acpi_parse_object
*
op
);
ASL_RESOURCE_NODE
*
rs_do_one_resource_descriptor
(
acpi_parse_object
*
descriptor_type_op
,
u32
current_byte_offset
);
u32
rs_link_descriptor_chain
(
ASL_RESOURCE_NODE
**
previous_rnode
,
ASL_RESOURCE_NODE
*
rnode
);
/*
* Small descriptors
*/
ASL_RESOURCE_NODE
*
rs_do_dma_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_end_dependent_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_fixed_io_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_interrupt_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_io_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_irq_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_irq_no_flags_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_memory24_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_memory32_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_memory32_fixed_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_start_dependent_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_start_dependent_no_pri_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_vendor_small_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
/*
* Large descriptors
*/
u32
rs_get_string_data_length
(
acpi_parse_object
*
initializer_op
);
ASL_RESOURCE_NODE
*
rs_do_dword_io_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_dword_memory_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_qword_io_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_qword_memory_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_word_io_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_word_bus_number_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_vendor_large_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
ASL_RESOURCE_NODE
*
rs_do_general_register_descriptor
(
acpi_parse_object
*
op
,
u32
current_byte_offset
);
#endif
drivers/acpi/include/platform/acenv.h
View file @
a6817928
/******************************************************************************
*
* Name: acenv.h - Generation environment specific items
* $Revision:
99
$
* $Revision:
101
$
*
*****************************************************************************/
...
...
@@ -33,7 +33,7 @@
#ifdef _ACPI_DUMP_APP
#ifndef MSDOS
#define ACPI_DEBUG
#define ACPI_DEBUG
_OUTPUT
#endif
#define ACPI_APPLICATION
#define ACPI_DISASSEMBLER
...
...
@@ -44,15 +44,15 @@
#ifdef _ACPI_EXEC_APP
#undef DEBUGGER_THREADING
#define DEBUGGER_THREADING DEBUGGER_SINGLE_THREADED
#define ACPI_DEBUG
#define ACPI_DEBUG
_OUTPUT
#define ACPI_APPLICATION
#define
ENABLE
_DEBUGGER
#define
ACPI
_DEBUGGER
#define ACPI_DISASSEMBLER
#define ACPI_USE_SYSTEM_CLIBRARY
#endif
#ifdef _ACPI_ASL_COMPILER
#define ACPI_DEBUG
#define ACPI_DEBUG
_OUTPUT
#define ACPI_APPLICATION
#define ACPI_DISASSEMBLER
#define ACPI_CONSTANT_EVAL_ONLY
...
...
@@ -149,7 +149,7 @@
* 1) This is the debug version
* 2) This is NOT a 16-bit version of the code (not enough real-mode memory)
*/
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
#if ACPI_MACHINE_WIDTH != 16
#define ACPI_DBG_TRACK_ALLOCATIONS
#endif
...
...
drivers/acpi/namespace/nsaccess.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: nsaccess - Top-level functions for accessing ACPI namespace
* $Revision: 1
56
$
* $Revision: 1
61
$
*
******************************************************************************/
...
...
@@ -117,6 +117,19 @@ acpi_ns_root_initialize (void)
* used for initial values are implemented here.
*/
switch
(
init_val
->
type
)
{
case
ACPI_TYPE_METHOD
:
obj_desc
->
method
.
param_count
=
(
u8
)
ACPI_STRTOUL
(
init_val
->
val
,
NULL
,
10
);
obj_desc
->
common
.
flags
|=
AOPOBJ_DATA_VALID
;
#if defined (ACPI_NO_METHOD_EXECUTION) || defined (ACPI_CONSTANT_EVAL_ONLY)
/* Compiler cheats by putting parameter count in the Owner_iD */
new_node
->
owner_id
=
obj_desc
->
method
.
param_count
;
#endif
break
;
case
ACPI_TYPE_INTEGER
:
obj_desc
->
integer
.
value
=
...
...
@@ -228,6 +241,7 @@ acpi_ns_lookup (
acpi_namespace_node
**
return_node
)
{
acpi_status
status
;
NATIVE_CHAR
*
path
=
pathname
;
acpi_namespace_node
*
prefix_node
;
acpi_namespace_node
*
current_node
=
NULL
;
acpi_namespace_node
*
this_node
=
NULL
;
...
...
@@ -235,7 +249,9 @@ acpi_ns_lookup (
acpi_name
simple_name
;
acpi_object_type
type_to_check_for
;
acpi_object_type
this_search_type
;
u32
local_flags
=
flags
&
~
ACPI_NS_ERROR_IF_FOUND
;
u32
search_parent_flag
=
ACPI_NS_SEARCH_PARENT
;
u32
local_flags
=
flags
&
~
(
ACPI_NS_ERROR_IF_FOUND
|
ACPI_NS_SEARCH_PARENT
);
ACPI_FUNCTION_TRACE
(
"Ns_lookup"
);
...
...
@@ -266,6 +282,21 @@ acpi_ns_lookup (
}
else
{
prefix_node
=
scope_info
->
scope
.
node
;
if
(
ACPI_GET_DESCRIPTOR_TYPE
(
prefix_node
)
!=
ACPI_DESC_TYPE_NAMED
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"[%p] Not a namespace node
\n
"
,
prefix_node
));
return_ACPI_STATUS
(
AE_AML_INTERNAL
);
}
/*
* This node might not be a actual "scope" node (such as a
* Device/Method, etc.) It could be a Package or other object node.
* Backup up the tree to find the containing scope node.
*/
while
(
!
acpi_ns_opens_scope
(
prefix_node
->
type
)
&&
prefix_node
->
type
!=
ACPI_TYPE_ANY
)
{
prefix_node
=
acpi_ns_get_parent_node
(
prefix_node
);
}
}
/*
...
...
@@ -297,7 +328,7 @@ acpi_ns_lookup (
num_segments
=
0
;
this_node
=
acpi_gbl_root_node
;
path
name
=
""
;
path
=
""
;
ACPI_DEBUG_PRINT
((
ACPI_DB_NAMES
,
"Null Pathname (Zero segments), Flags=%X
\n
"
,
flags
));
...
...
@@ -316,23 +347,24 @@ acpi_ns_lookup (
* Parent Prefixes (in which case the name's scope is relative
* to the current scope).
*/
if
(
*
path
name
==
(
u8
)
AML_ROOT_PREFIX
)
{
if
(
*
path
==
(
u8
)
AML_ROOT_PREFIX
)
{
/* Pathname is fully qualified, start from the root */
this_node
=
acpi_gbl_root_node
;
search_parent_flag
=
ACPI_NS_NO_UPSEARCH
;
/* Point to name segment part */
path
name
++
;
path
++
;
ACPI_DEBUG_PRINT
((
ACPI_DB_NAMES
,
"Searching from root [%p]
\n
"
,
this_node
));
ACPI_DEBUG_PRINT
((
ACPI_DB_NAMES
,
"Path is absolute from root [%p]
\n
"
,
this_node
));
}
else
{
/* Pathname is relative to current scope, start there */
ACPI_DEBUG_PRINT
((
ACPI_DB_NAMES
,
"Searching relative to p
f
x scope [%p]
\n
"
,
"Searching relative to p
refi
x scope [%p]
\n
"
,
prefix_node
));
/*
...
...
@@ -340,12 +372,15 @@ acpi_ns_lookup (
* the parent node for each prefix instance.
*/
this_node
=
prefix_node
;
while
(
*
pathname
==
(
u8
)
AML_PARENT_PREFIX
)
{
while
(
*
path
==
(
u8
)
AML_PARENT_PREFIX
)
{
/* Name is fully qualified, no search rules apply */
search_parent_flag
=
ACPI_NS_NO_UPSEARCH
;
/*
* Point past this prefix to the name segment
* part or the next Parent Prefix
*/
path
name
++
;
path
++
;
/* Backup to the parent node */
...
...
@@ -358,6 +393,11 @@ acpi_ns_lookup (
return_ACPI_STATUS
(
AE_NOT_FOUND
);
}
}
if
(
search_parent_flag
==
ACPI_NS_NO_UPSEARCH
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_NAMES
,
"Path is absolute with one or more carats
\n
"
));
}
}
/*
...
...
@@ -373,7 +413,7 @@ acpi_ns_lookup (
* Examine the name prefix opcode, if any, to determine the number of
* segments.
*/
switch
(
*
path
name
)
{
switch
(
*
path
)
{
case
0
:
/*
* Null name after a root or parent prefixes. We already
...
...
@@ -387,10 +427,14 @@ acpi_ns_lookup (
case
AML_DUAL_NAME_PREFIX
:
/* More than one Name_seg, search rules do not apply */
search_parent_flag
=
ACPI_NS_NO_UPSEARCH
;
/* Two segments, point to first name segment */
num_segments
=
2
;
path
name
++
;
path
++
;
ACPI_DEBUG_PRINT
((
ACPI_DB_NAMES
,
"Dual Pathname (2 segments, Flags=%X)
\n
"
,
flags
));
...
...
@@ -398,11 +442,15 @@ acpi_ns_lookup (
case
AML_MULTI_NAME_PREFIX_OP
:
/* More than one Name_seg, search rules do not apply */
search_parent_flag
=
ACPI_NS_NO_UPSEARCH
;
/* Extract segment count, point to first name segment */
path
name
++
;
num_segments
=
(
u32
)
(
u8
)
*
path
name
;
path
name
++
;
path
++
;
num_segments
=
(
u32
)
(
u8
)
*
path
;
path
++
;
ACPI_DEBUG_PRINT
((
ACPI_DB_NAMES
,
"Multi Pathname (%d Segments, Flags=%X)
\n
"
,
...
...
@@ -421,33 +469,49 @@ acpi_ns_lookup (
break
;
}
ACPI_DEBUG_EXEC
(
acpi_ns_print_pathname
(
num_segments
,
path
name
));
ACPI_DEBUG_EXEC
(
acpi_ns_print_pathname
(
num_segments
,
path
));
}
/*
* Search namespace for each segment of the name. Loop through and
* verify/add each name segment.
*/
current_node
=
this_node
;
while
(
num_segments
&&
current_node
)
{
/*
* Search for the current name segment under the current
* named object. The Type is significant only at the last name
* verify (or add to the namespace) each name segment.
*
* The object type is significant only at the last name
* segment. (We don't care about the types along the path, only
* the type of the final target object.)
*/
this_search_type
=
ACPI_TYPE_ANY
;
current_node
=
this_node
;
while
(
num_segments
&&
current_node
)
{
num_segments
--
;
if
(
!
num_segments
)
{
/*
* This is the last segment, enable typechecking
*/
this_search_type
=
type
;
local_flags
=
flags
;
/*
* Only allow automatic parent search (search rules) if the caller
* requested it AND we have a single, non-fully-qualified Name_seg
*/
if
((
search_parent_flag
!=
ACPI_NS_NO_UPSEARCH
)
&&
(
flags
&
ACPI_NS_SEARCH_PARENT
))
{
local_flags
|=
ACPI_NS_SEARCH_PARENT
;
}
/* Set error flag according to caller */
if
(
flags
&
ACPI_NS_ERROR_IF_FOUND
)
{
local_flags
|=
ACPI_NS_ERROR_IF_FOUND
;
}
}
/* Extract one ACPI name from the front of the pathname */
ACPI_MOVE_UNALIGNED32_TO_32
(
&
simple_name
,
path
name
);
ACPI_MOVE_UNALIGNED32_TO_32
(
&
simple_name
,
path
);
/* Try to find the ACPI name */
/* Try to find the
single (4 character)
ACPI name */
status
=
acpi_ns_search_and_enter
(
simple_name
,
walk_state
,
current_node
,
interpreter_mode
,
this_search_type
,
local_flags
,
&
this_node
);
...
...
@@ -457,7 +521,8 @@ acpi_ns_lookup (
ACPI_DEBUG_PRINT
((
ACPI_DB_NAMES
,
"Name [%4.4s] not found in scope [%4.4s] %p
\n
"
,
(
char
*
)
&
simple_name
,
(
char
*
)
&
current_node
->
name
,
current_node
));
(
char
*
)
&
simple_name
,
(
char
*
)
&
current_node
->
name
,
current_node
));
}
return_ACPI_STATUS
(
status
);
...
...
@@ -504,7 +569,7 @@ acpi_ns_lookup (
/* Point to next name segment and make this node current */
path
name
+=
ACPI_NAME_SIZE
;
path
+=
ACPI_NAME_SIZE
;
current_node
=
this_node
;
}
...
...
drivers/acpi/namespace/nsdump.c
View file @
a6817928
/******************************************************************************
*
* Module Name: nsdump - table dumping routines for debug
* $Revision: 13
7
$
* $Revision: 13
9
$
*
*****************************************************************************/
...
...
@@ -32,7 +32,7 @@
#define _COMPONENT ACPI_NAMESPACE
ACPI_MODULE_NAME
(
"nsdump"
)
#if defined(ACPI_DEBUG
) || defined(ENABLE
_DEBUGGER)
#if defined(ACPI_DEBUG
_OUTPUT) || defined(ACPI
_DEBUGGER)
/*******************************************************************************
...
...
drivers/acpi/namespace/nsdumpdv.c
View file @
a6817928
/******************************************************************************
*
* Module Name: nsdump - table dumping routines for debug
* $Revision:
1
$
* $Revision:
3
$
*
*****************************************************************************/
...
...
@@ -33,7 +33,7 @@
ACPI_MODULE_NAME
(
"nsdumpdv"
)
#if defined(ACPI_DEBUG
) || defined(ENABLE
_DEBUGGER)
#if defined(ACPI_DEBUG
_OUTPUT) || defined(ACPI
_DEBUGGER)
/*******************************************************************************
*
...
...
drivers/acpi/namespace/nseval.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
*
* Module Name: nseval - Object evaluation interfaces -- includes control
* method lookup and execution.
* $Revision: 11
7
$
* $Revision: 11
8
$
*
******************************************************************************/
...
...
drivers/acpi/namespace/nsinit.c
View file @
a6817928
/******************************************************************************
*
* Module Name: nsinit - namespace initialization
* $Revision: 4
7
$
* $Revision: 4
9
$
*
*****************************************************************************/
...
...
@@ -369,7 +369,7 @@ acpi_ns_init_one_device (
if
(
status
!=
AE_NOT_FOUND
)
{
/* Ignore error and move on to next device */
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
NATIVE_CHAR
*
scope_name
=
acpi_ns_get_external_pathname
(
obj_handle
);
ACPI_DEBUG_PRINT
((
ACPI_DB_WARN
,
"%s._INI failed: %s
\n
"
,
...
...
drivers/acpi/namespace/nsload.c
View file @
a6817928
/******************************************************************************
*
* Module Name: nsload - namespace loading/expanding/contracting procedures
* $Revision: 5
7
$
* $Revision: 5
8
$
*
*****************************************************************************/
...
...
drivers/acpi/namespace/nsnames.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: nsnames - Name manipulation and search
* $Revision: 7
8
$
* $Revision: 7
9
$
*
******************************************************************************/
...
...
@@ -103,7 +103,7 @@ acpi_ns_build_external_path (
}
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
/*******************************************************************************
*
* FUNCTION: Acpi_ns_get_external_pathname
...
...
drivers/acpi/namespace/nssearch.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: nssearch - Namespace search
* $Revision: 8
6
$
* $Revision: 8
9
$
*
******************************************************************************/
...
...
@@ -71,7 +71,7 @@ acpi_ns_search_node (
ACPI_FUNCTION_TRACE
(
"Ns_search_node"
);
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
if
(
ACPI_LV_NAMES
&
acpi_dbg_level
)
{
NATIVE_CHAR
*
scope_name
;
...
...
@@ -290,10 +290,10 @@ acpi_ns_search_and_enter (
/* Parameter validation */
if
(
!
node
||
!
target_name
||
!
return_node
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"Null param
- Table %p Name %X Return
%p
\n
"
,
ACPI_DEBUG_PRINT
((
ACPI_DB_ERROR
,
"Null param
: Node %p Name %X Return_node
%p
\n
"
,
node
,
target_name
,
return_node
));
ACPI_REPORT_ERROR
((
"Ns_search_and_enter:
bad (null)
parameter
\n
"
));
ACPI_REPORT_ERROR
((
"Ns_search_and_enter:
Null
parameter
\n
"
));
return_ACPI_STATUS
(
AE_BAD_PARAMETER
);
}
...
...
drivers/acpi/namespace/nsutils.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
*
* Module Name: nsutils - Utilities for accessing ACPI namespace, accessing
* parents and siblings and Scope manipulation
* $Revision: 11
0
$
* $Revision: 11
2
$
*
*****************************************************************************/
...
...
@@ -434,9 +434,12 @@ acpi_ns_externalize_name (
case
'^'
:
for
(
i
=
0
;
i
<
internal_name_length
;
i
++
)
{
if
(
internal_name
[
i
]
!
=
'^'
)
{
if
(
internal_name
[
i
]
=
=
'^'
)
{
prefix_length
=
i
+
1
;
}
else
{
break
;
}
}
if
(
i
==
internal_name_length
)
{
...
...
@@ -834,7 +837,7 @@ acpi_ns_find_parent_name (
}
#if defined(ACPI_DEBUG
) || defined(ENABLE
_DEBUGGER)
#if defined(ACPI_DEBUG
_OUTPUT) || defined(ACPI
_DEBUGGER)
/*******************************************************************************
*
...
...
@@ -868,7 +871,7 @@ acpi_ns_exist_downstream_sibling (
return
(
FALSE
);
}
#endif
/* ACPI_DEBUG */
#endif
/* ACPI_DEBUG
_OUTPUT
*/
/*******************************************************************************
...
...
drivers/acpi/namespace/nsxfeval.c
View file @
a6817928
...
...
@@ -2,7 +2,7 @@
*
* Module Name: nsxfeval - Public interfaces to the ACPI subsystem
* ACPI Object evaluation interfaces
* $Revision:
1
$
* $Revision:
2
$
*
******************************************************************************/
...
...
drivers/acpi/parser/psargs.c
View file @
a6817928
This diff is collapsed.
Click to expand it.
drivers/acpi/parser/psopcode.c
View file @
a6817928
/******************************************************************************
*
* Module Name: psopcode - Parser/Interpreter opcode information table
* $Revision: 7
1
$
* $Revision: 7
2
$
*
*****************************************************************************/
...
...
@@ -558,17 +558,17 @@ const acpi_opcode_info acpi_gbl_aml_op_info[AML_NUM_OPCODES] =
/* 60 */
ACPI_OP
(
"LNotEqual"
,
ARGP_LNOTEQUAL_OP
,
ARGI_LNOTEQUAL_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
|
AML_CONSTANT
),
/* 61 */
ACPI_OP
(
"LLessEqual"
,
ARGP_LLESSEQUAL_OP
,
ARGI_LLESSEQUAL_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
|
AML_CONSTANT
),
/* 62 */
ACPI_OP
(
"LGreaterEqual"
,
ARGP_LGREATEREQUAL_OP
,
ARGI_LGREATEREQUAL_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
|
AML_CONSTANT
),
/* 63 */
ACPI_OP
(
"
[NamePath]
"
,
ARGP_NAMEPATH_OP
,
ARGI_NAMEPATH_OP
,
INTERNAL_TYPE_REFERENCE
,
AML_CLASS_ARGUMENT
,
AML_TYPE_LITERAL
,
AML_NSOBJECT
|
AML_NSNODE
),
/* 64 */
ACPI_OP
(
"
[MethodCall]
"
,
ARGP_METHODCALL_OP
,
ARGI_METHODCALL_OP
,
ACPI_TYPE_METHOD
,
AML_CLASS_METHOD_CALL
,
AML_TYPE_METHOD_CALL
,
AML_HAS_ARGS
|
AML_NSOBJECT
|
AML_NSNODE
),
/* 65 */
ACPI_OP
(
"
[ByteList]
"
,
ARGP_BYTELIST_OP
,
ARGI_BYTELIST_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_ARGUMENT
,
AML_TYPE_LITERAL
,
0
),
/* 66 */
ACPI_OP
(
"
[ReservedField]
"
,
ARGP_RESERVEDFIELD_OP
,
ARGI_RESERVEDFIELD_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
0
),
/* 67 */
ACPI_OP
(
"
[NamedField]
"
,
ARGP_NAMEDFIELD_OP
,
ARGI_NAMEDFIELD_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
AML_NSOBJECT
|
AML_NSOPCODE
|
AML_NSNODE
|
AML_NAMED
),
/* 68 */
ACPI_OP
(
"
[AccessField]
"
,
ARGP_ACCESSFIELD_OP
,
ARGI_ACCESSFIELD_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
0
),
/* 69 */
ACPI_OP
(
"
[
StaticString"
,
ARGP_STATICSTRING_OP
,
ARGI_STATICSTRING_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
0
),
/* 6A */
ACPI_OP
(
"
[Return Value]
"
,
ARG_NONE
,
ARG_NONE
,
ACPI_TYPE_ANY
,
AML_CLASS_RETURN_VALUE
,
AML_TYPE_RETURN
,
AML_HAS_ARGS
|
AML_HAS_RETVAL
),
/* 6B */
ACPI_OP
(
"
UNKNOWN_OP!"
,
ARG_NONE
,
ARG_NONE
,
INTERNAL_TYPE_INVALID
,
AML_CLASS_UNKNOWN
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
),
/* 6C */
ACPI_OP
(
"
ASCII_ONLY!"
,
ARG_NONE
,
ARG_NONE
,
ACPI_TYPE_ANY
,
AML_CLASS_ASCII
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
),
/* 6D */
ACPI_OP
(
"
PREFIX_ONLY!"
,
ARG_NONE
,
ARG_NONE
,
ACPI_TYPE_ANY
,
AML_CLASS_PREFIX
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
),
/* 63 */
ACPI_OP
(
"
-NamePath-
"
,
ARGP_NAMEPATH_OP
,
ARGI_NAMEPATH_OP
,
INTERNAL_TYPE_REFERENCE
,
AML_CLASS_ARGUMENT
,
AML_TYPE_LITERAL
,
AML_NSOBJECT
|
AML_NSNODE
),
/* 64 */
ACPI_OP
(
"
-MethodCall-
"
,
ARGP_METHODCALL_OP
,
ARGI_METHODCALL_OP
,
ACPI_TYPE_METHOD
,
AML_CLASS_METHOD_CALL
,
AML_TYPE_METHOD_CALL
,
AML_HAS_ARGS
|
AML_NSOBJECT
|
AML_NSNODE
),
/* 65 */
ACPI_OP
(
"
-ByteList-
"
,
ARGP_BYTELIST_OP
,
ARGI_BYTELIST_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_ARGUMENT
,
AML_TYPE_LITERAL
,
0
),
/* 66 */
ACPI_OP
(
"
-ReservedField-
"
,
ARGP_RESERVEDFIELD_OP
,
ARGI_RESERVEDFIELD_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
0
),
/* 67 */
ACPI_OP
(
"
-NamedField-
"
,
ARGP_NAMEDFIELD_OP
,
ARGI_NAMEDFIELD_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
AML_NSOBJECT
|
AML_NSOPCODE
|
AML_NSNODE
|
AML_NAMED
),
/* 68 */
ACPI_OP
(
"
-AccessField-
"
,
ARGP_ACCESSFIELD_OP
,
ARGI_ACCESSFIELD_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
0
),
/* 69 */
ACPI_OP
(
"
-
StaticString"
,
ARGP_STATICSTRING_OP
,
ARGI_STATICSTRING_OP
,
ACPI_TYPE_ANY
,
AML_CLASS_INTERNAL
,
AML_TYPE_BOGUS
,
0
),
/* 6A */
ACPI_OP
(
"
-Return Value-
"
,
ARG_NONE
,
ARG_NONE
,
ACPI_TYPE_ANY
,
AML_CLASS_RETURN_VALUE
,
AML_TYPE_RETURN
,
AML_HAS_ARGS
|
AML_HAS_RETVAL
),
/* 6B */
ACPI_OP
(
"
-UNKNOWN_OP-"
,
ARG_NONE
,
ARG_NONE
,
INTERNAL_TYPE_INVALID
,
AML_CLASS_UNKNOWN
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
),
/* 6C */
ACPI_OP
(
"
-ASCII_ONLY-"
,
ARG_NONE
,
ARG_NONE
,
ACPI_TYPE_ANY
,
AML_CLASS_ASCII
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
),
/* 6D */
ACPI_OP
(
"
-PREFIX_ONLY-"
,
ARG_NONE
,
ARG_NONE
,
ACPI_TYPE_ANY
,
AML_CLASS_PREFIX
,
AML_TYPE_BOGUS
,
AML_HAS_ARGS
),
/* ACPI 2.0 opcodes */
...
...
drivers/acpi/parser/psparse.c
View file @
a6817928
/******************************************************************************
*
* Module Name: psparse - Parser top level AML parse routines
* $Revision: 1
29
$
* $Revision: 1
33
$
*
*****************************************************************************/
...
...
@@ -111,58 +111,6 @@ acpi_ps_peek_opcode (
}
/*******************************************************************************
*
* FUNCTION: Acpi_ps_find_object
*
* PARAMETERS: Opcode - Current opcode
* Parser_state - Current state
* Walk_state - Current state
* *Op - Where found/new op is returned
*
* RETURN: Status
*
* DESCRIPTION: Find a named object. Two versions - one to search the parse
* tree (for parser-only applications such as acpidump), another
* to search the ACPI internal namespace (the parse tree may no
* longer exist)
*
******************************************************************************/
#ifdef PARSER_ONLY
acpi_status
acpi_ps_find_object
(
acpi_walk_state
*
walk_state
,
acpi_parse_object
**
out_op
)
{
NATIVE_CHAR
*
path
;
/* We are only interested in opcodes that have an associated name */
if
(
!
(
walk_state
->
op_info
->
flags
&
AML_NAMED
))
{
*
out_op
=
walk_state
->
op
;
return
(
AE_OK
);
}
/* Find the name in the parse tree */
path
=
acpi_ps_get_next_namestring
(
&
walk_state
->
parser_state
);
*
out_op
=
acpi_ps_find
(
acpi_ps_get_parent_scope
(
&
walk_state
->
parser_state
),
path
,
walk_state
->
opcode
,
1
);
if
(
!
(
*
out_op
))
{
return
(
AE_NOT_FOUND
);
}
return
(
AE_OK
);
}
#endif
/*******************************************************************************
*
* FUNCTION: Acpi_ps_complete_this_op
...
...
@@ -181,7 +129,6 @@ acpi_ps_complete_this_op (
acpi_walk_state
*
walk_state
,
acpi_parse_object
*
op
)
{
#ifndef PARSER_ONLY
acpi_parse_object
*
prev
;
acpi_parse_object
*
next
;
const
acpi_opcode_info
*
parent_info
;
...
...
@@ -317,10 +264,6 @@ acpi_ps_complete_this_op (
}
return_VOID
;
#else
return
;
#endif
}
...
...
@@ -381,6 +324,13 @@ acpi_ps_next_parse_state (
parser_state
->
aml
=
walk_state
->
aml_last_while
;
break
;
#if 0
case AE_CTRL_SKIP:
parser_state->aml = parser_state->scope->parse_scope.pkg_end;
status = AE_OK;
break;
#endif
case
AE_CTRL_TRUE
:
...
...
@@ -585,14 +535,25 @@ acpi_ps_parse_loop (
* Get and append arguments until we find the node that contains
* the name (the type ARGP_NAME).
*/
while
(
GET_CURRENT_ARG_TYPE
(
walk_state
->
arg_types
)
!=
ARGP_NAME
)
{
arg
=
acpi_ps_get_next_arg
(
parser_state
,
while
(
GET_CURRENT_ARG_TYPE
(
walk_state
->
arg_types
)
&&
(
GET_CURRENT_ARG_TYPE
(
walk_state
->
arg_types
)
!=
ARGP_NAME
))
{
status
=
acpi_ps_get_next_arg
(
parser_state
,
GET_CURRENT_ARG_TYPE
(
walk_state
->
arg_types
),
&
walk_state
->
arg_count
);
&
walk_state
->
arg_count
,
&
arg
);
if
(
ACPI_FAILURE
(
status
))
{
goto
close_this_op
;
}
acpi_ps_append_arg
(
&
pre_op
,
arg
);
INCREMENT_ARG_LIST
(
walk_state
->
arg_types
);
}
/* Make sure that we found a NAME and didn't run out of arguments */
if
(
!
GET_CURRENT_ARG_TYPE
(
walk_state
->
arg_types
))
{
return_ACPI_STATUS
(
AE_AML_NO_OPERAND
);
}
/* We know that this arg is a name, move to next arg */
INCREMENT_ARG_LIST
(
walk_state
->
arg_types
);
...
...
@@ -688,8 +649,8 @@ acpi_ps_parse_loop (
if
(
walk_state
->
op_info
)
{
ACPI_DEBUG_PRINT
((
ACPI_DB_PARSE
,
"Opcode %4.4
h
X [%s] Op %p Aml %p Aml_offset %5.5X
\n
"
,
op
->
common
.
aml_opcode
,
walk_state
->
op_info
->
name
,
"Opcode %4.4X [%s] Op %p Aml %p Aml_offset %5.5X
\n
"
,
(
u32
)
op
->
common
.
aml_opcode
,
walk_state
->
op_info
->
name
,
op
,
parser_state
->
aml
,
op
->
common
.
aml_offset
));
}
}
...
...
@@ -717,7 +678,17 @@ acpi_ps_parse_loop (
case
AML_INT_NAMEPATH_OP
:
/* AML_NAMESTRING_ARG */
acpi_ps_get_next_namepath
(
parser_state
,
op
,
&
walk_state
->
arg_count
,
1
);
status
=
acpi_ps_get_next_namepath
(
parser_state
,
op
,
&
walk_state
->
arg_count
,
1
);
if
(
ACPI_FAILURE
(
status
))
{
/* NOT_FOUND is an error only if we are actually executing a method */
if
((((
walk_state
->
parse_flags
&
ACPI_PARSE_MODE_MASK
)
==
ACPI_PARSE_EXECUTE
)
&&
(
status
==
AE_NOT_FOUND
))
||
(
status
!=
AE_NOT_FOUND
))
{
goto
close_this_op
;
}
}
walk_state
->
arg_types
=
0
;
break
;
...
...
@@ -729,14 +700,24 @@ acpi_ps_parse_loop (
while
(
GET_CURRENT_ARG_TYPE
(
walk_state
->
arg_types
)
&&
!
walk_state
->
arg_count
)
{
walk_state
->
aml_offset
=
ACPI_PTR_DIFF
(
parser_state
->
aml
,
parser_state
->
aml_start
);
arg
=
acpi_ps_get_next_arg
(
parser_state
,
status
=
acpi_ps_get_next_arg
(
parser_state
,
GET_CURRENT_ARG_TYPE
(
walk_state
->
arg_types
),
&
walk_state
->
arg_count
);
&
walk_state
->
arg_count
,
&
arg
);
if
(
ACPI_FAILURE
(
status
))
{
/* NOT_FOUND is an error only if we are actually executing a method */
if
((((
walk_state
->
parse_flags
&
ACPI_PARSE_MODE_MASK
)
==
ACPI_PARSE_EXECUTE
)
&&
(
status
==
AE_NOT_FOUND
)
&&
(
op
->
common
.
aml_opcode
!=
AML_COND_REF_OF_OP
))
||
(
status
!=
AE_NOT_FOUND
))
{
goto
close_this_op
;
}
}
if
(
arg
)
{
arg
->
common
.
aml_offset
=
walk_state
->
aml_offset
;
acpi_ps_append_arg
(
op
,
arg
);
}
INCREMENT_ARG_LIST
(
walk_state
->
arg_types
);
}
...
...
@@ -887,6 +868,7 @@ acpi_ps_parse_loop (
acpi_ps_pop_scope
(
parser_state
,
&
op
,
&
walk_state
->
arg_types
,
&
walk_state
->
arg_count
);
if
(
op
)
{
walk_state
->
op
=
op
;
walk_state
->
op_info
=
acpi_ps_get_opcode_info
(
op
->
common
.
aml_opcode
);
walk_state
->
opcode
=
op
->
common
.
aml_opcode
;
...
...
@@ -896,6 +878,7 @@ acpi_ps_parse_loop (
acpi_ps_complete_this_op
(
walk_state
,
op
);
op
=
NULL
;
}
status
=
AE_OK
;
break
;
...
...
@@ -1053,6 +1036,7 @@ acpi_ps_parse_aml (
acpi_walk_state
*
walk_state
)
{
acpi_status
status
;
acpi_status
terminate_status
;
ACPI_THREAD_STATE
*
thread
;
ACPI_THREAD_STATE
*
prev_walk_list
=
acpi_gbl_current_walk_list
;
acpi_walk_state
*
previous_walk_state
;
...
...
@@ -1131,10 +1115,9 @@ acpi_ps_parse_aml (
* there's lots of cleanup to do
*/
if
((
walk_state
->
parse_flags
&
ACPI_PARSE_MODE_MASK
)
==
ACPI_PARSE_EXECUTE
)
{
status
=
acpi_ds_terminate_control_method
(
walk_state
);
if
(
ACPI_FAILURE
(
status
))
{
terminate_
status
=
acpi_ds_terminate_control_method
(
walk_state
);
if
(
ACPI_FAILURE
(
terminate_
status
))
{
ACPI_REPORT_ERROR
((
"Could not terminate control method properly
\n
"
));
status
=
AE_OK
;
/* Ignore error and continue */
}
...
...
drivers/acpi/parser/pstree.c
View file @
a6817928
/******************************************************************************
*
* Module Name: pstree - Parser op tree manipulation/traversal/search
* $Revision:
39
$
* $Revision:
40
$
*
*****************************************************************************/
...
...
drivers/acpi/resources/rsdump.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: rsdump - Functions to display the resource structures.
* $Revision: 3
2
$
* $Revision: 3
3
$
*
******************************************************************************/
...
...
@@ -31,7 +31,7 @@
ACPI_MODULE_NAME
(
"rsdump"
)
#if defined(ACPI_DEBUG
) || defined(ENABLE
_DEBUGGER)
#if defined(ACPI_DEBUG
_OUTPUT) || defined(ACPI
_DEBUGGER)
/*******************************************************************************
*
...
...
drivers/acpi/system.c
View file @
a6817928
...
...
@@ -256,7 +256,8 @@ acpi_system_suspend(
acpi_status
status
=
AE_ERROR
;
unsigned
long
flags
=
0
;
save_flags
(
flags
);
local_irq_save
(
flags
);
local_irq_disable
();
switch
(
state
)
{
...
...
@@ -270,7 +271,7 @@ acpi_system_suspend(
do_suspend_lowlevel
(
0
);
break
;
}
restore_flags
(
flags
);
local_irq_restore
(
flags
);
return
status
;
}
...
...
drivers/acpi/tables.c
View file @
a6817928
...
...
@@ -36,7 +36,7 @@
#define PREFIX "ACPI: "
#define ACPI_MAX_TABLES
ACPI_TABLE_COUNT
#define ACPI_MAX_TABLES
256
static
char
*
acpi_table_signatures
[
ACPI_TABLE_COUNT
]
=
{
[
ACPI_TABLE_UNKNOWN
]
=
"????"
,
...
...
@@ -338,7 +338,7 @@ acpi_table_get_sdt (
sdt
.
count
=
(
header
->
length
-
sizeof
(
struct
acpi_table_header
))
>>
3
;
if
(
sdt
.
count
>
ACPI_MAX_TABLES
)
{
printk
(
KERN_WARNING
PREFIX
"Truncated %lu XSDT entries
\n
"
,
(
ACPI_MAX_TABLES
-
sdt
.
count
));
(
sdt
.
count
-
ACPI_MAX_TABLES
));
sdt
.
count
=
ACPI_MAX_TABLES
;
}
...
...
@@ -383,7 +383,7 @@ acpi_table_get_sdt (
sdt
.
count
=
(
header
->
length
-
sizeof
(
struct
acpi_table_header
))
>>
2
;
if
(
sdt
.
count
>
ACPI_MAX_TABLES
)
{
printk
(
KERN_WARNING
PREFIX
"Truncated %lu RSDT entries
\n
"
,
(
ACPI_TABLE_COUNT
-
sdt
.
count
));
(
sdt
.
count
-
ACPI_TABLE_COUNT
));
sdt
.
count
=
ACPI_MAX_TABLES
;
}
...
...
drivers/acpi/tables/tbconvrt.c
View file @
a6817928
/******************************************************************************
*
* Module Name: tbconvrt - ACPI Table conversion utilities
* $Revision: 4
2
$
* $Revision: 4
3
$
*
*****************************************************************************/
...
...
drivers/acpi/tables/tbget.c
View file @
a6817928
/******************************************************************************
*
* Module Name: tbget - ACPI Table get* routines
* $Revision: 7
8
$
* $Revision: 7
9
$
*
*****************************************************************************/
...
...
drivers/acpi/tables/tbgetall.c
View file @
a6817928
/******************************************************************************
*
* Module Name: tbgetall - Get all required ACPI tables
* $Revision:
1
$
* $Revision:
2
$
*
*****************************************************************************/
...
...
drivers/acpi/tables/tbinstal.c
View file @
a6817928
/******************************************************************************
*
* Module Name: tbinstal - ACPI table installation and removal
* $Revision: 6
2
$
* $Revision: 6
3
$
*
*****************************************************************************/
...
...
drivers/acpi/tables/tbrsdt.c
View file @
a6817928
/******************************************************************************
*
* Module Name: tbrsdt - ACPI RSDT table utilities
* $Revision:
2
$
* $Revision:
3
$
*
*****************************************************************************/
...
...
drivers/acpi/tables/tbutils.c
View file @
a6817928
/******************************************************************************
*
* Module Name: tbutils - Table manipulation utilities
* $Revision: 5
5
$
* $Revision: 5
6
$
*
*****************************************************************************/
...
...
@@ -135,7 +135,7 @@ acpi_tb_validate_table_header (
table_header
,
(
char
*
)
&
signature
));
ACPI_REPORT_WARNING
((
"Invalid table header length (0x%X) found
\n
"
,
table_header
->
length
));
(
u32
)
table_header
->
length
));
ACPI_DUMP_BUFFER
(
table_header
,
sizeof
(
acpi_table_header
));
return
(
AE_BAD_HEADER
);
}
...
...
@@ -176,7 +176,7 @@ acpi_tb_verify_table_checksum (
if
(
checksum
)
{
ACPI_REPORT_WARNING
((
"Invalid checksum (%X) in table %4.4s
\n
"
,
checksum
,
table_header
->
signature
));
(
u32
)
checksum
,
table_header
->
signature
));
status
=
AE_BAD_CHECKSUM
;
}
...
...
drivers/acpi/thermal.c
View file @
a6817928
...
...
@@ -473,6 +473,7 @@ acpi_thermal_passive (
trend
,
passive
->
tc1
,
tz
->
temperature
,
tz
->
last_temperature
,
passive
->
tc2
,
tz
->
temperature
,
passive
->
temperature
));
tz
->
trips
.
passive
.
flags
.
enabled
=
1
;
/* Heating up? */
if
(
trend
>
0
)
for
(
i
=
0
;
i
<
passive
->
devices
.
count
;
i
++
)
...
...
@@ -518,6 +519,7 @@ acpi_thermal_active (
struct
acpi_thermal_active
*
active
=
NULL
;
int
i
=
0
;
int
j
=
0
;
unsigned
long
maxtemp
=
0
;
ACPI_FUNCTION_TRACE
(
"acpi_thermal_active"
);
...
...
@@ -537,7 +539,8 @@ acpi_thermal_active (
* associated with this active threshold.
*/
if
(
tz
->
temperature
>=
active
->
temperature
)
{
tz
->
state
.
active_index
=
i
;
if
(
active
->
temperature
>
maxtemp
)
tz
->
state
.
active_index
=
i
,
maxtemp
=
active
->
temperature
;
if
(
!
active
->
flags
.
enabled
)
{
for
(
j
=
0
;
j
<
active
->
devices
.
count
;
j
++
)
{
result
=
acpi_bus_set_power
(
active
->
devices
.
handles
[
j
],
ACPI_STATE_D0
);
...
...
@@ -591,6 +594,7 @@ acpi_thermal_check (
struct
acpi_thermal
*
tz
=
(
struct
acpi_thermal
*
)
data
;
unsigned
long
sleep_time
=
0
;
int
i
=
0
;
struct
acpi_thermal_state
state
=
tz
->
state
;
ACPI_FUNCTION_TRACE
(
"acpi_thermal_check"
);
...
...
@@ -613,15 +617,15 @@ acpi_thermal_check (
* this function determines when a state is entered, but the
* individual policy decides when it is exited (e.g. hysteresis).
*/
if
(
(
tz
->
trips
.
critical
.
flags
.
valid
)
&&
(
tz
->
temperature
>=
tz
->
trips
.
critical
.
temperature
)
)
tz
->
trips
.
critical
.
flags
.
enabled
=
1
;
if
(
(
tz
->
trips
.
hot
.
flags
.
valid
)
&&
(
tz
->
temperature
>=
tz
->
trips
.
hot
.
temperature
)
)
tz
->
trips
.
hot
.
flags
.
enabled
=
1
;
if
(
(
tz
->
trips
.
passive
.
flags
.
valid
)
&&
(
tz
->
temperature
>=
tz
->
trips
.
passive
.
temperature
)
)
tz
->
trips
.
passive
.
flags
.
enabled
=
1
;
if
(
tz
->
trips
.
critical
.
flags
.
valid
)
state
.
critical
|=
(
tz
->
temperature
>=
tz
->
trips
.
critical
.
temperature
)
;
if
(
tz
->
trips
.
hot
.
flags
.
valid
)
state
.
hot
|=
(
tz
->
temperature
>=
tz
->
trips
.
hot
.
temperature
)
;
if
(
tz
->
trips
.
passive
.
flags
.
valid
)
state
.
passive
|=
(
tz
->
temperature
>=
tz
->
trips
.
passive
.
temperature
)
;
for
(
i
=
0
;
i
<
ACPI_THERMAL_MAX_ACTIVE
;
i
++
)
if
(
(
tz
->
trips
.
active
[
i
].
flags
.
valid
)
&&
(
tz
->
temperature
>=
tz
->
trips
.
active
[
i
].
temperature
)
)
tz
->
trips
.
active
[
i
].
flags
.
enabled
=
1
;
if
(
tz
->
trips
.
active
[
i
].
flags
.
valid
)
state
.
active
|=
(
tz
->
temperature
>=
tz
->
trips
.
active
[
i
].
temperature
)
;
/*
* Invoke Policy
...
...
@@ -629,13 +633,13 @@ acpi_thermal_check (
* Separated from the above check to allow individual policy to
* determine when to exit a given state.
*/
if
(
tz
->
trips
.
critical
.
flags
.
enabled
)
if
(
state
.
critical
)
acpi_thermal_critical
(
tz
);
if
(
tz
->
trips
.
hot
.
flags
.
enabled
)
if
(
state
.
hot
)
acpi_thermal_hot
(
tz
);
if
(
tz
->
trips
.
passive
.
flags
.
enabled
)
if
(
state
.
passive
)
acpi_thermal_passive
(
tz
);
if
(
tz
->
trips
.
active
[
0
].
flags
.
enabled
)
if
(
state
.
active
)
acpi_thermal_active
(
tz
);
/*
...
...
drivers/acpi/utilities/utdebug.c
View file @
a6817928
/******************************************************************************
*
* Module Name: utdebug - Debug print routines
* $Revision: 10
3
$
* $Revision: 10
4
$
*
*****************************************************************************/
...
...
@@ -30,7 +30,7 @@
ACPI_MODULE_NAME
(
"utdebug"
)
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
static
u32
acpi_gbl_prev_thread_id
=
0xFFFFFFFF
;
static
char
*
acpi_gbl_fn_entry_str
=
"----Entry"
;
...
...
drivers/acpi/utilities/uteval.c
View file @
a6817928
/******************************************************************************
*
* Module Name: uteval - Object evaluation
* $Revision: 4
0
$
* $Revision: 4
1
$
*
*****************************************************************************/
...
...
drivers/acpi/utilities/utglobal.c
View file @
a6817928
/******************************************************************************
*
* Module Name: utglobal - Global variables for the ACPI subsystem
* $Revision: 16
5
$
* $Revision: 16
8
$
*
*****************************************************************************/
...
...
@@ -126,7 +126,7 @@ acpi_format_exception (
/* Debug switch - level and trace mask */
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
u32
acpi_dbg_level
=
DEBUG_DEFAULT
;
#else
u32
acpi_dbg_level
=
NORMAL_DEFAULT
;
...
...
@@ -185,6 +185,10 @@ const acpi_predefined_names acpi_gbl_pre_defined_names[] =
{
"_REV"
,
ACPI_TYPE_INTEGER
,
"2"
},
{
"_OS_"
,
ACPI_TYPE_STRING
,
ACPI_OS_NAME
},
{
"_GL_"
,
ACPI_TYPE_MUTEX
,
"0"
},
#if defined (ACPI_NO_METHOD_EXECUTION) || defined (ACPI_CONSTANT_EVAL_ONLY)
{
"_OSI"
,
ACPI_TYPE_METHOD
,
"1"
},
#endif
{
NULL
,
ACPI_TYPE_ANY
,
NULL
}
/* Table terminator */
};
...
...
@@ -522,7 +526,7 @@ acpi_ut_get_object_type_name (
}
#if defined(ACPI_DEBUG
) || defined(ENABLE
_DEBUGGER)
#if defined(ACPI_DEBUG
_OUTPUT) || defined(ACPI
_DEBUGGER)
/*
* Strings and procedures used for debug only
...
...
@@ -773,7 +777,7 @@ acpi_ut_init_globals (
acpi_gbl_root_node_struct
.
flags
=
ANOBJ_END_OF_PEER_LIST
;
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
acpi_gbl_lowest_stack_pointer
=
ACPI_SIZE_MAX
;
#endif
...
...
drivers/acpi/utilities/utinit.c
View file @
a6817928
/******************************************************************************
*
* Module Name: utinit - Common ACPI subsystem initialization
* $Revision: 11
2
$
* $Revision: 11
3
$
*
*****************************************************************************/
...
...
@@ -198,14 +198,14 @@ acpi_ut_subsystem_shutdown (void)
acpi_gbl_shutdown
=
TRUE
;
ACPI_DEBUG_PRINT
((
ACPI_DB_INFO
,
"Shutting down ACPI Subsystem...
\n
"
));
/* Close the Namespace */
acpi_ns_terminate
();
/* Close the Acpi_event Handling */
acpi_ev_terminate
();
/* Close the Namespace */
acpi_ns_terminate
();
/* Close the globals */
acpi_ut_terminate
();
...
...
drivers/acpi/utilities/utmisc.c
View file @
a6817928
/*******************************************************************************
*
* Module Name: utmisc - common utility procedures
* $Revision:
78
$
* $Revision:
80
$
*
******************************************************************************/
...
...
@@ -104,7 +104,7 @@ acpi_ut_set_integer_width (
}
#ifdef ACPI_DEBUG
#ifdef ACPI_DEBUG
_OUTPUT
/*******************************************************************************
*
* FUNCTION: Acpi_ut_display_init_pathname
...
...
drivers/acpi/utilities/utxface.c
View file @
a6817928
/******************************************************************************
*
* Module Name: utxface - External interfaces for "global" ACPI functions
* $Revision:
97
$
* $Revision:
100
$
*
*****************************************************************************/
...
...
@@ -159,6 +159,8 @@ acpi_enable_subsystem (
if
(
!
(
flags
&
ACPI_NO_ACPI_ENABLE
))
{
ACPI_DEBUG_PRINT
((
ACPI_DB_EXEC
,
"[Init] Going into ACPI mode
\n
"
));
acpi_gbl_original_mode
=
acpi_hw_get_mode
();
status
=
acpi_enable
();
if
(
ACPI_FAILURE
(
status
))
{
ACPI_DEBUG_PRINT
((
ACPI_DB_WARN
,
"Acpi_enable failed.
\n
"
));
...
...
@@ -291,7 +293,7 @@ acpi_terminate (void)
acpi_ut_mutex_terminate
();
#ifdef
ENABLE
_DEBUGGER
#ifdef
ACPI
_DEBUGGER
/* Shut down the debugger */
...
...
include/linux/acpi.h
View file @
a6817928
...
...
@@ -39,7 +39,7 @@
#include <asm/acpi.h>
#ifdef CONFIG_ACPI
_BOOT
#ifdef CONFIG_ACPI
enum
acpi_irq_model_id
{
ACPI_IRQ_MODEL_PIC
=
0
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment