diff options
Diffstat (limited to 'include/acpi/acglobal.h')
| -rw-r--r-- | include/acpi/acglobal.h | 117 |
1 files changed, 52 insertions, 65 deletions
diff --git a/include/acpi/acglobal.h b/include/acpi/acglobal.h index 06972e6637de..24c3f05ab367 100644 --- a/include/acpi/acglobal.h +++ b/include/acpi/acglobal.h | |||
| @@ -5,7 +5,7 @@ | |||
| 5 | *****************************************************************************/ | 5 | *****************************************************************************/ |
| 6 | 6 | ||
| 7 | /* | 7 | /* |
| 8 | * Copyright (C) 2000 - 2006, R. Byron Moore | 8 | * Copyright (C) 2000 - 2007, R. Byron Moore |
| 9 | * All rights reserved. | 9 | * All rights reserved. |
| 10 | * | 10 | * |
| 11 | * Redistribution and use in source and binary forms, with or without | 11 | * Redistribution and use in source and binary forms, with or without |
| @@ -58,37 +58,6 @@ | |||
| 58 | #define ACPI_INIT_GLOBAL(a,b) a | 58 | #define ACPI_INIT_GLOBAL(a,b) a |
| 59 | #endif | 59 | #endif |
| 60 | 60 | ||
| 61 | /* | ||
| 62 | * Keep local copies of these FADT-based registers. NOTE: These globals | ||
| 63 | * are first in this file for alignment reasons on 64-bit systems. | ||
| 64 | */ | ||
| 65 | ACPI_EXTERN struct acpi_generic_address acpi_gbl_xpm1a_enable; | ||
| 66 | ACPI_EXTERN struct acpi_generic_address acpi_gbl_xpm1b_enable; | ||
| 67 | |||
| 68 | /***************************************************************************** | ||
| 69 | * | ||
| 70 | * Debug support | ||
| 71 | * | ||
| 72 | ****************************************************************************/ | ||
| 73 | |||
| 74 | /* Runtime configuration of debug print levels */ | ||
| 75 | |||
| 76 | extern u32 acpi_dbg_level; | ||
| 77 | extern u32 acpi_dbg_layer; | ||
| 78 | |||
| 79 | /* Procedure nesting level for debug output */ | ||
| 80 | |||
| 81 | extern u32 acpi_gbl_nesting_level; | ||
| 82 | |||
| 83 | /* Support for dynamic control method tracing mechanism */ | ||
| 84 | |||
| 85 | ACPI_EXTERN u32 acpi_gbl_original_dbg_level; | ||
| 86 | ACPI_EXTERN u32 acpi_gbl_original_dbg_layer; | ||
| 87 | ACPI_EXTERN acpi_name acpi_gbl_trace_method_name; | ||
| 88 | ACPI_EXTERN u32 acpi_gbl_trace_dbg_level; | ||
| 89 | ACPI_EXTERN u32 acpi_gbl_trace_dbg_layer; | ||
| 90 | ACPI_EXTERN u32 acpi_gbl_trace_flags; | ||
| 91 | |||
| 92 | /***************************************************************************** | 61 | /***************************************************************************** |
| 93 | * | 62 | * |
| 94 | * Runtime configuration (static defaults that can be overriden at runtime) | 63 | * Runtime configuration (static defaults that can be overriden at runtime) |
| @@ -135,52 +104,62 @@ ACPI_EXTERN u8 ACPI_INIT_GLOBAL(acpi_gbl_leave_wake_gpes_disabled, TRUE); | |||
| 135 | 104 | ||
| 136 | /***************************************************************************** | 105 | /***************************************************************************** |
| 137 | * | 106 | * |
| 107 | * Debug support | ||
| 108 | * | ||
| 109 | ****************************************************************************/ | ||
| 110 | |||
| 111 | /* Runtime configuration of debug print levels */ | ||
| 112 | |||
| 113 | extern u32 acpi_dbg_level; | ||
| 114 | extern u32 acpi_dbg_layer; | ||
| 115 | |||
| 116 | /* Procedure nesting level for debug output */ | ||
| 117 | |||
| 118 | extern u32 acpi_gbl_nesting_level; | ||
| 119 | |||
| 120 | /* Event counters */ | ||
| 121 | |||
| 122 | ACPI_EXTERN u32 acpi_gpe_count; | ||
| 123 | |||
| 124 | /* Support for dynamic control method tracing mechanism */ | ||
| 125 | |||
| 126 | ACPI_EXTERN u32 acpi_gbl_original_dbg_level; | ||
| 127 | ACPI_EXTERN u32 acpi_gbl_original_dbg_layer; | ||
| 128 | ACPI_EXTERN acpi_name acpi_gbl_trace_method_name; | ||
| 129 | ACPI_EXTERN u32 acpi_gbl_trace_dbg_level; | ||
| 130 | ACPI_EXTERN u32 acpi_gbl_trace_dbg_layer; | ||
| 131 | ACPI_EXTERN u32 acpi_gbl_trace_flags; | ||
| 132 | |||
| 133 | /***************************************************************************** | ||
| 134 | * | ||
| 138 | * ACPI Table globals | 135 | * ACPI Table globals |
| 139 | * | 136 | * |
| 140 | ****************************************************************************/ | 137 | ****************************************************************************/ |
| 141 | 138 | ||
| 142 | /* | 139 | /* |
| 143 | * Table pointers. | 140 | * acpi_gbl_root_table_list is the master list of ACPI tables found in the |
| 144 | * Although these pointers are somewhat redundant with the global acpi_table, | 141 | * RSDT/XSDT. |
| 145 | * they are convenient because they are typed pointers. | ||
| 146 | * | 142 | * |
| 147 | * These tables are single-table only; meaning that there can be at most one | 143 | * acpi_gbl_FADT is a local copy of the FADT, converted to a common format. |
| 148 | * of each in the system. Each global points to the actual table. | ||
| 149 | */ | ||
| 150 | ACPI_EXTERN u32 acpi_gbl_table_flags; | ||
| 151 | ACPI_EXTERN u32 acpi_gbl_rsdt_table_count; | ||
| 152 | ACPI_EXTERN struct rsdp_descriptor *acpi_gbl_RSDP; | ||
| 153 | ACPI_EXTERN struct xsdt_descriptor *acpi_gbl_XSDT; | ||
| 154 | ACPI_EXTERN struct fadt_descriptor *acpi_gbl_FADT; | ||
| 155 | ACPI_EXTERN struct acpi_table_header *acpi_gbl_DSDT; | ||
| 156 | ACPI_EXTERN struct facs_descriptor *acpi_gbl_FACS; | ||
| 157 | ACPI_EXTERN struct acpi_common_facs acpi_gbl_common_fACS; | ||
| 158 | /* | ||
| 159 | * Since there may be multiple SSDTs and PSDTs, a single pointer is not | ||
| 160 | * sufficient; Therefore, there isn't one! | ||
| 161 | */ | 144 | */ |
| 145 | ACPI_EXTERN struct acpi_internal_rsdt acpi_gbl_root_table_list; | ||
| 146 | ACPI_EXTERN struct acpi_table_fadt acpi_gbl_FADT; | ||
| 147 | extern acpi_native_uint acpi_gbl_permanent_mmap; | ||
| 162 | 148 | ||
| 163 | /* The root table can be either an RSDT or an XSDT */ | 149 | /* These addresses are calculated from FADT address values */ |
| 164 | 150 | ||
| 165 | ACPI_EXTERN u8 acpi_gbl_root_table_type; | 151 | ACPI_EXTERN struct acpi_generic_address acpi_gbl_xpm1a_enable; |
| 166 | #define ACPI_TABLE_TYPE_RSDT 'R' | 152 | ACPI_EXTERN struct acpi_generic_address acpi_gbl_xpm1b_enable; |
| 167 | #define ACPI_TABLE_TYPE_XSDT 'X' | ||
| 168 | 153 | ||
| 169 | /* | 154 | /* |
| 170 | * Handle both ACPI 1.0 and ACPI 2.0 Integer widths: | 155 | * Handle both ACPI 1.0 and ACPI 2.0 Integer widths. The integer width is |
| 171 | * If we are executing a method that exists in a 32-bit ACPI table, | 156 | * determined by the revision of the DSDT: If the DSDT revision is less than |
| 172 | * use only the lower 32 bits of the (internal) 64-bit Integer. | 157 | * 2, use only the lower 32 bits of the internal 64-bit Integer. |
| 173 | */ | 158 | */ |
| 174 | ACPI_EXTERN u8 acpi_gbl_integer_bit_width; | 159 | ACPI_EXTERN u8 acpi_gbl_integer_bit_width; |
| 175 | ACPI_EXTERN u8 acpi_gbl_integer_byte_width; | 160 | ACPI_EXTERN u8 acpi_gbl_integer_byte_width; |
| 176 | ACPI_EXTERN u8 acpi_gbl_integer_nybble_width; | 161 | ACPI_EXTERN u8 acpi_gbl_integer_nybble_width; |
| 177 | 162 | ||
| 178 | /* | ||
| 179 | * ACPI Table info arrays | ||
| 180 | */ | ||
| 181 | extern struct acpi_table_list acpi_gbl_table_lists[ACPI_TABLE_ID_MAX + 1]; | ||
| 182 | extern struct acpi_table_support acpi_gbl_table_data[ACPI_TABLE_ID_MAX + 1]; | ||
| 183 | |||
| 184 | /***************************************************************************** | 163 | /***************************************************************************** |
| 185 | * | 164 | * |
| 186 | * Mutual exlusion within ACPICA subsystem | 165 | * Mutual exlusion within ACPICA subsystem |
| @@ -188,7 +167,7 @@ extern struct acpi_table_support acpi_gbl_table_data[ACPI_TABLE_ID_MAX + 1]; | |||
| 188 | ****************************************************************************/ | 167 | ****************************************************************************/ |
| 189 | 168 | ||
| 190 | /* | 169 | /* |
| 191 | * Predefined mutex objects. This array contains the | 170 | * Predefined mutex objects. This array contains the |
| 192 | * actual OS mutex handles, indexed by the local ACPI_MUTEX_HANDLEs. | 171 | * actual OS mutex handles, indexed by the local ACPI_MUTEX_HANDLEs. |
| 193 | * (The table maps local handles to the real OS handles) | 172 | * (The table maps local handles to the real OS handles) |
| 194 | */ | 173 | */ |
| @@ -197,6 +176,7 @@ ACPI_EXTERN struct acpi_mutex_info acpi_gbl_mutex_info[ACPI_NUM_MUTEX]; | |||
| 197 | /* | 176 | /* |
| 198 | * Global lock semaphore works in conjunction with the actual HW global lock | 177 | * Global lock semaphore works in conjunction with the actual HW global lock |
| 199 | */ | 178 | */ |
| 179 | ACPI_EXTERN acpi_mutex acpi_gbl_global_lock_mutex; | ||
| 200 | ACPI_EXTERN acpi_semaphore acpi_gbl_global_lock_semaphore; | 180 | ACPI_EXTERN acpi_semaphore acpi_gbl_global_lock_semaphore; |
| 201 | 181 | ||
| 202 | /* | 182 | /* |
| @@ -220,6 +200,7 @@ ACPI_EXTERN spinlock_t _acpi_gbl_hardware_lock; /* For ACPI H/W except GPE regis | |||
| 220 | 200 | ||
| 221 | ACPI_EXTERN struct acpi_memory_list *acpi_gbl_global_list; | 201 | ACPI_EXTERN struct acpi_memory_list *acpi_gbl_global_list; |
| 222 | ACPI_EXTERN struct acpi_memory_list *acpi_gbl_ns_node_list; | 202 | ACPI_EXTERN struct acpi_memory_list *acpi_gbl_ns_node_list; |
| 203 | ACPI_EXTERN u8 acpi_gbl_display_final_mem_stats; | ||
| 223 | #endif | 204 | #endif |
| 224 | 205 | ||
| 225 | /* Object caches */ | 206 | /* Object caches */ |
| @@ -240,7 +221,6 @@ ACPI_EXTERN struct acpi_walk_state *acpi_gbl_breakpoint_walk; | |||
| 240 | 221 | ||
| 241 | /* Misc */ | 222 | /* Misc */ |
| 242 | 223 | ||
| 243 | ACPI_EXTERN u32 acpi_gbl_global_lock_thread_count; | ||
| 244 | ACPI_EXTERN u32 acpi_gbl_original_mode; | 224 | ACPI_EXTERN u32 acpi_gbl_original_mode; |
| 245 | ACPI_EXTERN u32 acpi_gbl_rsdp_original_location; | 225 | ACPI_EXTERN u32 acpi_gbl_rsdp_original_location; |
| 246 | ACPI_EXTERN u32 acpi_gbl_ns_lookup_count; | 226 | ACPI_EXTERN u32 acpi_gbl_ns_lookup_count; |
| @@ -260,12 +240,19 @@ ACPI_EXTERN u8 acpi_gbl_system_awake_and_running; | |||
| 260 | 240 | ||
| 261 | extern u8 acpi_gbl_shutdown; | 241 | extern u8 acpi_gbl_shutdown; |
| 262 | extern u32 acpi_gbl_startup_flags; | 242 | extern u32 acpi_gbl_startup_flags; |
| 263 | extern const u8 acpi_gbl_decode_to8bit[8]; | ||
| 264 | extern const char *acpi_gbl_sleep_state_names[ACPI_S_STATE_COUNT]; | 243 | extern const char *acpi_gbl_sleep_state_names[ACPI_S_STATE_COUNT]; |
| 265 | extern const char *acpi_gbl_highest_dstate_names[4]; | 244 | extern const char *acpi_gbl_highest_dstate_names[4]; |
| 266 | extern const struct acpi_opcode_info acpi_gbl_aml_op_info[AML_NUM_OPCODES]; | 245 | extern const struct acpi_opcode_info acpi_gbl_aml_op_info[AML_NUM_OPCODES]; |
| 267 | extern const char *acpi_gbl_region_types[ACPI_NUM_PREDEFINED_REGIONS]; | 246 | extern const char *acpi_gbl_region_types[ACPI_NUM_PREDEFINED_REGIONS]; |
| 268 | 247 | ||
| 248 | /* Exception codes */ | ||
| 249 | |||
| 250 | extern char const *acpi_gbl_exception_names_env[]; | ||
| 251 | extern char const *acpi_gbl_exception_names_pgm[]; | ||
| 252 | extern char const *acpi_gbl_exception_names_tbl[]; | ||
| 253 | extern char const *acpi_gbl_exception_names_aml[]; | ||
| 254 | extern char const *acpi_gbl_exception_names_ctrl[]; | ||
| 255 | |||
| 269 | /***************************************************************************** | 256 | /***************************************************************************** |
| 270 | * | 257 | * |
| 271 | * Namespace globals | 258 | * Namespace globals |
