diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2015-06-18 19:15:19 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2015-06-18 19:15:19 -0400 |
commit | 9695a9805284f09fefb5f8c53ba72d0c77748dbe (patch) | |
tree | 8c26b7158f33d65be1b63762e4ce5992179476c9 | |
parent | 0f57d86787d8b1076ea8f9cbdddda2a46d534a27 (diff) | |
parent | f3b6ced236259a87829b829e8e542ff53bfb9a4f (diff) |
Merge branch 'acpica'
* acpica: (22 commits)
ACPICA: Fix for ill-formed GUID strings for NFIT tables.
ACPICA: acpihelp: Update for new NFIT table GUIDs.
ACPICA: Update version to 20150515.
ACPICA: ACPI 6.0: Add support for NFIT table.
ACPICA: acpi_help: Add option to display all known/supported ACPI tables.
ACPICA: iASL/disassembler - fix possible fault for -e option.
ACPICA: ACPI 6.0: Add changes for DRTM table.
ACPICA: ACPI 6.0: Add support for IORT table.
ACPICA: ACPI 6.0: Add ACPI_SUB_PTR().
ACPICA: ACPI 6.0: Add changes for MADT table.
ACPICA: Hardware: Fix a resource leak issue in acpi_hw_build_pci_list().
ACPICA: Dispatcher: Fix a resource leak issue in acpi_ds_auto_serialize_method().
ACPICA: ACPI 6.0: Add changes for LPIT table.
ACPICA: ACPI 6.0: Add changes for FADT table.
ACPICA: ACPI 6.0: Add support for WPBT table.
ACPICA: iASL: Enhance detection of non-ascii or corrupted input files.
ACPICA: Parser: Move a couple externals to the proper header.
ACPICA: ACPI 6.0: Add support for XENV table.
ACPICA: ACPI 6.0: Add support for new predefined names.
ACPICA: ACPI 6.0: Add support for STAO table.
...
-rw-r--r-- | drivers/acpi/acpica/acdebug.h | 4 | ||||
-rw-r--r-- | drivers/acpi/acpica/aclocal.h | 15 | ||||
-rw-r--r-- | drivers/acpi/acpica/acparser.h | 3 | ||||
-rw-r--r-- | drivers/acpi/acpica/acpredef.h | 45 | ||||
-rw-r--r-- | drivers/acpi/acpica/acutils.h | 2 | ||||
-rw-r--r-- | drivers/acpi/acpica/dsmethod.c | 5 | ||||
-rw-r--r-- | drivers/acpi/acpica/hwpci.c | 9 | ||||
-rw-r--r-- | drivers/acpi/acpica/nsprepkg.c | 13 | ||||
-rw-r--r-- | drivers/acpi/acpica/nsrepair.c | 2 | ||||
-rw-r--r-- | drivers/acpi/acpica/psopinfo.c | 3 | ||||
-rw-r--r-- | drivers/acpi/acpica/utfileio.c | 9 | ||||
-rw-r--r-- | drivers/acpi/acpica/uthex.c | 4 | ||||
-rw-r--r-- | drivers/acpi/acpica/utxferror.c | 11 | ||||
-rw-r--r-- | include/acpi/acpixf.h | 2 | ||||
-rw-r--r-- | include/acpi/actbl.h | 17 | ||||
-rw-r--r-- | include/acpi/actbl1.h | 176 | ||||
-rw-r--r-- | include/acpi/actbl2.h | 146 | ||||
-rw-r--r-- | include/acpi/actbl3.h | 88 | ||||
-rw-r--r-- | include/acpi/actypes.h | 6 | ||||
-rw-r--r-- | include/acpi/acuuid.h | 89 | ||||
-rw-r--r-- | include/acpi/platform/acenv.h | 3 | ||||
-rw-r--r-- | include/acpi/platform/acenvex.h | 3 |
22 files changed, 585 insertions, 70 deletions
diff --git a/drivers/acpi/acpica/acdebug.h b/drivers/acpi/acpica/acdebug.h index 4169bb87a996..43685dd36c77 100644 --- a/drivers/acpi/acpica/acdebug.h +++ b/drivers/acpi/acpica/acdebug.h | |||
@@ -231,7 +231,9 @@ void acpi_db_open_debug_file(char *name); | |||
231 | acpi_status acpi_db_load_acpi_table(char *filename); | 231 | acpi_status acpi_db_load_acpi_table(char *filename); |
232 | 232 | ||
233 | acpi_status | 233 | acpi_status |
234 | acpi_db_get_table_from_file(char *filename, struct acpi_table_header **table); | 234 | acpi_db_get_table_from_file(char *filename, |
235 | struct acpi_table_header **table, | ||
236 | u8 must_be_aml_table); | ||
235 | 237 | ||
236 | /* | 238 | /* |
237 | * dbhistry - debugger HISTORY command | 239 | * dbhistry - debugger HISTORY command |
diff --git a/drivers/acpi/acpica/aclocal.h b/drivers/acpi/acpica/aclocal.h index 87b27521fcac..ffdb956391f6 100644 --- a/drivers/acpi/acpica/aclocal.h +++ b/drivers/acpi/acpica/aclocal.h | |||
@@ -352,11 +352,21 @@ struct acpi_package_info3 { | |||
352 | u16 reserved; | 352 | u16 reserved; |
353 | }; | 353 | }; |
354 | 354 | ||
355 | struct acpi_package_info4 { | ||
356 | u8 type; | ||
357 | u8 object_type1; | ||
358 | u8 count1; | ||
359 | u8 sub_object_types; | ||
360 | u8 pkg_count; | ||
361 | u16 reserved; | ||
362 | }; | ||
363 | |||
355 | union acpi_predefined_info { | 364 | union acpi_predefined_info { |
356 | struct acpi_name_info info; | 365 | struct acpi_name_info info; |
357 | struct acpi_package_info ret_info; | 366 | struct acpi_package_info ret_info; |
358 | struct acpi_package_info2 ret_info2; | 367 | struct acpi_package_info2 ret_info2; |
359 | struct acpi_package_info3 ret_info3; | 368 | struct acpi_package_info3 ret_info3; |
369 | struct acpi_package_info4 ret_info4; | ||
360 | }; | 370 | }; |
361 | 371 | ||
362 | /* Reset to default packing */ | 372 | /* Reset to default packing */ |
@@ -1165,4 +1175,9 @@ struct ah_uuid { | |||
1165 | char *string; | 1175 | char *string; |
1166 | }; | 1176 | }; |
1167 | 1177 | ||
1178 | struct ah_table { | ||
1179 | char *signature; | ||
1180 | char *description; | ||
1181 | }; | ||
1182 | |||
1168 | #endif /* __ACLOCAL_H__ */ | 1183 | #endif /* __ACLOCAL_H__ */ |
diff --git a/drivers/acpi/acpica/acparser.h b/drivers/acpi/acpica/acparser.h index 74a390c6db16..0cdd2fce493a 100644 --- a/drivers/acpi/acpica/acparser.h +++ b/drivers/acpi/acpica/acparser.h | |||
@@ -70,6 +70,9 @@ | |||
70 | * | 70 | * |
71 | *****************************************************************************/ | 71 | *****************************************************************************/ |
72 | 72 | ||
73 | extern const u8 acpi_gbl_short_op_index[]; | ||
74 | extern const u8 acpi_gbl_long_op_index[]; | ||
75 | |||
73 | /* | 76 | /* |
74 | * psxface - Parser external interfaces | 77 | * psxface - Parser external interfaces |
75 | */ | 78 | */ |
diff --git a/drivers/acpi/acpica/acpredef.h b/drivers/acpi/acpica/acpredef.h index a972d11c97c9..b9474b529fcb 100644 --- a/drivers/acpi/acpica/acpredef.h +++ b/drivers/acpi/acpica/acpredef.h | |||
@@ -105,6 +105,11 @@ | |||
105 | * count = 0 (optional) | 105 | * count = 0 (optional) |
106 | * (Used for _DLM) | 106 | * (Used for _DLM) |
107 | * | 107 | * |
108 | * ACPI_PTYPE2_VAR_VAR: Variable number of subpackages, each of either a | ||
109 | * constant or variable length. The subpackages are preceded by a | ||
110 | * constant number of objects. | ||
111 | * (Used for _LPI, _RDI) | ||
112 | * | ||
108 | * ACPI_PTYPE2_UUID_PAIR: Each subpackage is preceded by a UUID Buffer. The UUID | 113 | * ACPI_PTYPE2_UUID_PAIR: Each subpackage is preceded by a UUID Buffer. The UUID |
109 | * defines the format of the package. Zero-length parent package is | 114 | * defines the format of the package. Zero-length parent package is |
110 | * allowed. | 115 | * allowed. |
@@ -123,7 +128,8 @@ enum acpi_return_package_types { | |||
123 | ACPI_PTYPE2_MIN = 8, | 128 | ACPI_PTYPE2_MIN = 8, |
124 | ACPI_PTYPE2_REV_FIXED = 9, | 129 | ACPI_PTYPE2_REV_FIXED = 9, |
125 | ACPI_PTYPE2_FIX_VAR = 10, | 130 | ACPI_PTYPE2_FIX_VAR = 10, |
126 | ACPI_PTYPE2_UUID_PAIR = 11 | 131 | ACPI_PTYPE2_VAR_VAR = 11, |
132 | ACPI_PTYPE2_UUID_PAIR = 12 | ||
127 | }; | 133 | }; |
128 | 134 | ||
129 | /* Support macros for users of the predefined info table */ | 135 | /* Support macros for users of the predefined info table */ |
@@ -172,7 +178,7 @@ enum acpi_return_package_types { | |||
172 | * These are the names that can actually be evaluated via acpi_evaluate_object. | 178 | * These are the names that can actually be evaluated via acpi_evaluate_object. |
173 | * Not present in this table are the following: | 179 | * Not present in this table are the following: |
174 | * | 180 | * |
175 | * 1) Predefined/Reserved names that are never evaluated via | 181 | * 1) Predefined/Reserved names that are not usually evaluated via |
176 | * acpi_evaluate_object: | 182 | * acpi_evaluate_object: |
177 | * _Lxx and _Exx GPE methods | 183 | * _Lxx and _Exx GPE methods |
178 | * _Qxx EC methods | 184 | * _Qxx EC methods |
@@ -361,6 +367,9 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
361 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Fixed-length (4 Int) */ | 367 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Fixed-length (4 Int) */ |
362 | PACKAGE_INFO(ACPI_PTYPE1_FIXED, ACPI_RTYPE_INTEGER, 4, 0, 0, 0), | 368 | PACKAGE_INFO(ACPI_PTYPE1_FIXED, ACPI_RTYPE_INTEGER, 4, 0, 0, 0), |
363 | 369 | ||
370 | {{"_BTH", METHOD_1ARGS(ACPI_TYPE_INTEGER), /* ACPI 6.0 */ | ||
371 | METHOD_NO_RETURN_VALUE}}, | ||
372 | |||
364 | {{"_BTM", METHOD_1ARGS(ACPI_TYPE_INTEGER), | 373 | {{"_BTM", METHOD_1ARGS(ACPI_TYPE_INTEGER), |
365 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | 374 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, |
366 | 375 | ||
@@ -390,6 +399,9 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
390 | PACKAGE_INFO(ACPI_PTYPE1_VAR, ACPI_RTYPE_INTEGER | ACPI_RTYPE_BUFFER, 0, | 399 | PACKAGE_INFO(ACPI_PTYPE1_VAR, ACPI_RTYPE_INTEGER | ACPI_RTYPE_BUFFER, 0, |
391 | 0, 0, 0), | 400 | 0, 0, 0), |
392 | 401 | ||
402 | {{"_CR3", METHOD_0ARGS, /* ACPI 6.0 */ | ||
403 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | ||
404 | |||
393 | {{"_CRS", METHOD_0ARGS, | 405 | {{"_CRS", METHOD_0ARGS, |
394 | METHOD_RETURNS(ACPI_RTYPE_BUFFER)}}, | 406 | METHOD_RETURNS(ACPI_RTYPE_BUFFER)}}, |
395 | 407 | ||
@@ -445,7 +457,7 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
445 | {{"_DOS", METHOD_1ARGS(ACPI_TYPE_INTEGER), | 457 | {{"_DOS", METHOD_1ARGS(ACPI_TYPE_INTEGER), |
446 | METHOD_NO_RETURN_VALUE}}, | 458 | METHOD_NO_RETURN_VALUE}}, |
447 | 459 | ||
448 | {{"_DSD", METHOD_0ARGS, | 460 | {{"_DSD", METHOD_0ARGS, /* ACPI 6.0 */ |
449 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (Pkgs) each: 1 Buf, 1 Pkg */ | 461 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (Pkgs) each: 1 Buf, 1 Pkg */ |
450 | PACKAGE_INFO(ACPI_PTYPE2_UUID_PAIR, ACPI_RTYPE_BUFFER, 1, | 462 | PACKAGE_INFO(ACPI_PTYPE2_UUID_PAIR, ACPI_RTYPE_BUFFER, 1, |
451 | ACPI_RTYPE_PACKAGE, 1, 0), | 463 | ACPI_RTYPE_PACKAGE, 1, 0), |
@@ -604,6 +616,12 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
604 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (1 Int(rev), n Pkg (2 Int) */ | 616 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (1 Int(rev), n Pkg (2 Int) */ |
605 | PACKAGE_INFO(ACPI_PTYPE2_REV_FIXED, ACPI_RTYPE_INTEGER, 2, 0, 0, 0), | 617 | PACKAGE_INFO(ACPI_PTYPE2_REV_FIXED, ACPI_RTYPE_INTEGER, 2, 0, 0, 0), |
606 | 618 | ||
619 | {{"_LPI", METHOD_0ARGS, /* ACPI 6.0 */ | ||
620 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (3 Int, n Pkg (10 Int/Buf) */ | ||
621 | PACKAGE_INFO(ACPI_PTYPE2_VAR_VAR, ACPI_RTYPE_INTEGER, 3, | ||
622 | ACPI_RTYPE_INTEGER | ACPI_RTYPE_BUFFER | ACPI_RTYPE_STRING, | ||
623 | 10, 0), | ||
624 | |||
607 | {{"_MAT", METHOD_0ARGS, | 625 | {{"_MAT", METHOD_0ARGS, |
608 | METHOD_RETURNS(ACPI_RTYPE_BUFFER)}}, | 626 | METHOD_RETURNS(ACPI_RTYPE_BUFFER)}}, |
609 | 627 | ||
@@ -624,6 +642,9 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
624 | ACPI_TYPE_INTEGER), | 642 | ACPI_TYPE_INTEGER), |
625 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | 643 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, |
626 | 644 | ||
645 | {{"_MTL", METHOD_0ARGS, /* ACPI 6.0 */ | ||
646 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | ||
647 | |||
627 | {{"_NTT", METHOD_0ARGS, | 648 | {{"_NTT", METHOD_0ARGS, |
628 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | 649 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, |
629 | 650 | ||
@@ -716,6 +737,10 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
716 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (Refs) */ | 737 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (Refs) */ |
717 | PACKAGE_INFO(ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0, 0, 0, 0), | 738 | PACKAGE_INFO(ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0, 0, 0, 0), |
718 | 739 | ||
740 | {{"_PRR", METHOD_0ARGS, /* ACPI 6.0 */ | ||
741 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Fixed-length (1 Ref) */ | ||
742 | PACKAGE_INFO(ACPI_PTYPE1_FIXED, ACPI_RTYPE_REFERENCE, 1, 0, 0, 0), | ||
743 | |||
719 | {{"_PRS", METHOD_0ARGS, | 744 | {{"_PRS", METHOD_0ARGS, |
720 | METHOD_RETURNS(ACPI_RTYPE_BUFFER)}}, | 745 | METHOD_RETURNS(ACPI_RTYPE_BUFFER)}}, |
721 | 746 | ||
@@ -796,6 +821,11 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
796 | {{"_PXM", METHOD_0ARGS, | 821 | {{"_PXM", METHOD_0ARGS, |
797 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | 822 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, |
798 | 823 | ||
824 | {{"_RDI", METHOD_0ARGS, /* ACPI 6.0 */ | ||
825 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (1 Int, n Pkg (m Ref)) */ | ||
826 | PACKAGE_INFO(ACPI_PTYPE2_VAR_VAR, ACPI_RTYPE_INTEGER, 1, | ||
827 | ACPI_RTYPE_REFERENCE, 0, 0), | ||
828 | |||
799 | {{"_REG", METHOD_2ARGS(ACPI_TYPE_INTEGER, ACPI_TYPE_INTEGER), | 829 | {{"_REG", METHOD_2ARGS(ACPI_TYPE_INTEGER, ACPI_TYPE_INTEGER), |
800 | METHOD_NO_RETURN_VALUE}}, | 830 | METHOD_NO_RETURN_VALUE}}, |
801 | 831 | ||
@@ -808,6 +838,9 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
808 | {{"_ROM", METHOD_2ARGS(ACPI_TYPE_INTEGER, ACPI_TYPE_INTEGER), | 838 | {{"_ROM", METHOD_2ARGS(ACPI_TYPE_INTEGER, ACPI_TYPE_INTEGER), |
809 | METHOD_RETURNS(ACPI_RTYPE_BUFFER)}}, | 839 | METHOD_RETURNS(ACPI_RTYPE_BUFFER)}}, |
810 | 840 | ||
841 | {{"_RST", METHOD_0ARGS, /* ACPI 6.0 */ | ||
842 | METHOD_NO_RETURN_VALUE}}, | ||
843 | |||
811 | {{"_RTV", METHOD_0ARGS, | 844 | {{"_RTV", METHOD_0ARGS, |
812 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | 845 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, |
813 | 846 | ||
@@ -935,6 +968,9 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
935 | {{"_TDL", METHOD_0ARGS, | 968 | {{"_TDL", METHOD_0ARGS, |
936 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | 969 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, |
937 | 970 | ||
971 | {{"_TFP", METHOD_0ARGS, /* ACPI 6.0 */ | ||
972 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | ||
973 | |||
938 | {{"_TIP", METHOD_1ARGS(ACPI_TYPE_INTEGER), | 974 | {{"_TIP", METHOD_1ARGS(ACPI_TYPE_INTEGER), |
939 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | 975 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, |
940 | 976 | ||
@@ -959,6 +995,9 @@ const union acpi_predefined_info acpi_gbl_predefined_methods[] = { | |||
959 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (Pkgs) each 5 Int with count */ | 995 | METHOD_RETURNS(ACPI_RTYPE_PACKAGE)}}, /* Variable-length (Pkgs) each 5 Int with count */ |
960 | PACKAGE_INFO(ACPI_PTYPE2_COUNT, ACPI_RTYPE_INTEGER, 5, 0, 0, 0), | 996 | PACKAGE_INFO(ACPI_PTYPE2_COUNT, ACPI_RTYPE_INTEGER, 5, 0, 0, 0), |
961 | 997 | ||
998 | {{"_TSN", METHOD_0ARGS, /* ACPI 6.0 */ | ||
999 | METHOD_RETURNS(ACPI_RTYPE_REFERENCE)}}, | ||
1000 | |||
962 | {{"_TSP", METHOD_0ARGS, | 1001 | {{"_TSP", METHOD_0ARGS, |
963 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, | 1002 | METHOD_RETURNS(ACPI_RTYPE_INTEGER)}}, |
964 | 1003 | ||
diff --git a/drivers/acpi/acpica/acutils.h b/drivers/acpi/acpica/acutils.h index 2b3c5bd222f1..d49f5c7a20d9 100644 --- a/drivers/acpi/acpica/acutils.h +++ b/drivers/acpi/acpica/acutils.h | |||
@@ -251,7 +251,7 @@ extern const u8 _acpi_ctype[]; | |||
251 | #define _ACPI_DI 0x04 /* '0'-'9' */ | 251 | #define _ACPI_DI 0x04 /* '0'-'9' */ |
252 | #define _ACPI_LO 0x02 /* 'a'-'z' */ | 252 | #define _ACPI_LO 0x02 /* 'a'-'z' */ |
253 | #define _ACPI_PU 0x10 /* punctuation */ | 253 | #define _ACPI_PU 0x10 /* punctuation */ |
254 | #define _ACPI_SP 0x08 /* space */ | 254 | #define _ACPI_SP 0x08 /* space, tab, CR, LF, VT, FF */ |
255 | #define _ACPI_UP 0x01 /* 'A'-'Z' */ | 255 | #define _ACPI_UP 0x01 /* 'A'-'Z' */ |
256 | #define _ACPI_XD 0x80 /* '0'-'9', 'A'-'F', 'a'-'f' */ | 256 | #define _ACPI_XD 0x80 /* '0'-'9', 'A'-'F', 'a'-'f' */ |
257 | 257 | ||
diff --git a/drivers/acpi/acpica/dsmethod.c b/drivers/acpi/acpica/dsmethod.c index d72565a3c646..85bb951430d9 100644 --- a/drivers/acpi/acpica/dsmethod.c +++ b/drivers/acpi/acpica/dsmethod.c | |||
@@ -116,6 +116,7 @@ acpi_ds_auto_serialize_method(struct acpi_namespace_node *node, | |||
116 | walk_state = | 116 | walk_state = |
117 | acpi_ds_create_walk_state(node->owner_id, NULL, NULL, NULL); | 117 | acpi_ds_create_walk_state(node->owner_id, NULL, NULL, NULL); |
118 | if (!walk_state) { | 118 | if (!walk_state) { |
119 | acpi_ps_free_op(op); | ||
119 | return_ACPI_STATUS(AE_NO_MEMORY); | 120 | return_ACPI_STATUS(AE_NO_MEMORY); |
120 | } | 121 | } |
121 | 122 | ||
@@ -125,6 +126,7 @@ acpi_ds_auto_serialize_method(struct acpi_namespace_node *node, | |||
125 | obj_desc->method.aml_length, NULL, 0); | 126 | obj_desc->method.aml_length, NULL, 0); |
126 | if (ACPI_FAILURE(status)) { | 127 | if (ACPI_FAILURE(status)) { |
127 | acpi_ds_delete_walk_state(walk_state); | 128 | acpi_ds_delete_walk_state(walk_state); |
129 | acpi_ps_free_op(op); | ||
128 | return_ACPI_STATUS(status); | 130 | return_ACPI_STATUS(status); |
129 | } | 131 | } |
130 | 132 | ||
@@ -133,9 +135,6 @@ acpi_ds_auto_serialize_method(struct acpi_namespace_node *node, | |||
133 | /* Parse the method, scan for creation of named objects */ | 135 | /* Parse the method, scan for creation of named objects */ |
134 | 136 | ||
135 | status = acpi_ps_parse_aml(walk_state); | 137 | status = acpi_ps_parse_aml(walk_state); |
136 | if (ACPI_FAILURE(status)) { | ||
137 | return_ACPI_STATUS(status); | ||
138 | } | ||
139 | 138 | ||
140 | acpi_ps_delete_parse_tree(op); | 139 | acpi_ps_delete_parse_tree(op); |
141 | return_ACPI_STATUS(status); | 140 | return_ACPI_STATUS(status); |
diff --git a/drivers/acpi/acpica/hwpci.c b/drivers/acpi/acpica/hwpci.c index c5214dec4988..f785ea788356 100644 --- a/drivers/acpi/acpica/hwpci.c +++ b/drivers/acpi/acpica/hwpci.c | |||
@@ -123,7 +123,7 @@ acpi_hw_derive_pci_id(struct acpi_pci_id *pci_id, | |||
123 | acpi_handle root_pci_device, acpi_handle pci_region) | 123 | acpi_handle root_pci_device, acpi_handle pci_region) |
124 | { | 124 | { |
125 | acpi_status status; | 125 | acpi_status status; |
126 | struct acpi_pci_device *list_head = NULL; | 126 | struct acpi_pci_device *list_head; |
127 | 127 | ||
128 | ACPI_FUNCTION_TRACE(hw_derive_pci_id); | 128 | ACPI_FUNCTION_TRACE(hw_derive_pci_id); |
129 | 129 | ||
@@ -177,13 +177,13 @@ acpi_hw_build_pci_list(acpi_handle root_pci_device, | |||
177 | acpi_handle parent_device; | 177 | acpi_handle parent_device; |
178 | acpi_status status; | 178 | acpi_status status; |
179 | struct acpi_pci_device *list_element; | 179 | struct acpi_pci_device *list_element; |
180 | struct acpi_pci_device *list_head = NULL; | ||
181 | 180 | ||
182 | /* | 181 | /* |
183 | * Ascend namespace branch until the root_pci_device is reached, building | 182 | * Ascend namespace branch until the root_pci_device is reached, building |
184 | * a list of device nodes. Loop will exit when either the PCI device is | 183 | * a list of device nodes. Loop will exit when either the PCI device is |
185 | * found, or the root of the namespace is reached. | 184 | * found, or the root of the namespace is reached. |
186 | */ | 185 | */ |
186 | *return_list_head = NULL; | ||
187 | current_device = pci_region; | 187 | current_device = pci_region; |
188 | while (1) { | 188 | while (1) { |
189 | status = acpi_get_parent(current_device, &parent_device); | 189 | status = acpi_get_parent(current_device, &parent_device); |
@@ -198,7 +198,6 @@ acpi_hw_build_pci_list(acpi_handle root_pci_device, | |||
198 | /* Finished when we reach the PCI root device (PNP0A03 or PNP0A08) */ | 198 | /* Finished when we reach the PCI root device (PNP0A03 or PNP0A08) */ |
199 | 199 | ||
200 | if (parent_device == root_pci_device) { | 200 | if (parent_device == root_pci_device) { |
201 | *return_list_head = list_head; | ||
202 | return (AE_OK); | 201 | return (AE_OK); |
203 | } | 202 | } |
204 | 203 | ||
@@ -213,9 +212,9 @@ acpi_hw_build_pci_list(acpi_handle root_pci_device, | |||
213 | 212 | ||
214 | /* Put new element at the head of the list */ | 213 | /* Put new element at the head of the list */ |
215 | 214 | ||
216 | list_element->next = list_head; | 215 | list_element->next = *return_list_head; |
217 | list_element->device = parent_device; | 216 | list_element->device = parent_device; |
218 | list_head = list_element; | 217 | *return_list_head = list_element; |
219 | 218 | ||
220 | current_device = parent_device; | 219 | current_device = parent_device; |
221 | } | 220 | } |
diff --git a/drivers/acpi/acpica/nsprepkg.c b/drivers/acpi/acpica/nsprepkg.c index 8b79958b7aca..9bb251932b45 100644 --- a/drivers/acpi/acpica/nsprepkg.c +++ b/drivers/acpi/acpica/nsprepkg.c | |||
@@ -316,6 +316,13 @@ acpi_ns_check_package(struct acpi_evaluate_info *info, | |||
316 | acpi_ns_check_package_list(info, package, elements, count); | 316 | acpi_ns_check_package_list(info, package, elements, count); |
317 | break; | 317 | break; |
318 | 318 | ||
319 | case ACPI_PTYPE2_VAR_VAR: | ||
320 | /* | ||
321 | * Returns a variable list of packages, each with a variable list | ||
322 | * of objects. | ||
323 | */ | ||
324 | break; | ||
325 | |||
319 | case ACPI_PTYPE2_UUID_PAIR: | 326 | case ACPI_PTYPE2_UUID_PAIR: |
320 | 327 | ||
321 | /* The package must contain pairs of (UUID + type) */ | 328 | /* The package must contain pairs of (UUID + type) */ |
@@ -487,6 +494,12 @@ acpi_ns_check_package_list(struct acpi_evaluate_info *info, | |||
487 | } | 494 | } |
488 | break; | 495 | break; |
489 | 496 | ||
497 | case ACPI_PTYPE2_VAR_VAR: | ||
498 | /* | ||
499 | * Each subpackage has a fixed or variable number of elements | ||
500 | */ | ||
501 | break; | ||
502 | |||
490 | case ACPI_PTYPE2_FIXED: | 503 | case ACPI_PTYPE2_FIXED: |
491 | 504 | ||
492 | /* Each subpackage has a fixed length */ | 505 | /* Each subpackage has a fixed length */ |
diff --git a/drivers/acpi/acpica/nsrepair.c b/drivers/acpi/acpica/nsrepair.c index 151fcd95ba84..77d8103d0094 100644 --- a/drivers/acpi/acpica/nsrepair.c +++ b/drivers/acpi/acpica/nsrepair.c | |||
@@ -497,10 +497,10 @@ acpi_ns_remove_null_elements(struct acpi_evaluate_info *info, | |||
497 | case ACPI_PTYPE2_MIN: | 497 | case ACPI_PTYPE2_MIN: |
498 | case ACPI_PTYPE2_REV_FIXED: | 498 | case ACPI_PTYPE2_REV_FIXED: |
499 | case ACPI_PTYPE2_FIX_VAR: | 499 | case ACPI_PTYPE2_FIX_VAR: |
500 | |||
501 | break; | 500 | break; |
502 | 501 | ||
503 | default: | 502 | default: |
503 | case ACPI_PTYPE2_VAR_VAR: | ||
504 | case ACPI_PTYPE1_FIXED: | 504 | case ACPI_PTYPE1_FIXED: |
505 | case ACPI_PTYPE1_OPTION: | 505 | case ACPI_PTYPE1_OPTION: |
506 | return; | 506 | return; |
diff --git a/drivers/acpi/acpica/psopinfo.c b/drivers/acpi/acpica/psopinfo.c index 20e1a35169fc..58310907fa7b 100644 --- a/drivers/acpi/acpica/psopinfo.c +++ b/drivers/acpi/acpica/psopinfo.c | |||
@@ -50,9 +50,6 @@ | |||
50 | #define _COMPONENT ACPI_PARSER | 50 | #define _COMPONENT ACPI_PARSER |
51 | ACPI_MODULE_NAME("psopinfo") | 51 | ACPI_MODULE_NAME("psopinfo") |
52 | 52 | ||
53 | extern const u8 acpi_gbl_short_op_index[]; | ||
54 | extern const u8 acpi_gbl_long_op_index[]; | ||
55 | |||
56 | static const u8 acpi_gbl_argument_count[] = | 53 | static const u8 acpi_gbl_argument_count[] = |
57 | { 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 6 }; | 54 | { 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 6 }; |
58 | 55 | ||
diff --git a/drivers/acpi/acpica/utfileio.c b/drivers/acpi/acpica/utfileio.c index 7e1168be39fa..857af824337b 100644 --- a/drivers/acpi/acpica/utfileio.c +++ b/drivers/acpi/acpica/utfileio.c | |||
@@ -198,11 +198,8 @@ acpi_ut_read_table(FILE * fp, | |||
198 | table_header.length, file_size); | 198 | table_header.length, file_size); |
199 | 199 | ||
200 | #ifdef ACPI_ASL_COMPILER | 200 | #ifdef ACPI_ASL_COMPILER |
201 | status = fl_check_for_ascii(fp, NULL, FALSE); | 201 | acpi_os_printf("File is corrupt or is ASCII text -- " |
202 | if (ACPI_SUCCESS(status)) { | 202 | "it must be a binary file\n"); |
203 | acpi_os_printf | ||
204 | ("File appears to be ASCII only, must be binary\n"); | ||
205 | } | ||
206 | #endif | 203 | #endif |
207 | return (AE_BAD_HEADER); | 204 | return (AE_BAD_HEADER); |
208 | } | 205 | } |
@@ -315,7 +312,7 @@ acpi_ut_read_table_from_file(char *filename, struct acpi_table_header ** table) | |||
315 | /* Get the entire file */ | 312 | /* Get the entire file */ |
316 | 313 | ||
317 | fprintf(stderr, | 314 | fprintf(stderr, |
318 | "Loading Acpi table from file %10s - Length %.8u (%06X)\n", | 315 | "Reading ACPI table from file %10s - Length %.8u (0x%06X)\n", |
319 | filename, file_size, file_size); | 316 | filename, file_size, file_size); |
320 | 317 | ||
321 | status = acpi_ut_read_table(file, table, &table_length); | 318 | status = acpi_ut_read_table(file, table, &table_length); |
diff --git a/drivers/acpi/acpica/uthex.c b/drivers/acpi/acpica/uthex.c index aa448278ba28..fda8b3def81c 100644 --- a/drivers/acpi/acpica/uthex.c +++ b/drivers/acpi/acpica/uthex.c | |||
@@ -75,9 +75,9 @@ char acpi_ut_hex_to_ascii_char(u64 integer, u32 position) | |||
75 | 75 | ||
76 | /******************************************************************************* | 76 | /******************************************************************************* |
77 | * | 77 | * |
78 | * FUNCTION: acpi_ut_hex_char_to_value | 78 | * FUNCTION: acpi_ut_ascii_char_to_hex |
79 | * | 79 | * |
80 | * PARAMETERS: ascii_char - Hex character in Ascii | 80 | * PARAMETERS: hex_char - Hex character in Ascii |
81 | * | 81 | * |
82 | * RETURN: The binary value of the ascii/hex character | 82 | * RETURN: The binary value of the ascii/hex character |
83 | * | 83 | * |
diff --git a/drivers/acpi/acpica/utxferror.c b/drivers/acpi/acpica/utxferror.c index 306e785f9418..98d578753101 100644 --- a/drivers/acpi/acpica/utxferror.c +++ b/drivers/acpi/acpica/utxferror.c | |||
@@ -107,9 +107,16 @@ acpi_exception(const char *module_name, | |||
107 | va_list arg_list; | 107 | va_list arg_list; |
108 | 108 | ||
109 | ACPI_MSG_REDIRECT_BEGIN; | 109 | ACPI_MSG_REDIRECT_BEGIN; |
110 | acpi_os_printf(ACPI_MSG_EXCEPTION "%s, ", | ||
111 | acpi_format_exception(status)); | ||
112 | 110 | ||
111 | /* For AE_OK, just print the message */ | ||
112 | |||
113 | if (ACPI_SUCCESS(status)) { | ||
114 | acpi_os_printf(ACPI_MSG_EXCEPTION); | ||
115 | |||
116 | } else { | ||
117 | acpi_os_printf(ACPI_MSG_EXCEPTION "%s, ", | ||
118 | acpi_format_exception(status)); | ||
119 | } | ||
113 | va_start(arg_list, format); | 120 | va_start(arg_list, format); |
114 | acpi_os_vprintf(format, arg_list); | 121 | acpi_os_vprintf(format, arg_list); |
115 | ACPI_MSG_SUFFIX; | 122 | ACPI_MSG_SUFFIX; |
diff --git a/include/acpi/acpixf.h b/include/acpi/acpixf.h index 08ef57bc8d63..d68f1cd39c49 100644 --- a/include/acpi/acpixf.h +++ b/include/acpi/acpixf.h | |||
@@ -46,7 +46,7 @@ | |||
46 | 46 | ||
47 | /* Current ACPICA subsystem version in YYYYMMDD format */ | 47 | /* Current ACPICA subsystem version in YYYYMMDD format */ |
48 | 48 | ||
49 | #define ACPI_CA_VERSION 0x20150410 | 49 | #define ACPI_CA_VERSION 0x20150515 |
50 | 50 | ||
51 | #include <acpi/acconfig.h> | 51 | #include <acpi/acconfig.h> |
52 | #include <acpi/actypes.h> | 52 | #include <acpi/actypes.h> |
diff --git a/include/acpi/actbl.h b/include/acpi/actbl.h index d4081fef1095..cb8a6b97ceda 100644 --- a/include/acpi/actbl.h +++ b/include/acpi/actbl.h | |||
@@ -284,6 +284,7 @@ struct acpi_table_fadt { | |||
284 | struct acpi_generic_address xgpe1_block; /* 64-bit Extended General Purpose Event 1 Reg Blk address */ | 284 | struct acpi_generic_address xgpe1_block; /* 64-bit Extended General Purpose Event 1 Reg Blk address */ |
285 | struct acpi_generic_address sleep_control; /* 64-bit Sleep Control register (ACPI 5.0) */ | 285 | struct acpi_generic_address sleep_control; /* 64-bit Sleep Control register (ACPI 5.0) */ |
286 | struct acpi_generic_address sleep_status; /* 64-bit Sleep Status register (ACPI 5.0) */ | 286 | struct acpi_generic_address sleep_status; /* 64-bit Sleep Status register (ACPI 5.0) */ |
287 | u64 hypervisor_id; /* Hypervisor Vendor ID (ACPI 6.0) */ | ||
287 | }; | 288 | }; |
288 | 289 | ||
289 | /* Masks for FADT IA-PC Boot Architecture Flags (boot_flags) [Vx]=Introduced in this FADT revision */ | 290 | /* Masks for FADT IA-PC Boot Architecture Flags (boot_flags) [Vx]=Introduced in this FADT revision */ |
@@ -341,7 +342,7 @@ enum acpi_preferred_pm_profiles { | |||
341 | PM_TABLET = 8 | 342 | PM_TABLET = 8 |
342 | }; | 343 | }; |
343 | 344 | ||
344 | /* Values for sleep_status and sleep_control registers (V5 FADT) */ | 345 | /* Values for sleep_status and sleep_control registers (V5+ FADT) */ |
345 | 346 | ||
346 | #define ACPI_X_WAKE_STATUS 0x80 | 347 | #define ACPI_X_WAKE_STATUS 0x80 |
347 | #define ACPI_X_SLEEP_TYPE_MASK 0x1C | 348 | #define ACPI_X_SLEEP_TYPE_MASK 0x1C |
@@ -398,15 +399,17 @@ struct acpi_table_desc { | |||
398 | * FADT is the bottom line as to what the version really is. | 399 | * FADT is the bottom line as to what the version really is. |
399 | * | 400 | * |
400 | * For reference, the values below are as follows: | 401 | * For reference, the values below are as follows: |
401 | * FADT V1 size: 0x074 | 402 | * FADT V1 size: 0x074 |
402 | * FADT V2 size: 0x084 | 403 | * FADT V2 size: 0x084 |
403 | * FADT V3 size: 0x0F4 | 404 | * FADT V3 size: 0x0F4 |
404 | * FADT V4 size: 0x0F4 | 405 | * FADT V4 size: 0x0F4 |
405 | * FADT V5 size: 0x10C | 406 | * FADT V5 size: 0x10C |
407 | * FADT V6 size: 0x114 | ||
406 | */ | 408 | */ |
407 | #define ACPI_FADT_V1_SIZE (u32) (ACPI_FADT_OFFSET (flags) + 4) | 409 | #define ACPI_FADT_V1_SIZE (u32) (ACPI_FADT_OFFSET (flags) + 4) |
408 | #define ACPI_FADT_V2_SIZE (u32) (ACPI_FADT_OFFSET (minor_revision) + 1) | 410 | #define ACPI_FADT_V2_SIZE (u32) (ACPI_FADT_OFFSET (minor_revision) + 1) |
409 | #define ACPI_FADT_V3_SIZE (u32) (ACPI_FADT_OFFSET (sleep_control)) | 411 | #define ACPI_FADT_V3_SIZE (u32) (ACPI_FADT_OFFSET (sleep_control)) |
410 | #define ACPI_FADT_V5_SIZE (u32) (sizeof (struct acpi_table_fadt)) | 412 | #define ACPI_FADT_V5_SIZE (u32) (ACPI_FADT_OFFSET (hypervisor_id)) |
413 | #define ACPI_FADT_V6_SIZE (u32) (sizeof (struct acpi_table_fadt)) | ||
411 | 414 | ||
412 | #endif /* __ACTBL_H__ */ | 415 | #endif /* __ACTBL_H__ */ |
diff --git a/include/acpi/actbl1.h b/include/acpi/actbl1.h index b80b0e6dabc5..06b61f01ea59 100644 --- a/include/acpi/actbl1.h +++ b/include/acpi/actbl1.h | |||
@@ -71,6 +71,7 @@ | |||
71 | #define ACPI_SIG_SBST "SBST" /* Smart Battery Specification Table */ | 71 | #define ACPI_SIG_SBST "SBST" /* Smart Battery Specification Table */ |
72 | #define ACPI_SIG_SLIT "SLIT" /* System Locality Distance Information Table */ | 72 | #define ACPI_SIG_SLIT "SLIT" /* System Locality Distance Information Table */ |
73 | #define ACPI_SIG_SRAT "SRAT" /* System Resource Affinity Table */ | 73 | #define ACPI_SIG_SRAT "SRAT" /* System Resource Affinity Table */ |
74 | #define ACPI_SIG_NFIT "NFIT" /* NVDIMM Firmware Interface Table */ | ||
74 | 75 | ||
75 | /* | 76 | /* |
76 | * All tables must be byte-packed to match the ACPI specification, since | 77 | * All tables must be byte-packed to match the ACPI specification, since |
@@ -673,7 +674,8 @@ enum acpi_madt_type { | |||
673 | ACPI_MADT_TYPE_GENERIC_DISTRIBUTOR = 12, | 674 | ACPI_MADT_TYPE_GENERIC_DISTRIBUTOR = 12, |
674 | ACPI_MADT_TYPE_GENERIC_MSI_FRAME = 13, | 675 | ACPI_MADT_TYPE_GENERIC_MSI_FRAME = 13, |
675 | ACPI_MADT_TYPE_GENERIC_REDISTRIBUTOR = 14, | 676 | ACPI_MADT_TYPE_GENERIC_REDISTRIBUTOR = 14, |
676 | ACPI_MADT_TYPE_RESERVED = 15 /* 15 and greater are reserved */ | 677 | ACPI_MADT_TYPE_GENERIC_TRANSLATOR = 15, |
678 | ACPI_MADT_TYPE_RESERVED = 16 /* 16 and greater are reserved */ | ||
677 | }; | 679 | }; |
678 | 680 | ||
679 | /* | 681 | /* |
@@ -794,7 +796,7 @@ struct acpi_madt_local_x2apic_nmi { | |||
794 | u8 reserved[3]; /* reserved - must be zero */ | 796 | u8 reserved[3]; /* reserved - must be zero */ |
795 | }; | 797 | }; |
796 | 798 | ||
797 | /* 11: Generic Interrupt (ACPI 5.0) */ | 799 | /* 11: Generic Interrupt (ACPI 5.0 + ACPI 6.0 changes) */ |
798 | 800 | ||
799 | struct acpi_madt_generic_interrupt { | 801 | struct acpi_madt_generic_interrupt { |
800 | struct acpi_subtable_header header; | 802 | struct acpi_subtable_header header; |
@@ -811,6 +813,8 @@ struct acpi_madt_generic_interrupt { | |||
811 | u32 vgic_interrupt; | 813 | u32 vgic_interrupt; |
812 | u64 gicr_base_address; | 814 | u64 gicr_base_address; |
813 | u64 arm_mpidr; | 815 | u64 arm_mpidr; |
816 | u8 efficiency_class; | ||
817 | u8 reserved2[3]; | ||
814 | }; | 818 | }; |
815 | 819 | ||
816 | /* Masks for Flags field above */ | 820 | /* Masks for Flags field above */ |
@@ -819,7 +823,7 @@ struct acpi_madt_generic_interrupt { | |||
819 | #define ACPI_MADT_PERFORMANCE_IRQ_MODE (1<<1) /* 01: Performance Interrupt Mode */ | 823 | #define ACPI_MADT_PERFORMANCE_IRQ_MODE (1<<1) /* 01: Performance Interrupt Mode */ |
820 | #define ACPI_MADT_VGIC_IRQ_MODE (1<<2) /* 02: VGIC Maintenance Interrupt mode */ | 824 | #define ACPI_MADT_VGIC_IRQ_MODE (1<<2) /* 02: VGIC Maintenance Interrupt mode */ |
821 | 825 | ||
822 | /* 12: Generic Distributor (ACPI 5.0) */ | 826 | /* 12: Generic Distributor (ACPI 5.0 + ACPI 6.0 changes) */ |
823 | 827 | ||
824 | struct acpi_madt_generic_distributor { | 828 | struct acpi_madt_generic_distributor { |
825 | struct acpi_subtable_header header; | 829 | struct acpi_subtable_header header; |
@@ -827,7 +831,8 @@ struct acpi_madt_generic_distributor { | |||
827 | u32 gic_id; | 831 | u32 gic_id; |
828 | u64 base_address; | 832 | u64 base_address; |
829 | u32 global_irq_base; | 833 | u32 global_irq_base; |
830 | u32 reserved2; /* reserved - must be zero */ | 834 | u8 version; |
835 | u8 reserved2[3]; /* reserved - must be zero */ | ||
831 | }; | 836 | }; |
832 | 837 | ||
833 | /* 13: Generic MSI Frame (ACPI 5.1) */ | 838 | /* 13: Generic MSI Frame (ACPI 5.1) */ |
@@ -855,6 +860,16 @@ struct acpi_madt_generic_redistributor { | |||
855 | u32 length; | 860 | u32 length; |
856 | }; | 861 | }; |
857 | 862 | ||
863 | /* 15: Generic Translator (ACPI 6.0) */ | ||
864 | |||
865 | struct acpi_madt_generic_translator { | ||
866 | struct acpi_subtable_header header; | ||
867 | u16 reserved; /* reserved - must be zero */ | ||
868 | u32 translation_id; | ||
869 | u64 base_address; | ||
870 | u32 reserved2; | ||
871 | }; | ||
872 | |||
858 | /* | 873 | /* |
859 | * Common flags fields for MADT subtables | 874 | * Common flags fields for MADT subtables |
860 | */ | 875 | */ |
@@ -908,6 +923,159 @@ struct acpi_msct_proximity { | |||
908 | 923 | ||
909 | /******************************************************************************* | 924 | /******************************************************************************* |
910 | * | 925 | * |
926 | * NFIT - NVDIMM Interface Table (ACPI 6.0) | ||
927 | * Version 1 | ||
928 | * | ||
929 | ******************************************************************************/ | ||
930 | |||
931 | struct acpi_table_nfit { | ||
932 | struct acpi_table_header header; /* Common ACPI table header */ | ||
933 | u32 reserved; /* Reserved, must be zero */ | ||
934 | }; | ||
935 | |||
936 | /* Subtable header for NFIT */ | ||
937 | |||
938 | struct acpi_nfit_header { | ||
939 | u16 type; | ||
940 | u16 length; | ||
941 | }; | ||
942 | |||
943 | /* Values for subtable type in struct acpi_nfit_header */ | ||
944 | |||
945 | enum acpi_nfit_type { | ||
946 | ACPI_NFIT_TYPE_SYSTEM_ADDRESS = 0, | ||
947 | ACPI_NFIT_TYPE_MEMORY_MAP = 1, | ||
948 | ACPI_NFIT_TYPE_INTERLEAVE = 2, | ||
949 | ACPI_NFIT_TYPE_SMBIOS = 3, | ||
950 | ACPI_NFIT_TYPE_CONTROL_REGION = 4, | ||
951 | ACPI_NFIT_TYPE_DATA_REGION = 5, | ||
952 | ACPI_NFIT_TYPE_FLUSH_ADDRESS = 6, | ||
953 | ACPI_NFIT_TYPE_RESERVED = 7 /* 7 and greater are reserved */ | ||
954 | }; | ||
955 | |||
956 | /* | ||
957 | * NFIT Subtables | ||
958 | */ | ||
959 | |||
960 | /* 0: System Physical Address Range Structure */ | ||
961 | |||
962 | struct acpi_nfit_system_address { | ||
963 | struct acpi_nfit_header header; | ||
964 | u16 range_index; | ||
965 | u16 flags; | ||
966 | u32 reserved; /* Reseved, must be zero */ | ||
967 | u32 proximity_domain; | ||
968 | u8 range_guid[16]; | ||
969 | u64 address; | ||
970 | u64 length; | ||
971 | u64 memory_mapping; | ||
972 | }; | ||
973 | |||
974 | /* Flags */ | ||
975 | |||
976 | #define ACPI_NFIT_ADD_ONLINE_ONLY (1) /* 00: Add/Online Operation Only */ | ||
977 | #define ACPI_NFIT_PROXIMITY_VALID (1<<1) /* 01: Proximity Domain Valid */ | ||
978 | |||
979 | /* Range Type GUIDs appear in the include/acuuid.h file */ | ||
980 | |||
981 | /* 1: Memory Device to System Address Range Map Structure */ | ||
982 | |||
983 | struct acpi_nfit_memory_map { | ||
984 | struct acpi_nfit_header header; | ||
985 | u32 device_handle; | ||
986 | u16 physical_id; | ||
987 | u16 region_id; | ||
988 | u16 range_index; | ||
989 | u16 region_index; | ||
990 | u64 region_size; | ||
991 | u64 region_offset; | ||
992 | u64 address; | ||
993 | u16 interleave_index; | ||
994 | u16 interleave_ways; | ||
995 | u16 flags; | ||
996 | u16 reserved; /* Reserved, must be zero */ | ||
997 | }; | ||
998 | |||
999 | /* Flags */ | ||
1000 | |||
1001 | #define ACPI_NFIT_MEM_SAVE_FAILED (1) /* 00: Last SAVE to Memory Device failed */ | ||
1002 | #define ACPI_NFIT_MEM_RESTORE_FAILED (1<<1) /* 01: Last RESTORE from Memory Device failed */ | ||
1003 | #define ACPI_NFIT_MEM_FLUSH_FAILED (1<<2) /* 02: Platform flush failed */ | ||
1004 | #define ACPI_NFIT_MEM_ARMED (1<<3) /* 03: Memory Device observed to be not armed */ | ||
1005 | #define ACPI_NFIT_MEM_HEALTH_OBSERVED (1<<4) /* 04: Memory Device observed SMART/health events */ | ||
1006 | #define ACPI_NFIT_MEM_HEALTH_ENABLED (1<<5) /* 05: SMART/health events enabled */ | ||
1007 | |||
1008 | /* 2: Interleave Structure */ | ||
1009 | |||
1010 | struct acpi_nfit_interleave { | ||
1011 | struct acpi_nfit_header header; | ||
1012 | u16 interleave_index; | ||
1013 | u16 reserved; /* Reserved, must be zero */ | ||
1014 | u32 line_count; | ||
1015 | u32 line_size; | ||
1016 | u32 line_offset[1]; /* Variable length */ | ||
1017 | }; | ||
1018 | |||
1019 | /* 3: SMBIOS Management Information Structure */ | ||
1020 | |||
1021 | struct acpi_nfit_smbios { | ||
1022 | struct acpi_nfit_header header; | ||
1023 | u32 reserved; /* Reserved, must be zero */ | ||
1024 | u8 data[1]; /* Variable length */ | ||
1025 | }; | ||
1026 | |||
1027 | /* 4: NVDIMM Control Region Structure */ | ||
1028 | |||
1029 | struct acpi_nfit_control_region { | ||
1030 | struct acpi_nfit_header header; | ||
1031 | u16 region_index; | ||
1032 | u16 vendor_id; | ||
1033 | u16 device_id; | ||
1034 | u16 revision_id; | ||
1035 | u16 subsystem_vendor_id; | ||
1036 | u16 subsystem_device_id; | ||
1037 | u16 subsystem_revision_id; | ||
1038 | u8 reserved[6]; /* Reserved, must be zero */ | ||
1039 | u32 serial_number; | ||
1040 | u16 code; | ||
1041 | u16 windows; | ||
1042 | u64 window_size; | ||
1043 | u64 command_offset; | ||
1044 | u64 command_size; | ||
1045 | u64 status_offset; | ||
1046 | u64 status_size; | ||
1047 | u16 flags; | ||
1048 | u8 reserved1[6]; /* Reserved, must be zero */ | ||
1049 | }; | ||
1050 | |||
1051 | /* Flags */ | ||
1052 | |||
1053 | #define ACPI_NFIT_CONTROL_BUFFERED (1) /* Block Data Windows implementation is buffered */ | ||
1054 | |||
1055 | /* 5: NVDIMM Block Data Window Region Structure */ | ||
1056 | |||
1057 | struct acpi_nfit_data_region { | ||
1058 | struct acpi_nfit_header header; | ||
1059 | u16 region_index; | ||
1060 | u16 windows; | ||
1061 | u64 offset; | ||
1062 | u64 size; | ||
1063 | u64 capacity; | ||
1064 | u64 start_address; | ||
1065 | }; | ||
1066 | |||
1067 | /* 6: Flush Hint Address Structure */ | ||
1068 | |||
1069 | struct acpi_nfit_flush_address { | ||
1070 | struct acpi_nfit_header header; | ||
1071 | u32 device_handle; | ||
1072 | u16 hint_count; | ||
1073 | u8 reserved[6]; /* Reserved, must be zero */ | ||
1074 | u64 hint_address[1]; /* Variable length */ | ||
1075 | }; | ||
1076 | |||
1077 | /******************************************************************************* | ||
1078 | * | ||
911 | * SBST - Smart Battery Specification Table | 1079 | * SBST - Smart Battery Specification Table |
912 | * Version 1 | 1080 | * Version 1 |
913 | * | 1081 | * |
diff --git a/include/acpi/actbl2.h b/include/acpi/actbl2.h index cafdeb50fbdf..370d69d871a0 100644 --- a/include/acpi/actbl2.h +++ b/include/acpi/actbl2.h | |||
@@ -69,6 +69,7 @@ | |||
69 | #define ACPI_SIG_DMAR "DMAR" /* DMA Remapping table */ | 69 | #define ACPI_SIG_DMAR "DMAR" /* DMA Remapping table */ |
70 | #define ACPI_SIG_HPET "HPET" /* High Precision Event Timer table */ | 70 | #define ACPI_SIG_HPET "HPET" /* High Precision Event Timer table */ |
71 | #define ACPI_SIG_IBFT "IBFT" /* iSCSI Boot Firmware Table */ | 71 | #define ACPI_SIG_IBFT "IBFT" /* iSCSI Boot Firmware Table */ |
72 | #define ACPI_SIG_IORT "IORT" /* IO Remapping Table */ | ||
72 | #define ACPI_SIG_IVRS "IVRS" /* I/O Virtualization Reporting Structure */ | 73 | #define ACPI_SIG_IVRS "IVRS" /* I/O Virtualization Reporting Structure */ |
73 | #define ACPI_SIG_LPIT "LPIT" /* Low Power Idle Table */ | 74 | #define ACPI_SIG_LPIT "LPIT" /* Low Power Idle Table */ |
74 | #define ACPI_SIG_MCFG "MCFG" /* PCI Memory Mapped Configuration table */ | 75 | #define ACPI_SIG_MCFG "MCFG" /* PCI Memory Mapped Configuration table */ |
@@ -650,6 +651,131 @@ struct acpi_ibft_target { | |||
650 | 651 | ||
651 | /******************************************************************************* | 652 | /******************************************************************************* |
652 | * | 653 | * |
654 | * IORT - IO Remapping Table | ||
655 | * | ||
656 | * Conforms to "IO Remapping Table System Software on ARM Platforms", | ||
657 | * Document number: ARM DEN 0049A, 2015 | ||
658 | * | ||
659 | ******************************************************************************/ | ||
660 | |||
661 | struct acpi_table_iort { | ||
662 | struct acpi_table_header header; | ||
663 | u32 node_count; | ||
664 | u32 node_offset; | ||
665 | u32 reserved; | ||
666 | }; | ||
667 | |||
668 | /* | ||
669 | * IORT subtables | ||
670 | */ | ||
671 | struct acpi_iort_node { | ||
672 | u8 type; | ||
673 | u16 length; | ||
674 | u8 revision; | ||
675 | u32 reserved; | ||
676 | u32 mapping_count; | ||
677 | u32 mapping_offset; | ||
678 | char node_data[1]; | ||
679 | }; | ||
680 | |||
681 | /* Values for subtable Type above */ | ||
682 | |||
683 | enum acpi_iort_node_type { | ||
684 | ACPI_IORT_NODE_ITS_GROUP = 0x00, | ||
685 | ACPI_IORT_NODE_NAMED_COMPONENT = 0x01, | ||
686 | ACPI_IORT_NODE_PCI_ROOT_COMPLEX = 0x02, | ||
687 | ACPI_IORT_NODE_SMMU = 0x03 | ||
688 | }; | ||
689 | |||
690 | struct acpi_iort_id_mapping { | ||
691 | u32 input_base; /* Lowest value in input range */ | ||
692 | u32 id_count; /* Number of IDs */ | ||
693 | u32 output_base; /* Lowest value in output range */ | ||
694 | u32 output_reference; /* A reference to the output node */ | ||
695 | u32 flags; | ||
696 | }; | ||
697 | |||
698 | /* Masks for Flags field above for IORT subtable */ | ||
699 | |||
700 | #define ACPI_IORT_ID_SINGLE_MAPPING (1) | ||
701 | |||
702 | struct acpi_iort_memory_access { | ||
703 | u32 cache_coherency; | ||
704 | u8 hints; | ||
705 | u16 reserved; | ||
706 | u8 memory_flags; | ||
707 | }; | ||
708 | |||
709 | /* Values for cache_coherency field above */ | ||
710 | |||
711 | #define ACPI_IORT_NODE_COHERENT 0x00000001 /* The device node is fully coherent */ | ||
712 | #define ACPI_IORT_NODE_NOT_COHERENT 0x00000000 /* The device node is not coherent */ | ||
713 | |||
714 | /* Masks for Hints field above */ | ||
715 | |||
716 | #define ACPI_IORT_HT_TRANSIENT (1) | ||
717 | #define ACPI_IORT_HT_WRITE (1<<1) | ||
718 | #define ACPI_IORT_HT_READ (1<<2) | ||
719 | #define ACPI_IORT_HT_OVERRIDE (1<<3) | ||
720 | |||
721 | /* Masks for memory_flags field above */ | ||
722 | |||
723 | #define ACPI_IORT_MF_COHERENCY (1) | ||
724 | #define ACPI_IORT_MF_ATTRIBUTES (1<<1) | ||
725 | |||
726 | /* | ||
727 | * IORT node specific subtables | ||
728 | */ | ||
729 | struct acpi_iort_its_group { | ||
730 | u32 its_count; | ||
731 | u32 identifiers[1]; /* GIC ITS identifier arrary */ | ||
732 | }; | ||
733 | |||
734 | struct acpi_iort_named_component { | ||
735 | u32 node_flags; | ||
736 | u64 memory_properties; /* Memory access properties */ | ||
737 | u8 memory_address_limit; /* Memory address size limit */ | ||
738 | char device_name[1]; /* Path of namespace object */ | ||
739 | }; | ||
740 | |||
741 | struct acpi_iort_root_complex { | ||
742 | u64 memory_properties; /* Memory access properties */ | ||
743 | u32 ats_attribute; | ||
744 | u32 pci_segment_number; | ||
745 | }; | ||
746 | |||
747 | /* Values for ats_attribute field above */ | ||
748 | |||
749 | #define ACPI_IORT_ATS_SUPPORTED 0x00000001 /* The root complex supports ATS */ | ||
750 | #define ACPI_IORT_ATS_UNSUPPORTED 0x00000000 /* The root complex doesn't support ATS */ | ||
751 | |||
752 | struct acpi_iort_smmu { | ||
753 | u64 base_address; /* SMMU base address */ | ||
754 | u64 span; /* Length of memory range */ | ||
755 | u32 model; | ||
756 | u32 flags; | ||
757 | u32 global_interrupt_offset; | ||
758 | u32 context_interrupt_count; | ||
759 | u32 context_interrupt_offset; | ||
760 | u32 pmu_interrupt_count; | ||
761 | u32 pmu_interrupt_offset; | ||
762 | u64 interrupts[1]; /* Interrupt array */ | ||
763 | }; | ||
764 | |||
765 | /* Values for Model field above */ | ||
766 | |||
767 | #define ACPI_IORT_SMMU_V1 0x00000000 /* Generic SMMUv1 */ | ||
768 | #define ACPI_IORT_SMMU_V2 0x00000001 /* Generic SMMUv2 */ | ||
769 | #define ACPI_IORT_SMMU_CORELINK_MMU400 0x00000002 /* ARM Corelink MMU-400 */ | ||
770 | #define ACPI_IORT_SMMU_CORELINK_MMU500 0x00000003 /* ARM Corelink MMU-500 */ | ||
771 | |||
772 | /* Masks for Flags field above */ | ||
773 | |||
774 | #define ACPI_IORT_SMMU_DVM_SUPPORTED (1) | ||
775 | #define ACPI_IORT_SMMU_COHERENT_WALK (1<<1) | ||
776 | |||
777 | /******************************************************************************* | ||
778 | * | ||
653 | * IVRS - I/O Virtualization Reporting Structure | 779 | * IVRS - I/O Virtualization Reporting Structure |
654 | * Version 1 | 780 | * Version 1 |
655 | * | 781 | * |
@@ -824,7 +950,7 @@ struct acpi_ivrs_memory { | |||
824 | * | 950 | * |
825 | * LPIT - Low Power Idle Table | 951 | * LPIT - Low Power Idle Table |
826 | * | 952 | * |
827 | * Conforms to "ACPI Low Power Idle Table (LPIT) and _LPD Proposal (DRAFT)" | 953 | * Conforms to "ACPI Low Power Idle Table (LPIT)" July 2014. |
828 | * | 954 | * |
829 | ******************************************************************************/ | 955 | ******************************************************************************/ |
830 | 956 | ||
@@ -846,8 +972,7 @@ struct acpi_lpit_header { | |||
846 | 972 | ||
847 | enum acpi_lpit_type { | 973 | enum acpi_lpit_type { |
848 | ACPI_LPIT_TYPE_NATIVE_CSTATE = 0x00, | 974 | ACPI_LPIT_TYPE_NATIVE_CSTATE = 0x00, |
849 | ACPI_LPIT_TYPE_SIMPLE_IO = 0x01, | 975 | ACPI_LPIT_TYPE_RESERVED = 0x01 /* 1 and above are reserved */ |
850 | ACPI_LPIT_TYPE_RESERVED = 0x02 /* 2 and above are reserved */ | ||
851 | }; | 976 | }; |
852 | 977 | ||
853 | /* Masks for Flags field above */ | 978 | /* Masks for Flags field above */ |
@@ -870,21 +995,6 @@ struct acpi_lpit_native { | |||
870 | u64 counter_frequency; | 995 | u64 counter_frequency; |
871 | }; | 996 | }; |
872 | 997 | ||
873 | /* 0x01: Simple I/O based LPI structure */ | ||
874 | |||
875 | struct acpi_lpit_io { | ||
876 | struct acpi_lpit_header header; | ||
877 | struct acpi_generic_address entry_trigger; | ||
878 | u32 trigger_action; | ||
879 | u64 trigger_value; | ||
880 | u64 trigger_mask; | ||
881 | struct acpi_generic_address minimum_idle_state; | ||
882 | u32 residency; | ||
883 | u32 latency; | ||
884 | struct acpi_generic_address residency_counter; | ||
885 | u64 counter_frequency; | ||
886 | }; | ||
887 | |||
888 | /******************************************************************************* | 998 | /******************************************************************************* |
889 | * | 999 | * |
890 | * MCFG - PCI Memory Mapped Configuration table and subtable | 1000 | * MCFG - PCI Memory Mapped Configuration table and subtable |
diff --git a/include/acpi/actbl3.h b/include/acpi/actbl3.h index 440ca8104b43..4018986d2a2e 100644 --- a/include/acpi/actbl3.h +++ b/include/acpi/actbl3.h | |||
@@ -68,7 +68,10 @@ | |||
68 | #define ACPI_SIG_PCCT "PCCT" /* Platform Communications Channel Table */ | 68 | #define ACPI_SIG_PCCT "PCCT" /* Platform Communications Channel Table */ |
69 | #define ACPI_SIG_PMTT "PMTT" /* Platform Memory Topology Table */ | 69 | #define ACPI_SIG_PMTT "PMTT" /* Platform Memory Topology Table */ |
70 | #define ACPI_SIG_RASF "RASF" /* RAS Feature table */ | 70 | #define ACPI_SIG_RASF "RASF" /* RAS Feature table */ |
71 | #define ACPI_SIG_STAO "STAO" /* Status Override table */ | ||
71 | #define ACPI_SIG_TPM2 "TPM2" /* Trusted Platform Module 2.0 H/W interface table */ | 72 | #define ACPI_SIG_TPM2 "TPM2" /* Trusted Platform Module 2.0 H/W interface table */ |
73 | #define ACPI_SIG_WPBT "WPBT" /* Windows Platform Binary Table */ | ||
74 | #define ACPI_SIG_XENV "XENV" /* Xen Environment table */ | ||
72 | 75 | ||
73 | #define ACPI_SIG_S3PT "S3PT" /* S3 Performance (sub)Table */ | 76 | #define ACPI_SIG_S3PT "S3PT" /* S3 Performance (sub)Table */ |
74 | #define ACPI_SIG_PCCS "PCC" /* PCC Shared Memory Region */ | 77 | #define ACPI_SIG_PCCS "PCC" /* PCC Shared Memory Region */ |
@@ -77,7 +80,6 @@ | |||
77 | 80 | ||
78 | #define ACPI_SIG_MATR "MATR" /* Memory Address Translation Table */ | 81 | #define ACPI_SIG_MATR "MATR" /* Memory Address Translation Table */ |
79 | #define ACPI_SIG_MSDM "MSDM" /* Microsoft Data Management Table */ | 82 | #define ACPI_SIG_MSDM "MSDM" /* Microsoft Data Management Table */ |
80 | #define ACPI_SIG_WPBT "WPBT" /* Windows Platform Binary Table */ | ||
81 | 83 | ||
82 | /* | 84 | /* |
83 | * All tables must be byte-packed to match the ACPI specification, since | 85 | * All tables must be byte-packed to match the ACPI specification, since |
@@ -117,6 +119,8 @@ struct acpi_table_bgrt { | |||
117 | /******************************************************************************* | 119 | /******************************************************************************* |
118 | * | 120 | * |
119 | * DRTM - Dynamic Root of Trust for Measurement table | 121 | * DRTM - Dynamic Root of Trust for Measurement table |
122 | * Conforms to "TCG D-RTM Architecture" June 17 2013, Version 1.0.0 | ||
123 | * Table version 1 | ||
120 | * | 124 | * |
121 | ******************************************************************************/ | 125 | ******************************************************************************/ |
122 | 126 | ||
@@ -133,22 +137,40 @@ struct acpi_table_drtm { | |||
133 | u32 flags; | 137 | u32 flags; |
134 | }; | 138 | }; |
135 | 139 | ||
136 | /* 1) Validated Tables List */ | 140 | /* Flag Definitions for above */ |
141 | |||
142 | #define ACPI_DRTM_ACCESS_ALLOWED (1) | ||
143 | #define ACPI_DRTM_ENABLE_GAP_CODE (1<<1) | ||
144 | #define ACPI_DRTM_INCOMPLETE_MEASUREMENTS (1<<2) | ||
145 | #define ACPI_DRTM_AUTHORITY_ORDER (1<<3) | ||
137 | 146 | ||
138 | struct acpi_drtm_vtl_list { | 147 | /* 1) Validated Tables List (64-bit addresses) */ |
139 | u32 validated_table_list_count; | 148 | |
149 | struct acpi_drtm_vtable_list { | ||
150 | u32 validated_table_count; | ||
151 | u64 validated_tables[1]; | ||
140 | }; | 152 | }; |
141 | 153 | ||
142 | /* 2) Resources List */ | 154 | /* 2) Resources List (of Resource Descriptors) */ |
155 | |||
156 | /* Resource Descriptor */ | ||
157 | |||
158 | struct acpi_drtm_resource { | ||
159 | u8 size[7]; | ||
160 | u8 type; | ||
161 | u64 address; | ||
162 | }; | ||
143 | 163 | ||
144 | struct acpi_drtm_resource_list { | 164 | struct acpi_drtm_resource_list { |
145 | u32 resource_list_count; | 165 | u32 resource_count; |
166 | struct acpi_drtm_resource resources[1]; | ||
146 | }; | 167 | }; |
147 | 168 | ||
148 | /* 3) Platform-specific Identifiers List */ | 169 | /* 3) Platform-specific Identifiers List */ |
149 | 170 | ||
150 | struct acpi_drtm_id_list { | 171 | struct acpi_drtm_dps_id { |
151 | u32 id_list_count; | 172 | u32 dps_id_length; |
173 | u8 dps_id[16]; | ||
152 | }; | 174 | }; |
153 | 175 | ||
154 | /******************************************************************************* | 176 | /******************************************************************************* |
@@ -685,6 +707,21 @@ enum acpi_rasf_status { | |||
685 | 707 | ||
686 | /******************************************************************************* | 708 | /******************************************************************************* |
687 | * | 709 | * |
710 | * STAO - Status Override Table (_STA override) - ACPI 6.0 | ||
711 | * Version 1 | ||
712 | * | ||
713 | * Conforms to "ACPI Specification for Status Override Table" | ||
714 | * 6 January 2015 | ||
715 | * | ||
716 | ******************************************************************************/ | ||
717 | |||
718 | struct acpi_table_stao { | ||
719 | struct acpi_table_header header; /* Common ACPI table header */ | ||
720 | u8 ignore_uart; | ||
721 | }; | ||
722 | |||
723 | /******************************************************************************* | ||
724 | * | ||
688 | * TPM2 - Trusted Platform Module (TPM) 2.0 Hardware Interface Table | 725 | * TPM2 - Trusted Platform Module (TPM) 2.0 Hardware Interface Table |
689 | * Version 3 | 726 | * Version 3 |
690 | * | 727 | * |
@@ -713,6 +750,41 @@ struct acpi_tpm2_control { | |||
713 | u64 response_address; | 750 | u64 response_address; |
714 | }; | 751 | }; |
715 | 752 | ||
753 | /******************************************************************************* | ||
754 | * | ||
755 | * WPBT - Windows Platform Environment Table (ACPI 6.0) | ||
756 | * Version 1 | ||
757 | * | ||
758 | * Conforms to "Windows Platform Binary Table (WPBT)" 29 November 2011 | ||
759 | * | ||
760 | ******************************************************************************/ | ||
761 | |||
762 | struct acpi_table_wpbt { | ||
763 | struct acpi_table_header header; /* Common ACPI table header */ | ||
764 | u32 handoff_size; | ||
765 | u64 handoff_address; | ||
766 | u8 layout; | ||
767 | u8 type; | ||
768 | u16 arguments_length; | ||
769 | }; | ||
770 | |||
771 | /******************************************************************************* | ||
772 | * | ||
773 | * XENV - Xen Environment Table (ACPI 6.0) | ||
774 | * Version 1 | ||
775 | * | ||
776 | * Conforms to "ACPI Specification for Xen Environment Table" 4 January 2015 | ||
777 | * | ||
778 | ******************************************************************************/ | ||
779 | |||
780 | struct acpi_table_xenv { | ||
781 | struct acpi_table_header header; /* Common ACPI table header */ | ||
782 | u64 grant_table_address; | ||
783 | u64 grant_table_size; | ||
784 | u32 event_interrupt; | ||
785 | u8 event_flags; | ||
786 | }; | ||
787 | |||
716 | /* Reset to default packing */ | 788 | /* Reset to default packing */ |
717 | 789 | ||
718 | #pragma pack() | 790 | #pragma pack() |
diff --git a/include/acpi/actypes.h b/include/acpi/actypes.h index 1c3002e1db20..63fd7f5e9fb3 100644 --- a/include/acpi/actypes.h +++ b/include/acpi/actypes.h | |||
@@ -471,11 +471,6 @@ typedef u8 acpi_owner_id; | |||
471 | 471 | ||
472 | #define ACPI_INTEGER_BIT_SIZE 64 | 472 | #define ACPI_INTEGER_BIT_SIZE 64 |
473 | #define ACPI_MAX_DECIMAL_DIGITS 20 /* 2^64 = 18,446,744,073,709,551,616 */ | 473 | #define ACPI_MAX_DECIMAL_DIGITS 20 /* 2^64 = 18,446,744,073,709,551,616 */ |
474 | |||
475 | #if ACPI_MACHINE_WIDTH == 64 | ||
476 | #define ACPI_USE_NATIVE_DIVIDE /* Use compiler native 64-bit divide */ | ||
477 | #endif | ||
478 | |||
479 | #define ACPI_MAX64_DECIMAL_DIGITS 20 | 474 | #define ACPI_MAX64_DECIMAL_DIGITS 20 |
480 | #define ACPI_MAX32_DECIMAL_DIGITS 10 | 475 | #define ACPI_MAX32_DECIMAL_DIGITS 10 |
481 | #define ACPI_MAX16_DECIMAL_DIGITS 5 | 476 | #define ACPI_MAX16_DECIMAL_DIGITS 5 |
@@ -530,6 +525,7 @@ typedef u64 acpi_integer; | |||
530 | #define ACPI_CAST_PTR(t, p) ((t *) (acpi_uintptr_t) (p)) | 525 | #define ACPI_CAST_PTR(t, p) ((t *) (acpi_uintptr_t) (p)) |
531 | #define ACPI_CAST_INDIRECT_PTR(t, p) ((t **) (acpi_uintptr_t) (p)) | 526 | #define ACPI_CAST_INDIRECT_PTR(t, p) ((t **) (acpi_uintptr_t) (p)) |
532 | #define ACPI_ADD_PTR(t, a, b) ACPI_CAST_PTR (t, (ACPI_CAST_PTR (u8, (a)) + (acpi_size)(b))) | 527 | #define ACPI_ADD_PTR(t, a, b) ACPI_CAST_PTR (t, (ACPI_CAST_PTR (u8, (a)) + (acpi_size)(b))) |
528 | #define ACPI_SUB_PTR(t, a, b) ACPI_CAST_PTR (t, (ACPI_CAST_PTR (u8, (a)) - (acpi_size)(b))) | ||
533 | #define ACPI_PTR_DIFF(a, b) (acpi_size) (ACPI_CAST_PTR (u8, (a)) - ACPI_CAST_PTR (u8, (b))) | 529 | #define ACPI_PTR_DIFF(a, b) (acpi_size) (ACPI_CAST_PTR (u8, (a)) - ACPI_CAST_PTR (u8, (b))) |
534 | 530 | ||
535 | /* Pointer/Integer type conversions */ | 531 | /* Pointer/Integer type conversions */ |
diff --git a/include/acpi/acuuid.h b/include/acpi/acuuid.h new file mode 100644 index 000000000000..80fe8cf74d7a --- /dev/null +++ b/include/acpi/acuuid.h | |||
@@ -0,0 +1,89 @@ | |||
1 | /****************************************************************************** | ||
2 | * | ||
3 | * Name: acuuid.h - ACPI-related UUID/GUID definitions | ||
4 | * | ||
5 | *****************************************************************************/ | ||
6 | |||
7 | /* | ||
8 | * Copyright (C) 2000 - 2015, Intel Corp. | ||
9 | * All rights reserved. | ||
10 | * | ||
11 | * Redistribution and use in source and binary forms, with or without | ||
12 | * modification, are permitted provided that the following conditions | ||
13 | * are met: | ||
14 | * 1. Redistributions of source code must retain the above copyright | ||
15 | * notice, this list of conditions, and the following disclaimer, | ||
16 | * without modification. | ||
17 | * 2. Redistributions in binary form must reproduce at minimum a disclaimer | ||
18 | * substantially similar to the "NO WARRANTY" disclaimer below | ||
19 | * ("Disclaimer") and any redistribution must be conditioned upon | ||
20 | * including a substantially similar Disclaimer requirement for further | ||
21 | * binary redistribution. | ||
22 | * 3. Neither the names of the above-listed copyright holders nor the names | ||
23 | * of any contributors may be used to endorse or promote products derived | ||
24 | * from this software without specific prior written permission. | ||
25 | * | ||
26 | * Alternatively, this software may be distributed under the terms of the | ||
27 | * GNU General Public License ("GPL") version 2 as published by the Free | ||
28 | * Software Foundation. | ||
29 | * | ||
30 | * NO WARRANTY | ||
31 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | ||
32 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | ||
33 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR | ||
34 | * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | ||
35 | * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
36 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS | ||
37 | * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | ||
38 | * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, | ||
39 | * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING | ||
40 | * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE | ||
41 | * POSSIBILITY OF SUCH DAMAGES. | ||
42 | */ | ||
43 | |||
44 | #ifndef __ACUUID_H__ | ||
45 | #define __ACUUID_H__ | ||
46 | |||
47 | /* | ||
48 | * Note1: UUIDs and GUIDs are defined to be identical in ACPI. | ||
49 | * | ||
50 | * Note2: This file is standalone and should remain that way. | ||
51 | */ | ||
52 | |||
53 | /* Controllers */ | ||
54 | |||
55 | #define UUID_GPIO_CONTROLLER "4f248f40-d5e2-499f-834c-27758ea1cd3f" | ||
56 | #define UUID_USB_CONTROLLER "ce2ee385-00e6-48cb-9f05-2edb927c4899" | ||
57 | #define UUID_SATA_CONTROLLER "e4db149b-fcfe-425b-a6d8-92357d78fc7f" | ||
58 | |||
59 | /* Devices */ | ||
60 | |||
61 | #define UUID_PCI_HOST_BRIDGE "33db4d5b-1ff7-401c-9657-7441c03dd766" | ||
62 | #define UUID_I2C_DEVICE "3cdff6f7-4267-4555-ad05-b30a3d8938de" | ||
63 | #define UUID_POWER_BUTTON "dfbcf3c5-e7a5-44e6-9c1f-29c76f6e059c" | ||
64 | |||
65 | /* Interfaces */ | ||
66 | |||
67 | #define UUID_DEVICE_LABELING "e5c937d0-3553-4d7a-9117-ea4d19c3434d" | ||
68 | #define UUID_PHYSICAL_PRESENCE "3dddfaa6-361b-4eb4-a424-8d10089d1653" | ||
69 | |||
70 | /* NVDIMM - NFIT table */ | ||
71 | |||
72 | #define UUID_VOLATILE_MEMORY "7305944f-fdda-44e3-b16c-3f22d252e5d0" | ||
73 | #define UUID_PERSISTENT_MEMORY "66f0d379-b4f3-4074-ac43-0d3318b78cdb" | ||
74 | #define UUID_CONTROL_REGION "92f701f6-13b4-405d-910b-299367e8234c" | ||
75 | #define UUID_DATA_REGION "91af0530-5d86-470e-a6b0-0a2db9408249" | ||
76 | #define UUID_VOLATILE_VIRTUAL_DISK "77ab535a-45fc-624b-5560-f7b281d1f96e" | ||
77 | #define UUID_VOLATILE_VIRTUAL_CD "3d5abd30-4175-87ce-6d64-d2ade523c4bb" | ||
78 | #define UUID_PERSISTENT_VIRTUAL_DISK "5cea02c9-4d07-69d3-269f-4496fbe096f9" | ||
79 | #define UUID_PERSISTENT_VIRTUAL_CD "08018188-42cd-bb48-100f-5387d53ded3d" | ||
80 | |||
81 | /* Miscellaneous */ | ||
82 | |||
83 | #define UUID_PLATFORM_CAPABILITIES "0811b06e-4a27-44f9-8d60-3cbbc22e7b48" | ||
84 | #define UUID_DYNAMIC_ENUMERATION "d8c1a3a6-be9b-4c9b-91bf-c3cb81fc5daf" | ||
85 | #define UUID_BATTERY_THERMAL_LIMIT "4c2067e3-887d-475c-9720-4af1d3ed602e" | ||
86 | #define UUID_THERMAL_EXTENSIONS "14d399cd-7a27-4b18-8fb4-7cb7b9f4e500" | ||
87 | #define UUID_DEVICE_PROPERTIES "daffd814-6eba-4d8c-8a91-bc9bbf4aa301" | ||
88 | |||
89 | #endif /* __AUUID_H__ */ | ||
diff --git a/include/acpi/platform/acenv.h b/include/acpi/platform/acenv.h index ecdf9405dd3a..073997d729e9 100644 --- a/include/acpi/platform/acenv.h +++ b/include/acpi/platform/acenv.h | |||
@@ -175,6 +175,9 @@ | |||
175 | #elif defined(_APPLE) || defined(__APPLE__) | 175 | #elif defined(_APPLE) || defined(__APPLE__) |
176 | #include "acmacosx.h" | 176 | #include "acmacosx.h" |
177 | 177 | ||
178 | #elif defined(__DragonFly__) | ||
179 | #include "acdragonfly.h" | ||
180 | |||
178 | #elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) | 181 | #elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) |
179 | #include "acfreebsd.h" | 182 | #include "acfreebsd.h" |
180 | 183 | ||
diff --git a/include/acpi/platform/acenvex.h b/include/acpi/platform/acenvex.h index 71e5ec5b07a3..14dc6f68ca18 100644 --- a/include/acpi/platform/acenvex.h +++ b/include/acpi/platform/acenvex.h | |||
@@ -56,6 +56,9 @@ | |||
56 | #if defined(_LINUX) || defined(__linux__) | 56 | #if defined(_LINUX) || defined(__linux__) |
57 | #include <acpi/platform/aclinuxex.h> | 57 | #include <acpi/platform/aclinuxex.h> |
58 | 58 | ||
59 | #elif defined(__DragonFly__) | ||
60 | #include "acdragonflyex.h" | ||
61 | |||
59 | #endif | 62 | #endif |
60 | 63 | ||
61 | /*! [End] no source code translation !*/ | 64 | /*! [End] no source code translation !*/ |