ACPICA: Fix to allow region arguments to reference other scopes
[linux-flexiantxendom0.git] / drivers / acpi / acpica / acobject.h
index cde18ea..6d276c2 100644 (file)
@@ -6,7 +6,7 @@
  *****************************************************************************/
 
 /*
- * Copyright (C) 2000 - 2010, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
 
 /* Values for Flag byte above */
 
-#define AOPOBJ_AML_CONSTANT         0x01
-#define AOPOBJ_STATIC_POINTER       0x02
-#define AOPOBJ_DATA_VALID           0x04
-#define AOPOBJ_OBJECT_INITIALIZED   0x08
-#define AOPOBJ_SETUP_COMPLETE       0x10
-#define AOPOBJ_SINGLE_DATUM         0x20
-#define AOPOBJ_INVALID              0x40       /* Used if host OS won't allow an op_region address */
-#define AOPOBJ_MODULE_LEVEL         0x80
+#define AOPOBJ_AML_CONSTANT         0x01       /* Integer is an AML constant */
+#define AOPOBJ_STATIC_POINTER       0x02       /* Data is part of an ACPI table, don't delete */
+#define AOPOBJ_DATA_VALID           0x04       /* Object is initialized and data is valid */
+#define AOPOBJ_OBJECT_INITIALIZED   0x08       /* Region is initialized, _REG was run */
+#define AOPOBJ_SETUP_COMPLETE       0x10       /* Region setup is complete */
+#define AOPOBJ_INVALID              0x20       /* Host OS won't allow a Region address */
 
 /******************************************************************************
  *
@@ -175,7 +173,7 @@ struct acpi_object_region {
 };
 
 struct acpi_object_method {
-       ACPI_OBJECT_COMMON_HEADER u8 method_flags;
+       ACPI_OBJECT_COMMON_HEADER u8 info_flags;
        u8 param_count;
        u8 sync_level;
        union acpi_operand_object *mutex;
@@ -183,13 +181,21 @@ struct acpi_object_method {
        union {
                ACPI_INTERNAL_METHOD implementation;
                union acpi_operand_object *handler;
-       } extra;
+       } dispatch;
 
        u32 aml_length;
        u8 thread_count;
        acpi_owner_id owner_id;
 };
 
+/* Flags for info_flags field above */
+
+#define ACPI_METHOD_MODULE_LEVEL        0x01   /* Method is actually module-level code */
+#define ACPI_METHOD_INTERNAL_ONLY       0x02   /* Method is implemented internally (_OSI) */
+#define ACPI_METHOD_SERIALIZED          0x04   /* Method is serialized */
+#define ACPI_METHOD_SERIALIZED_PENDING  0x08   /* Method is to be marked serialized */
+#define ACPI_METHOD_MODIFIED_NAMESPACE  0x10   /* Method modified the namespace */
+
 /******************************************************************************
  *
  * Objects that can be notified.  All share a common notify_info area.
@@ -248,7 +254,7 @@ ACPI_OBJECT_COMMON_HEADER ACPI_COMMON_NOTIFY_INFO};
        u32                             base_byte_offset;   /* Byte offset within containing object */\
        u32                             value;              /* Value to store into the Bank or Index register */\
        u8                              start_field_bit_offset;/* Bit offset within first field datum (0-63) */\
-       u8                              access_bit_width;       /* Read/Write size in bits (8-64) */
+
 
 struct acpi_object_field_common {      /* COMMON FIELD (for BUFFER, REGION, BANK, and INDEX fields) */
        ACPI_OBJECT_COMMON_HEADER ACPI_COMMON_FIELD_INFO union acpi_operand_object *region_obj; /* Parent Operation Region object (REGION/BANK fields only) */
@@ -352,6 +358,7 @@ typedef enum {
  */
 struct acpi_object_extra {
        ACPI_OBJECT_COMMON_HEADER struct acpi_namespace_node *method_REG;       /* _REG method for this region (if any) */
+       struct acpi_namespace_node *scope_node;
        void *region_context;   /* Region-specific data */
        u8 *aml_start;
        u32 aml_length;