diff options
Diffstat (limited to 'drivers/acpi/acpica/utdecode.c')
-rw-r--r-- | drivers/acpi/acpica/utdecode.c | 70 |
1 files changed, 18 insertions, 52 deletions
diff --git a/drivers/acpi/acpica/utdecode.c b/drivers/acpi/acpica/utdecode.c index 684849949bf3..60a158472d82 100644 --- a/drivers/acpi/acpica/utdecode.c +++ b/drivers/acpi/acpica/utdecode.c | |||
@@ -49,41 +49,6 @@ | |||
49 | #define _COMPONENT ACPI_UTILITIES | 49 | #define _COMPONENT ACPI_UTILITIES |
50 | ACPI_MODULE_NAME("utdecode") | 50 | ACPI_MODULE_NAME("utdecode") |
51 | 51 | ||
52 | /******************************************************************************* | ||
53 | * | ||
54 | * FUNCTION: acpi_format_exception | ||
55 | * | ||
56 | * PARAMETERS: Status - The acpi_status code to be formatted | ||
57 | * | ||
58 | * RETURN: A string containing the exception text. A valid pointer is | ||
59 | * always returned. | ||
60 | * | ||
61 | * DESCRIPTION: This function translates an ACPI exception into an ASCII string | ||
62 | * It is here instead of utxface.c so it is always present. | ||
63 | * | ||
64 | ******************************************************************************/ | ||
65 | const char *acpi_format_exception(acpi_status status) | ||
66 | { | ||
67 | const char *exception = NULL; | ||
68 | |||
69 | ACPI_FUNCTION_ENTRY(); | ||
70 | |||
71 | exception = acpi_ut_validate_exception(status); | ||
72 | if (!exception) { | ||
73 | |||
74 | /* Exception code was not recognized */ | ||
75 | |||
76 | ACPI_ERROR((AE_INFO, | ||
77 | "Unknown exception code: 0x%8.8X", status)); | ||
78 | |||
79 | exception = "UNKNOWN_STATUS_CODE"; | ||
80 | } | ||
81 | |||
82 | return (ACPI_CAST_PTR(const char, exception)); | ||
83 | } | ||
84 | |||
85 | ACPI_EXPORT_SYMBOL(acpi_format_exception) | ||
86 | |||
87 | /* | 52 | /* |
88 | * Properties of the ACPI Object Types, both internal and external. | 53 | * Properties of the ACPI Object Types, both internal and external. |
89 | * The table is indexed by values of acpi_object_type | 54 | * The table is indexed by values of acpi_object_type |
@@ -126,8 +91,8 @@ const u8 acpi_gbl_ns_properties[ACPI_NUM_NS_TYPES] = { | |||
126 | * | 91 | * |
127 | * FUNCTION: acpi_ut_hex_to_ascii_char | 92 | * FUNCTION: acpi_ut_hex_to_ascii_char |
128 | * | 93 | * |
129 | * PARAMETERS: Integer - Contains the hex digit | 94 | * PARAMETERS: integer - Contains the hex digit |
130 | * Position - bit position of the digit within the | 95 | * position - bit position of the digit within the |
131 | * integer (multiple of 4) | 96 | * integer (multiple of 4) |
132 | * | 97 | * |
133 | * RETURN: The converted Ascii character | 98 | * RETURN: The converted Ascii character |
@@ -164,16 +129,17 @@ char acpi_ut_hex_to_ascii_char(u64 integer, u32 position) | |||
164 | /* Region type decoding */ | 129 | /* Region type decoding */ |
165 | 130 | ||
166 | const char *acpi_gbl_region_types[ACPI_NUM_PREDEFINED_REGIONS] = { | 131 | const char *acpi_gbl_region_types[ACPI_NUM_PREDEFINED_REGIONS] = { |
167 | "SystemMemory", | 132 | "SystemMemory", /* 0x00 */ |
168 | "SystemIO", | 133 | "SystemIO", /* 0x01 */ |
169 | "PCI_Config", | 134 | "PCI_Config", /* 0x02 */ |
170 | "EmbeddedControl", | 135 | "EmbeddedControl", /* 0x03 */ |
171 | "SMBus", | 136 | "SMBus", /* 0x04 */ |
172 | "SystemCMOS", | 137 | "SystemCMOS", /* 0x05 */ |
173 | "PCIBARTarget", | 138 | "PCIBARTarget", /* 0x06 */ |
174 | "IPMI", | 139 | "IPMI", /* 0x07 */ |
175 | "GeneralPurposeIo", | 140 | "GeneralPurposeIo", /* 0x08 */ |
176 | "GenericSerialBus" | 141 | "GenericSerialBus", /* 0x09 */ |
142 | "PCC" /* 0x0A */ | ||
177 | }; | 143 | }; |
178 | 144 | ||
179 | char *acpi_ut_get_region_name(u8 space_id) | 145 | char *acpi_ut_get_region_name(u8 space_id) |
@@ -228,7 +194,7 @@ char *acpi_ut_get_event_name(u32 event_id) | |||
228 | * | 194 | * |
229 | * FUNCTION: acpi_ut_get_type_name | 195 | * FUNCTION: acpi_ut_get_type_name |
230 | * | 196 | * |
231 | * PARAMETERS: Type - An ACPI object type | 197 | * PARAMETERS: type - An ACPI object type |
232 | * | 198 | * |
233 | * RETURN: Decoded ACPI object type name | 199 | * RETURN: Decoded ACPI object type name |
234 | * | 200 | * |
@@ -306,7 +272,7 @@ char *acpi_ut_get_object_type_name(union acpi_operand_object *obj_desc) | |||
306 | * | 272 | * |
307 | * FUNCTION: acpi_ut_get_node_name | 273 | * FUNCTION: acpi_ut_get_node_name |
308 | * | 274 | * |
309 | * PARAMETERS: Object - A namespace node | 275 | * PARAMETERS: object - A namespace node |
310 | * | 276 | * |
311 | * RETURN: ASCII name of the node | 277 | * RETURN: ASCII name of the node |
312 | * | 278 | * |
@@ -351,7 +317,7 @@ char *acpi_ut_get_node_name(void *object) | |||
351 | * | 317 | * |
352 | * FUNCTION: acpi_ut_get_descriptor_name | 318 | * FUNCTION: acpi_ut_get_descriptor_name |
353 | * | 319 | * |
354 | * PARAMETERS: Object - An ACPI object | 320 | * PARAMETERS: object - An ACPI object |
355 | * | 321 | * |
356 | * RETURN: Decoded name of the descriptor type | 322 | * RETURN: Decoded name of the descriptor type |
357 | * | 323 | * |
@@ -401,7 +367,7 @@ char *acpi_ut_get_descriptor_name(void *object) | |||
401 | * | 367 | * |
402 | * FUNCTION: acpi_ut_get_reference_name | 368 | * FUNCTION: acpi_ut_get_reference_name |
403 | * | 369 | * |
404 | * PARAMETERS: Object - An ACPI reference object | 370 | * PARAMETERS: object - An ACPI reference object |
405 | * | 371 | * |
406 | * RETURN: Decoded name of the type of reference | 372 | * RETURN: Decoded name of the type of reference |
407 | * | 373 | * |
@@ -532,7 +498,7 @@ const char *acpi_ut_get_notify_name(u32 notify_value) | |||
532 | * | 498 | * |
533 | * FUNCTION: acpi_ut_valid_object_type | 499 | * FUNCTION: acpi_ut_valid_object_type |
534 | * | 500 | * |
535 | * PARAMETERS: Type - Object type to be validated | 501 | * PARAMETERS: type - Object type to be validated |
536 | * | 502 | * |
537 | * RETURN: TRUE if valid object type, FALSE otherwise | 503 | * RETURN: TRUE if valid object type, FALSE otherwise |
538 | * | 504 | * |