diff options
Diffstat (limited to 'drivers/acpi/utilities/utmisc.c')
-rw-r--r-- | drivers/acpi/utilities/utmisc.c | 39 |
1 files changed, 18 insertions, 21 deletions
diff --git a/drivers/acpi/utilities/utmisc.c b/drivers/acpi/utilities/utmisc.c index 1f057b71db1a..f34be6773556 100644 --- a/drivers/acpi/utilities/utmisc.c +++ b/drivers/acpi/utilities/utmisc.c | |||
@@ -64,7 +64,7 @@ ACPI_MODULE_NAME("utmisc") | |||
64 | ******************************************************************************/ | 64 | ******************************************************************************/ |
65 | const char *acpi_ut_validate_exception(acpi_status status) | 65 | const char *acpi_ut_validate_exception(acpi_status status) |
66 | { | 66 | { |
67 | acpi_status sub_status; | 67 | u32 sub_status; |
68 | const char *exception = NULL; | 68 | const char *exception = NULL; |
69 | 69 | ||
70 | ACPI_FUNCTION_ENTRY(); | 70 | ACPI_FUNCTION_ENTRY(); |
@@ -85,32 +85,28 @@ const char *acpi_ut_validate_exception(acpi_status status) | |||
85 | case AE_CODE_PROGRAMMER: | 85 | case AE_CODE_PROGRAMMER: |
86 | 86 | ||
87 | if (sub_status <= AE_CODE_PGM_MAX) { | 87 | if (sub_status <= AE_CODE_PGM_MAX) { |
88 | exception = | 88 | exception = acpi_gbl_exception_names_pgm[sub_status]; |
89 | acpi_gbl_exception_names_pgm[sub_status - 1]; | ||
90 | } | 89 | } |
91 | break; | 90 | break; |
92 | 91 | ||
93 | case AE_CODE_ACPI_TABLES: | 92 | case AE_CODE_ACPI_TABLES: |
94 | 93 | ||
95 | if (sub_status <= AE_CODE_TBL_MAX) { | 94 | if (sub_status <= AE_CODE_TBL_MAX) { |
96 | exception = | 95 | exception = acpi_gbl_exception_names_tbl[sub_status]; |
97 | acpi_gbl_exception_names_tbl[sub_status - 1]; | ||
98 | } | 96 | } |
99 | break; | 97 | break; |
100 | 98 | ||
101 | case AE_CODE_AML: | 99 | case AE_CODE_AML: |
102 | 100 | ||
103 | if (sub_status <= AE_CODE_AML_MAX) { | 101 | if (sub_status <= AE_CODE_AML_MAX) { |
104 | exception = | 102 | exception = acpi_gbl_exception_names_aml[sub_status]; |
105 | acpi_gbl_exception_names_aml[sub_status - 1]; | ||
106 | } | 103 | } |
107 | break; | 104 | break; |
108 | 105 | ||
109 | case AE_CODE_CONTROL: | 106 | case AE_CODE_CONTROL: |
110 | 107 | ||
111 | if (sub_status <= AE_CODE_CTRL_MAX) { | 108 | if (sub_status <= AE_CODE_CTRL_MAX) { |
112 | exception = | 109 | exception = acpi_gbl_exception_names_ctrl[sub_status]; |
113 | acpi_gbl_exception_names_ctrl[sub_status - 1]; | ||
114 | } | 110 | } |
115 | break; | 111 | break; |
116 | 112 | ||
@@ -165,9 +161,9 @@ u8 acpi_ut_is_aml_table(struct acpi_table_header *table) | |||
165 | 161 | ||
166 | acpi_status acpi_ut_allocate_owner_id(acpi_owner_id * owner_id) | 162 | acpi_status acpi_ut_allocate_owner_id(acpi_owner_id * owner_id) |
167 | { | 163 | { |
168 | acpi_native_uint i; | 164 | u32 i; |
169 | acpi_native_uint j; | 165 | u32 j; |
170 | acpi_native_uint k; | 166 | u32 k; |
171 | acpi_status status; | 167 | acpi_status status; |
172 | 168 | ||
173 | ACPI_FUNCTION_TRACE(ut_allocate_owner_id); | 169 | ACPI_FUNCTION_TRACE(ut_allocate_owner_id); |
@@ -273,7 +269,7 @@ void acpi_ut_release_owner_id(acpi_owner_id * owner_id_ptr) | |||
273 | { | 269 | { |
274 | acpi_owner_id owner_id = *owner_id_ptr; | 270 | acpi_owner_id owner_id = *owner_id_ptr; |
275 | acpi_status status; | 271 | acpi_status status; |
276 | acpi_native_uint index; | 272 | u32 index; |
277 | u32 bit; | 273 | u32 bit; |
278 | 274 | ||
279 | ACPI_FUNCTION_TRACE_U32(ut_release_owner_id, owner_id); | 275 | ACPI_FUNCTION_TRACE_U32(ut_release_owner_id, owner_id); |
@@ -593,7 +589,7 @@ acpi_ut_display_init_pathname(u8 type, | |||
593 | * | 589 | * |
594 | ******************************************************************************/ | 590 | ******************************************************************************/ |
595 | 591 | ||
596 | u8 acpi_ut_valid_acpi_char(char character, acpi_native_uint position) | 592 | u8 acpi_ut_valid_acpi_char(char character, u32 position) |
597 | { | 593 | { |
598 | 594 | ||
599 | if (!((character >= 'A' && character <= 'Z') || | 595 | if (!((character >= 'A' && character <= 'Z') || |
@@ -628,7 +624,7 @@ u8 acpi_ut_valid_acpi_char(char character, acpi_native_uint position) | |||
628 | 624 | ||
629 | u8 acpi_ut_valid_acpi_name(u32 name) | 625 | u8 acpi_ut_valid_acpi_name(u32 name) |
630 | { | 626 | { |
631 | acpi_native_uint i; | 627 | u32 i; |
632 | 628 | ||
633 | ACPI_FUNCTION_ENTRY(); | 629 | ACPI_FUNCTION_ENTRY(); |
634 | 630 | ||
@@ -657,7 +653,7 @@ u8 acpi_ut_valid_acpi_name(u32 name) | |||
657 | 653 | ||
658 | acpi_name acpi_ut_repair_name(char *name) | 654 | acpi_name acpi_ut_repair_name(char *name) |
659 | { | 655 | { |
660 | acpi_native_uint i; | 656 | u32 i; |
661 | char new_name[ACPI_NAME_SIZE]; | 657 | char new_name[ACPI_NAME_SIZE]; |
662 | 658 | ||
663 | for (i = 0; i < ACPI_NAME_SIZE; i++) { | 659 | for (i = 0; i < ACPI_NAME_SIZE; i++) { |
@@ -1024,7 +1020,7 @@ acpi_ut_walk_package_tree(union acpi_operand_object * source_object, | |||
1024 | ******************************************************************************/ | 1020 | ******************************************************************************/ |
1025 | 1021 | ||
1026 | void ACPI_INTERNAL_VAR_XFACE | 1022 | void ACPI_INTERNAL_VAR_XFACE |
1027 | acpi_ut_error(char *module_name, u32 line_number, char *format, ...) | 1023 | acpi_ut_error(const char *module_name, u32 line_number, const char *format, ...) |
1028 | { | 1024 | { |
1029 | va_list args; | 1025 | va_list args; |
1030 | 1026 | ||
@@ -1037,8 +1033,8 @@ acpi_ut_error(char *module_name, u32 line_number, char *format, ...) | |||
1037 | } | 1033 | } |
1038 | 1034 | ||
1039 | void ACPI_INTERNAL_VAR_XFACE | 1035 | void ACPI_INTERNAL_VAR_XFACE |
1040 | acpi_ut_exception(char *module_name, | 1036 | acpi_ut_exception(const char *module_name, |
1041 | u32 line_number, acpi_status status, char *format, ...) | 1037 | u32 line_number, acpi_status status, const char *format, ...) |
1042 | { | 1038 | { |
1043 | va_list args; | 1039 | va_list args; |
1044 | 1040 | ||
@@ -1054,7 +1050,8 @@ acpi_ut_exception(char *module_name, | |||
1054 | EXPORT_SYMBOL(acpi_ut_exception); | 1050 | EXPORT_SYMBOL(acpi_ut_exception); |
1055 | 1051 | ||
1056 | void ACPI_INTERNAL_VAR_XFACE | 1052 | void ACPI_INTERNAL_VAR_XFACE |
1057 | acpi_ut_warning(char *module_name, u32 line_number, char *format, ...) | 1053 | acpi_ut_warning(const char *module_name, |
1054 | u32 line_number, const char *format, ...) | ||
1058 | { | 1055 | { |
1059 | va_list args; | 1056 | va_list args; |
1060 | 1057 | ||
@@ -1067,7 +1064,7 @@ acpi_ut_warning(char *module_name, u32 line_number, char *format, ...) | |||
1067 | } | 1064 | } |
1068 | 1065 | ||
1069 | void ACPI_INTERNAL_VAR_XFACE | 1066 | void ACPI_INTERNAL_VAR_XFACE |
1070 | acpi_ut_info(char *module_name, u32 line_number, char *format, ...) | 1067 | acpi_ut_info(const char *module_name, u32 line_number, const char *format, ...) |
1071 | { | 1068 | { |
1072 | va_list args; | 1069 | va_list args; |
1073 | 1070 | ||