aboutsummaryrefslogtreecommitdiffstats
path: root/include/acpi
diff options
context:
space:
mode:
Diffstat (limited to 'include/acpi')
-rw-r--r--include/acpi/acpi_bus.h5
-rw-r--r--include/acpi/acpixf.h20
-rw-r--r--include/acpi/actypes.h52
3 files changed, 49 insertions, 28 deletions
diff --git a/include/acpi/acpi_bus.h b/include/acpi/acpi_bus.h
index f2499f572109..20b05cd68663 100644
--- a/include/acpi/acpi_bus.h
+++ b/include/acpi/acpi_bus.h
@@ -149,8 +149,7 @@ struct acpi_device_flags {
149 u32 power_manageable:1; 149 u32 power_manageable:1;
150 u32 performance_manageable:1; 150 u32 performance_manageable:1;
151 u32 wake_capable:1; /* Wakeup(_PRW) supported? */ 151 u32 wake_capable:1; /* Wakeup(_PRW) supported? */
152 u32 force_power_state:1; 152 u32 reserved:23;
153 u32 reserved:22;
154}; 153};
155 154
156/* File System */ 155/* File System */
@@ -322,8 +321,8 @@ void acpi_bus_data_handler(acpi_handle handle, void *context);
322acpi_status acpi_bus_get_status_handle(acpi_handle handle, 321acpi_status acpi_bus_get_status_handle(acpi_handle handle,
323 unsigned long long *sta); 322 unsigned long long *sta);
324int acpi_bus_get_status(struct acpi_device *device); 323int acpi_bus_get_status(struct acpi_device *device);
325int acpi_bus_get_power(acpi_handle handle, int *state);
326int acpi_bus_set_power(acpi_handle handle, int state); 324int acpi_bus_set_power(acpi_handle handle, int state);
325int acpi_bus_update_power(acpi_handle handle, int *state_p);
327bool acpi_bus_power_manageable(acpi_handle handle); 326bool acpi_bus_power_manageable(acpi_handle handle);
328bool acpi_bus_can_wakeup(acpi_handle handle); 327bool acpi_bus_can_wakeup(acpi_handle handle);
329#ifdef CONFIG_ACPI_PROC_EVENT 328#ifdef CONFIG_ACPI_PROC_EVENT
diff --git a/include/acpi/acpixf.h b/include/acpi/acpixf.h
index 53b7cfd924a3..241b8a04c83c 100644
--- a/include/acpi/acpixf.h
+++ b/include/acpi/acpixf.h
@@ -47,7 +47,7 @@
47 47
48/* Current ACPICA subsystem version in YYYYMMDD format */ 48/* Current ACPICA subsystem version in YYYYMMDD format */
49 49
50#define ACPI_CA_VERSION 0x20101013 50#define ACPI_CA_VERSION 0x20101209
51 51
52#include "actypes.h" 52#include "actypes.h"
53#include "actbl.h" 53#include "actbl.h"
@@ -229,6 +229,10 @@ acpi_status
229acpi_install_initialization_handler(acpi_init_handler handler, u32 function); 229acpi_install_initialization_handler(acpi_init_handler handler, u32 function);
230 230
231acpi_status 231acpi_status
232acpi_install_global_event_handler(ACPI_GBL_EVENT_HANDLER handler,
233 void *context);
234
235acpi_status
232acpi_install_fixed_event_handler(u32 acpi_event, 236acpi_install_fixed_event_handler(u32 acpi_event,
233 acpi_event_handler handler, void *context); 237 acpi_event_handler handler, void *context);
234 238
@@ -258,11 +262,11 @@ acpi_remove_address_space_handler(acpi_handle device,
258acpi_status 262acpi_status
259acpi_install_gpe_handler(acpi_handle gpe_device, 263acpi_install_gpe_handler(acpi_handle gpe_device,
260 u32 gpe_number, 264 u32 gpe_number,
261 u32 type, acpi_event_handler address, void *context); 265 u32 type, acpi_gpe_handler address, void *context);
262 266
263acpi_status 267acpi_status
264acpi_remove_gpe_handler(acpi_handle gpe_device, 268acpi_remove_gpe_handler(acpi_handle gpe_device,
265 u32 gpe_number, acpi_event_handler address); 269 u32 gpe_number, acpi_gpe_handler address);
266 270
267#ifdef ACPI_FUTURE_USAGE 271#ifdef ACPI_FUTURE_USAGE
268acpi_status acpi_install_exception_handler(acpi_exception_handler handler); 272acpi_status acpi_install_exception_handler(acpi_exception_handler handler);
@@ -292,11 +296,13 @@ acpi_status acpi_enable_gpe(acpi_handle gpe_device, u32 gpe_number);
292 296
293acpi_status acpi_disable_gpe(acpi_handle gpe_device, u32 gpe_number); 297acpi_status acpi_disable_gpe(acpi_handle gpe_device, u32 gpe_number);
294 298
295acpi_status acpi_gpe_can_wake(acpi_handle gpe_device, u32 gpe_number);
296
297acpi_status acpi_clear_gpe(acpi_handle gpe_device, u32 gpe_number); 299acpi_status acpi_clear_gpe(acpi_handle gpe_device, u32 gpe_number);
298 300
299acpi_status acpi_gpe_wakeup(acpi_handle gpe_device, u32 gpe_number, u8 action); 301acpi_status
302acpi_setup_gpe_for_wake(acpi_handle parent_device,
303 acpi_handle gpe_device, u32 gpe_number);
304
305acpi_status acpi_set_gpe_wake_mask(acpi_handle gpe_device, u32 gpe_number, u8 action);
300 306
301acpi_status 307acpi_status
302acpi_get_gpe_status(acpi_handle gpe_device, 308acpi_get_gpe_status(acpi_handle gpe_device,
@@ -315,7 +321,7 @@ acpi_install_gpe_block(acpi_handle gpe_device,
315 321
316acpi_status acpi_remove_gpe_block(acpi_handle gpe_device); 322acpi_status acpi_remove_gpe_block(acpi_handle gpe_device);
317 323
318acpi_status acpi_update_gpes(void); 324acpi_status acpi_update_all_gpes(void);
319 325
320/* 326/*
321 * Resource interfaces 327 * Resource interfaces
diff --git a/include/acpi/actypes.h b/include/acpi/actypes.h
index 2b134b691e34..939a431a6ab6 100644
--- a/include/acpi/actypes.h
+++ b/include/acpi/actypes.h
@@ -656,33 +656,34 @@ typedef u32 acpi_event_status;
656#define ACPI_GPE_MAX 0xFF 656#define ACPI_GPE_MAX 0xFF
657#define ACPI_NUM_GPE 256 657#define ACPI_NUM_GPE 256
658 658
659/* Actions for acpi_gpe_wakeup, acpi_hw_low_set_gpe */ 659/* Actions for acpi_set_gpe_wake_mask, acpi_hw_low_set_gpe */
660 660
661#define ACPI_GPE_ENABLE 0 661#define ACPI_GPE_ENABLE 0
662#define ACPI_GPE_DISABLE 1 662#define ACPI_GPE_DISABLE 1
663#define ACPI_GPE_COND_ENABLE 2 663#define ACPI_GPE_CONDITIONAL_ENABLE 2
664 664
665/* 665/*
666 * GPE info flags - Per GPE 666 * GPE info flags - Per GPE
667 * +-------+---+-+-+ 667 * +-------+-+-+---+
668 * | 7:4 |3:2|1|0| 668 * | 7:4 |3|2|1:0|
669 * +-------+---+-+-+ 669 * +-------+-+-+---+
670 * | | | | 670 * | | | |
671 * | | | +--- Interrupt type: edge or level triggered 671 * | | | +-- Type of dispatch:to method, handler, notify, or none
672 * | | +----- GPE can wake the system 672 * | | +----- Interrupt type: edge or level triggered
673 * | +-------- Type of dispatch:to method, handler, or none 673 * | +------- Is a Wake GPE
674 * +-------------- <Reserved> 674 * +------------ <Reserved>
675 */ 675 */
676#define ACPI_GPE_XRUPT_TYPE_MASK (u8) 0x01 676#define ACPI_GPE_DISPATCH_NONE (u8) 0x00
677#define ACPI_GPE_LEVEL_TRIGGERED (u8) 0x01 677#define ACPI_GPE_DISPATCH_METHOD (u8) 0x01
678#define ACPI_GPE_EDGE_TRIGGERED (u8) 0x00 678#define ACPI_GPE_DISPATCH_HANDLER (u8) 0x02
679#define ACPI_GPE_DISPATCH_NOTIFY (u8) 0x03
680#define ACPI_GPE_DISPATCH_MASK (u8) 0x03
679 681
680#define ACPI_GPE_CAN_WAKE (u8) 0x02 682#define ACPI_GPE_LEVEL_TRIGGERED (u8) 0x04
683#define ACPI_GPE_EDGE_TRIGGERED (u8) 0x00
684#define ACPI_GPE_XRUPT_TYPE_MASK (u8) 0x04
681 685
682#define ACPI_GPE_DISPATCH_MASK (u8) 0x0C 686#define ACPI_GPE_CAN_WAKE (u8) 0x08
683#define ACPI_GPE_DISPATCH_HANDLER (u8) 0x04
684#define ACPI_GPE_DISPATCH_METHOD (u8) 0x08
685#define ACPI_GPE_DISPATCH_NOT_USED (u8) 0x00
686 687
687/* 688/*
688 * Flags for GPE and Lock interfaces 689 * Flags for GPE and Lock interfaces
@@ -894,9 +895,20 @@ typedef void
894/* 895/*
895 * Various handlers and callback procedures 896 * Various handlers and callback procedures
896 */ 897 */
898typedef
899void (*ACPI_GBL_EVENT_HANDLER) (u32 event_type,
900 acpi_handle device,
901 u32 event_number, void *context);
902
903#define ACPI_EVENT_TYPE_GPE 0
904#define ACPI_EVENT_TYPE_FIXED 1
905
897typedef u32(*acpi_event_handler) (void *context); 906typedef u32(*acpi_event_handler) (void *context);
898 907
899typedef 908typedef
909u32 (*acpi_gpe_handler) (acpi_handle gpe_device, u32 gpe_number, void *context);
910
911typedef
900void (*acpi_notify_handler) (acpi_handle device, u32 value, void *context); 912void (*acpi_notify_handler) (acpi_handle device, u32 value, void *context);
901 913
902typedef 914typedef
@@ -951,6 +963,10 @@ u32 (*acpi_interface_handler) (acpi_string interface_name, u32 supported);
951#define ACPI_INTERRUPT_NOT_HANDLED 0x00 963#define ACPI_INTERRUPT_NOT_HANDLED 0x00
952#define ACPI_INTERRUPT_HANDLED 0x01 964#define ACPI_INTERRUPT_HANDLED 0x01
953 965
966/* GPE handler return values */
967
968#define ACPI_REENABLE_GPE 0x80
969
954/* Length of 32-bit EISAID values when converted back to a string */ 970/* Length of 32-bit EISAID values when converted back to a string */
955 971
956#define ACPI_EISAID_STRING_SIZE 8 /* Includes null terminator */ 972#define ACPI_EISAID_STRING_SIZE 8 /* Includes null terminator */