summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAndy Grover <agrover@groveronline.com>2003-02-27 00:23:08 -0800
committerAndy Grover <agrover@groveronline.com>2003-02-27 00:23:08 -0800
commitda8bbd484da33232f351709c57fee02502b29547 (patch)
treeeea076f2ea3e91ccedf02f84356043b634e2e913 /include
parentdb72219bc0b3bcaddb0d92e6f532a99450dd9c03 (diff)
ACPI: Interpreter update
- Add acpi_walk_resource support (Bjorn Helgaas) - Add S4BIOS support (Pavel Machek) - Rewrite GPE code to deal with future GPE block devices - Fix a bug that caused long delays when receiving SCIs - Fix a bug that causes oopses when battery strings are ""
Diffstat (limited to 'include')
-rw-r--r--include/acpi/acdebug.h3
-rw-r--r--include/acpi/acevents.h18
-rw-r--r--include/acpi/acglobal.h17
-rw-r--r--include/acpi/achware.h14
-rw-r--r--include/acpi/aclocal.h47
-rw-r--r--include/acpi/acpixf.h21
-rw-r--r--include/acpi/acresrc.h6
-rw-r--r--include/acpi/acutils.h2
8 files changed, 67 insertions, 61 deletions
diff --git a/include/acpi/acdebug.h b/include/acpi/acdebug.h
index cd2b474ec837..ae75649c348b 100644
--- a/include/acpi/acdebug.h
+++ b/include/acpi/acdebug.h
@@ -177,6 +177,9 @@ acpi_db_display_resources (
char *object_arg);
void
+acpi_db_display_gpes (void);
+
+void
acpi_db_check_integrity (
void);
diff --git a/include/acpi/acevents.h b/include/acpi/acevents.h
index 1a4b232179e8..0301e19427b8 100644
--- a/include/acpi/acevents.h
+++ b/include/acpi/acevents.h
@@ -91,14 +91,6 @@ acpi_status
acpi_ev_init_global_lock_handler (
void);
-struct acpi_gpe_register_info *
-acpi_ev_get_gpe_register_info (
- u32 gpe_number);
-
-struct acpi_gpe_number_info *
-acpi_ev_get_gpe_number_info (
- u32 gpe_number);
-
u32
acpi_ev_get_gpe_number_index (
u32 gpe_number);
@@ -117,17 +109,17 @@ acpi_ev_notify_dispatch (
* Evgpe - GPE handling and dispatch
*/
-acpi_status
-acpi_ev_gpe_initialize (
- void);
+struct acpi_gpe_event_info *
+acpi_ev_get_gpe_event_info (
+ u32 gpe_number);
acpi_status
-acpi_ev_init_gpe_control_methods (
+acpi_ev_gpe_initialize (
void);
u32
acpi_ev_gpe_dispatch (
- u32 gpe_number);
+ struct acpi_gpe_event_info *gpe_event_info);
u32
acpi_ev_gpe_detect (
diff --git a/include/acpi/acglobal.h b/include/acpi/acglobal.h
index b6713c925987..8a6978e75505 100644
--- a/include/acpi/acglobal.h
+++ b/include/acpi/acglobal.h
@@ -234,22 +234,7 @@ ACPI_EXTERN u8 acpi_gbl_sleep_type_b;
extern struct acpi_fixed_event_info acpi_gbl_fixed_event_info[ACPI_NUM_FIXED_EVENTS];
ACPI_EXTERN struct acpi_fixed_event_handler acpi_gbl_fixed_event_handlers[ACPI_NUM_FIXED_EVENTS];
-
-ACPI_EXTERN acpi_handle acpi_gbl_gpe_obj_handle;
-ACPI_EXTERN u32 acpi_gbl_gpe_register_count;
-ACPI_EXTERN u32 acpi_gbl_gpe_number_max;
-ACPI_EXTERN struct acpi_gpe_register_info *acpi_gbl_gpe_register_info;
-ACPI_EXTERN struct acpi_gpe_number_info *acpi_gbl_gpe_number_info;
-ACPI_EXTERN struct acpi_gpe_block_info acpi_gbl_gpe_block_info[ACPI_MAX_GPE_BLOCKS];
-
-/*
- * GPE translation table
- * Indexed by the GPE number, returns a valid index into the global GPE tables.
- *
- * This table is needed because the GPE numbers supported by block 1 do not
- * have to be contiguous with the GPE numbers supported by block 0.
- */
-ACPI_EXTERN struct acpi_gpe_index_info *acpi_gbl_gpe_number_to_index;
+ACPI_EXTERN struct acpi_gpe_block_info *acpi_gbl_gpe_block_list_head;
/*****************************************************************************
diff --git a/include/acpi/achware.h b/include/acpi/achware.h
index af0240db7963..de4a84220ed3 100644
--- a/include/acpi/achware.h
+++ b/include/acpi/achware.h
@@ -115,29 +115,25 @@ acpi_hw_clear_acpi_status (
/* GPE support */
-u8
-acpi_hw_get_gpe_bit_mask (
- u32 gpe_number);
-
acpi_status
acpi_hw_enable_gpe (
- u32 gpe_number);
+ struct acpi_gpe_event_info *gpe_event_info);
void
acpi_hw_enable_gpe_for_wakeup (
- u32 gpe_number);
+ struct acpi_gpe_event_info *gpe_event_info);
acpi_status
acpi_hw_disable_gpe (
- u32 gpe_number);
+ struct acpi_gpe_event_info *gpe_event_info);
void
acpi_hw_disable_gpe_for_wakeup (
- u32 gpe_number);
+ struct acpi_gpe_event_info *gpe_event_info);
acpi_status
acpi_hw_clear_gpe (
- u32 gpe_number);
+ struct acpi_gpe_event_info *gpe_event_info);
acpi_status
acpi_hw_get_gpe_status (
diff --git a/include/acpi/aclocal.h b/include/acpi/aclocal.h
index 2ab9bee98a31..47c3f4a1de2d 100644
--- a/include/acpi/aclocal.h
+++ b/include/acpi/aclocal.h
@@ -308,25 +308,28 @@ struct acpi_create_field_info
*
****************************************************************************/
-/* Information about each GPE register block */
+/* Information about each particular GPE level */
-struct acpi_gpe_block_info
+struct acpi_gpe_event_info
{
- struct acpi_generic_address *block_address;
- u16 register_count;
- u8 block_base_number;
+ struct acpi_namespace_node *method_node; /* Method node for this GPE level */
+ acpi_gpe_handler handler; /* Address of handler, if any */
+ void *context; /* Context to be passed to handler */
+ struct acpi_gpe_register_info *register_info;
+ u8 type; /* Level or Edge */
+ u8 bit_mask;
};
/* Information about a particular GPE register pair */
struct acpi_gpe_register_info
{
- struct acpi_generic_address status_address; /* Address of status reg */
- struct acpi_generic_address enable_address; /* Address of enable reg */
- u8 status; /* Current value of status reg */
- u8 enable; /* Current value of enable reg */
- u8 wake_enable; /* Mask of bits to keep enabled when sleeping */
- u8 base_gpe_number; /* Base GPE number for this register */
+ struct acpi_generic_address status_address; /* Address of status reg */
+ struct acpi_generic_address enable_address; /* Address of enable reg */
+ u8 status; /* Current value of status reg */
+ u8 enable; /* Current value of enable reg */
+ u8 wake_enable; /* Mask of bits to keep enabled when sleeping */
+ u8 base_gpe_number; /* Base GPE number for this register */
};
@@ -334,23 +337,21 @@ struct acpi_gpe_register_info
#define ACPI_GPE_EDGE_TRIGGERED 2
-/* Information about each particular GPE level */
+/* Information about each GPE register block */
-struct acpi_gpe_number_info
+struct acpi_gpe_block_info
{
- struct acpi_namespace_node *method_node; /* Method node for this GPE level */
- acpi_gpe_handler handler; /* Address of handler, if any */
- void *context; /* Context to be passed to handler */
- u8 type; /* Level or Edge */
- u8 bit_mask;
+ struct acpi_gpe_block_info *previous;
+ struct acpi_gpe_block_info *next;
+ struct acpi_gpe_block_info *next_on_interrupt;
+ struct acpi_gpe_register_info *register_info;
+ struct acpi_gpe_event_info *event_info;
+ struct acpi_generic_address block_address;
+ u32 register_count;
+ u8 block_base_number;
};
-struct acpi_gpe_index_info
-{
- u8 number_index;
-};
-
/* Information about each particular fixed event */
struct acpi_fixed_event_handler
diff --git a/include/acpi/acpixf.h b/include/acpi/acpixf.h
index 581cf961fb35..a1ff7679f6e7 100644
--- a/include/acpi/acpixf.h
+++ b/include/acpi/acpixf.h
@@ -339,6 +339,12 @@ acpi_get_event_status (
* Resource interfaces
*/
+typedef
+acpi_status (*ACPI_WALK_RESOURCE_CALLBACK) (
+ struct acpi_resource *resource,
+ void *context);
+
+
acpi_status
acpi_get_current_resources(
acpi_handle device_handle,
@@ -350,6 +356,13 @@ acpi_get_possible_resources(
struct acpi_buffer *ret_buffer);
acpi_status
+acpi_walk_resources (
+ acpi_handle device_handle,
+ char *path,
+ ACPI_WALK_RESOURCE_CALLBACK user_function,
+ void *context);
+
+acpi_status
acpi_set_current_resources (
acpi_handle device_handle,
struct acpi_buffer *in_buffer);
@@ -359,6 +372,10 @@ acpi_get_irq_routing_table (
acpi_handle bus_device_handle,
struct acpi_buffer *ret_buffer);
+acpi_status
+acpi_resource_to_address64 (
+ struct acpi_resource *resource,
+ struct acpi_resource_address64 *out);
/*
* Hardware (ACPI device) interfaces
@@ -399,6 +416,10 @@ acpi_enter_sleep_state (
u8 sleep_state);
acpi_status
+acpi_enter_sleep_state_s4bios (
+ void);
+
+acpi_status
acpi_leave_sleep_state (
u8 sleep_state);
diff --git a/include/acpi/acresrc.h b/include/acpi/acresrc.h
index fa2e298d6c0a..814c77078178 100644
--- a/include/acpi/acresrc.h
+++ b/include/acpi/acresrc.h
@@ -66,6 +66,12 @@ acpi_rs_get_prs_method_data (
struct acpi_buffer *ret_buffer);
acpi_status
+acpi_rs_get_method_data (
+ acpi_handle handle,
+ char *path,
+ struct acpi_buffer *ret_buffer);
+
+acpi_status
acpi_rs_set_srs_method_data (
acpi_handle handle,
struct acpi_buffer *ret_buffer);
diff --git a/include/acpi/acutils.h b/include/acpi/acutils.h
index 114793ddf698..576ad04ca41f 100644
--- a/include/acpi/acutils.h
+++ b/include/acpi/acutils.h
@@ -463,6 +463,8 @@ acpi_ut_delete_internal_object_list (
#define METHOD_NAME__SEG "_SEG"
#define METHOD_NAME__BBN "_BBN"
#define METHOD_NAME__PRT "_PRT"
+#define METHOD_NAME__CRS "_CRS"
+#define METHOD_NAME__PRS "_PRS"
acpi_status