You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
Merge branch 'acpica'
* acpica: (26 commits) ACPICA: Update version to 20121018 ACPICA: AcpiGetObjectInfo: Add support for ACPI 5 _SUB method ACPICA: Update for 64-bit generation of recent error message changes ACPICA: Fix externalize name to complete migration to ACPI_MOVE_NAME ACPICA: Add starting offset parameter to common dump buffer routine ACPICA: Deploy ACPI_MOVE_NAME across ACPICA source base ACPICA: Update support for ACPI 5 MPST table ACPICA: Enhance error reporting for invalid opcodes and bad ACPI_NAMEs ACPICA: Add ACPI_MOVE_NAME macro to optimize 4-byte ACPI_NAME copies ACPICA: AcpiExec: Improve algorithm for tracking memory leaks ACPICA: Add debug print message for mutex objects that are force-released ACPICA: Resource Mgr: Small fix for buffer size calculation ACPICA: Remove extra spaces after periods in the Intel license ACPICA: Remove extra spaces after periods within comments ACPICA: Update local C library module comments for ASCII table ACPICA: Fix for predefined name loop during ACPICA initialization ACPICA: Fix some typos in comments ACPICA: ACPICA core: Cleanup empty lines at file start and end ACPICA: Audit/update for ACPICA return macros and debug depth counter ACPICA: Fix unmerged acmacros.h divergences. ...
This commit is contained in:
@@ -161,3 +161,6 @@ acpi-y += \
|
||||
utxfinit.o \
|
||||
utxferror.o \
|
||||
utxfmutex.o
|
||||
|
||||
acpi-$(ACPI_FUTURE_USAGE) += uttrack.o utcache.o utclib.o
|
||||
|
||||
|
||||
@@ -44,17 +44,28 @@
|
||||
#ifndef __ACDEBUG_H__
|
||||
#define __ACDEBUG_H__
|
||||
|
||||
#define ACPI_DEBUG_BUFFER_SIZE 4196
|
||||
#define ACPI_DEBUG_BUFFER_SIZE 0x4000 /* 16K buffer for return objects */
|
||||
|
||||
struct command_info {
|
||||
struct acpi_db_command_info {
|
||||
char *name; /* Command Name */
|
||||
u8 min_args; /* Minimum arguments required */
|
||||
};
|
||||
|
||||
struct argument_info {
|
||||
struct acpi_db_command_help {
|
||||
u8 line_count; /* Number of help lines */
|
||||
char *invocation; /* Command Invocation */
|
||||
char *description; /* Command Description */
|
||||
};
|
||||
|
||||
struct acpi_db_argument_info {
|
||||
char *name; /* Argument Name */
|
||||
};
|
||||
|
||||
struct acpi_db_execute_walk {
|
||||
u32 count;
|
||||
u32 max_count;
|
||||
};
|
||||
|
||||
#define PARAM_LIST(pl) pl
|
||||
#define DBTEST_OUTPUT_LEVEL(lvl) if (acpi_gbl_db_opt_verbose)
|
||||
#define VERBOSE_PRINT(fp) DBTEST_OUTPUT_LEVEL(lvl) {\
|
||||
@@ -77,43 +88,19 @@ acpi_db_single_step(struct acpi_walk_state *walk_state,
|
||||
/*
|
||||
* dbcmds - debug commands and output routines
|
||||
*/
|
||||
acpi_status acpi_db_disassemble_method(char *name);
|
||||
struct acpi_namespace_node *acpi_db_convert_to_node(char *in_string);
|
||||
|
||||
void acpi_db_display_table_info(char *table_arg);
|
||||
|
||||
void acpi_db_unload_acpi_table(char *table_arg, char *instance_arg);
|
||||
void acpi_db_display_template(char *buffer_arg);
|
||||
|
||||
void
|
||||
acpi_db_set_method_breakpoint(char *location,
|
||||
struct acpi_walk_state *walk_state,
|
||||
union acpi_parse_object *op);
|
||||
|
||||
void acpi_db_set_method_call_breakpoint(union acpi_parse_object *op);
|
||||
|
||||
void acpi_db_get_bus_info(void);
|
||||
|
||||
void acpi_db_disassemble_aml(char *statements, union acpi_parse_object *op);
|
||||
|
||||
void acpi_db_dump_namespace(char *start_arg, char *depth_arg);
|
||||
|
||||
void acpi_db_dump_namespace_by_owner(char *owner_arg, char *depth_arg);
|
||||
void acpi_db_unload_acpi_table(char *name);
|
||||
|
||||
void acpi_db_send_notify(char *name, u32 value);
|
||||
|
||||
void acpi_db_set_method_data(char *type_arg, char *index_arg, char *value_arg);
|
||||
|
||||
acpi_status
|
||||
acpi_db_display_objects(char *obj_type_arg, char *display_count_arg);
|
||||
|
||||
void acpi_db_display_interfaces(char *action_arg, char *interface_name_arg);
|
||||
|
||||
acpi_status acpi_db_find_name_in_namespace(char *name_arg);
|
||||
|
||||
void acpi_db_set_scope(char *name);
|
||||
|
||||
ACPI_HW_DEPENDENT_RETURN_OK(acpi_status acpi_db_sleep(char *object_arg))
|
||||
|
||||
void acpi_db_find_references(char *object_arg);
|
||||
acpi_status acpi_db_sleep(char *object_arg);
|
||||
|
||||
void acpi_db_display_locks(void);
|
||||
|
||||
@@ -121,15 +108,51 @@ void acpi_db_display_resources(char *object_arg);
|
||||
|
||||
ACPI_HW_DEPENDENT_RETURN_VOID(void acpi_db_display_gpes(void))
|
||||
|
||||
void acpi_db_check_integrity(void);
|
||||
void acpi_db_display_handlers(void);
|
||||
|
||||
ACPI_HW_DEPENDENT_RETURN_VOID(void
|
||||
acpi_db_generate_gpe(char *gpe_arg,
|
||||
char *block_arg))
|
||||
|
||||
/*
|
||||
* dbmethod - control method commands
|
||||
*/
|
||||
void
|
||||
acpi_db_set_method_breakpoint(char *location,
|
||||
struct acpi_walk_state *walk_state,
|
||||
union acpi_parse_object *op);
|
||||
|
||||
void acpi_db_set_method_call_breakpoint(union acpi_parse_object *op);
|
||||
|
||||
void acpi_db_set_method_data(char *type_arg, char *index_arg, char *value_arg);
|
||||
|
||||
acpi_status acpi_db_disassemble_method(char *name);
|
||||
|
||||
void acpi_db_disassemble_aml(char *statements, union acpi_parse_object *op);
|
||||
|
||||
void acpi_db_batch_execute(char *count_arg);
|
||||
|
||||
/*
|
||||
* dbnames - namespace commands
|
||||
*/
|
||||
void acpi_db_set_scope(char *name);
|
||||
|
||||
void acpi_db_dump_namespace(char *start_arg, char *depth_arg);
|
||||
|
||||
void acpi_db_dump_namespace_by_owner(char *owner_arg, char *depth_arg);
|
||||
|
||||
acpi_status acpi_db_find_name_in_namespace(char *name_arg);
|
||||
|
||||
void acpi_db_check_predefined_names(void);
|
||||
|
||||
void acpi_db_batch_execute(void);
|
||||
acpi_status
|
||||
acpi_db_display_objects(char *obj_type_arg, char *display_count_arg);
|
||||
|
||||
void acpi_db_check_integrity(void);
|
||||
|
||||
void acpi_db_find_references(char *object_arg);
|
||||
|
||||
void acpi_db_get_bus_info(void);
|
||||
|
||||
/*
|
||||
* dbdisply - debug display commands
|
||||
@@ -161,7 +184,8 @@ acpi_db_display_argument_object(union acpi_operand_object *obj_desc,
|
||||
/*
|
||||
* dbexec - debugger control method execution
|
||||
*/
|
||||
void acpi_db_execute(char *name, char **args, u32 flags);
|
||||
void
|
||||
acpi_db_execute(char *name, char **args, acpi_object_type * types, u32 flags);
|
||||
|
||||
void
|
||||
acpi_db_create_execution_threads(char *num_threads_arg,
|
||||
@@ -175,7 +199,8 @@ u32 acpi_db_get_cache_info(struct acpi_memory_list *cache);
|
||||
* dbfileio - Debugger file I/O commands
|
||||
*/
|
||||
acpi_object_type
|
||||
acpi_db_match_argument(char *user_argument, struct argument_info *arguments);
|
||||
acpi_db_match_argument(char *user_argument,
|
||||
struct acpi_db_argument_info *arguments);
|
||||
|
||||
void acpi_db_close_debug_file(void);
|
||||
|
||||
@@ -208,6 +233,11 @@ acpi_db_command_dispatch(char *input_buffer,
|
||||
|
||||
void ACPI_SYSTEM_XFACE acpi_db_execute_thread(void *context);
|
||||
|
||||
acpi_status acpi_db_user_commands(char prompt, union acpi_parse_object *op);
|
||||
|
||||
char *acpi_db_get_next_token(char *string,
|
||||
char **next, acpi_object_type * return_type);
|
||||
|
||||
/*
|
||||
* dbstats - Generation and display of ACPI table statistics
|
||||
*/
|
||||
|
||||
@@ -309,10 +309,13 @@ acpi_ds_obj_stack_push(void *object, struct acpi_walk_state *walk_state);
|
||||
acpi_status
|
||||
acpi_ds_obj_stack_pop(u32 pop_count, struct acpi_walk_state *walk_state);
|
||||
|
||||
struct acpi_walk_state *acpi_ds_create_walk_state(acpi_owner_id owner_id, union acpi_parse_object
|
||||
*origin, union acpi_operand_object
|
||||
*mth_desc, struct acpi_thread_state
|
||||
*thread);
|
||||
struct acpi_walk_state * acpi_ds_create_walk_state(acpi_owner_id owner_id,
|
||||
union acpi_parse_object
|
||||
*origin,
|
||||
union acpi_operand_object
|
||||
*mth_desc,
|
||||
struct acpi_thread_state
|
||||
*thread);
|
||||
|
||||
acpi_status
|
||||
acpi_ds_init_aml_walk(struct acpi_walk_state *walk_state,
|
||||
|
||||
@@ -84,9 +84,11 @@ acpi_ev_update_gpe_enable_mask(struct acpi_gpe_event_info *gpe_event_info);
|
||||
|
||||
acpi_status acpi_ev_enable_gpe(struct acpi_gpe_event_info *gpe_event_info);
|
||||
|
||||
acpi_status acpi_ev_add_gpe_reference(struct acpi_gpe_event_info *gpe_event_info);
|
||||
acpi_status
|
||||
acpi_ev_add_gpe_reference(struct acpi_gpe_event_info *gpe_event_info);
|
||||
|
||||
acpi_status acpi_ev_remove_gpe_reference(struct acpi_gpe_event_info *gpe_event_info);
|
||||
acpi_status
|
||||
acpi_ev_remove_gpe_reference(struct acpi_gpe_event_info *gpe_event_info);
|
||||
|
||||
struct acpi_gpe_event_info *acpi_ev_get_gpe_event_info(acpi_handle gpe_device,
|
||||
u32 gpe_number);
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
|
||||
/*
|
||||
* Enable "slack" in the AML interpreter? Default is FALSE, and the
|
||||
* interpreter strictly follows the ACPI specification. Setting to TRUE
|
||||
* interpreter strictly follows the ACPI specification. Setting to TRUE
|
||||
* allows the interpreter to ignore certain errors and/or bad AML constructs.
|
||||
*
|
||||
* Currently, these features are enabled by this flag:
|
||||
@@ -153,26 +153,6 @@ u8 acpi_gbl_reduced_hardware;
|
||||
|
||||
ACPI_EXTERN u8 ACPI_INIT_GLOBAL(acpi_gbl_no_resource_disassembly, FALSE);
|
||||
|
||||
/*****************************************************************************
|
||||
*
|
||||
* Debug support
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/* Procedure nesting level for debug output */
|
||||
|
||||
extern u32 acpi_gbl_nesting_level;
|
||||
|
||||
ACPI_EXTERN u32 acpi_gpe_count;
|
||||
ACPI_EXTERN u32 acpi_fixed_event_count[ACPI_NUM_FIXED_EVENTS];
|
||||
|
||||
/* Support for dynamic control method tracing mechanism */
|
||||
|
||||
ACPI_EXTERN u32 acpi_gbl_original_dbg_level;
|
||||
ACPI_EXTERN u32 acpi_gbl_original_dbg_layer;
|
||||
ACPI_EXTERN u32 acpi_gbl_trace_dbg_level;
|
||||
ACPI_EXTERN u32 acpi_gbl_trace_dbg_layer;
|
||||
|
||||
/*****************************************************************************
|
||||
*
|
||||
* ACPI Table globals
|
||||
@@ -259,15 +239,6 @@ ACPI_EXTERN acpi_spinlock acpi_gbl_hardware_lock; /* For ACPI H/W except GPE reg
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef ACPI_DBG_TRACK_ALLOCATIONS
|
||||
|
||||
/* Lists for tracking memory allocations */
|
||||
|
||||
ACPI_EXTERN struct acpi_memory_list *acpi_gbl_global_list;
|
||||
ACPI_EXTERN struct acpi_memory_list *acpi_gbl_ns_node_list;
|
||||
ACPI_EXTERN u8 acpi_gbl_display_final_mem_stats;
|
||||
#endif
|
||||
|
||||
/* Object caches */
|
||||
|
||||
ACPI_EXTERN acpi_cache_t *acpi_gbl_namespace_cache;
|
||||
@@ -326,6 +297,15 @@ extern const char *acpi_gbl_region_types[ACPI_NUM_PREDEFINED_REGIONS];
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef ACPI_DBG_TRACK_ALLOCATIONS
|
||||
|
||||
/* Lists for tracking memory allocations */
|
||||
|
||||
ACPI_EXTERN struct acpi_memory_list *acpi_gbl_global_list;
|
||||
ACPI_EXTERN struct acpi_memory_list *acpi_gbl_ns_node_list;
|
||||
ACPI_EXTERN u8 acpi_gbl_display_final_mem_stats;
|
||||
#endif
|
||||
|
||||
/*****************************************************************************
|
||||
*
|
||||
* Namespace globals
|
||||
@@ -396,11 +376,33 @@ ACPI_EXTERN struct acpi_gpe_block_info
|
||||
#if (!ACPI_REDUCED_HARDWARE)
|
||||
|
||||
ACPI_EXTERN u8 acpi_gbl_all_gpes_initialized;
|
||||
ACPI_EXTERN ACPI_GBL_EVENT_HANDLER acpi_gbl_global_event_handler;
|
||||
ACPI_EXTERN acpi_gbl_event_handler acpi_gbl_global_event_handler;
|
||||
ACPI_EXTERN void *acpi_gbl_global_event_handler_context;
|
||||
|
||||
#endif /* !ACPI_REDUCED_HARDWARE */
|
||||
|
||||
/*****************************************************************************
|
||||
*
|
||||
* Debug support
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/* Procedure nesting level for debug output */
|
||||
|
||||
extern u32 acpi_gbl_nesting_level;
|
||||
|
||||
/* Event counters */
|
||||
|
||||
ACPI_EXTERN u32 acpi_gpe_count;
|
||||
ACPI_EXTERN u32 acpi_fixed_event_count[ACPI_NUM_FIXED_EVENTS];
|
||||
|
||||
/* Support for dynamic control method tracing mechanism */
|
||||
|
||||
ACPI_EXTERN u32 acpi_gbl_original_dbg_level;
|
||||
ACPI_EXTERN u32 acpi_gbl_original_dbg_layer;
|
||||
ACPI_EXTERN u32 acpi_gbl_trace_dbg_level;
|
||||
ACPI_EXTERN u32 acpi_gbl_trace_dbg_layer;
|
||||
|
||||
/*****************************************************************************
|
||||
*
|
||||
* Debugger globals
|
||||
@@ -426,10 +428,11 @@ ACPI_EXTERN u8 acpi_gbl_db_opt_stats;
|
||||
ACPI_EXTERN u8 acpi_gbl_db_opt_ini_methods;
|
||||
|
||||
ACPI_EXTERN char *acpi_gbl_db_args[ACPI_DEBUGGER_MAX_ARGS];
|
||||
ACPI_EXTERN char acpi_gbl_db_line_buf[80];
|
||||
ACPI_EXTERN char acpi_gbl_db_parsed_buf[80];
|
||||
ACPI_EXTERN char acpi_gbl_db_scope_buf[40];
|
||||
ACPI_EXTERN char acpi_gbl_db_debug_filename[40];
|
||||
ACPI_EXTERN acpi_object_type acpi_gbl_db_arg_types[ACPI_DEBUGGER_MAX_ARGS];
|
||||
ACPI_EXTERN char acpi_gbl_db_line_buf[ACPI_DB_LINE_BUFFER_SIZE];
|
||||
ACPI_EXTERN char acpi_gbl_db_parsed_buf[ACPI_DB_LINE_BUFFER_SIZE];
|
||||
ACPI_EXTERN char acpi_gbl_db_scope_buf[80];
|
||||
ACPI_EXTERN char acpi_gbl_db_debug_filename[80];
|
||||
ACPI_EXTERN u8 acpi_gbl_db_output_to_file;
|
||||
ACPI_EXTERN char *acpi_gbl_db_buffer;
|
||||
ACPI_EXTERN char *acpi_gbl_db_filename;
|
||||
|
||||
@@ -262,10 +262,10 @@ struct acpi_create_field_info {
|
||||
};
|
||||
|
||||
typedef
|
||||
acpi_status(*ACPI_INTERNAL_METHOD) (struct acpi_walk_state * walk_state);
|
||||
acpi_status(*acpi_internal_method) (struct acpi_walk_state * walk_state);
|
||||
|
||||
/*
|
||||
* Bitmapped ACPI types. Used internally only
|
||||
* Bitmapped ACPI types. Used internally only
|
||||
*/
|
||||
#define ACPI_BTYPE_ANY 0x00000000
|
||||
#define ACPI_BTYPE_INTEGER 0x00000001
|
||||
@@ -486,8 +486,10 @@ struct acpi_gpe_device_info {
|
||||
struct acpi_namespace_node *gpe_device;
|
||||
};
|
||||
|
||||
typedef acpi_status(*acpi_gpe_callback) (struct acpi_gpe_xrupt_info *gpe_xrupt_info,
|
||||
struct acpi_gpe_block_info *gpe_block, void *context);
|
||||
typedef acpi_status(*acpi_gpe_callback) (struct acpi_gpe_xrupt_info *
|
||||
gpe_xrupt_info,
|
||||
struct acpi_gpe_block_info *gpe_block,
|
||||
void *context);
|
||||
|
||||
/* Information about each particular fixed event */
|
||||
|
||||
@@ -582,7 +584,7 @@ struct acpi_pscope_state {
|
||||
};
|
||||
|
||||
/*
|
||||
* Thread state - one per thread across multiple walk states. Multiple walk
|
||||
* Thread state - one per thread across multiple walk states. Multiple walk
|
||||
* states are created when there are nested control methods executing.
|
||||
*/
|
||||
struct acpi_thread_state {
|
||||
@@ -645,7 +647,7 @@ union acpi_generic_state {
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
typedef acpi_status(*ACPI_EXECUTE_OP) (struct acpi_walk_state * walk_state);
|
||||
typedef acpi_status(*acpi_execute_op) (struct acpi_walk_state * walk_state);
|
||||
|
||||
/* Address Range info block */
|
||||
|
||||
@@ -1031,6 +1033,7 @@ struct acpi_db_method_info {
|
||||
acpi_handle method;
|
||||
acpi_handle main_thread_gate;
|
||||
acpi_handle thread_complete_gate;
|
||||
acpi_handle info_gate;
|
||||
acpi_thread_id *threads;
|
||||
u32 num_threads;
|
||||
u32 num_created;
|
||||
@@ -1041,6 +1044,7 @@ struct acpi_db_method_info {
|
||||
u32 num_loops;
|
||||
char pathname[128];
|
||||
char **args;
|
||||
acpi_object_type *types;
|
||||
|
||||
/*
|
||||
* Arguments to be passed to method for the command
|
||||
|
||||
+58
-105
@@ -84,29 +84,29 @@
|
||||
|
||||
/* These macros reverse the bytes during the move, converting little-endian to big endian */
|
||||
|
||||
/* Big Endian <== Little Endian */
|
||||
/* Hi...Lo Lo...Hi */
|
||||
/* Big Endian <== Little Endian */
|
||||
/* Hi...Lo Lo...Hi */
|
||||
/* 16-bit source, 16/32/64 destination */
|
||||
|
||||
#define ACPI_MOVE_16_TO_16(d, s) {(( u8 *)(void *)(d))[0] = ((u8 *)(void *)(s))[1];\
|
||||
(( u8 *)(void *)(d))[1] = ((u8 *)(void *)(s))[0];}
|
||||
(( u8 *)(void *)(d))[1] = ((u8 *)(void *)(s))[0];}
|
||||
|
||||
#define ACPI_MOVE_16_TO_32(d, s) {(*(u32 *)(void *)(d))=0;\
|
||||
((u8 *)(void *)(d))[2] = ((u8 *)(void *)(s))[1];\
|
||||
((u8 *)(void *)(d))[3] = ((u8 *)(void *)(s))[0];}
|
||||
((u8 *)(void *)(d))[2] = ((u8 *)(void *)(s))[1];\
|
||||
((u8 *)(void *)(d))[3] = ((u8 *)(void *)(s))[0];}
|
||||
|
||||
#define ACPI_MOVE_16_TO_64(d, s) {(*(u64 *)(void *)(d))=0;\
|
||||
((u8 *)(void *)(d))[6] = ((u8 *)(void *)(s))[1];\
|
||||
((u8 *)(void *)(d))[7] = ((u8 *)(void *)(s))[0];}
|
||||
((u8 *)(void *)(d))[6] = ((u8 *)(void *)(s))[1];\
|
||||
((u8 *)(void *)(d))[7] = ((u8 *)(void *)(s))[0];}
|
||||
|
||||
/* 32-bit source, 16/32/64 destination */
|
||||
|
||||
#define ACPI_MOVE_32_TO_16(d, s) ACPI_MOVE_16_TO_16(d, s) /* Truncate to 16 */
|
||||
|
||||
#define ACPI_MOVE_32_TO_32(d, s) {(( u8 *)(void *)(d))[0] = ((u8 *)(void *)(s))[3];\
|
||||
(( u8 *)(void *)(d))[1] = ((u8 *)(void *)(s))[2];\
|
||||
(( u8 *)(void *)(d))[2] = ((u8 *)(void *)(s))[1];\
|
||||
(( u8 *)(void *)(d))[3] = ((u8 *)(void *)(s))[0];}
|
||||
(( u8 *)(void *)(d))[1] = ((u8 *)(void *)(s))[2];\
|
||||
(( u8 *)(void *)(d))[2] = ((u8 *)(void *)(s))[1];\
|
||||
(( u8 *)(void *)(d))[3] = ((u8 *)(void *)(s))[0];}
|
||||
|
||||
#define ACPI_MOVE_32_TO_64(d, s) {(*(u64 *)(void *)(d))=0;\
|
||||
((u8 *)(void *)(d))[4] = ((u8 *)(void *)(s))[3];\
|
||||
@@ -196,24 +196,12 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* Macros based on machine integer width */
|
||||
|
||||
#if ACPI_MACHINE_WIDTH == 32
|
||||
#define ACPI_MOVE_SIZE_TO_16(d, s) ACPI_MOVE_32_TO_16(d, s)
|
||||
|
||||
#elif ACPI_MACHINE_WIDTH == 64
|
||||
#define ACPI_MOVE_SIZE_TO_16(d, s) ACPI_MOVE_64_TO_16(d, s)
|
||||
|
||||
#else
|
||||
#error unknown ACPI_MACHINE_WIDTH
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Fast power-of-two math macros for non-optimized compilers
|
||||
*/
|
||||
#define _ACPI_DIV(value, power_of2) ((u32) ((value) >> (power_of2)))
|
||||
#define _ACPI_MUL(value, power_of2) ((u32) ((value) << (power_of2)))
|
||||
#define _ACPI_MOD(value, divisor) ((u32) ((value) & ((divisor) -1)))
|
||||
#define _ACPI_DIV(value, power_of2) ((u32) ((value) >> (power_of2)))
|
||||
#define _ACPI_MUL(value, power_of2) ((u32) ((value) << (power_of2)))
|
||||
#define _ACPI_MOD(value, divisor) ((u32) ((value) & ((divisor) -1)))
|
||||
|
||||
#define ACPI_DIV_2(a) _ACPI_DIV(a, 1)
|
||||
#define ACPI_MUL_2(a) _ACPI_MUL(a, 1)
|
||||
@@ -238,12 +226,12 @@
|
||||
/*
|
||||
* Rounding macros (Power of two boundaries only)
|
||||
*/
|
||||
#define ACPI_ROUND_DOWN(value, boundary) (((acpi_size)(value)) & \
|
||||
(~(((acpi_size) boundary)-1)))
|
||||
#define ACPI_ROUND_DOWN(value, boundary) (((acpi_size)(value)) & \
|
||||
(~(((acpi_size) boundary)-1)))
|
||||
|
||||
#define ACPI_ROUND_UP(value, boundary) ((((acpi_size)(value)) + \
|
||||
(((acpi_size) boundary)-1)) & \
|
||||
(~(((acpi_size) boundary)-1)))
|
||||
#define ACPI_ROUND_UP(value, boundary) ((((acpi_size)(value)) + \
|
||||
(((acpi_size) boundary)-1)) & \
|
||||
(~(((acpi_size) boundary)-1)))
|
||||
|
||||
/* Note: sizeof(acpi_size) evaluates to either 4 or 8 (32- vs 64-bit mode) */
|
||||
|
||||
@@ -264,7 +252,7 @@
|
||||
|
||||
#define ACPI_ROUND_UP_TO(value, boundary) (((value) + ((boundary)-1)) / (boundary))
|
||||
|
||||
#define ACPI_IS_MISALIGNED(value) (((acpi_size) value) & (sizeof(acpi_size)-1))
|
||||
#define ACPI_IS_MISALIGNED(value) (((acpi_size) value) & (sizeof(acpi_size)-1))
|
||||
|
||||
/*
|
||||
* Bitmask creation
|
||||
@@ -355,7 +343,6 @@
|
||||
* Ascii error messages can be configured out
|
||||
*/
|
||||
#ifndef ACPI_NO_ERROR_MESSAGES
|
||||
|
||||
/*
|
||||
* Error reporting. Callers module and line number are inserted by AE_INFO,
|
||||
* the plist contains a set of parens to allow variable-length lists.
|
||||
@@ -375,18 +362,15 @@
|
||||
#define ACPI_WARN_PREDEFINED(plist)
|
||||
#define ACPI_INFO_PREDEFINED(plist)
|
||||
|
||||
#endif /* ACPI_NO_ERROR_MESSAGES */
|
||||
#endif /* ACPI_NO_ERROR_MESSAGES */
|
||||
|
||||
/*
|
||||
* Debug macros that are conditionally compiled
|
||||
*/
|
||||
#ifdef ACPI_DEBUG_OUTPUT
|
||||
|
||||
/*
|
||||
* Function entry tracing
|
||||
*/
|
||||
#ifdef CONFIG_ACPI_DEBUG_FUNC_TRACE
|
||||
|
||||
#define ACPI_FUNCTION_TRACE(a) ACPI_FUNCTION_NAME(a) \
|
||||
acpi_ut_trace(ACPI_DEBUG_PARAMETERS)
|
||||
#define ACPI_FUNCTION_TRACE_PTR(a, b) ACPI_FUNCTION_NAME(a) \
|
||||
@@ -464,45 +448,19 @@
|
||||
|
||||
#endif /* ACPI_SIMPLE_RETURN_MACROS */
|
||||
|
||||
#else /* !CONFIG_ACPI_DEBUG_FUNC_TRACE */
|
||||
|
||||
#define ACPI_FUNCTION_TRACE(a)
|
||||
#define ACPI_FUNCTION_TRACE_PTR(a,b)
|
||||
#define ACPI_FUNCTION_TRACE_U32(a,b)
|
||||
#define ACPI_FUNCTION_TRACE_STR(a,b)
|
||||
#define ACPI_FUNCTION_EXIT
|
||||
#define ACPI_FUNCTION_STATUS_EXIT(s)
|
||||
#define ACPI_FUNCTION_VALUE_EXIT(s)
|
||||
#define ACPI_FUNCTION_TRACE(a)
|
||||
#define ACPI_FUNCTION_ENTRY()
|
||||
|
||||
#define return_VOID return
|
||||
#define return_ACPI_STATUS(s) return(s)
|
||||
#define return_VALUE(s) return(s)
|
||||
#define return_UINT8(s) return(s)
|
||||
#define return_UINT32(s) return(s)
|
||||
#define return_PTR(s) return(s)
|
||||
|
||||
#endif /* CONFIG_ACPI_DEBUG_FUNC_TRACE */
|
||||
|
||||
/* Conditional execution */
|
||||
|
||||
#define ACPI_DEBUG_EXEC(a) a
|
||||
#define ACPI_NORMAL_EXEC(a)
|
||||
|
||||
#define ACPI_DEBUG_DEFINE(a) a;
|
||||
#define ACPI_DEBUG_ONLY_MEMBERS(a) a;
|
||||
#define _VERBOSE_STRUCTURES
|
||||
|
||||
/* Stack and buffer dumping */
|
||||
/* Various object display routines for debug */
|
||||
|
||||
#define ACPI_DUMP_STACK_ENTRY(a) acpi_ex_dump_operand((a), 0)
|
||||
#define ACPI_DUMP_OPERANDS(a, b, c) acpi_ex_dump_operands(a, b, c)
|
||||
|
||||
#define ACPI_DUMP_OPERANDS(a, b ,c) acpi_ex_dump_operands(a, b, c)
|
||||
#define ACPI_DUMP_ENTRY(a, b) acpi_ns_dump_entry (a, b)
|
||||
#define ACPI_DUMP_PATHNAME(a, b, c, d) acpi_ns_dump_pathname(a, b, c, d)
|
||||
#define ACPI_DUMP_RESOURCE_LIST(a) acpi_rs_dump_resource_list(a)
|
||||
#define ACPI_DUMP_BUFFER(a, b) acpi_ut_dump_buffer((u8 *) a, b, DB_BYTE_DISPLAY, _COMPONENT)
|
||||
#define ACPI_DUMP_BUFFER(a, b) acpi_ut_debug_dump_buffer((u8 *) a, b, DB_BYTE_DISPLAY, _COMPONENT)
|
||||
|
||||
#else
|
||||
/*
|
||||
@@ -510,25 +468,23 @@
|
||||
* leaving no executable debug code!
|
||||
*/
|
||||
#define ACPI_DEBUG_EXEC(a)
|
||||
#define ACPI_NORMAL_EXEC(a) a;
|
||||
|
||||
#define ACPI_DEBUG_DEFINE(a) do { } while(0)
|
||||
#define ACPI_DEBUG_ONLY_MEMBERS(a) do { } while(0)
|
||||
#define ACPI_FUNCTION_TRACE(a) do { } while(0)
|
||||
#define ACPI_FUNCTION_TRACE_PTR(a, b) do { } while(0)
|
||||
#define ACPI_FUNCTION_TRACE_U32(a, b) do { } while(0)
|
||||
#define ACPI_FUNCTION_TRACE_STR(a, b) do { } while(0)
|
||||
#define ACPI_FUNCTION_EXIT do { } while(0)
|
||||
#define ACPI_FUNCTION_STATUS_EXIT(s) do { } while(0)
|
||||
#define ACPI_FUNCTION_VALUE_EXIT(s) do { } while(0)
|
||||
#define ACPI_FUNCTION_ENTRY() do { } while(0)
|
||||
#define ACPI_DUMP_STACK_ENTRY(a) do { } while(0)
|
||||
#define ACPI_DUMP_OPERANDS(a, b, c) do { } while(0)
|
||||
#define ACPI_DUMP_ENTRY(a, b) do { } while(0)
|
||||
#define ACPI_DUMP_TABLES(a, b) do { } while(0)
|
||||
#define ACPI_DUMP_PATHNAME(a, b, c, d) do { } while(0)
|
||||
#define ACPI_DUMP_RESOURCE_LIST(a) do { } while(0)
|
||||
#define ACPI_DUMP_BUFFER(a, b) do { } while(0)
|
||||
#define ACPI_DEBUG_ONLY_MEMBERS(a)
|
||||
#define ACPI_FUNCTION_TRACE(a)
|
||||
#define ACPI_FUNCTION_TRACE_PTR(a, b)
|
||||
#define ACPI_FUNCTION_TRACE_U32(a, b)
|
||||
#define ACPI_FUNCTION_TRACE_STR(a, b)
|
||||
#define ACPI_FUNCTION_EXIT
|
||||
#define ACPI_FUNCTION_STATUS_EXIT(s)
|
||||
#define ACPI_FUNCTION_VALUE_EXIT(s)
|
||||
#define ACPI_FUNCTION_ENTRY()
|
||||
#define ACPI_DUMP_STACK_ENTRY(a)
|
||||
#define ACPI_DUMP_OPERANDS(a, b, c)
|
||||
#define ACPI_DUMP_ENTRY(a, b)
|
||||
#define ACPI_DUMP_TABLES(a, b)
|
||||
#define ACPI_DUMP_PATHNAME(a, b, c, d)
|
||||
#define ACPI_DUMP_BUFFER(a, b)
|
||||
#define ACPI_DEBUG_PRINT(pl)
|
||||
#define ACPI_DEBUG_PRINT_RAW(pl)
|
||||
|
||||
#define return_VOID return
|
||||
#define return_ACPI_STATUS(s) return(s)
|
||||
@@ -556,18 +512,6 @@
|
||||
#define ACPI_DEBUGGER_EXEC(a)
|
||||
#endif
|
||||
|
||||
#ifdef ACPI_DEBUG_OUTPUT
|
||||
/*
|
||||
* 1) Set name to blanks
|
||||
* 2) Copy the object name
|
||||
*/
|
||||
#define ACPI_ADD_OBJECT_NAME(a,b) ACPI_MEMSET (a->common.name, ' ', sizeof (a->common.name));\
|
||||
ACPI_STRNCPY (a->common.name, acpi_gbl_ns_type_names[b], sizeof (a->common.name))
|
||||
#else
|
||||
|
||||
#define ACPI_ADD_OBJECT_NAME(a,b)
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Memory allocation tracking (DEBUG ONLY)
|
||||
*/
|
||||
@@ -578,13 +522,13 @@
|
||||
/* Memory allocation */
|
||||
|
||||
#ifndef ACPI_ALLOCATE
|
||||
#define ACPI_ALLOCATE(a) acpi_ut_allocate((acpi_size)(a), ACPI_MEM_PARAMETERS)
|
||||
#define ACPI_ALLOCATE(a) acpi_ut_allocate((acpi_size) (a), ACPI_MEM_PARAMETERS)
|
||||
#endif
|
||||
#ifndef ACPI_ALLOCATE_ZEROED
|
||||
#define ACPI_ALLOCATE_ZEROED(a) acpi_ut_allocate_zeroed((acpi_size)(a), ACPI_MEM_PARAMETERS)
|
||||
#define ACPI_ALLOCATE_ZEROED(a) acpi_ut_allocate_zeroed((acpi_size) (a), ACPI_MEM_PARAMETERS)
|
||||
#endif
|
||||
#ifndef ACPI_FREE
|
||||
#define ACPI_FREE(a) acpio_os_free(a)
|
||||
#define ACPI_FREE(a) acpi_os_free(a)
|
||||
#endif
|
||||
#define ACPI_MEM_TRACKING(a)
|
||||
|
||||
@@ -592,16 +536,25 @@
|
||||
|
||||
/* Memory allocation */
|
||||
|
||||
#define ACPI_ALLOCATE(a) acpi_ut_allocate_and_track((acpi_size)(a), ACPI_MEM_PARAMETERS)
|
||||
#define ACPI_ALLOCATE_ZEROED(a) acpi_ut_allocate_zeroed_and_track((acpi_size)(a), ACPI_MEM_PARAMETERS)
|
||||
#define ACPI_ALLOCATE(a) acpi_ut_allocate_and_track((acpi_size) (a), ACPI_MEM_PARAMETERS)
|
||||
#define ACPI_ALLOCATE_ZEROED(a) acpi_ut_allocate_zeroed_and_track((acpi_size) (a), ACPI_MEM_PARAMETERS)
|
||||
#define ACPI_FREE(a) acpi_ut_free_and_track(a, ACPI_MEM_PARAMETERS)
|
||||
#define ACPI_MEM_TRACKING(a) a
|
||||
|
||||
#endif /* ACPI_DBG_TRACK_ALLOCATIONS */
|
||||
|
||||
/* Preemption point */
|
||||
#ifndef ACPI_PREEMPTION_POINT
|
||||
#define ACPI_PREEMPTION_POINT() /* no preemption */
|
||||
#endif
|
||||
/*
|
||||
* Macros used for ACPICA utilities only
|
||||
*/
|
||||
|
||||
/* Generate a UUID */
|
||||
|
||||
#define ACPI_INIT_UUID(a, b, c, d0, d1, d2, d3, d4, d5, d6, d7) \
|
||||
(a) & 0xFF, ((a) >> 8) & 0xFF, ((a) >> 16) & 0xFF, ((a) >> 24) & 0xFF, \
|
||||
(b) & 0xFF, ((b) >> 8) & 0xFF, \
|
||||
(c) & 0xFF, ((c) >> 8) & 0xFF, \
|
||||
(d0), (d1), (d2), (d3), (d4), (d5), (d6), (d7)
|
||||
|
||||
#define ACPI_IS_OCTAL_DIGIT(d) (((char)(d) >= '0') && ((char)(d) <= '7'))
|
||||
|
||||
#endif /* ACMACROS_H */
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
/******************************************************************************
|
||||
*
|
||||
* Name: acobject.h - Definition of union acpi_operand_object (Internal object only)
|
||||
@@ -179,7 +178,7 @@ struct acpi_object_method {
|
||||
union acpi_operand_object *mutex;
|
||||
u8 *aml_start;
|
||||
union {
|
||||
ACPI_INTERNAL_METHOD implementation;
|
||||
acpi_internal_method implementation;
|
||||
union acpi_operand_object *handler;
|
||||
} dispatch;
|
||||
|
||||
@@ -198,7 +197,7 @@ struct acpi_object_method {
|
||||
|
||||
/******************************************************************************
|
||||
*
|
||||
* Objects that can be notified. All share a common notify_info area.
|
||||
* Objects that can be notified. All share a common notify_info area.
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
@@ -235,7 +234,7 @@ ACPI_OBJECT_COMMON_HEADER ACPI_COMMON_NOTIFY_INFO};
|
||||
|
||||
/******************************************************************************
|
||||
*
|
||||
* Fields. All share a common header/info field.
|
||||
* Fields. All share a common header/info field.
|
||||
*
|
||||
*****************************************************************************/
|
||||
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
#define _UNK 0x6B
|
||||
|
||||
/*
|
||||
* Reserved ASCII characters. Do not use any of these for
|
||||
* Reserved ASCII characters. Do not use any of these for
|
||||
* internal opcodes, since they are used to differentiate
|
||||
* name strings from AML opcodes
|
||||
*/
|
||||
@@ -63,7 +63,7 @@
|
||||
#define _PFX 0x6D
|
||||
|
||||
/*
|
||||
* All AML opcodes and the parse-time arguments for each. Used by the AML
|
||||
* All AML opcodes and the parse-time arguments for each. Used by the AML
|
||||
* parser Each list is compressed into a 32-bit number and stored in the
|
||||
* master opcode table (in psopcode.c).
|
||||
*/
|
||||
@@ -193,7 +193,7 @@
|
||||
#define ARGP_ZERO_OP ARG_NONE
|
||||
|
||||
/*
|
||||
* All AML opcodes and the runtime arguments for each. Used by the AML
|
||||
* All AML opcodes and the runtime arguments for each. Used by the AML
|
||||
* interpreter Each list is compressed into a 32-bit number and stored
|
||||
* in the master opcode table (in psopcode.c).
|
||||
*
|
||||
|
||||
@@ -150,8 +150,7 @@ u8 acpi_ps_has_completed_scope(struct acpi_parse_state *parser_state);
|
||||
|
||||
void
|
||||
acpi_ps_pop_scope(struct acpi_parse_state *parser_state,
|
||||
union acpi_parse_object **op,
|
||||
u32 * arg_list, u32 * arg_count);
|
||||
union acpi_parse_object **op, u32 *arg_list, u32 *arg_count);
|
||||
|
||||
acpi_status
|
||||
acpi_ps_push_scope(struct acpi_parse_state *parser_state,
|
||||
|
||||
@@ -150,8 +150,7 @@ enum acpi_return_package_types {
|
||||
* is saved here (rather than in a separate table) in order to minimize the
|
||||
* overall size of the stored data.
|
||||
*/
|
||||
static const union acpi_predefined_info predefined_names[] =
|
||||
{
|
||||
static const union acpi_predefined_info predefined_names[] = {
|
||||
{{"_AC0", 0, ACPI_RTYPE_INTEGER}},
|
||||
{{"_AC1", 0, ACPI_RTYPE_INTEGER}},
|
||||
{{"_AC2", 0, ACPI_RTYPE_INTEGER}},
|
||||
@@ -538,7 +537,8 @@ static const union acpi_predefined_info predefined_names[] =
|
||||
|
||||
/* Acpi 1.0 defined _WAK with no return value. Later, it was changed to return a package */
|
||||
|
||||
{{"_WAK", 1, ACPI_RTYPE_NONE | ACPI_RTYPE_INTEGER | ACPI_RTYPE_PACKAGE}},
|
||||
{{"_WAK", 1,
|
||||
ACPI_RTYPE_NONE | ACPI_RTYPE_INTEGER | ACPI_RTYPE_PACKAGE}},
|
||||
{{{ACPI_PTYPE1_FIXED, ACPI_RTYPE_INTEGER, 2,0}, 0,0}}, /* Fixed-length (2 Int), but is optional */
|
||||
|
||||
/* _WDG/_WED are MS extensions defined by "Windows Instrumentation" */
|
||||
@@ -551,11 +551,12 @@ static const union acpi_predefined_info predefined_names[] =
|
||||
};
|
||||
|
||||
#if 0
|
||||
|
||||
/* This is an internally implemented control method, no need to check */
|
||||
{{"_OSI", 1, ACPI_RTYPE_INTEGER}},
|
||||
{ {
|
||||
"_OSI", 1, ACPI_RTYPE_INTEGER}},
|
||||
|
||||
/* TBD: */
|
||||
|
||||
_PRT - currently ignore reversed entries. attempt to fix here?
|
||||
think about possibly fixing package elements like _BIF, etc.
|
||||
#endif
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
****************************************************************************/
|
||||
|
||||
/*
|
||||
* Walk state - current state of a parse tree walk. Used for both a leisurely
|
||||
* Walk state - current state of a parse tree walk. Used for both a leisurely
|
||||
* stroll through the tree (for whatever reason), and for control method
|
||||
* execution.
|
||||
*/
|
||||
|
||||
@@ -69,6 +69,22 @@ extern const char *acpi_gbl_siz_decode[];
|
||||
extern const char *acpi_gbl_trs_decode[];
|
||||
extern const char *acpi_gbl_ttp_decode[];
|
||||
extern const char *acpi_gbl_typ_decode[];
|
||||
extern const char *acpi_gbl_ppc_decode[];
|
||||
extern const char *acpi_gbl_ior_decode[];
|
||||
extern const char *acpi_gbl_dts_decode[];
|
||||
extern const char *acpi_gbl_ct_decode[];
|
||||
extern const char *acpi_gbl_sbt_decode[];
|
||||
extern const char *acpi_gbl_am_decode[];
|
||||
extern const char *acpi_gbl_sm_decode[];
|
||||
extern const char *acpi_gbl_wm_decode[];
|
||||
extern const char *acpi_gbl_cph_decode[];
|
||||
extern const char *acpi_gbl_cpo_decode[];
|
||||
extern const char *acpi_gbl_dp_decode[];
|
||||
extern const char *acpi_gbl_ed_decode[];
|
||||
extern const char *acpi_gbl_bpb_decode[];
|
||||
extern const char *acpi_gbl_sb_decode[];
|
||||
extern const char *acpi_gbl_fc_decode[];
|
||||
extern const char *acpi_gbl_pt_decode[];
|
||||
#endif
|
||||
|
||||
/* Types for Resource descriptor entries */
|
||||
@@ -79,14 +95,14 @@ extern const char *acpi_gbl_typ_decode[];
|
||||
#define ACPI_SMALL_VARIABLE_LENGTH 3
|
||||
|
||||
typedef
|
||||
acpi_status(*acpi_walk_aml_callback) (u8 * aml,
|
||||
acpi_status(*acpi_walk_aml_callback) (u8 *aml,
|
||||
u32 length,
|
||||
u32 offset,
|
||||
u8 resource_index, void **context);
|
||||
|
||||
typedef
|
||||
acpi_status(*acpi_pkg_callback) (u8 object_type,
|
||||
union acpi_operand_object * source_object,
|
||||
union acpi_operand_object *source_object,
|
||||
union acpi_generic_state * state,
|
||||
void *context);
|
||||
|
||||
@@ -202,7 +218,9 @@ extern const u8 _acpi_ctype[];
|
||||
#define ACPI_IS_PRINT(c) (_acpi_ctype[(unsigned char)(c)] & (_ACPI_LO | _ACPI_UP | _ACPI_DI | _ACPI_SP | _ACPI_PU))
|
||||
#define ACPI_IS_ALPHA(c) (_acpi_ctype[(unsigned char)(c)] & (_ACPI_LO | _ACPI_UP))
|
||||
|
||||
#endif /* ACPI_USE_SYSTEM_CLIBRARY */
|
||||
#endif /* !ACPI_USE_SYSTEM_CLIBRARY */
|
||||
|
||||
#define ACPI_IS_ASCII(c) ((c) < 0x80)
|
||||
|
||||
/*
|
||||
* utcopy - Object construction and conversion interfaces
|
||||
@@ -210,11 +228,11 @@ extern const u8 _acpi_ctype[];
|
||||
acpi_status
|
||||
acpi_ut_build_simple_object(union acpi_operand_object *obj,
|
||||
union acpi_object *user_obj,
|
||||
u8 * data_space, u32 * buffer_space_used);
|
||||
u8 *data_space, u32 *buffer_space_used);
|
||||
|
||||
acpi_status
|
||||
acpi_ut_build_package_object(union acpi_operand_object *obj,
|
||||
u8 * buffer, u32 * space_used);
|
||||
u8 *buffer, u32 *space_used);
|
||||
|
||||
acpi_status
|
||||
acpi_ut_copy_iobject_to_eobject(union acpi_operand_object *obj,
|
||||
@@ -287,9 +305,10 @@ acpi_ut_ptr_exit(u32 line_number,
|
||||
const char *function_name,
|
||||
const char *module_name, u32 component_id, u8 *ptr);
|
||||
|
||||
void acpi_ut_dump_buffer(u8 * buffer, u32 count, u32 display, u32 component_id);
|
||||
void
|
||||
acpi_ut_debug_dump_buffer(u8 *buffer, u32 count, u32 display, u32 component_id);
|
||||
|
||||
void acpi_ut_dump_buffer2(u8 * buffer, u32 count, u32 display);
|
||||
void acpi_ut_dump_buffer(u8 *buffer, u32 count, u32 display, u32 offset);
|
||||
|
||||
void acpi_ut_report_error(char *module_name, u32 line_number);
|
||||
|
||||
@@ -337,15 +356,19 @@ acpi_ut_execute_power_methods(struct acpi_namespace_node *device_node,
|
||||
*/
|
||||
acpi_status
|
||||
acpi_ut_execute_HID(struct acpi_namespace_node *device_node,
|
||||
struct acpica_device_id **return_id);
|
||||
struct acpi_pnp_device_id ** return_id);
|
||||
|
||||
acpi_status
|
||||
acpi_ut_execute_UID(struct acpi_namespace_node *device_node,
|
||||
struct acpica_device_id **return_id);
|
||||
struct acpi_pnp_device_id ** return_id);
|
||||
|
||||
acpi_status
|
||||
acpi_ut_execute_SUB(struct acpi_namespace_node *device_node,
|
||||
struct acpi_pnp_device_id **return_id);
|
||||
|
||||
acpi_status
|
||||
acpi_ut_execute_CID(struct acpi_namespace_node *device_node,
|
||||
struct acpica_device_id_list **return_cid_list);
|
||||
struct acpi_pnp_device_id_list ** return_cid_list);
|
||||
|
||||
/*
|
||||
* utlock - reader/writer locks
|
||||
@@ -479,15 +502,19 @@ acpi_ut_walk_package_tree(union acpi_operand_object *source_object,
|
||||
|
||||
void acpi_ut_strupr(char *src_string);
|
||||
|
||||
void acpi_ut_strlwr(char *src_string);
|
||||
|
||||
int acpi_ut_stricmp(char *string1, char *string2);
|
||||
|
||||
void acpi_ut_print_string(char *string, u8 max_length);
|
||||
|
||||
u8 acpi_ut_valid_acpi_name(u32 name);
|
||||
|
||||
acpi_name acpi_ut_repair_name(char *name);
|
||||
void acpi_ut_repair_name(char *name);
|
||||
|
||||
u8 acpi_ut_valid_acpi_char(char character, u32 position);
|
||||
|
||||
acpi_status acpi_ut_strtoul64(char *string, u32 base, u64 * ret_integer);
|
||||
acpi_status acpi_ut_strtoul64(char *string, u32 base, u64 *ret_integer);
|
||||
|
||||
/* Values for Base above (16=Hex, 10=Decimal) */
|
||||
|
||||
@@ -508,12 +535,12 @@ acpi_ut_display_init_pathname(u8 type,
|
||||
* utresrc
|
||||
*/
|
||||
acpi_status
|
||||
acpi_ut_walk_aml_resources(u8 * aml,
|
||||
acpi_ut_walk_aml_resources(u8 *aml,
|
||||
acpi_size aml_length,
|
||||
acpi_walk_aml_callback user_function,
|
||||
void **context);
|
||||
|
||||
acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index);
|
||||
acpi_status acpi_ut_validate_resource(void *aml, u8 *return_index);
|
||||
|
||||
u32 acpi_ut_get_descriptor_length(void *aml);
|
||||
|
||||
@@ -524,8 +551,7 @@ u8 acpi_ut_get_resource_header_length(void *aml);
|
||||
u8 acpi_ut_get_resource_type(void *aml);
|
||||
|
||||
acpi_status
|
||||
acpi_ut_get_resource_end_tag(union acpi_operand_object *obj_desc,
|
||||
u8 ** end_tag);
|
||||
acpi_ut_get_resource_end_tag(union acpi_operand_object *obj_desc, u8 **end_tag);
|
||||
|
||||
/*
|
||||
* utmutex - mutex support
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
/******************************************************************************
|
||||
*
|
||||
* Module Name: amlresrc.h - AML resource descriptors
|
||||
|
||||
@@ -280,7 +280,7 @@ acpi_ds_exec_end_control_op(struct acpi_walk_state * walk_state,
|
||||
|
||||
/*
|
||||
* Get the return value and save as the last result
|
||||
* value. This is the only place where walk_state->return_desc
|
||||
* value. This is the only place where walk_state->return_desc
|
||||
* is set to anything other than zero!
|
||||
*/
|
||||
walk_state->return_desc = walk_state->operands[0];
|
||||
|
||||
@@ -277,7 +277,7 @@ acpi_ds_create_buffer_field(union acpi_parse_object *op,
|
||||
*
|
||||
* RETURN: Status
|
||||
*
|
||||
* DESCRIPTION: Process all named fields in a field declaration. Names are
|
||||
* DESCRIPTION: Process all named fields in a field declaration. Names are
|
||||
* entered into the namespace.
|
||||
*
|
||||
******************************************************************************/
|
||||
|
||||
@@ -170,7 +170,7 @@ acpi_ds_create_method_mutex(union acpi_operand_object *method_desc)
|
||||
*
|
||||
* RETURN: Status
|
||||
*
|
||||
* DESCRIPTION: Prepare a method for execution. Parses the method if necessary,
|
||||
* DESCRIPTION: Prepare a method for execution. Parses the method if necessary,
|
||||
* increments the thread count, and waits at the method semaphore
|
||||
* for clearance to execute.
|
||||
*
|
||||
@@ -444,7 +444,7 @@ acpi_ds_call_control_method(struct acpi_thread_state *thread,
|
||||
* RETURN: Status
|
||||
*
|
||||
* DESCRIPTION: Restart a method that was preempted by another (nested) method
|
||||
* invocation. Handle the return value (if any) from the callee.
|
||||
* invocation. Handle the return value (if any) from the callee.
|
||||
*
|
||||
******************************************************************************/
|
||||
|
||||
@@ -530,7 +530,7 @@ acpi_ds_restart_control_method(struct acpi_walk_state *walk_state,
|
||||
*
|
||||
* RETURN: None
|
||||
*
|
||||
* DESCRIPTION: Terminate a control method. Delete everything that the method
|
||||
* DESCRIPTION: Terminate a control method. Delete everything that the method
|
||||
* created, delete all locals and arguments, and delete the parse
|
||||
* tree if requested.
|
||||
*
|
||||
|
||||
@@ -76,7 +76,7 @@ acpi_ds_method_data_get_type(u16 opcode,
|
||||
* RETURN: Status
|
||||
*
|
||||
* DESCRIPTION: Initialize the data structures that hold the method's arguments
|
||||
* and locals. The data struct is an array of namespace nodes for
|
||||
* and locals. The data struct is an array of namespace nodes for
|
||||
* each - this allows ref_of and de_ref_of to work properly for these
|
||||
* special data types.
|
||||
*
|
||||
@@ -129,7 +129,7 @@ void acpi_ds_method_data_init(struct acpi_walk_state *walk_state)
|
||||
*
|
||||
* RETURN: None
|
||||
*
|
||||
* DESCRIPTION: Delete method locals and arguments. Arguments are only
|
||||
* DESCRIPTION: Delete method locals and arguments. Arguments are only
|
||||
* deleted if this method was called from another method.
|
||||
*
|
||||
******************************************************************************/
|
||||
@@ -183,7 +183,7 @@ void acpi_ds_method_data_delete_all(struct acpi_walk_state *walk_state)
|
||||
*
|
||||
* RETURN: Status
|
||||
*
|
||||
* DESCRIPTION: Initialize arguments for a method. The parameter list is a list
|
||||
* DESCRIPTION: Initialize arguments for a method. The parameter list is a list
|
||||
* of ACPI operand objects, either null terminated or whose length
|
||||
* is defined by max_param_count.
|
||||
*
|
||||
@@ -401,7 +401,7 @@ acpi_ds_method_data_get_value(u8 type,
|
||||
* This means that either 1) The expected argument was
|
||||
* not passed to the method, or 2) A local variable
|
||||
* was referenced by the method (via the ASL)
|
||||
* before it was initialized. Either case is an error.
|
||||
* before it was initialized. Either case is an error.
|
||||
*/
|
||||
|
||||
/* If slack enabled, init the local_x/arg_x to an Integer of value zero */
|
||||
@@ -465,7 +465,7 @@ acpi_ds_method_data_get_value(u8 type,
|
||||
*
|
||||
* RETURN: None
|
||||
*
|
||||
* DESCRIPTION: Delete the entry at Opcode:Index. Inserts
|
||||
* DESCRIPTION: Delete the entry at Opcode:Index. Inserts
|
||||
* a null into the stack slot after the object is deleted.
|
||||
*
|
||||
******************************************************************************/
|
||||
@@ -523,7 +523,7 @@ acpi_ds_method_data_delete_value(u8 type,
|
||||
*
|
||||
* RETURN: Status
|
||||
*
|
||||
* DESCRIPTION: Store a value in an Arg or Local. The obj_desc is installed
|
||||
* DESCRIPTION: Store a value in an Arg or Local. The obj_desc is installed
|
||||
* as the new value for the Arg or Local and the reference count
|
||||
* for obj_desc is incremented.
|
||||
*
|
||||
@@ -566,7 +566,7 @@ acpi_ds_store_object_to_local(u8 type,
|
||||
|
||||
/*
|
||||
* If the reference count on the object is more than one, we must
|
||||
* take a copy of the object before we store. A reference count
|
||||
* take a copy of the object before we store. A reference count
|
||||
* of exactly 1 means that the object was just created during the
|
||||
* evaluation of an expression, and we can safely use it since it
|
||||
* is not used anywhere else.
|
||||
|
||||
@@ -293,7 +293,7 @@ acpi_ds_build_internal_buffer_obj(struct acpi_walk_state *walk_state,
|
||||
|
||||
/*
|
||||
* Second arg is the buffer data (optional) byte_list can be either
|
||||
* individual bytes or a string initializer. In either case, a
|
||||
* individual bytes or a string initializer. In either case, a
|
||||
* byte_list appears in the AML.
|
||||
*/
|
||||
arg = op->common.value.arg; /* skip first arg */
|
||||
@@ -568,7 +568,7 @@ acpi_ds_create_node(struct acpi_walk_state *walk_state,
|
||||
|
||||
/*
|
||||
* Because of the execution pass through the non-control-method
|
||||
* parts of the table, we can arrive here twice. Only init
|
||||
* parts of the table, we can arrive here twice. Only init
|
||||
* the named object node the first time through
|
||||
*/
|
||||
if (acpi_ns_get_attached_object(node)) {
|
||||
@@ -618,7 +618,7 @@ acpi_ds_create_node(struct acpi_walk_state *walk_state,
|
||||
* RETURN: Status
|
||||
*
|
||||
* DESCRIPTION: Initialize a namespace object from a parser Op and its
|
||||
* associated arguments. The namespace object is a more compact
|
||||
* associated arguments. The namespace object is a more compact
|
||||
* representation of the Op and its arguments.
|
||||
*
|
||||
******************************************************************************/
|
||||
|
||||
@@ -649,7 +649,8 @@ acpi_ds_eval_data_object_operands(struct acpi_walk_state *walk_state,
|
||||
((op->common.parent->common.aml_opcode != AML_PACKAGE_OP) &&
|
||||
(op->common.parent->common.aml_opcode !=
|
||||
AML_VAR_PACKAGE_OP)
|
||||
&& (op->common.parent->common.aml_opcode != AML_NAME_OP))) {
|
||||
&& (op->common.parent->common.aml_opcode !=
|
||||
AML_NAME_OP))) {
|
||||
walk_state->result_obj = obj_desc;
|
||||
}
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user