aboutsummaryrefslogtreecommitdiff
path: root/include/acpi
diff options
context:
space:
mode:
Diffstat (limited to 'include/acpi')
-rw-r--r--include/acpi/acconfig.h4
-rw-r--r--include/acpi/acdisasm.h36
-rw-r--r--include/acpi/aclocal.h23
-rw-r--r--include/acpi/acresrc.h46
-rw-r--r--include/acpi/actypes.h13
-rw-r--r--include/acpi/amlresrc.h56
-rw-r--r--include/acpi/platform/acenv.h1
7 files changed, 104 insertions, 75 deletions
diff --git a/include/acpi/acconfig.h b/include/acpi/acconfig.h
index 427cff1a3f8..1427c5cf430 100644
--- a/include/acpi/acconfig.h
+++ b/include/acpi/acconfig.h
@@ -61,9 +61,9 @@
*
*/
-/* Version string */
+/* Current ACPICA subsystem version in YYYYMMDD format */
-#define ACPI_CA_VERSION 0x20050902
+#define ACPI_CA_VERSION 0x20050916
/*
* OS name, used for the _OS object. The _OS object is essentially obsolete,
diff --git a/include/acpi/acdisasm.h b/include/acpi/acdisasm.h
index 3d96dcb1bb4..759b4cff4f8 100644
--- a/include/acpi/acdisasm.h
+++ b/include/acpi/acdisasm.h
@@ -187,73 +187,73 @@ void acpi_dm_decode_attribute(u8 attribute);
* dmresrcl
*/
void
-acpi_dm_word_descriptor(struct asl_word_address_desc *resource,
+acpi_dm_word_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_dword_descriptor(struct asl_dword_address_desc *resource,
+acpi_dm_dword_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_extended_descriptor(struct asl_extended_address_desc *resource,
+acpi_dm_extended_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_qword_descriptor(struct asl_qword_address_desc *resource,
+acpi_dm_qword_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_memory24_descriptor(struct asl_memory_24_desc *resource,
+acpi_dm_memory24_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_memory32_descriptor(struct asl_memory_32_desc *resource,
+acpi_dm_memory32_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_fixed_mem32_descriptor(struct asl_fixed_memory_32_desc *resource,
- u32 length, u32 level);
+acpi_dm_fixed_memory32_descriptor(union asl_resource_desc *resource,
+ u32 length, u32 level);
void
-acpi_dm_generic_register_descriptor(struct asl_general_register_desc *resource,
+acpi_dm_generic_register_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_interrupt_descriptor(struct asl_extended_xrupt_desc *resource,
+acpi_dm_interrupt_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_vendor_large_descriptor(struct asl_large_vendor_desc *resource,
+acpi_dm_vendor_large_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
/*
* dmresrcs
*/
void
-acpi_dm_irq_descriptor(struct asl_irq_format_desc *resource,
+acpi_dm_irq_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_dma_descriptor(struct asl_dma_format_desc *resource,
+acpi_dm_dma_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_io_descriptor(struct asl_io_port_desc *resource, u32 length, u32 level);
+acpi_dm_io_descriptor(union asl_resource_desc *resource, u32 length, u32 level);
void
-acpi_dm_fixed_io_descriptor(struct asl_fixed_io_port_desc *resource,
+acpi_dm_fixed_io_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_start_dependent_descriptor(struct asl_start_dependent_desc *resource,
+acpi_dm_start_dependent_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_end_dependent_descriptor(struct asl_start_dependent_desc *resource,
+acpi_dm_end_dependent_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
void
-acpi_dm_vendor_small_descriptor(struct asl_small_vendor_desc *resource,
+acpi_dm_vendor_small_descriptor(union asl_resource_desc *resource,
u32 length, u32 level);
/*
diff --git a/include/acpi/aclocal.h b/include/acpi/aclocal.h
index 9fba0fddda9..76ac1533c40 100644
--- a/include/acpi/aclocal.h
+++ b/include/acpi/aclocal.h
@@ -744,12 +744,13 @@ struct acpi_bit_register_info {
#define ACPI_RDESC_TYPE_LARGE 0x80
#define ACPI_RDESC_TYPE_SMALL 0x00
-#define ACPI_RDESC_TYPE_MASK 0x80
-#define ACPI_RDESC_SMALL_MASK 0x78 /* Only bits 6:3 contain the type */
+#define ACPI_RDESC_SMALL_MASK 0x78 /* Bits 6:3 contain the type */
+#define ACPI_RDESC_SMALL_LENGTH_MASK 0x07 /* Bits 2:0 contain the length */
+#define ACPI_RDESC_LARGE_MASK 0x7F /* Bits 6:0 contain the type */
/*
* Small resource descriptor types
- * Note: The 3 length bits (2:0) must be zero
+ * Note: Bits 2:0 are used for the descriptor length
*/
#define ACPI_RDESC_TYPE_IRQ_FORMAT 0x20
#define ACPI_RDESC_TYPE_DMA_FORMAT 0x28
@@ -757,6 +758,10 @@ struct acpi_bit_register_info {
#define ACPI_RDESC_TYPE_END_DEPENDENT 0x38
#define ACPI_RDESC_TYPE_IO_PORT 0x40
#define ACPI_RDESC_TYPE_FIXED_IO_PORT 0x48
+#define ACPI_RDESC_TYPE_RESERVED_S1 0x50
+#define ACPI_RDESC_TYPE_RESERVED_S2 0x58
+#define ACPI_RDESC_TYPE_RESERVED_S3 0x60
+#define ACPI_RDESC_TYPE_RESERVED_S4 0x68
#define ACPI_RDESC_TYPE_SMALL_VENDOR 0x70
#define ACPI_RDESC_TYPE_END_TAG 0x78
@@ -764,7 +769,8 @@ struct acpi_bit_register_info {
* Large resource descriptor types
*/
#define ACPI_RDESC_TYPE_MEMORY_24 0x81
-#define ACPI_RDESC_TYPE_GENERAL_REGISTER 0x82
+#define ACPI_RDESC_TYPE_GENERIC_REGISTER 0x82
+#define ACPI_RDESC_TYPE_RESERVED_L1 0x83
#define ACPI_RDESC_TYPE_LARGE_VENDOR 0x84
#define ACPI_RDESC_TYPE_MEMORY_32 0x85
#define ACPI_RDESC_TYPE_FIXED_MEMORY_32 0x86
@@ -773,6 +779,15 @@ struct acpi_bit_register_info {
#define ACPI_RDESC_TYPE_EXTENDED_XRUPT 0x89
#define ACPI_RDESC_TYPE_QWORD_ADDRESS_SPACE 0x8A
#define ACPI_RDESC_TYPE_EXTENDED_ADDRESS_SPACE 0x8B
+#define ACPI_RDESC_LARGE_MAX 0x8B
+
+/*
+ * Minimum lengths for descriptors with optional fields
+ */
+#define ACPI_RDESC_QWORD_MIN 43
+#define ACPI_RDESC_DWORD_MIN 23
+#define ACPI_RDESC_WORD_MIN 13
+#define ACPI_RDESC_EXT_XRUPT_MIN 6
/*****************************************************************************
*
diff --git a/include/acpi/acresrc.h b/include/acpi/acresrc.h
index 38e798b05d0..ce2cf72fd4c 100644
--- a/include/acpi/acresrc.h
+++ b/include/acpi/acresrc.h
@@ -110,7 +110,7 @@ acpi_rs_byte_stream_to_list(u8 * byte_stream_buffer,
u32 byte_stream_buffer_length, u8 * output_buffer);
acpi_status
-acpi_rs_list_to_byte_stream(struct acpi_resource *linked_list,
+acpi_rs_list_to_byte_stream(struct acpi_resource *resource,
acpi_size byte_stream_size_needed,
u8 * output_buffer);
@@ -125,11 +125,11 @@ acpi_rs_fixed_io_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_io_stream(struct acpi_resource *linked_list,
+acpi_rs_io_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
-acpi_rs_fixed_io_stream(struct acpi_resource *linked_list,
+acpi_rs_fixed_io_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -138,7 +138,7 @@ acpi_rs_irq_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_irq_stream(struct acpi_resource *linked_list,
+acpi_rs_irq_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -147,7 +147,7 @@ acpi_rs_dma_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_dma_stream(struct acpi_resource *linked_list,
+acpi_rs_dma_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -156,7 +156,7 @@ acpi_rs_address16_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_address16_stream(struct acpi_resource *linked_list,
+acpi_rs_address16_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -165,7 +165,7 @@ acpi_rs_address32_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_address32_stream(struct acpi_resource *linked_list,
+acpi_rs_address32_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -174,7 +174,7 @@ acpi_rs_address64_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_address64_stream(struct acpi_resource *linked_list,
+acpi_rs_address64_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -190,12 +190,12 @@ acpi_rs_end_depend_fns_resource(u8 * byte_stream_buffer,
acpi_size * structure_size);
acpi_status
-acpi_rs_start_depend_fns_stream(struct acpi_resource *linked_list,
+acpi_rs_start_depend_fns_stream(struct acpi_resource *resource,
u8 ** output_buffer,
acpi_size * bytes_consumed);
acpi_status
-acpi_rs_end_depend_fns_stream(struct acpi_resource *linked_list,
+acpi_rs_end_depend_fns_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -204,7 +204,7 @@ acpi_rs_memory24_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_memory24_stream(struct acpi_resource *linked_list,
+acpi_rs_memory24_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -220,11 +220,11 @@ acpi_rs_fixed_memory32_resource(u8 * byte_stream_buffer,
acpi_size * structure_size);
acpi_status
-acpi_rs_memory32_range_stream(struct acpi_resource *linked_list,
+acpi_rs_memory32_range_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
-acpi_rs_fixed_memory32_stream(struct acpi_resource *linked_list,
+acpi_rs_fixed_memory32_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -233,7 +233,7 @@ acpi_rs_extended_irq_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_extended_irq_stream(struct acpi_resource *linked_list,
+acpi_rs_extended_irq_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -242,7 +242,7 @@ acpi_rs_end_tag_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_end_tag_stream(struct acpi_resource *linked_list,
+acpi_rs_end_tag_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
acpi_status
@@ -251,9 +251,23 @@ acpi_rs_vendor_resource(u8 * byte_stream_buffer,
u8 ** output_buffer, acpi_size * structure_size);
acpi_status
-acpi_rs_vendor_stream(struct acpi_resource *linked_list,
+acpi_rs_vendor_stream(struct acpi_resource *resource,
u8 ** output_buffer, acpi_size * bytes_consumed);
u8 acpi_rs_get_resource_type(u8 resource_start_byte);
+/*
+ * rsmisc
+ */
+acpi_status
+acpi_rs_generic_register_resource(u8 * byte_stream_buffer,
+ acpi_size * bytes_consumed,
+ u8 ** output_buffer,
+ acpi_size * structure_size);
+
+acpi_status
+acpi_rs_generic_register_stream(struct acpi_resource *resource,
+ u8 ** output_buffer,
+ acpi_size * bytes_consumed);
+
#endif /* __ACRESRC_H__ */
diff --git a/include/acpi/actypes.h b/include/acpi/actypes.h
index 6213b27516e..1dfa64fae4e 100644
--- a/include/acpi/actypes.h
+++ b/include/acpi/actypes.h
@@ -1125,6 +1125,14 @@ struct acpi_resource_ext_irq {
u32 interrupts[1];
};
+struct acpi_resource_generic_reg {
+ u32 space_id;
+ u32 bit_width;
+ u32 bit_offset;
+ u32 address_size;
+ u64 address;
+};
+
/* ACPI_RESOURCE_TYPEs */
#define ACPI_RSTYPE_IRQ 0
@@ -1142,6 +1150,8 @@ struct acpi_resource_ext_irq {
#define ACPI_RSTYPE_ADDRESS32 12
#define ACPI_RSTYPE_ADDRESS64 13
#define ACPI_RSTYPE_EXT_IRQ 14
+#define ACPI_RSTYPE_GENERIC_REG 15
+#define ACPI_RSTYPE_MAX 15
typedef u32 acpi_resource_type;
@@ -1161,10 +1171,11 @@ union acpi_resource_data {
struct acpi_resource_address32 address32;
struct acpi_resource_address64 address64;
struct acpi_resource_ext_irq extended_irq;
+ struct acpi_resource_generic_reg generic_reg;
};
struct acpi_resource {
- acpi_resource_type id;
+ acpi_resource_type type;
u32 length;
union acpi_resource_data data;
};
diff --git a/include/acpi/amlresrc.h b/include/acpi/amlresrc.h
index 051786e4b21..a3c46ba6358 100644
--- a/include/acpi/amlresrc.h
+++ b/include/acpi/amlresrc.h
@@ -157,10 +157,15 @@ struct asl_end_tag_desc {
/* LARGE descriptors */
+#define ASL_LARGE_HEADER_COMMON \
+ u8 descriptor_type;\
+ u16 length;
+
+struct asl_large_header {
+ASL_LARGE_HEADER_COMMON};
+
struct asl_memory_24_desc {
- u8 descriptor_type;
- u16 length;
- u8 information;
+ ASL_LARGE_HEADER_COMMON u8 information;
u16 address_min;
u16 address_max;
u16 alignment;
@@ -168,15 +173,11 @@ struct asl_memory_24_desc {
};
struct asl_large_vendor_desc {
- u8 descriptor_type;
- u16 length;
- u8 vendor_defined[1];
+ ASL_LARGE_HEADER_COMMON u8 vendor_defined[1];
};
struct asl_memory_32_desc {
- u8 descriptor_type;
- u16 length;
- u8 information;
+ ASL_LARGE_HEADER_COMMON u8 information;
u32 address_min;
u32 address_max;
u32 alignment;
@@ -184,17 +185,13 @@ struct asl_memory_32_desc {
};
struct asl_fixed_memory_32_desc {
- u8 descriptor_type;
- u16 length;
- u8 information;
+ ASL_LARGE_HEADER_COMMON u8 information;
u32 base_address;
u32 range_length;
};
struct asl_extended_address_desc {
- u8 descriptor_type;
- u16 length;
- u8 resource_type;
+ ASL_LARGE_HEADER_COMMON u8 resource_type;
u8 flags;
u8 specific_flags;
u8 revision_iD;
@@ -211,9 +208,7 @@ struct asl_extended_address_desc {
#define ASL_EXTENDED_ADDRESS_DESC_REVISION 1 /* ACPI 3.0 */
struct asl_qword_address_desc {
- u8 descriptor_type;
- u16 length;
- u8 resource_type;
+ ASL_LARGE_HEADER_COMMON u8 resource_type;
u8 flags;
u8 specific_flags;
u64 granularity;
@@ -225,9 +220,7 @@ struct asl_qword_address_desc {
};
struct asl_dword_address_desc {
- u8 descriptor_type;
- u16 length;
- u8 resource_type;
+ ASL_LARGE_HEADER_COMMON u8 resource_type;
u8 flags;
u8 specific_flags;
u32 granularity;
@@ -239,9 +232,7 @@ struct asl_dword_address_desc {
};
struct asl_word_address_desc {
- u8 descriptor_type;
- u16 length;
- u8 resource_type;
+ ASL_LARGE_HEADER_COMMON u8 resource_type;
u8 flags;
u8 specific_flags;
u16 granularity;
@@ -253,18 +244,14 @@ struct asl_word_address_desc {
};
struct asl_extended_xrupt_desc {
- u8 descriptor_type;
- u16 length;
- u8 flags;
+ ASL_LARGE_HEADER_COMMON u8 flags;
u8 table_length;
u32 interrupt_number[1];
/* res_source_index, res_source optional fields follow */
};
-struct asl_general_register_desc {
- u8 descriptor_type;
- u16 length;
- u8 address_space_id;
+struct asl_generic_register_desc {
+ ASL_LARGE_HEADER_COMMON u8 address_space_id;
u8 bit_width;
u8 bit_offset;
u8 access_size; /* ACPI 3.0, was Reserved */
@@ -280,13 +267,14 @@ struct asl_general_register_desc {
union asl_resource_desc {
struct asl_irq_format_desc irq;
struct asl_dma_format_desc dma;
- struct asl_start_dependent_desc std;
- struct asl_end_dependent_desc end;
struct asl_io_port_desc iop;
struct asl_fixed_io_port_desc fio;
+ struct asl_start_dependent_desc std;
+ struct asl_end_dependent_desc end;
struct asl_small_vendor_desc smv;
struct asl_end_tag_desc et;
+ struct asl_large_header lhd;
struct asl_memory_24_desc M24;
struct asl_large_vendor_desc lgv;
struct asl_memory_32_desc M32;
@@ -296,7 +284,7 @@ union asl_resource_desc {
struct asl_word_address_desc was;
struct asl_extended_address_desc eas;
struct asl_extended_xrupt_desc exx;
- struct asl_general_register_desc grg;
+ struct asl_generic_register_desc grg;
u32 u32_item;
u16 u16_item;
u8 U8item;
diff --git a/include/acpi/platform/acenv.h b/include/acpi/platform/acenv.h
index 16609c1ab2e..08539125696 100644
--- a/include/acpi/platform/acenv.h
+++ b/include/acpi/platform/acenv.h
@@ -68,6 +68,7 @@
#define ACPI_APPLICATION
#define ACPI_DEBUGGER
#define ACPI_DISASSEMBLER
+#define ACPI_MUTEX_DEBUG
#endif
#ifdef ACPI_ASL_COMPILER