2 /******************************************************************************
4 * Name: acpixf.h - External interfaces to the ACPI subsystem
6 *****************************************************************************/
9 * Copyright (C) 2000 - 2004, R. Byron Moore
10 * All rights reserved.
12 * Redistribution and use in source and binary forms, with or without
13 * modification, are permitted provided that the following conditions
15 * 1. Redistributions of source code must retain the above copyright
16 * notice, this list of conditions, and the following disclaimer,
17 * without modification.
18 * 2. Redistributions in binary form must reproduce at minimum a disclaimer
19 * substantially similar to the "NO WARRANTY" disclaimer below
20 * ("Disclaimer") and any redistribution must be conditioned upon
21 * including a substantially similar Disclaimer requirement for further
22 * binary redistribution.
23 * 3. Neither the names of the above-listed copyright holders nor the names
24 * of any contributors may be used to endorse or promote products derived
25 * from this software without specific prior written permission.
27 * Alternatively, this software may be distributed under the terms of the
28 * GNU General Public License ("GPL") version 2 as published by the Free
29 * Software Foundation.
32 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
33 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
34 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
35 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
36 * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
37 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
38 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
39 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
40 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
41 * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
42 * POSSIBILITY OF SUCH DAMAGES.
58 acpi_initialize_subsystem (
62 acpi_enable_subsystem (
66 acpi_initialize_objects (
74 acpi_subsystem_status (
86 acpi_get_system_info (
87 struct acpi_buffer *ret_buffer);
90 acpi_format_exception (
91 acpi_status exception);
94 acpi_purge_cached_objects (
98 acpi_install_initialization_handler (
99 acpi_init_handler handler,
103 * ACPI Memory manager
120 * ACPI table manipulation interfaces
124 acpi_find_root_pointer (
126 struct acpi_pointer *rsdp_address);
134 struct acpi_table_header *table_ptr);
138 acpi_table_type table_type);
141 acpi_get_table_header (
142 acpi_table_type table_type,
144 struct acpi_table_header *out_table_header);
148 acpi_table_type table_type,
150 struct acpi_buffer *ret_buffer);
153 acpi_get_firmware_table (
154 acpi_string signature,
157 struct acpi_table_header **table_pointer);
161 * Namespace and name interfaces
165 acpi_walk_namespace (
166 acpi_object_type type,
167 acpi_handle start_object,
169 acpi_walk_callback user_function,
171 void **return_value);
176 acpi_walk_callback user_function,
178 void **return_value);
184 struct acpi_buffer *ret_path_ptr);
189 acpi_string pathname,
190 acpi_handle *ret_handle);
194 acpi_handle obj_handle,
195 acpi_object_handler handler,
200 acpi_handle obj_handle,
201 acpi_object_handler handler);
205 acpi_handle obj_handle,
206 acpi_object_handler handler,
211 * Object manipulation and enumeration
215 acpi_evaluate_object (
217 acpi_string pathname,
218 struct acpi_object_list *parameter_objects,
219 struct acpi_buffer *return_object_buffer);
222 acpi_evaluate_object_typed (
224 acpi_string pathname,
225 struct acpi_object_list *external_params,
226 struct acpi_buffer *return_buffer,
227 acpi_object_type return_type);
230 acpi_get_object_info (
232 struct acpi_buffer *return_buffer);
235 acpi_get_next_object (
236 acpi_object_type type,
239 acpi_handle *out_handle);
244 acpi_object_type *out_type);
249 acpi_handle *out_handle);
253 * Event handler interfaces
257 acpi_install_fixed_event_handler (
259 acpi_event_handler handler,
263 acpi_remove_fixed_event_handler (
265 acpi_event_handler handler);
268 acpi_install_notify_handler (
271 acpi_notify_handler handler,
275 acpi_remove_notify_handler (
278 acpi_notify_handler handler);
281 acpi_install_address_space_handler (
283 acpi_adr_space_type space_id,
284 acpi_adr_space_handler handler,
285 acpi_adr_space_setup setup,
289 acpi_remove_address_space_handler (
291 acpi_adr_space_type space_id,
292 acpi_adr_space_handler handler);
295 acpi_install_gpe_handler (
296 acpi_handle gpe_device,
299 acpi_gpe_handler handler,
303 acpi_acquire_global_lock (
308 acpi_release_global_lock (
312 acpi_remove_gpe_handler (
313 acpi_handle gpe_device,
315 acpi_gpe_handler handler);
332 acpi_get_event_status (
334 acpi_event_status *event_status);
338 acpi_handle gpe_device,
344 acpi_handle gpe_device,
350 acpi_handle gpe_device,
355 acpi_get_gpe_status (
356 acpi_handle gpe_device,
359 acpi_event_status *event_status);
362 acpi_install_gpe_block (
363 acpi_handle gpe_device,
364 struct acpi_generic_address *gpe_block_address,
366 u32 interrupt_level);
369 acpi_remove_gpe_block (
370 acpi_handle gpe_device);
374 * Resource interfaces
378 acpi_status (*ACPI_WALK_RESOURCE_CALLBACK) (
379 struct acpi_resource *resource,
384 acpi_get_current_resources(
385 acpi_handle device_handle,
386 struct acpi_buffer *ret_buffer);
389 acpi_get_possible_resources(
390 acpi_handle device_handle,
391 struct acpi_buffer *ret_buffer);
394 acpi_walk_resources (
395 acpi_handle device_handle,
397 ACPI_WALK_RESOURCE_CALLBACK user_function,
401 acpi_set_current_resources (
402 acpi_handle device_handle,
403 struct acpi_buffer *in_buffer);
406 acpi_get_irq_routing_table (
407 acpi_handle bus_device_handle,
408 struct acpi_buffer *ret_buffer);
411 acpi_resource_to_address64 (
412 struct acpi_resource *resource,
413 struct acpi_resource_address64 *out);
416 * Hardware (ACPI device) interfaces
432 acpi_set_firmware_waking_vector (
433 acpi_physical_address physical_address);
436 acpi_get_firmware_waking_vector (
437 acpi_physical_address *physical_address);
440 acpi_get_sleep_type_data (
446 acpi_enter_sleep_state_prep (
449 acpi_status asmlinkage
450 acpi_enter_sleep_state (
453 acpi_status asmlinkage
454 acpi_enter_sleep_state_s4bios (
458 acpi_leave_sleep_state (
462 #endif /* __ACXFACE_H__ */