diff options
author | Chao Guan <chao.guan@intel.com> | 2013-06-07 20:58:14 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-06-15 18:55:05 -0400 |
commit | 1d1ea1b723d9f239f736b8cf284327cbbf9d15d1 (patch) | |
tree | a94241a1f42a8952415d68e623f58de6d43c6369 /drivers | |
parent | b6872ff9a4785a790f9647ee2076e7e616a3bb0e (diff) |
ACPICA: Standardize all switch() blocks
After many years, different formatting for switch() has crept in.
This change makes every switch block identical. Chao Guan.
ACPICA bugzilla 997.
References: https://bugs.acpica.org/show_bug.cgi?id=997
Signed-off-by: Chao Guan <chao.guan@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers')
71 files changed, 242 insertions, 77 deletions
diff --git a/drivers/acpi/acpica/dscontrol.c b/drivers/acpi/acpica/dscontrol.c index 7ea0f162f11c..eb56b66444b5 100644 --- a/drivers/acpi/acpica/dscontrol.c +++ b/drivers/acpi/acpica/dscontrol.c | |||
@@ -78,7 +78,6 @@ acpi_ds_exec_begin_control_op(struct acpi_walk_state *walk_state, | |||
78 | 78 | ||
79 | switch (op->common.aml_opcode) { | 79 | switch (op->common.aml_opcode) { |
80 | case AML_WHILE_OP: | 80 | case AML_WHILE_OP: |
81 | |||
82 | /* | 81 | /* |
83 | * If this is an additional iteration of a while loop, continue. | 82 | * If this is an additional iteration of a while loop, continue. |
84 | * There is no need to allocate a new control state. | 83 | * There is no need to allocate a new control state. |
@@ -99,7 +98,6 @@ acpi_ds_exec_begin_control_op(struct acpi_walk_state *walk_state, | |||
99 | /*lint -fallthrough */ | 98 | /*lint -fallthrough */ |
100 | 99 | ||
101 | case AML_IF_OP: | 100 | case AML_IF_OP: |
102 | |||
103 | /* | 101 | /* |
104 | * IF/WHILE: Create a new control state to manage these | 102 | * IF/WHILE: Create a new control state to manage these |
105 | * constructs. We need to manage these as a stack, in order | 103 | * constructs. We need to manage these as a stack, in order |
@@ -142,6 +140,7 @@ acpi_ds_exec_begin_control_op(struct acpi_walk_state *walk_state, | |||
142 | break; | 140 | break; |
143 | 141 | ||
144 | default: | 142 | default: |
143 | |||
145 | break; | 144 | break; |
146 | } | 145 | } |
147 | 146 | ||
@@ -344,6 +343,7 @@ acpi_ds_exec_end_control_op(struct acpi_walk_state * walk_state, | |||
344 | case AML_NOOP_OP: | 343 | case AML_NOOP_OP: |
345 | 344 | ||
346 | /* Just do nothing! */ | 345 | /* Just do nothing! */ |
346 | |||
347 | break; | 347 | break; |
348 | 348 | ||
349 | case AML_BREAK_POINT_OP: | 349 | case AML_BREAK_POINT_OP: |
diff --git a/drivers/acpi/acpica/dsfield.c b/drivers/acpi/acpica/dsfield.c index feadeed1012d..d4bfe7b7f90a 100644 --- a/drivers/acpi/acpica/dsfield.c +++ b/drivers/acpi/acpica/dsfield.c | |||
@@ -563,21 +563,25 @@ acpi_ds_init_field_objects(union acpi_parse_object *op, | |||
563 | */ | 563 | */ |
564 | switch (walk_state->opcode) { | 564 | switch (walk_state->opcode) { |
565 | case AML_FIELD_OP: | 565 | case AML_FIELD_OP: |
566 | |||
566 | arg = acpi_ps_get_arg(op, 2); | 567 | arg = acpi_ps_get_arg(op, 2); |
567 | type = ACPI_TYPE_LOCAL_REGION_FIELD; | 568 | type = ACPI_TYPE_LOCAL_REGION_FIELD; |
568 | break; | 569 | break; |
569 | 570 | ||
570 | case AML_BANK_FIELD_OP: | 571 | case AML_BANK_FIELD_OP: |
572 | |||
571 | arg = acpi_ps_get_arg(op, 4); | 573 | arg = acpi_ps_get_arg(op, 4); |
572 | type = ACPI_TYPE_LOCAL_BANK_FIELD; | 574 | type = ACPI_TYPE_LOCAL_BANK_FIELD; |
573 | break; | 575 | break; |
574 | 576 | ||
575 | case AML_INDEX_FIELD_OP: | 577 | case AML_INDEX_FIELD_OP: |
578 | |||
576 | arg = acpi_ps_get_arg(op, 3); | 579 | arg = acpi_ps_get_arg(op, 3); |
577 | type = ACPI_TYPE_LOCAL_INDEX_FIELD; | 580 | type = ACPI_TYPE_LOCAL_INDEX_FIELD; |
578 | break; | 581 | break; |
579 | 582 | ||
580 | default: | 583 | default: |
584 | |||
581 | return_ACPI_STATUS(AE_BAD_PARAMETER); | 585 | return_ACPI_STATUS(AE_BAD_PARAMETER); |
582 | } | 586 | } |
583 | 587 | ||
diff --git a/drivers/acpi/acpica/dsinit.c b/drivers/acpi/acpica/dsinit.c index bc8e63f7784b..14424200d246 100644 --- a/drivers/acpi/acpica/dsinit.c +++ b/drivers/acpi/acpica/dsinit.c | |||
@@ -127,6 +127,7 @@ acpi_ds_init_one_object(acpi_handle obj_handle, | |||
127 | break; | 127 | break; |
128 | 128 | ||
129 | default: | 129 | default: |
130 | |||
130 | break; | 131 | break; |
131 | } | 132 | } |
132 | 133 | ||
diff --git a/drivers/acpi/acpica/dsmthdat.c b/drivers/acpi/acpica/dsmthdat.c index 3da80460ce38..c4b0b3657237 100644 --- a/drivers/acpi/acpica/dsmthdat.c +++ b/drivers/acpi/acpica/dsmthdat.c | |||
@@ -285,6 +285,7 @@ acpi_ds_method_data_get_node(u8 type, | |||
285 | break; | 285 | break; |
286 | 286 | ||
287 | default: | 287 | default: |
288 | |||
288 | ACPI_ERROR((AE_INFO, "Type %u is invalid", type)); | 289 | ACPI_ERROR((AE_INFO, "Type %u is invalid", type)); |
289 | return_ACPI_STATUS(AE_TYPE); | 290 | return_ACPI_STATUS(AE_TYPE); |
290 | } | 291 | } |
@@ -428,7 +429,6 @@ acpi_ds_method_data_get_value(u8 type, | |||
428 | return_ACPI_STATUS(AE_AML_UNINITIALIZED_ARG); | 429 | return_ACPI_STATUS(AE_AML_UNINITIALIZED_ARG); |
429 | 430 | ||
430 | case ACPI_REFCLASS_LOCAL: | 431 | case ACPI_REFCLASS_LOCAL: |
431 | |||
432 | /* | 432 | /* |
433 | * No error message for this case, will be trapped again later to | 433 | * No error message for this case, will be trapped again later to |
434 | * detect and ignore cases of Store(local_x,local_x) | 434 | * detect and ignore cases of Store(local_x,local_x) |
diff --git a/drivers/acpi/acpica/dsobject.c b/drivers/acpi/acpica/dsobject.c index e20e9f84eee8..63f0d220ca3d 100644 --- a/drivers/acpi/acpica/dsobject.c +++ b/drivers/acpi/acpica/dsobject.c | |||
@@ -648,7 +648,6 @@ acpi_ds_init_object_from_op(struct acpi_walk_state *walk_state, | |||
648 | 648 | ||
649 | switch (obj_desc->common.type) { | 649 | switch (obj_desc->common.type) { |
650 | case ACPI_TYPE_BUFFER: | 650 | case ACPI_TYPE_BUFFER: |
651 | |||
652 | /* | 651 | /* |
653 | * Defer evaluation of Buffer term_arg operand | 652 | * Defer evaluation of Buffer term_arg operand |
654 | */ | 653 | */ |
@@ -660,7 +659,6 @@ acpi_ds_init_object_from_op(struct acpi_walk_state *walk_state, | |||
660 | break; | 659 | break; |
661 | 660 | ||
662 | case ACPI_TYPE_PACKAGE: | 661 | case ACPI_TYPE_PACKAGE: |
663 | |||
664 | /* | 662 | /* |
665 | * Defer evaluation of Package term_arg operand | 663 | * Defer evaluation of Package term_arg operand |
666 | */ | 664 | */ |
@@ -741,6 +739,7 @@ acpi_ds_init_object_from_op(struct acpi_walk_state *walk_state, | |||
741 | break; | 739 | break; |
742 | 740 | ||
743 | default: | 741 | default: |
742 | |||
744 | ACPI_ERROR((AE_INFO, "Unknown Integer type 0x%X", | 743 | ACPI_ERROR((AE_INFO, "Unknown Integer type 0x%X", |
745 | op_info->type)); | 744 | op_info->type)); |
746 | status = AE_AML_OPERAND_TYPE; | 745 | status = AE_AML_OPERAND_TYPE; |
diff --git a/drivers/acpi/acpica/dsopcode.c b/drivers/acpi/acpica/dsopcode.c index ee6367b8eaf7..1fc1ff114f26 100644 --- a/drivers/acpi/acpica/dsopcode.c +++ b/drivers/acpi/acpica/dsopcode.c | |||
@@ -636,6 +636,7 @@ acpi_ds_eval_data_object_operands(struct acpi_walk_state *walk_state, | |||
636 | break; | 636 | break; |
637 | 637 | ||
638 | default: | 638 | default: |
639 | |||
639 | return_ACPI_STATUS(AE_AML_BAD_OPCODE); | 640 | return_ACPI_STATUS(AE_AML_BAD_OPCODE); |
640 | } | 641 | } |
641 | 642 | ||
diff --git a/drivers/acpi/acpica/dsutils.c b/drivers/acpi/acpica/dsutils.c index 99778997c35a..c666fc014987 100644 --- a/drivers/acpi/acpica/dsutils.c +++ b/drivers/acpi/acpica/dsutils.c | |||
@@ -240,7 +240,6 @@ acpi_ds_is_result_used(union acpi_parse_object * op, | |||
240 | 240 | ||
241 | case AML_IF_OP: | 241 | case AML_IF_OP: |
242 | case AML_WHILE_OP: | 242 | case AML_WHILE_OP: |
243 | |||
244 | /* | 243 | /* |
245 | * If we are executing the predicate AND this is the predicate op, | 244 | * If we are executing the predicate AND this is the predicate op, |
246 | * we will use the return value | 245 | * we will use the return value |
@@ -254,7 +253,9 @@ acpi_ds_is_result_used(union acpi_parse_object * op, | |||
254 | break; | 253 | break; |
255 | 254 | ||
256 | default: | 255 | default: |
256 | |||
257 | /* Ignore other control opcodes */ | 257 | /* Ignore other control opcodes */ |
258 | |||
258 | break; | 259 | break; |
259 | } | 260 | } |
260 | 261 | ||
@@ -263,7 +264,6 @@ acpi_ds_is_result_used(union acpi_parse_object * op, | |||
263 | goto result_not_used; | 264 | goto result_not_used; |
264 | 265 | ||
265 | case AML_CLASS_CREATE: | 266 | case AML_CLASS_CREATE: |
266 | |||
267 | /* | 267 | /* |
268 | * These opcodes allow term_arg(s) as operands and therefore | 268 | * These opcodes allow term_arg(s) as operands and therefore |
269 | * the operands can be method calls. The result is used. | 269 | * the operands can be method calls. The result is used. |
@@ -292,7 +292,6 @@ acpi_ds_is_result_used(union acpi_parse_object * op, | |||
292 | goto result_not_used; | 292 | goto result_not_used; |
293 | 293 | ||
294 | default: | 294 | default: |
295 | |||
296 | /* | 295 | /* |
297 | * In all other cases. the parent will actually use the return | 296 | * In all other cases. the parent will actually use the return |
298 | * object, so keep it. | 297 | * object, so keep it. |
diff --git a/drivers/acpi/acpica/dswexec.c b/drivers/acpi/acpica/dswexec.c index e2199a947470..151d924817e1 100644 --- a/drivers/acpi/acpica/dswexec.c +++ b/drivers/acpi/acpica/dswexec.c | |||
@@ -327,6 +327,7 @@ acpi_ds_exec_begin_op(struct acpi_walk_state *walk_state, | |||
327 | break; | 327 | break; |
328 | 328 | ||
329 | default: | 329 | default: |
330 | |||
330 | break; | 331 | break; |
331 | } | 332 | } |
332 | 333 | ||
@@ -488,7 +489,6 @@ acpi_status acpi_ds_exec_end_op(struct acpi_walk_state *walk_state) | |||
488 | break; | 489 | break; |
489 | 490 | ||
490 | case AML_TYPE_METHOD_CALL: | 491 | case AML_TYPE_METHOD_CALL: |
491 | |||
492 | /* | 492 | /* |
493 | * If the method is referenced from within a package | 493 | * If the method is referenced from within a package |
494 | * declaration, it is not a invocation of the method, just | 494 | * declaration, it is not a invocation of the method, just |
@@ -582,7 +582,6 @@ acpi_status acpi_ds_exec_end_op(struct acpi_walk_state *walk_state) | |||
582 | 582 | ||
583 | switch (op->common.parent->common.aml_opcode) { | 583 | switch (op->common.parent->common.aml_opcode) { |
584 | case AML_NAME_OP: | 584 | case AML_NAME_OP: |
585 | |||
586 | /* | 585 | /* |
587 | * Put the Node on the object stack (Contains the ACPI Name | 586 | * Put the Node on the object stack (Contains the ACPI Name |
588 | * of this object) | 587 | * of this object) |
diff --git a/drivers/acpi/acpica/dswload.c b/drivers/acpi/acpica/dswload.c index 6e17c0e24e63..95e681a36f9c 100644 --- a/drivers/acpi/acpica/dswload.c +++ b/drivers/acpi/acpica/dswload.c | |||
@@ -74,6 +74,7 @@ acpi_ds_init_callbacks(struct acpi_walk_state *walk_state, u32 pass_number) | |||
74 | 74 | ||
75 | switch (pass_number) { | 75 | switch (pass_number) { |
76 | case 1: | 76 | case 1: |
77 | |||
77 | walk_state->parse_flags = ACPI_PARSE_LOAD_PASS1 | | 78 | walk_state->parse_flags = ACPI_PARSE_LOAD_PASS1 | |
78 | ACPI_PARSE_DELETE_TREE; | 79 | ACPI_PARSE_DELETE_TREE; |
79 | walk_state->descending_callback = acpi_ds_load1_begin_op; | 80 | walk_state->descending_callback = acpi_ds_load1_begin_op; |
@@ -81,6 +82,7 @@ acpi_ds_init_callbacks(struct acpi_walk_state *walk_state, u32 pass_number) | |||
81 | break; | 82 | break; |
82 | 83 | ||
83 | case 2: | 84 | case 2: |
85 | |||
84 | walk_state->parse_flags = ACPI_PARSE_LOAD_PASS1 | | 86 | walk_state->parse_flags = ACPI_PARSE_LOAD_PASS1 | |
85 | ACPI_PARSE_DELETE_TREE; | 87 | ACPI_PARSE_DELETE_TREE; |
86 | walk_state->descending_callback = acpi_ds_load2_begin_op; | 88 | walk_state->descending_callback = acpi_ds_load2_begin_op; |
@@ -88,6 +90,7 @@ acpi_ds_init_callbacks(struct acpi_walk_state *walk_state, u32 pass_number) | |||
88 | break; | 90 | break; |
89 | 91 | ||
90 | case 3: | 92 | case 3: |
93 | |||
91 | #ifndef ACPI_NO_METHOD_EXECUTION | 94 | #ifndef ACPI_NO_METHOD_EXECUTION |
92 | walk_state->parse_flags |= ACPI_PARSE_EXECUTE | | 95 | walk_state->parse_flags |= ACPI_PARSE_EXECUTE | |
93 | ACPI_PARSE_DELETE_TREE; | 96 | ACPI_PARSE_DELETE_TREE; |
@@ -97,6 +100,7 @@ acpi_ds_init_callbacks(struct acpi_walk_state *walk_state, u32 pass_number) | |||
97 | break; | 100 | break; |
98 | 101 | ||
99 | default: | 102 | default: |
103 | |||
100 | return (AE_BAD_PARAMETER); | 104 | return (AE_BAD_PARAMETER); |
101 | } | 105 | } |
102 | 106 | ||
@@ -161,7 +165,6 @@ acpi_ds_load1_begin_op(struct acpi_walk_state * walk_state, | |||
161 | 165 | ||
162 | switch (walk_state->opcode) { | 166 | switch (walk_state->opcode) { |
163 | case AML_SCOPE_OP: | 167 | case AML_SCOPE_OP: |
164 | |||
165 | /* | 168 | /* |
166 | * The target name of the Scope() operator must exist at this point so | 169 | * The target name of the Scope() operator must exist at this point so |
167 | * that we can actually open the scope to enter new names underneath it. | 170 | * that we can actually open the scope to enter new names underneath it. |
@@ -210,7 +213,6 @@ acpi_ds_load1_begin_op(struct acpi_walk_state * walk_state, | |||
210 | case ACPI_TYPE_INTEGER: | 213 | case ACPI_TYPE_INTEGER: |
211 | case ACPI_TYPE_STRING: | 214 | case ACPI_TYPE_STRING: |
212 | case ACPI_TYPE_BUFFER: | 215 | case ACPI_TYPE_BUFFER: |
213 | |||
214 | /* | 216 | /* |
215 | * These types we will allow, but we will change the type. | 217 | * These types we will allow, but we will change the type. |
216 | * This enables some existing code of the form: | 218 | * This enables some existing code of the form: |
@@ -232,7 +234,6 @@ acpi_ds_load1_begin_op(struct acpi_walk_state * walk_state, | |||
232 | break; | 234 | break; |
233 | 235 | ||
234 | case ACPI_TYPE_METHOD: | 236 | case ACPI_TYPE_METHOD: |
235 | |||
236 | /* | 237 | /* |
237 | * Allow scope change to root during execution of module-level | 238 | * Allow scope change to root during execution of module-level |
238 | * code. Root is typed METHOD during this time. | 239 | * code. Root is typed METHOD during this time. |
diff --git a/drivers/acpi/acpica/dswload2.c b/drivers/acpi/acpica/dswload2.c index 4407ff2377d5..b1f8f4725c23 100644 --- a/drivers/acpi/acpica/dswload2.c +++ b/drivers/acpi/acpica/dswload2.c | |||
@@ -509,6 +509,7 @@ acpi_status acpi_ds_load2_end_op(struct acpi_walk_state *walk_state) | |||
509 | break; | 509 | break; |
510 | 510 | ||
511 | default: | 511 | default: |
512 | |||
512 | /* All NAMED_FIELD opcodes must be handled above */ | 513 | /* All NAMED_FIELD opcodes must be handled above */ |
513 | break; | 514 | break; |
514 | } | 515 | } |
@@ -548,6 +549,7 @@ acpi_status acpi_ds_load2_end_op(struct acpi_walk_state *walk_state) | |||
548 | break; | 549 | break; |
549 | 550 | ||
550 | default: | 551 | default: |
552 | |||
551 | /* Unknown opcode */ | 553 | /* Unknown opcode */ |
552 | 554 | ||
553 | status = AE_OK; | 555 | status = AE_OK; |
@@ -674,6 +676,7 @@ acpi_status acpi_ds_load2_end_op(struct acpi_walk_state *walk_state) | |||
674 | #endif /* ACPI_NO_METHOD_EXECUTION */ | 676 | #endif /* ACPI_NO_METHOD_EXECUTION */ |
675 | 677 | ||
676 | default: | 678 | default: |
679 | |||
677 | /* All NAMED_COMPLEX opcodes must be handled above */ | 680 | /* All NAMED_COMPLEX opcodes must be handled above */ |
678 | break; | 681 | break; |
679 | } | 682 | } |
@@ -721,6 +724,7 @@ acpi_status acpi_ds_load2_end_op(struct acpi_walk_state *walk_state) | |||
721 | break; | 724 | break; |
722 | 725 | ||
723 | default: | 726 | default: |
727 | |||
724 | break; | 728 | break; |
725 | } | 729 | } |
726 | 730 | ||
diff --git a/drivers/acpi/acpica/evgpe.c b/drivers/acpi/acpica/evgpe.c index ae50d6cc535f..c8a1f7d5931f 100644 --- a/drivers/acpi/acpica/evgpe.c +++ b/drivers/acpi/acpica/evgpe.c | |||
@@ -529,7 +529,6 @@ static void ACPI_SYSTEM_XFACE acpi_ev_asynch_execute_gpe_method(void *context) | |||
529 | 529 | ||
530 | switch (local_gpe_event_info->flags & ACPI_GPE_DISPATCH_MASK) { | 530 | switch (local_gpe_event_info->flags & ACPI_GPE_DISPATCH_MASK) { |
531 | case ACPI_GPE_DISPATCH_NOTIFY: | 531 | case ACPI_GPE_DISPATCH_NOTIFY: |
532 | |||
533 | /* | 532 | /* |
534 | * Implicit notify. | 533 | * Implicit notify. |
535 | * Dispatch a DEVICE_WAKE notify to the appropriate handler. | 534 | * Dispatch a DEVICE_WAKE notify to the appropriate handler. |
@@ -582,7 +581,8 @@ static void ACPI_SYSTEM_XFACE acpi_ev_asynch_execute_gpe_method(void *context) | |||
582 | break; | 581 | break; |
583 | 582 | ||
584 | default: | 583 | default: |
585 | return_VOID; /* Should never happen */ | 584 | |
585 | return_VOID; /* Should never happen */ | ||
586 | } | 586 | } |
587 | 587 | ||
588 | /* Defer enabling of GPE until all notify handlers are done */ | 588 | /* Defer enabling of GPE until all notify handlers are done */ |
@@ -754,7 +754,6 @@ acpi_ev_gpe_dispatch(struct acpi_namespace_node *gpe_device, | |||
754 | 754 | ||
755 | case ACPI_GPE_DISPATCH_METHOD: | 755 | case ACPI_GPE_DISPATCH_METHOD: |
756 | case ACPI_GPE_DISPATCH_NOTIFY: | 756 | case ACPI_GPE_DISPATCH_NOTIFY: |
757 | |||
758 | /* | 757 | /* |
759 | * Execute the method associated with the GPE | 758 | * Execute the method associated with the GPE |
760 | * NOTE: Level-triggered GPEs are cleared after the method completes. | 759 | * NOTE: Level-triggered GPEs are cleared after the method completes. |
@@ -770,7 +769,6 @@ acpi_ev_gpe_dispatch(struct acpi_namespace_node *gpe_device, | |||
770 | break; | 769 | break; |
771 | 770 | ||
772 | default: | 771 | default: |
773 | |||
774 | /* | 772 | /* |
775 | * No handler or method to run! | 773 | * No handler or method to run! |
776 | * 03/2010: This case should no longer be possible. We will not allow | 774 | * 03/2010: This case should no longer be possible. We will not allow |
diff --git a/drivers/acpi/acpica/evgpeinit.c b/drivers/acpi/acpica/evgpeinit.c index 72b8f6b3f4ca..9037f17c9608 100644 --- a/drivers/acpi/acpica/evgpeinit.c +++ b/drivers/acpi/acpica/evgpeinit.c | |||
@@ -363,14 +363,17 @@ acpi_ev_match_gpe_method(acpi_handle obj_handle, | |||
363 | */ | 363 | */ |
364 | switch (name[1]) { | 364 | switch (name[1]) { |
365 | case 'L': | 365 | case 'L': |
366 | |||
366 | type = ACPI_GPE_LEVEL_TRIGGERED; | 367 | type = ACPI_GPE_LEVEL_TRIGGERED; |
367 | break; | 368 | break; |
368 | 369 | ||
369 | case 'E': | 370 | case 'E': |
371 | |||
370 | type = ACPI_GPE_EDGE_TRIGGERED; | 372 | type = ACPI_GPE_EDGE_TRIGGERED; |
371 | break; | 373 | break; |
372 | 374 | ||
373 | default: | 375 | default: |
376 | |||
374 | /* Unknown method type, just ignore it */ | 377 | /* Unknown method type, just ignore it */ |
375 | 378 | ||
376 | ACPI_DEBUG_PRINT((ACPI_DB_LOAD, | 379 | ACPI_DEBUG_PRINT((ACPI_DB_LOAD, |
diff --git a/drivers/acpi/acpica/evhandler.c b/drivers/acpi/acpica/evhandler.c index d4f83112c2e2..068af96134b8 100644 --- a/drivers/acpi/acpica/evhandler.c +++ b/drivers/acpi/acpica/evhandler.c | |||
@@ -354,36 +354,43 @@ acpi_ev_install_space_handler(struct acpi_namespace_node * node, | |||
354 | 354 | ||
355 | switch (space_id) { | 355 | switch (space_id) { |
356 | case ACPI_ADR_SPACE_SYSTEM_MEMORY: | 356 | case ACPI_ADR_SPACE_SYSTEM_MEMORY: |
357 | |||
357 | handler = acpi_ex_system_memory_space_handler; | 358 | handler = acpi_ex_system_memory_space_handler; |
358 | setup = acpi_ev_system_memory_region_setup; | 359 | setup = acpi_ev_system_memory_region_setup; |
359 | break; | 360 | break; |
360 | 361 | ||
361 | case ACPI_ADR_SPACE_SYSTEM_IO: | 362 | case ACPI_ADR_SPACE_SYSTEM_IO: |
363 | |||
362 | handler = acpi_ex_system_io_space_handler; | 364 | handler = acpi_ex_system_io_space_handler; |
363 | setup = acpi_ev_io_space_region_setup; | 365 | setup = acpi_ev_io_space_region_setup; |
364 | break; | 366 | break; |
365 | 367 | ||
366 | case ACPI_ADR_SPACE_PCI_CONFIG: | 368 | case ACPI_ADR_SPACE_PCI_CONFIG: |
369 | |||
367 | handler = acpi_ex_pci_config_space_handler; | 370 | handler = acpi_ex_pci_config_space_handler; |
368 | setup = acpi_ev_pci_config_region_setup; | 371 | setup = acpi_ev_pci_config_region_setup; |
369 | break; | 372 | break; |
370 | 373 | ||
371 | case ACPI_ADR_SPACE_CMOS: | 374 | case ACPI_ADR_SPACE_CMOS: |
375 | |||
372 | handler = acpi_ex_cmos_space_handler; | 376 | handler = acpi_ex_cmos_space_handler; |
373 | setup = acpi_ev_cmos_region_setup; | 377 | setup = acpi_ev_cmos_region_setup; |
374 | break; | 378 | break; |
375 | 379 | ||
376 | case ACPI_ADR_SPACE_PCI_BAR_TARGET: | 380 | case ACPI_ADR_SPACE_PCI_BAR_TARGET: |
381 | |||
377 | handler = acpi_ex_pci_bar_space_handler; | 382 | handler = acpi_ex_pci_bar_space_handler; |
378 | setup = acpi_ev_pci_bar_region_setup; | 383 | setup = acpi_ev_pci_bar_region_setup; |
379 | break; | 384 | break; |
380 | 385 | ||
381 | case ACPI_ADR_SPACE_DATA_TABLE: | 386 | case ACPI_ADR_SPACE_DATA_TABLE: |
387 | |||
382 | handler = acpi_ex_data_table_space_handler; | 388 | handler = acpi_ex_data_table_space_handler; |
383 | setup = NULL; | 389 | setup = NULL; |
384 | break; | 390 | break; |
385 | 391 | ||
386 | default: | 392 | default: |
393 | |||
387 | status = AE_BAD_PARAMETER; | 394 | status = AE_BAD_PARAMETER; |
388 | goto unlock_and_exit; | 395 | goto unlock_and_exit; |
389 | } | 396 | } |
diff --git a/drivers/acpi/acpica/evmisc.c b/drivers/acpi/acpica/evmisc.c index c986b2336b81..db59fe3f6391 100644 --- a/drivers/acpi/acpica/evmisc.c +++ b/drivers/acpi/acpica/evmisc.c | |||
@@ -78,6 +78,7 @@ u8 acpi_ev_is_notify_object(struct acpi_namespace_node *node) | |||
78 | return (TRUE); | 78 | return (TRUE); |
79 | 79 | ||
80 | default: | 80 | default: |
81 | |||
81 | return (FALSE); | 82 | return (FALSE); |
82 | } | 83 | } |
83 | } | 84 | } |
diff --git a/drivers/acpi/acpica/evrgnini.c b/drivers/acpi/acpica/evrgnini.c index 3bb616794b3b..8354c4f7f10c 100644 --- a/drivers/acpi/acpica/evrgnini.c +++ b/drivers/acpi/acpica/evrgnini.c | |||
@@ -596,7 +596,9 @@ acpi_ev_initialize_region(union acpi_operand_object *region_obj, | |||
596 | break; | 596 | break; |
597 | 597 | ||
598 | default: | 598 | default: |
599 | |||
599 | /* Ignore other objects */ | 600 | /* Ignore other objects */ |
601 | |||
600 | break; | 602 | break; |
601 | } | 603 | } |
602 | 604 | ||
diff --git a/drivers/acpi/acpica/evxfgpe.c b/drivers/acpi/acpica/evxfgpe.c index aff4cc261211..7662f1a42ff6 100644 --- a/drivers/acpi/acpica/evxfgpe.c +++ b/drivers/acpi/acpica/evxfgpe.c | |||
@@ -366,16 +366,19 @@ acpi_set_gpe_wake_mask(acpi_handle gpe_device, u32 gpe_number, u8 action) | |||
366 | 366 | ||
367 | switch (action) { | 367 | switch (action) { |
368 | case ACPI_GPE_ENABLE: | 368 | case ACPI_GPE_ENABLE: |
369 | |||
369 | ACPI_SET_BIT(gpe_register_info->enable_for_wake, | 370 | ACPI_SET_BIT(gpe_register_info->enable_for_wake, |
370 | (u8)register_bit); | 371 | (u8)register_bit); |
371 | break; | 372 | break; |
372 | 373 | ||
373 | case ACPI_GPE_DISABLE: | 374 | case ACPI_GPE_DISABLE: |
375 | |||
374 | ACPI_CLEAR_BIT(gpe_register_info->enable_for_wake, | 376 | ACPI_CLEAR_BIT(gpe_register_info->enable_for_wake, |
375 | (u8)register_bit); | 377 | (u8)register_bit); |
376 | break; | 378 | break; |
377 | 379 | ||
378 | default: | 380 | default: |
381 | |||
379 | ACPI_ERROR((AE_INFO, "%u, Invalid action", action)); | 382 | ACPI_ERROR((AE_INFO, "%u, Invalid action", action)); |
380 | status = AE_BAD_PARAMETER; | 383 | status = AE_BAD_PARAMETER; |
381 | break; | 384 | break; |
diff --git a/drivers/acpi/acpica/evxfregn.c b/drivers/acpi/acpica/evxfregn.c index 96c9e5f355ae..80cecf838591 100644 --- a/drivers/acpi/acpica/evxfregn.c +++ b/drivers/acpi/acpica/evxfregn.c | |||
@@ -139,6 +139,7 @@ acpi_install_address_space_handler(acpi_handle device, | |||
139 | break; | 139 | break; |
140 | 140 | ||
141 | default: | 141 | default: |
142 | |||
142 | break; | 143 | break; |
143 | } | 144 | } |
144 | 145 | ||
diff --git a/drivers/acpi/acpica/exconfig.c b/drivers/acpi/acpica/exconfig.c index a689aacae2ba..06d216c8d43a 100644 --- a/drivers/acpi/acpica/exconfig.c +++ b/drivers/acpi/acpica/exconfig.c | |||
@@ -480,6 +480,7 @@ acpi_ex_load_op(union acpi_operand_object *obj_desc, | |||
480 | break; | 480 | break; |
481 | 481 | ||
482 | default: | 482 | default: |
483 | |||
483 | return_ACPI_STATUS(AE_AML_OPERAND_TYPE); | 484 | return_ACPI_STATUS(AE_AML_OPERAND_TYPE); |
484 | } | 485 | } |
485 | 486 | ||
diff --git a/drivers/acpi/acpica/exconvrt.c b/drivers/acpi/acpica/exconvrt.c index d2b9613bbf01..69e4a8cc9b71 100644 --- a/drivers/acpi/acpica/exconvrt.c +++ b/drivers/acpi/acpica/exconvrt.c | |||
@@ -99,6 +99,7 @@ acpi_ex_convert_to_integer(union acpi_operand_object *obj_desc, | |||
99 | break; | 99 | break; |
100 | 100 | ||
101 | default: | 101 | default: |
102 | |||
102 | return_ACPI_STATUS(AE_TYPE); | 103 | return_ACPI_STATUS(AE_TYPE); |
103 | } | 104 | } |
104 | 105 | ||
@@ -117,7 +118,6 @@ acpi_ex_convert_to_integer(union acpi_operand_object *obj_desc, | |||
117 | 118 | ||
118 | switch (obj_desc->common.type) { | 119 | switch (obj_desc->common.type) { |
119 | case ACPI_TYPE_STRING: | 120 | case ACPI_TYPE_STRING: |
120 | |||
121 | /* | 121 | /* |
122 | * Convert string to an integer - for most cases, the string must be | 122 | * Convert string to an integer - for most cases, the string must be |
123 | * hexadecimal as per the ACPI specification. The only exception (as | 123 | * hexadecimal as per the ACPI specification. The only exception (as |
@@ -161,6 +161,7 @@ acpi_ex_convert_to_integer(union acpi_operand_object *obj_desc, | |||
161 | default: | 161 | default: |
162 | 162 | ||
163 | /* No other types can get here */ | 163 | /* No other types can get here */ |
164 | |||
164 | break; | 165 | break; |
165 | } | 166 | } |
166 | 167 | ||
@@ -213,7 +214,6 @@ acpi_ex_convert_to_buffer(union acpi_operand_object *obj_desc, | |||
213 | return_ACPI_STATUS(AE_OK); | 214 | return_ACPI_STATUS(AE_OK); |
214 | 215 | ||
215 | case ACPI_TYPE_INTEGER: | 216 | case ACPI_TYPE_INTEGER: |
216 | |||
217 | /* | 217 | /* |
218 | * Create a new Buffer object. | 218 | * Create a new Buffer object. |
219 | * Need enough space for one integer | 219 | * Need enough space for one integer |
@@ -233,7 +233,6 @@ acpi_ex_convert_to_buffer(union acpi_operand_object *obj_desc, | |||
233 | break; | 233 | break; |
234 | 234 | ||
235 | case ACPI_TYPE_STRING: | 235 | case ACPI_TYPE_STRING: |
236 | |||
237 | /* | 236 | /* |
238 | * Create a new Buffer object | 237 | * Create a new Buffer object |
239 | * Size will be the string length | 238 | * Size will be the string length |
@@ -258,6 +257,7 @@ acpi_ex_convert_to_buffer(union acpi_operand_object *obj_desc, | |||
258 | break; | 257 | break; |
259 | 258 | ||
260 | default: | 259 | default: |
260 | |||
261 | return_ACPI_STATUS(AE_TYPE); | 261 | return_ACPI_STATUS(AE_TYPE); |
262 | } | 262 | } |
263 | 263 | ||
@@ -304,15 +304,18 @@ acpi_ex_convert_to_ascii(u64 integer, u16 base, u8 *string, u8 data_width) | |||
304 | 304 | ||
305 | switch (data_width) { | 305 | switch (data_width) { |
306 | case 1: | 306 | case 1: |
307 | |||
307 | decimal_length = ACPI_MAX8_DECIMAL_DIGITS; | 308 | decimal_length = ACPI_MAX8_DECIMAL_DIGITS; |
308 | break; | 309 | break; |
309 | 310 | ||
310 | case 4: | 311 | case 4: |
312 | |||
311 | decimal_length = ACPI_MAX32_DECIMAL_DIGITS; | 313 | decimal_length = ACPI_MAX32_DECIMAL_DIGITS; |
312 | break; | 314 | break; |
313 | 315 | ||
314 | case 8: | 316 | case 8: |
315 | default: | 317 | default: |
318 | |||
316 | decimal_length = ACPI_MAX64_DECIMAL_DIGITS; | 319 | decimal_length = ACPI_MAX64_DECIMAL_DIGITS; |
317 | break; | 320 | break; |
318 | } | 321 | } |
@@ -546,6 +549,7 @@ acpi_ex_convert_to_string(union acpi_operand_object * obj_desc, | |||
546 | break; | 549 | break; |
547 | 550 | ||
548 | default: | 551 | default: |
552 | |||
549 | return_ACPI_STATUS(AE_TYPE); | 553 | return_ACPI_STATUS(AE_TYPE); |
550 | } | 554 | } |
551 | 555 | ||
@@ -599,6 +603,7 @@ acpi_ex_convert_to_target_type(acpi_object_type destination_type, | |||
599 | break; | 603 | break; |
600 | 604 | ||
601 | default: | 605 | default: |
606 | |||
602 | /* No conversion allowed for these types */ | 607 | /* No conversion allowed for these types */ |
603 | 608 | ||
604 | if (destination_type != source_desc->common.type) { | 609 | if (destination_type != source_desc->common.type) { |
@@ -649,6 +654,7 @@ acpi_ex_convert_to_target_type(acpi_object_type destination_type, | |||
649 | break; | 654 | break; |
650 | 655 | ||
651 | default: | 656 | default: |
657 | |||
652 | ACPI_ERROR((AE_INFO, | 658 | ACPI_ERROR((AE_INFO, |
653 | "Bad destination type during conversion: 0x%X", | 659 | "Bad destination type during conversion: 0x%X", |
654 | destination_type)); | 660 | destination_type)); |
@@ -664,6 +670,7 @@ acpi_ex_convert_to_target_type(acpi_object_type destination_type, | |||
664 | break; | 670 | break; |
665 | 671 | ||
666 | default: | 672 | default: |
673 | |||
667 | ACPI_ERROR((AE_INFO, | 674 | ACPI_ERROR((AE_INFO, |
668 | "Unknown Target type ID 0x%X AmlOpcode 0x%X DestType %s", | 675 | "Unknown Target type ID 0x%X AmlOpcode 0x%X DestType %s", |
669 | GET_CURRENT_ARG_TYPE(walk_state->op_info-> | 676 | GET_CURRENT_ARG_TYPE(walk_state->op_info-> |
diff --git a/drivers/acpi/acpica/excreate.c b/drivers/acpi/acpica/excreate.c index 26a13f67977e..269e81d86ef4 100644 --- a/drivers/acpi/acpica/excreate.c +++ b/drivers/acpi/acpica/excreate.c | |||
@@ -103,7 +103,6 @@ acpi_status acpi_ex_create_alias(struct acpi_walk_state *walk_state) | |||
103 | case ACPI_TYPE_BUFFER: | 103 | case ACPI_TYPE_BUFFER: |
104 | case ACPI_TYPE_PACKAGE: | 104 | case ACPI_TYPE_PACKAGE: |
105 | case ACPI_TYPE_BUFFER_FIELD: | 105 | case ACPI_TYPE_BUFFER_FIELD: |
106 | |||
107 | /* | 106 | /* |
108 | * These types open a new scope, so we need the NS node in order to access | 107 | * These types open a new scope, so we need the NS node in order to access |
109 | * any children. | 108 | * any children. |
@@ -113,7 +112,6 @@ acpi_status acpi_ex_create_alias(struct acpi_walk_state *walk_state) | |||
113 | case ACPI_TYPE_PROCESSOR: | 112 | case ACPI_TYPE_PROCESSOR: |
114 | case ACPI_TYPE_THERMAL: | 113 | case ACPI_TYPE_THERMAL: |
115 | case ACPI_TYPE_LOCAL_SCOPE: | 114 | case ACPI_TYPE_LOCAL_SCOPE: |
116 | |||
117 | /* | 115 | /* |
118 | * The new alias has the type ALIAS and points to the original | 116 | * The new alias has the type ALIAS and points to the original |
119 | * NS node, not the object itself. | 117 | * NS node, not the object itself. |
@@ -124,7 +122,6 @@ acpi_status acpi_ex_create_alias(struct acpi_walk_state *walk_state) | |||
124 | break; | 122 | break; |
125 | 123 | ||
126 | case ACPI_TYPE_METHOD: | 124 | case ACPI_TYPE_METHOD: |
127 | |||
128 | /* | 125 | /* |
129 | * Control method aliases need to be differentiated | 126 | * Control method aliases need to be differentiated |
130 | */ | 127 | */ |
diff --git a/drivers/acpi/acpica/exdebug.c b/drivers/acpi/acpica/exdebug.c index 7eb853cd279f..81c72a4ecd82 100644 --- a/drivers/acpi/acpica/exdebug.c +++ b/drivers/acpi/acpica/exdebug.c | |||
@@ -193,6 +193,7 @@ acpi_ex_do_debug_object(union acpi_operand_object *source_desc, | |||
193 | return_VOID; | 193 | return_VOID; |
194 | 194 | ||
195 | default: | 195 | default: |
196 | |||
196 | break; | 197 | break; |
197 | } | 198 | } |
198 | 199 | ||
@@ -226,6 +227,7 @@ acpi_ex_do_debug_object(union acpi_operand_object *source_desc, | |||
226 | break; | 227 | break; |
227 | 228 | ||
228 | default: | 229 | default: |
230 | |||
229 | acpi_ex_do_debug_object((source_desc-> | 231 | acpi_ex_do_debug_object((source_desc-> |
230 | reference. | 232 | reference. |
231 | node)->object, | 233 | node)->object, |
diff --git a/drivers/acpi/acpica/exdump.c b/drivers/acpi/acpica/exdump.c index e5a3c249f7fa..c740f24e3101 100644 --- a/drivers/acpi/acpica/exdump.c +++ b/drivers/acpi/acpica/exdump.c | |||
@@ -357,6 +357,7 @@ acpi_ex_dump_object(union acpi_operand_object *obj_desc, | |||
357 | 357 | ||
358 | switch (info->opcode) { | 358 | switch (info->opcode) { |
359 | case ACPI_EXD_INIT: | 359 | case ACPI_EXD_INIT: |
360 | |||
360 | break; | 361 | break; |
361 | 362 | ||
362 | case ACPI_EXD_TYPE: | 363 | case ACPI_EXD_TYPE: |
@@ -718,6 +719,7 @@ void acpi_ex_dump_operand(union acpi_operand_object *obj_desc, u32 depth) | |||
718 | break; | 719 | break; |
719 | 720 | ||
720 | default: | 721 | default: |
722 | |||
721 | /* Unknown Type */ | 723 | /* Unknown Type */ |
722 | 724 | ||
723 | acpi_os_printf("Unknown Type %X\n", obj_desc->common.type); | 725 | acpi_os_printf("Unknown Type %X\n", obj_desc->common.type); |
diff --git a/drivers/acpi/acpica/exfield.c b/drivers/acpi/acpica/exfield.c index 7d4bae71e8c6..c2a65aaf29af 100644 --- a/drivers/acpi/acpica/exfield.c +++ b/drivers/acpi/acpica/exfield.c | |||
@@ -331,21 +331,25 @@ acpi_ex_write_data_to_field(union acpi_operand_object *source_desc, | |||
331 | 331 | ||
332 | switch (source_desc->common.type) { | 332 | switch (source_desc->common.type) { |
333 | case ACPI_TYPE_INTEGER: | 333 | case ACPI_TYPE_INTEGER: |
334 | |||
334 | buffer = &source_desc->integer.value; | 335 | buffer = &source_desc->integer.value; |
335 | length = sizeof(source_desc->integer.value); | 336 | length = sizeof(source_desc->integer.value); |
336 | break; | 337 | break; |
337 | 338 | ||
338 | case ACPI_TYPE_BUFFER: | 339 | case ACPI_TYPE_BUFFER: |
340 | |||
339 | buffer = source_desc->buffer.pointer; | 341 | buffer = source_desc->buffer.pointer; |
340 | length = source_desc->buffer.length; | 342 | length = source_desc->buffer.length; |
341 | break; | 343 | break; |
342 | 344 | ||
343 | case ACPI_TYPE_STRING: | 345 | case ACPI_TYPE_STRING: |
346 | |||
344 | buffer = source_desc->string.pointer; | 347 | buffer = source_desc->string.pointer; |
345 | length = source_desc->string.length; | 348 | length = source_desc->string.length; |
346 | break; | 349 | break; |
347 | 350 | ||
348 | default: | 351 | default: |
352 | |||
349 | return_ACPI_STATUS(AE_AML_OPERAND_TYPE); | 353 | return_ACPI_STATUS(AE_AML_OPERAND_TYPE); |
350 | } | 354 | } |
351 | 355 | ||
diff --git a/drivers/acpi/acpica/exfldio.c b/drivers/acpi/acpica/exfldio.c index c84ee956fa4c..7e0afe72487e 100644 --- a/drivers/acpi/acpica/exfldio.c +++ b/drivers/acpi/acpica/exfldio.c | |||
@@ -446,7 +446,6 @@ acpi_ex_field_datum_io(union acpi_operand_object *obj_desc, | |||
446 | break; | 446 | break; |
447 | 447 | ||
448 | case ACPI_TYPE_LOCAL_BANK_FIELD: | 448 | case ACPI_TYPE_LOCAL_BANK_FIELD: |
449 | |||
450 | /* | 449 | /* |
451 | * Ensure that the bank_value is not beyond the capacity of | 450 | * Ensure that the bank_value is not beyond the capacity of |
452 | * the register | 451 | * the register |
@@ -488,7 +487,6 @@ acpi_ex_field_datum_io(union acpi_operand_object *obj_desc, | |||
488 | break; | 487 | break; |
489 | 488 | ||
490 | case ACPI_TYPE_LOCAL_INDEX_FIELD: | 489 | case ACPI_TYPE_LOCAL_INDEX_FIELD: |
491 | |||
492 | /* | 490 | /* |
493 | * Ensure that the index_value is not beyond the capacity of | 491 | * Ensure that the index_value is not beyond the capacity of |
494 | * the register | 492 | * the register |
diff --git a/drivers/acpi/acpica/exmisc.c b/drivers/acpi/acpica/exmisc.c index 72a2a13b6d36..00bf29877574 100644 --- a/drivers/acpi/acpica/exmisc.c +++ b/drivers/acpi/acpica/exmisc.c | |||
@@ -105,7 +105,6 @@ acpi_ex_get_object_reference(union acpi_operand_object *obj_desc, | |||
105 | break; | 105 | break; |
106 | 106 | ||
107 | case ACPI_DESC_TYPE_NAMED: | 107 | case ACPI_DESC_TYPE_NAMED: |
108 | |||
109 | /* | 108 | /* |
110 | * A named reference that has already been resolved to a Node | 109 | * A named reference that has already been resolved to a Node |
111 | */ | 110 | */ |
@@ -261,20 +260,24 @@ acpi_ex_do_concatenate(union acpi_operand_object *operand0, | |||
261 | */ | 260 | */ |
262 | switch (operand0->common.type) { | 261 | switch (operand0->common.type) { |
263 | case ACPI_TYPE_INTEGER: | 262 | case ACPI_TYPE_INTEGER: |
263 | |||
264 | status = | 264 | status = |
265 | acpi_ex_convert_to_integer(operand1, &local_operand1, 16); | 265 | acpi_ex_convert_to_integer(operand1, &local_operand1, 16); |
266 | break; | 266 | break; |
267 | 267 | ||
268 | case ACPI_TYPE_STRING: | 268 | case ACPI_TYPE_STRING: |
269 | |||
269 | status = acpi_ex_convert_to_string(operand1, &local_operand1, | 270 | status = acpi_ex_convert_to_string(operand1, &local_operand1, |
270 | ACPI_IMPLICIT_CONVERT_HEX); | 271 | ACPI_IMPLICIT_CONVERT_HEX); |
271 | break; | 272 | break; |
272 | 273 | ||
273 | case ACPI_TYPE_BUFFER: | 274 | case ACPI_TYPE_BUFFER: |
275 | |||
274 | status = acpi_ex_convert_to_buffer(operand1, &local_operand1); | 276 | status = acpi_ex_convert_to_buffer(operand1, &local_operand1); |
275 | break; | 277 | break; |
276 | 278 | ||
277 | default: | 279 | default: |
280 | |||
278 | ACPI_ERROR((AE_INFO, "Invalid object type: 0x%X", | 281 | ACPI_ERROR((AE_INFO, "Invalid object type: 0x%X", |
279 | operand0->common.type)); | 282 | operand0->common.type)); |
280 | status = AE_AML_INTERNAL; | 283 | status = AE_AML_INTERNAL; |
@@ -519,6 +522,7 @@ acpi_ex_do_logical_numeric_op(u16 opcode, | |||
519 | break; | 522 | break; |
520 | 523 | ||
521 | default: | 524 | default: |
525 | |||
522 | status = AE_AML_INTERNAL; | 526 | status = AE_AML_INTERNAL; |
523 | break; | 527 | break; |
524 | } | 528 | } |
@@ -580,20 +584,24 @@ acpi_ex_do_logical_op(u16 opcode, | |||
580 | */ | 584 | */ |
581 | switch (operand0->common.type) { | 585 | switch (operand0->common.type) { |
582 | case ACPI_TYPE_INTEGER: | 586 | case ACPI_TYPE_INTEGER: |
587 | |||
583 | status = | 588 | status = |
584 | acpi_ex_convert_to_integer(operand1, &local_operand1, 16); | 589 | acpi_ex_convert_to_integer(operand1, &local_operand1, 16); |
585 | break; | 590 | break; |
586 | 591 | ||
587 | case ACPI_TYPE_STRING: | 592 | case ACPI_TYPE_STRING: |
593 | |||
588 | status = acpi_ex_convert_to_string(operand1, &local_operand1, | 594 | status = acpi_ex_convert_to_string(operand1, &local_operand1, |
589 | ACPI_IMPLICIT_CONVERT_HEX); | 595 | ACPI_IMPLICIT_CONVERT_HEX); |
590 | break; | 596 | break; |
591 | 597 | ||
592 | case ACPI_TYPE_BUFFER: | 598 | case ACPI_TYPE_BUFFER: |
599 | |||
593 | status = acpi_ex_convert_to_buffer(operand1, &local_operand1); | 600 | status = acpi_ex_convert_to_buffer(operand1, &local_operand1); |
594 | break; | 601 | break; |
595 | 602 | ||
596 | default: | 603 | default: |
604 | |||
597 | status = AE_AML_INTERNAL; | 605 | status = AE_AML_INTERNAL; |
598 | break; | 606 | break; |
599 | } | 607 | } |
@@ -636,6 +644,7 @@ acpi_ex_do_logical_op(u16 opcode, | |||
636 | break; | 644 | break; |
637 | 645 | ||
638 | default: | 646 | default: |
647 | |||
639 | status = AE_AML_INTERNAL; | 648 | status = AE_AML_INTERNAL; |
640 | break; | 649 | break; |
641 | } | 650 | } |
@@ -703,6 +712,7 @@ acpi_ex_do_logical_op(u16 opcode, | |||
703 | break; | 712 | break; |
704 | 713 | ||
705 | default: | 714 | default: |
715 | |||
706 | status = AE_AML_INTERNAL; | 716 | status = AE_AML_INTERNAL; |
707 | break; | 717 | break; |
708 | } | 718 | } |
diff --git a/drivers/acpi/acpica/exoparg1.c b/drivers/acpi/acpica/exoparg1.c index b60c877f5906..814b4a3d656a 100644 --- a/drivers/acpi/acpica/exoparg1.c +++ b/drivers/acpi/acpica/exoparg1.c | |||
@@ -327,7 +327,6 @@ acpi_status acpi_ex_opcode_1A_1T_1R(struct acpi_walk_state *walk_state) | |||
327 | break; | 327 | break; |
328 | 328 | ||
329 | case AML_FROM_BCD_OP: /* from_bcd (BCDValue, Result) */ | 329 | case AML_FROM_BCD_OP: /* from_bcd (BCDValue, Result) */ |
330 | |||
331 | /* | 330 | /* |
332 | * The 64-bit ACPI integer can hold 16 4-bit BCD characters | 331 | * The 64-bit ACPI integer can hold 16 4-bit BCD characters |
333 | * (if table is 32-bit, integer can hold 8 BCD characters) | 332 | * (if table is 32-bit, integer can hold 8 BCD characters) |
@@ -407,7 +406,6 @@ acpi_status acpi_ex_opcode_1A_1T_1R(struct acpi_walk_state *walk_state) | |||
407 | break; | 406 | break; |
408 | 407 | ||
409 | case AML_COND_REF_OF_OP: /* cond_ref_of (source_object, Result) */ | 408 | case AML_COND_REF_OF_OP: /* cond_ref_of (source_object, Result) */ |
410 | |||
411 | /* | 409 | /* |
412 | * This op is a little strange because the internal return value is | 410 | * This op is a little strange because the internal return value is |
413 | * different than the return value stored in the result descriptor | 411 | * different than the return value stored in the result descriptor |
@@ -442,13 +440,14 @@ acpi_status acpi_ex_opcode_1A_1T_1R(struct acpi_walk_state *walk_state) | |||
442 | goto cleanup; | 440 | goto cleanup; |
443 | 441 | ||
444 | default: | 442 | default: |
443 | |||
445 | /* No other opcodes get here */ | 444 | /* No other opcodes get here */ |
445 | |||
446 | break; | 446 | break; |
447 | } | 447 | } |
448 | break; | 448 | break; |
449 | 449 | ||
450 | case AML_STORE_OP: /* Store (Source, Target) */ | 450 | case AML_STORE_OP: /* Store (Source, Target) */ |
451 | |||
452 | /* | 451 | /* |
453 | * A store operand is typically a number, string, buffer or lvalue | 452 | * A store operand is typically a number, string, buffer or lvalue |
454 | * Be careful about deleting the source object, | 453 | * Be careful about deleting the source object, |
@@ -615,7 +614,6 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
615 | 614 | ||
616 | case AML_DECREMENT_OP: /* Decrement (Operand) */ | 615 | case AML_DECREMENT_OP: /* Decrement (Operand) */ |
617 | case AML_INCREMENT_OP: /* Increment (Operand) */ | 616 | case AML_INCREMENT_OP: /* Increment (Operand) */ |
618 | |||
619 | /* | 617 | /* |
620 | * Create a new integer. Can't just get the base integer and | 618 | * Create a new integer. Can't just get the base integer and |
621 | * increment it because it may be an Arg or Field. | 619 | * increment it because it may be an Arg or Field. |
@@ -682,7 +680,6 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
682 | break; | 680 | break; |
683 | 681 | ||
684 | case AML_TYPE_OP: /* object_type (source_object) */ | 682 | case AML_TYPE_OP: /* object_type (source_object) */ |
685 | |||
686 | /* | 683 | /* |
687 | * Note: The operand is not resolved at this point because we want to | 684 | * Note: The operand is not resolved at this point because we want to |
688 | * get the associated object, not its value. For example, we don't | 685 | * get the associated object, not its value. For example, we don't |
@@ -709,7 +706,6 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
709 | break; | 706 | break; |
710 | 707 | ||
711 | case AML_SIZE_OF_OP: /* size_of (source_object) */ | 708 | case AML_SIZE_OF_OP: /* size_of (source_object) */ |
712 | |||
713 | /* | 709 | /* |
714 | * Note: The operand is not resolved at this point because we want to | 710 | * Note: The operand is not resolved at this point because we want to |
715 | * get the associated object, not its value. | 711 | * get the associated object, not its value. |
@@ -735,10 +731,12 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
735 | */ | 731 | */ |
736 | switch (type) { | 732 | switch (type) { |
737 | case ACPI_TYPE_INTEGER: | 733 | case ACPI_TYPE_INTEGER: |
734 | |||
738 | value = acpi_gbl_integer_byte_width; | 735 | value = acpi_gbl_integer_byte_width; |
739 | break; | 736 | break; |
740 | 737 | ||
741 | case ACPI_TYPE_STRING: | 738 | case ACPI_TYPE_STRING: |
739 | |||
742 | value = temp_desc->string.length; | 740 | value = temp_desc->string.length; |
743 | break; | 741 | break; |
744 | 742 | ||
@@ -759,6 +757,7 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
759 | break; | 757 | break; |
760 | 758 | ||
761 | default: | 759 | default: |
760 | |||
762 | ACPI_ERROR((AE_INFO, | 761 | ACPI_ERROR((AE_INFO, |
763 | "Operand must be Buffer/Integer/String/Package - found type %s", | 762 | "Operand must be Buffer/Integer/String/Package - found type %s", |
764 | acpi_ut_get_type_name(type))); | 763 | acpi_ut_get_type_name(type))); |
@@ -860,9 +859,11 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
860 | break; | 859 | break; |
861 | 860 | ||
862 | case ACPI_TYPE_STRING: | 861 | case ACPI_TYPE_STRING: |
862 | |||
863 | break; | 863 | break; |
864 | 864 | ||
865 | default: | 865 | default: |
866 | |||
866 | status = AE_AML_OPERAND_TYPE; | 867 | status = AE_AML_OPERAND_TYPE; |
867 | goto cleanup; | 868 | goto cleanup; |
868 | } | 869 | } |
@@ -923,7 +924,6 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
923 | */ | 924 | */ |
924 | switch (operand[0]->reference.class) { | 925 | switch (operand[0]->reference.class) { |
925 | case ACPI_REFCLASS_INDEX: | 926 | case ACPI_REFCLASS_INDEX: |
926 | |||
927 | /* | 927 | /* |
928 | * The target type for the Index operator must be | 928 | * The target type for the Index operator must be |
929 | * either a Buffer or a Package | 929 | * either a Buffer or a Package |
@@ -956,7 +956,6 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
956 | break; | 956 | break; |
957 | 957 | ||
958 | case ACPI_TYPE_PACKAGE: | 958 | case ACPI_TYPE_PACKAGE: |
959 | |||
960 | /* | 959 | /* |
961 | * Return the referenced element of the package. We must | 960 | * Return the referenced element of the package. We must |
962 | * add another reference to the referenced object, however. | 961 | * add another reference to the referenced object, however. |
@@ -999,6 +998,7 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state) | |||
999 | break; | 998 | break; |
1000 | 999 | ||
1001 | default: | 1000 | default: |
1001 | |||
1002 | ACPI_ERROR((AE_INFO, | 1002 | ACPI_ERROR((AE_INFO, |
1003 | "Unknown class in reference(%p) - 0x%2.2X", | 1003 | "Unknown class in reference(%p) - 0x%2.2X", |
1004 | operand[0], | 1004 | operand[0], |
diff --git a/drivers/acpi/acpica/exoparg2.c b/drivers/acpi/acpica/exoparg2.c index b0838a4ea53e..d5088f7030c7 100644 --- a/drivers/acpi/acpica/exoparg2.c +++ b/drivers/acpi/acpica/exoparg2.c | |||
@@ -304,7 +304,6 @@ acpi_status acpi_ex_opcode_2A_1T_1R(struct acpi_walk_state *walk_state) | |||
304 | break; | 304 | break; |
305 | 305 | ||
306 | case AML_TO_STRING_OP: /* to_string (Buffer, Length, Result) (ACPI 2.0) */ | 306 | case AML_TO_STRING_OP: /* to_string (Buffer, Length, Result) (ACPI 2.0) */ |
307 | |||
308 | /* | 307 | /* |
309 | * Input object is guaranteed to be a buffer at this point (it may have | 308 | * Input object is guaranteed to be a buffer at this point (it may have |
310 | * been converted.) Copy the raw buffer data to a new object of | 309 | * been converted.) Copy the raw buffer data to a new object of |
diff --git a/drivers/acpi/acpica/exoparg3.c b/drivers/acpi/acpica/exoparg3.c index 2d7491f3126e..37656f12f204 100644 --- a/drivers/acpi/acpica/exoparg3.c +++ b/drivers/acpi/acpica/exoparg3.c | |||
@@ -155,7 +155,6 @@ acpi_status acpi_ex_opcode_3A_1T_1R(struct acpi_walk_state *walk_state) | |||
155 | 155 | ||
156 | switch (walk_state->opcode) { | 156 | switch (walk_state->opcode) { |
157 | case AML_MID_OP: /* Mid (Source[0], Index[1], Length[2], Result[3]) */ | 157 | case AML_MID_OP: /* Mid (Source[0], Index[1], Length[2], Result[3]) */ |
158 | |||
159 | /* | 158 | /* |
160 | * Create the return object. The Source operand is guaranteed to be | 159 | * Create the return object. The Source operand is guaranteed to be |
161 | * either a String or a Buffer, so just use its type. | 160 | * either a String or a Buffer, so just use its type. |
diff --git a/drivers/acpi/acpica/exoparg6.c b/drivers/acpi/acpica/exoparg6.c index b76b97002dff..879b6cd8319c 100644 --- a/drivers/acpi/acpica/exoparg6.c +++ b/drivers/acpi/acpica/exoparg6.c | |||
@@ -119,7 +119,6 @@ acpi_ex_do_match(u32 match_op, | |||
119 | break; | 119 | break; |
120 | 120 | ||
121 | case MATCH_MEQ: | 121 | case MATCH_MEQ: |
122 | |||
123 | /* | 122 | /* |
124 | * True if equal: (P[i] == M) | 123 | * True if equal: (P[i] == M) |
125 | * Change to: (M == P[i]) | 124 | * Change to: (M == P[i]) |
@@ -133,7 +132,6 @@ acpi_ex_do_match(u32 match_op, | |||
133 | break; | 132 | break; |
134 | 133 | ||
135 | case MATCH_MLE: | 134 | case MATCH_MLE: |
136 | |||
137 | /* | 135 | /* |
138 | * True if less than or equal: (P[i] <= M) (P[i] not_greater than M) | 136 | * True if less than or equal: (P[i] <= M) (P[i] not_greater than M) |
139 | * Change to: (M >= P[i]) (M not_less than P[i]) | 137 | * Change to: (M >= P[i]) (M not_less than P[i]) |
@@ -148,7 +146,6 @@ acpi_ex_do_match(u32 match_op, | |||
148 | break; | 146 | break; |
149 | 147 | ||
150 | case MATCH_MLT: | 148 | case MATCH_MLT: |
151 | |||
152 | /* | 149 | /* |
153 | * True if less than: (P[i] < M) | 150 | * True if less than: (P[i] < M) |
154 | * Change to: (M > P[i]) | 151 | * Change to: (M > P[i]) |
@@ -162,7 +159,6 @@ acpi_ex_do_match(u32 match_op, | |||
162 | break; | 159 | break; |
163 | 160 | ||
164 | case MATCH_MGE: | 161 | case MATCH_MGE: |
165 | |||
166 | /* | 162 | /* |
167 | * True if greater than or equal: (P[i] >= M) (P[i] not_less than M) | 163 | * True if greater than or equal: (P[i] >= M) (P[i] not_less than M) |
168 | * Change to: (M <= P[i]) (M not_greater than P[i]) | 164 | * Change to: (M <= P[i]) (M not_greater than P[i]) |
@@ -177,7 +173,6 @@ acpi_ex_do_match(u32 match_op, | |||
177 | break; | 173 | break; |
178 | 174 | ||
179 | case MATCH_MGT: | 175 | case MATCH_MGT: |
180 | |||
181 | /* | 176 | /* |
182 | * True if greater than: (P[i] > M) | 177 | * True if greater than: (P[i] > M) |
183 | * Change to: (M < P[i]) | 178 | * Change to: (M < P[i]) |
diff --git a/drivers/acpi/acpica/exprep.c b/drivers/acpi/acpica/exprep.c index 6b728aef2dca..5a588611ab48 100644 --- a/drivers/acpi/acpica/exprep.c +++ b/drivers/acpi/acpica/exprep.c | |||
@@ -253,26 +253,31 @@ acpi_ex_decode_field_access(union acpi_operand_object *obj_desc, | |||
253 | 253 | ||
254 | case AML_FIELD_ACCESS_BYTE: | 254 | case AML_FIELD_ACCESS_BYTE: |
255 | case AML_FIELD_ACCESS_BUFFER: /* ACPI 2.0 (SMBus Buffer) */ | 255 | case AML_FIELD_ACCESS_BUFFER: /* ACPI 2.0 (SMBus Buffer) */ |
256 | |||
256 | byte_alignment = 1; | 257 | byte_alignment = 1; |
257 | bit_length = 8; | 258 | bit_length = 8; |
258 | break; | 259 | break; |
259 | 260 | ||
260 | case AML_FIELD_ACCESS_WORD: | 261 | case AML_FIELD_ACCESS_WORD: |
262 | |||
261 | byte_alignment = 2; | 263 | byte_alignment = 2; |
262 | bit_length = 16; | 264 | bit_length = 16; |
263 | break; | 265 | break; |
264 | 266 | ||
265 | case AML_FIELD_ACCESS_DWORD: | 267 | case AML_FIELD_ACCESS_DWORD: |
268 | |||
266 | byte_alignment = 4; | 269 | byte_alignment = 4; |
267 | bit_length = 32; | 270 | bit_length = 32; |
268 | break; | 271 | break; |
269 | 272 | ||
270 | case AML_FIELD_ACCESS_QWORD: /* ACPI 2.0 */ | 273 | case AML_FIELD_ACCESS_QWORD: /* ACPI 2.0 */ |
274 | |||
271 | byte_alignment = 8; | 275 | byte_alignment = 8; |
272 | bit_length = 64; | 276 | bit_length = 64; |
273 | break; | 277 | break; |
274 | 278 | ||
275 | default: | 279 | default: |
280 | |||
276 | /* Invalid field access type */ | 281 | /* Invalid field access type */ |
277 | 282 | ||
278 | ACPI_ERROR((AE_INFO, "Unknown field access type 0x%X", access)); | 283 | ACPI_ERROR((AE_INFO, "Unknown field access type 0x%X", access)); |
@@ -598,7 +603,9 @@ acpi_status acpi_ex_prep_field_value(struct acpi_create_field_info *info) | |||
598 | break; | 603 | break; |
599 | 604 | ||
600 | default: | 605 | default: |
606 | |||
601 | /* No other types should get here */ | 607 | /* No other types should get here */ |
608 | |||
602 | break; | 609 | break; |
603 | } | 610 | } |
604 | 611 | ||
diff --git a/drivers/acpi/acpica/exregion.c b/drivers/acpi/acpica/exregion.c index 182abaf045e1..303429bb4d5d 100644 --- a/drivers/acpi/acpica/exregion.c +++ b/drivers/acpi/acpica/exregion.c | |||
@@ -88,22 +88,27 @@ acpi_ex_system_memory_space_handler(u32 function, | |||
88 | 88 | ||
89 | switch (bit_width) { | 89 | switch (bit_width) { |
90 | case 8: | 90 | case 8: |
91 | |||
91 | length = 1; | 92 | length = 1; |
92 | break; | 93 | break; |
93 | 94 | ||
94 | case 16: | 95 | case 16: |
96 | |||
95 | length = 2; | 97 | length = 2; |
96 | break; | 98 | break; |
97 | 99 | ||
98 | case 32: | 100 | case 32: |
101 | |||
99 | length = 4; | 102 | length = 4; |
100 | break; | 103 | break; |
101 | 104 | ||
102 | case 64: | 105 | case 64: |
106 | |||
103 | length = 8; | 107 | length = 8; |
104 | break; | 108 | break; |
105 | 109 | ||
106 | default: | 110 | default: |
111 | |||
107 | ACPI_ERROR((AE_INFO, "Invalid SystemMemory width %u", | 112 | ACPI_ERROR((AE_INFO, "Invalid SystemMemory width %u", |
108 | bit_width)); | 113 | bit_width)); |
109 | return_ACPI_STATUS(AE_AML_OPERAND_VALUE); | 114 | return_ACPI_STATUS(AE_AML_OPERAND_VALUE); |
@@ -214,23 +219,29 @@ acpi_ex_system_memory_space_handler(u32 function, | |||
214 | *value = 0; | 219 | *value = 0; |
215 | switch (bit_width) { | 220 | switch (bit_width) { |
216 | case 8: | 221 | case 8: |
217 | *value = (u64) ACPI_GET8(logical_addr_ptr); | 222 | |
223 | *value = (u64)ACPI_GET8(logical_addr_ptr); | ||
218 | break; | 224 | break; |
219 | 225 | ||
220 | case 16: | 226 | case 16: |
221 | *value = (u64) ACPI_GET16(logical_addr_ptr); | 227 | |
228 | *value = (u64)ACPI_GET16(logical_addr_ptr); | ||
222 | break; | 229 | break; |
223 | 230 | ||
224 | case 32: | 231 | case 32: |
225 | *value = (u64) ACPI_GET32(logical_addr_ptr); | 232 | |
233 | *value = (u64)ACPI_GET32(logical_addr_ptr); | ||
226 | break; | 234 | break; |
227 | 235 | ||
228 | case 64: | 236 | case 64: |
229 | *value = (u64) ACPI_GET64(logical_addr_ptr); | 237 | |
238 | *value = (u64)ACPI_GET64(logical_addr_ptr); | ||
230 | break; | 239 | break; |
231 | 240 | ||
232 | default: | 241 | default: |
242 | |||
233 | /* bit_width was already validated */ | 243 | /* bit_width was already validated */ |
244 | |||
234 | break; | 245 | break; |
235 | } | 246 | } |
236 | break; | 247 | break; |
@@ -239,28 +250,35 @@ acpi_ex_system_memory_space_handler(u32 function, | |||
239 | 250 | ||
240 | switch (bit_width) { | 251 | switch (bit_width) { |
241 | case 8: | 252 | case 8: |
253 | |||
242 | ACPI_SET8(logical_addr_ptr, *value); | 254 | ACPI_SET8(logical_addr_ptr, *value); |
243 | break; | 255 | break; |
244 | 256 | ||
245 | case 16: | 257 | case 16: |
258 | |||
246 | ACPI_SET16(logical_addr_ptr, *value); | 259 | ACPI_SET16(logical_addr_ptr, *value); |
247 | break; | 260 | break; |
248 | 261 | ||
249 | case 32: | 262 | case 32: |
263 | |||
250 | ACPI_SET32(logical_addr_ptr, *value); | 264 | ACPI_SET32(logical_addr_ptr, *value); |
251 | break; | 265 | break; |
252 | 266 | ||
253 | case 64: | 267 | case 64: |
268 | |||
254 | ACPI_SET64(logical_addr_ptr, *value); | 269 | ACPI_SET64(logical_addr_ptr, *value); |
255 | break; | 270 | break; |
256 | 271 | ||
257 | default: | 272 | default: |
273 | |||
258 | /* bit_width was already validated */ | 274 | /* bit_width was already validated */ |
275 | |||
259 | break; | 276 | break; |
260 | } | 277 | } |
261 | break; | 278 | break; |
262 | 279 | ||
263 | default: | 280 | default: |
281 | |||
264 | status = AE_BAD_PARAMETER; | 282 | status = AE_BAD_PARAMETER; |
265 | break; | 283 | break; |
266 | } | 284 | } |
@@ -320,6 +338,7 @@ acpi_ex_system_io_space_handler(u32 function, | |||
320 | break; | 338 | break; |
321 | 339 | ||
322 | default: | 340 | default: |
341 | |||
323 | status = AE_BAD_PARAMETER; | 342 | status = AE_BAD_PARAMETER; |
324 | break; | 343 | break; |
325 | } | 344 | } |
diff --git a/drivers/acpi/acpica/exresnte.c b/drivers/acpi/acpica/exresnte.c index 8565b6bd12bb..acd34f599313 100644 --- a/drivers/acpi/acpica/exresnte.c +++ b/drivers/acpi/acpica/exresnte.c | |||
@@ -248,6 +248,7 @@ acpi_ex_resolve_node_to_value(struct acpi_namespace_node **object_ptr, | |||
248 | break; | 248 | break; |
249 | 249 | ||
250 | default: | 250 | default: |
251 | |||
251 | /* No named references are allowed here */ | 252 | /* No named references are allowed here */ |
252 | 253 | ||
253 | ACPI_ERROR((AE_INFO, | 254 | ACPI_ERROR((AE_INFO, |
diff --git a/drivers/acpi/acpica/exresolv.c b/drivers/acpi/acpica/exresolv.c index e4f9dfbb2a13..ac04278ad28f 100644 --- a/drivers/acpi/acpica/exresolv.c +++ b/drivers/acpi/acpica/exresolv.c | |||
@@ -156,7 +156,6 @@ acpi_ex_resolve_object_to_value(union acpi_operand_object **stack_ptr, | |||
156 | switch (ref_type) { | 156 | switch (ref_type) { |
157 | case ACPI_REFCLASS_LOCAL: | 157 | case ACPI_REFCLASS_LOCAL: |
158 | case ACPI_REFCLASS_ARG: | 158 | case ACPI_REFCLASS_ARG: |
159 | |||
160 | /* | 159 | /* |
161 | * Get the local from the method's state info | 160 | * Get the local from the method's state info |
162 | * Note: this increments the local's object reference count | 161 | * Note: this increments the local's object reference count |
@@ -309,6 +308,7 @@ acpi_ex_resolve_object_to_value(union acpi_operand_object **stack_ptr, | |||
309 | break; | 308 | break; |
310 | 309 | ||
311 | default: | 310 | default: |
311 | |||
312 | break; | 312 | break; |
313 | } | 313 | } |
314 | 314 | ||
@@ -348,10 +348,12 @@ acpi_ex_resolve_multiple(struct acpi_walk_state *walk_state, | |||
348 | 348 | ||
349 | switch (ACPI_GET_DESCRIPTOR_TYPE(obj_desc)) { | 349 | switch (ACPI_GET_DESCRIPTOR_TYPE(obj_desc)) { |
350 | case ACPI_DESC_TYPE_OPERAND: | 350 | case ACPI_DESC_TYPE_OPERAND: |
351 | |||
351 | type = obj_desc->common.type; | 352 | type = obj_desc->common.type; |
352 | break; | 353 | break; |
353 | 354 | ||
354 | case ACPI_DESC_TYPE_NAMED: | 355 | case ACPI_DESC_TYPE_NAMED: |
356 | |||
355 | type = ((struct acpi_namespace_node *)obj_desc)->type; | 357 | type = ((struct acpi_namespace_node *)obj_desc)->type; |
356 | obj_desc = | 358 | obj_desc = |
357 | acpi_ns_get_attached_object((struct acpi_namespace_node *) | 359 | acpi_ns_get_attached_object((struct acpi_namespace_node *) |
@@ -538,7 +540,9 @@ acpi_ex_resolve_multiple(struct acpi_walk_state *walk_state, | |||
538 | break; | 540 | break; |
539 | 541 | ||
540 | default: | 542 | default: |
543 | |||
541 | /* No change to Type required */ | 544 | /* No change to Type required */ |
545 | |||
542 | break; | 546 | break; |
543 | } | 547 | } |
544 | 548 | ||
diff --git a/drivers/acpi/acpica/exresop.c b/drivers/acpi/acpica/exresop.c index 9fb9f5e9a4da..00e5af7129c1 100644 --- a/drivers/acpi/acpica/exresop.c +++ b/drivers/acpi/acpica/exresop.c | |||
@@ -307,7 +307,6 @@ acpi_ex_resolve_operands(u16 opcode, | |||
307 | case ARGI_TARGETREF: /* Allows implicit conversion rules before store */ | 307 | case ARGI_TARGETREF: /* Allows implicit conversion rules before store */ |
308 | case ARGI_FIXED_TARGET: /* No implicit conversion before store to target */ | 308 | case ARGI_FIXED_TARGET: /* No implicit conversion before store to target */ |
309 | case ARGI_SIMPLE_TARGET: /* Name, Local, or arg - no implicit conversion */ | 309 | case ARGI_SIMPLE_TARGET: /* Name, Local, or arg - no implicit conversion */ |
310 | |||
311 | /* | 310 | /* |
312 | * Need an operand of type ACPI_TYPE_LOCAL_REFERENCE | 311 | * Need an operand of type ACPI_TYPE_LOCAL_REFERENCE |
313 | * A Namespace Node is OK as-is | 312 | * A Namespace Node is OK as-is |
@@ -326,7 +325,6 @@ acpi_ex_resolve_operands(u16 opcode, | |||
326 | goto next_operand; | 325 | goto next_operand; |
327 | 326 | ||
328 | case ARGI_DATAREFOBJ: /* Store operator only */ | 327 | case ARGI_DATAREFOBJ: /* Store operator only */ |
329 | |||
330 | /* | 328 | /* |
331 | * We don't want to resolve index_op reference objects during | 329 | * We don't want to resolve index_op reference objects during |
332 | * a store because this would be an implicit de_ref_of operation. | 330 | * a store because this would be an implicit de_ref_of operation. |
@@ -343,7 +341,9 @@ acpi_ex_resolve_operands(u16 opcode, | |||
343 | break; | 341 | break; |
344 | 342 | ||
345 | default: | 343 | default: |
344 | |||
346 | /* All cases covered above */ | 345 | /* All cases covered above */ |
346 | |||
347 | break; | 347 | break; |
348 | } | 348 | } |
349 | 349 | ||
@@ -433,7 +433,6 @@ acpi_ex_resolve_operands(u16 opcode, | |||
433 | goto next_operand; | 433 | goto next_operand; |
434 | 434 | ||
435 | case ARGI_BUFFER: | 435 | case ARGI_BUFFER: |
436 | |||
437 | /* | 436 | /* |
438 | * Need an operand of type ACPI_TYPE_BUFFER, | 437 | * Need an operand of type ACPI_TYPE_BUFFER, |
439 | * But we can implicitly convert from a STRING or INTEGER | 438 | * But we can implicitly convert from a STRING or INTEGER |
@@ -459,7 +458,6 @@ acpi_ex_resolve_operands(u16 opcode, | |||
459 | goto next_operand; | 458 | goto next_operand; |
460 | 459 | ||
461 | case ARGI_STRING: | 460 | case ARGI_STRING: |
462 | |||
463 | /* | 461 | /* |
464 | * Need an operand of type ACPI_TYPE_STRING, | 462 | * Need an operand of type ACPI_TYPE_STRING, |
465 | * But we can implicitly convert from a BUFFER or INTEGER | 463 | * But we can implicitly convert from a BUFFER or INTEGER |
@@ -562,6 +560,7 @@ acpi_ex_resolve_operands(u16 opcode, | |||
562 | break; | 560 | break; |
563 | 561 | ||
564 | default: | 562 | default: |
563 | |||
565 | ACPI_ERROR((AE_INFO, | 564 | ACPI_ERROR((AE_INFO, |
566 | "Needed [Buffer/String/Package/Reference], found [%s] %p", | 565 | "Needed [Buffer/String/Package/Reference], found [%s] %p", |
567 | acpi_ut_get_object_type_name | 566 | acpi_ut_get_object_type_name |
@@ -584,6 +583,7 @@ acpi_ex_resolve_operands(u16 opcode, | |||
584 | break; | 583 | break; |
585 | 584 | ||
586 | default: | 585 | default: |
586 | |||
587 | ACPI_ERROR((AE_INFO, | 587 | ACPI_ERROR((AE_INFO, |
588 | "Needed [Buffer/String/Package], found [%s] %p", | 588 | "Needed [Buffer/String/Package], found [%s] %p", |
589 | acpi_ut_get_object_type_name | 589 | acpi_ut_get_object_type_name |
@@ -605,6 +605,7 @@ acpi_ex_resolve_operands(u16 opcode, | |||
605 | break; | 605 | break; |
606 | 606 | ||
607 | default: | 607 | default: |
608 | |||
608 | ACPI_ERROR((AE_INFO, | 609 | ACPI_ERROR((AE_INFO, |
609 | "Needed [Region/Buffer], found [%s] %p", | 610 | "Needed [Region/Buffer], found [%s] %p", |
610 | acpi_ut_get_object_type_name | 611 | acpi_ut_get_object_type_name |
diff --git a/drivers/acpi/acpica/exstore.c b/drivers/acpi/acpica/exstore.c index 93c6049c2d75..2bdba6f7d762 100644 --- a/drivers/acpi/acpica/exstore.c +++ b/drivers/acpi/acpica/exstore.c | |||
@@ -114,6 +114,7 @@ acpi_ex_store(union acpi_operand_object *source_desc, | |||
114 | 114 | ||
115 | switch (dest_desc->common.type) { | 115 | switch (dest_desc->common.type) { |
116 | case ACPI_TYPE_LOCAL_REFERENCE: | 116 | case ACPI_TYPE_LOCAL_REFERENCE: |
117 | |||
117 | break; | 118 | break; |
118 | 119 | ||
119 | case ACPI_TYPE_INTEGER: | 120 | case ACPI_TYPE_INTEGER: |
@@ -178,7 +179,6 @@ acpi_ex_store(union acpi_operand_object *source_desc, | |||
178 | break; | 179 | break; |
179 | 180 | ||
180 | case ACPI_REFCLASS_DEBUG: | 181 | case ACPI_REFCLASS_DEBUG: |
181 | |||
182 | /* | 182 | /* |
183 | * Storing to the Debug object causes the value stored to be | 183 | * Storing to the Debug object causes the value stored to be |
184 | * displayed and otherwise has no effect -- see ACPI Specification | 184 | * displayed and otherwise has no effect -- see ACPI Specification |
@@ -291,7 +291,6 @@ acpi_ex_store_object_to_index(union acpi_operand_object *source_desc, | |||
291 | break; | 291 | break; |
292 | 292 | ||
293 | case ACPI_TYPE_BUFFER_FIELD: | 293 | case ACPI_TYPE_BUFFER_FIELD: |
294 | |||
295 | /* | 294 | /* |
296 | * Store into a Buffer or String (not actually a real buffer_field) | 295 | * Store into a Buffer or String (not actually a real buffer_field) |
297 | * at a location defined by an Index. | 296 | * at a location defined by an Index. |
@@ -447,7 +446,6 @@ acpi_ex_store_object_to_node(union acpi_operand_object *source_desc, | |||
447 | case ACPI_TYPE_INTEGER: | 446 | case ACPI_TYPE_INTEGER: |
448 | case ACPI_TYPE_STRING: | 447 | case ACPI_TYPE_STRING: |
449 | case ACPI_TYPE_BUFFER: | 448 | case ACPI_TYPE_BUFFER: |
450 | |||
451 | /* | 449 | /* |
452 | * These target types are all of type Integer/String/Buffer, and | 450 | * These target types are all of type Integer/String/Buffer, and |
453 | * therefore support implicit conversion before the store. | 451 | * therefore support implicit conversion before the store. |
diff --git a/drivers/acpi/acpica/exstoren.c b/drivers/acpi/acpica/exstoren.c index 1cefe777068e..20d809d90c5b 100644 --- a/drivers/acpi/acpica/exstoren.c +++ b/drivers/acpi/acpica/exstoren.c | |||
@@ -85,11 +85,9 @@ acpi_ex_resolve_object(union acpi_operand_object **source_desc_ptr, | |||
85 | * These cases all require only Integers or values that | 85 | * These cases all require only Integers or values that |
86 | * can be converted to Integers (Strings or Buffers) | 86 | * can be converted to Integers (Strings or Buffers) |
87 | */ | 87 | */ |
88 | |||
89 | case ACPI_TYPE_INTEGER: | 88 | case ACPI_TYPE_INTEGER: |
90 | case ACPI_TYPE_STRING: | 89 | case ACPI_TYPE_STRING: |
91 | case ACPI_TYPE_BUFFER: | 90 | case ACPI_TYPE_BUFFER: |
92 | |||
93 | /* | 91 | /* |
94 | * Stores into a Field/Region or into a Integer/Buffer/String | 92 | * Stores into a Field/Region or into a Integer/Buffer/String |
95 | * are all essentially the same. This case handles the | 93 | * are all essentially the same. This case handles the |
@@ -133,7 +131,6 @@ acpi_ex_resolve_object(union acpi_operand_object **source_desc_ptr, | |||
133 | 131 | ||
134 | case ACPI_TYPE_LOCAL_ALIAS: | 132 | case ACPI_TYPE_LOCAL_ALIAS: |
135 | case ACPI_TYPE_LOCAL_METHOD_ALIAS: | 133 | case ACPI_TYPE_LOCAL_METHOD_ALIAS: |
136 | |||
137 | /* | 134 | /* |
138 | * All aliases should have been resolved earlier, during the | 135 | * All aliases should have been resolved earlier, during the |
139 | * operand resolution phase. | 136 | * operand resolution phase. |
@@ -144,7 +141,6 @@ acpi_ex_resolve_object(union acpi_operand_object **source_desc_ptr, | |||
144 | 141 | ||
145 | case ACPI_TYPE_PACKAGE: | 142 | case ACPI_TYPE_PACKAGE: |
146 | default: | 143 | default: |
147 | |||
148 | /* | 144 | /* |
149 | * All other types than Alias and the various Fields come here, | 145 | * All other types than Alias and the various Fields come here, |
150 | * including the untyped case - ACPI_TYPE_ANY. | 146 | * including the untyped case - ACPI_TYPE_ANY. |
diff --git a/drivers/acpi/acpica/hwacpi.c b/drivers/acpi/acpica/hwacpi.c index 579c3a53ac87..3d36df828f52 100644 --- a/drivers/acpi/acpica/hwacpi.c +++ b/drivers/acpi/acpica/hwacpi.c | |||
@@ -108,7 +108,6 @@ acpi_status acpi_hw_set_mode(u32 mode) | |||
108 | break; | 108 | break; |
109 | 109 | ||
110 | case ACPI_SYS_MODE_LEGACY: | 110 | case ACPI_SYS_MODE_LEGACY: |
111 | |||
112 | /* | 111 | /* |
113 | * BIOS should clear all fixed status bits and restore fixed event | 112 | * BIOS should clear all fixed status bits and restore fixed event |
114 | * enable bits to default | 113 | * enable bits to default |
@@ -120,6 +119,7 @@ acpi_status acpi_hw_set_mode(u32 mode) | |||
120 | break; | 119 | break; |
121 | 120 | ||
122 | default: | 121 | default: |
122 | |||
123 | return_ACPI_STATUS(AE_BAD_PARAMETER); | 123 | return_ACPI_STATUS(AE_BAD_PARAMETER); |
124 | } | 124 | } |
125 | 125 | ||
diff --git a/drivers/acpi/acpica/hwgpe.c b/drivers/acpi/acpica/hwgpe.c index 20d02e93c990..96540506058f 100644 --- a/drivers/acpi/acpica/hwgpe.c +++ b/drivers/acpi/acpica/hwgpe.c | |||
@@ -127,14 +127,17 @@ acpi_hw_low_set_gpe(struct acpi_gpe_event_info *gpe_event_info, u32 action) | |||
127 | /*lint -fallthrough */ | 127 | /*lint -fallthrough */ |
128 | 128 | ||
129 | case ACPI_GPE_ENABLE: | 129 | case ACPI_GPE_ENABLE: |
130 | |||
130 | ACPI_SET_BIT(enable_mask, register_bit); | 131 | ACPI_SET_BIT(enable_mask, register_bit); |
131 | break; | 132 | break; |
132 | 133 | ||
133 | case ACPI_GPE_DISABLE: | 134 | case ACPI_GPE_DISABLE: |
135 | |||
134 | ACPI_CLEAR_BIT(enable_mask, register_bit); | 136 | ACPI_CLEAR_BIT(enable_mask, register_bit); |
135 | break; | 137 | break; |
136 | 138 | ||
137 | default: | 139 | default: |
140 | |||
138 | ACPI_ERROR((AE_INFO, "Invalid GPE Action, %u", action)); | 141 | ACPI_ERROR((AE_INFO, "Invalid GPE Action, %u", action)); |
139 | return (AE_BAD_PARAMETER); | 142 | return (AE_BAD_PARAMETER); |
140 | } | 143 | } |
diff --git a/drivers/acpi/acpica/hwregs.c b/drivers/acpi/acpica/hwregs.c index 083d6551f0e2..8d2e866be15f 100644 --- a/drivers/acpi/acpica/hwregs.c +++ b/drivers/acpi/acpica/hwregs.c | |||
@@ -419,6 +419,7 @@ acpi_status acpi_hw_register_read(u32 register_id, u32 *return_value) | |||
419 | break; | 419 | break; |
420 | 420 | ||
421 | default: | 421 | default: |
422 | |||
422 | ACPI_ERROR((AE_INFO, "Unknown Register ID: 0x%X", register_id)); | 423 | ACPI_ERROR((AE_INFO, "Unknown Register ID: 0x%X", register_id)); |
423 | status = AE_BAD_PARAMETER; | 424 | status = AE_BAD_PARAMETER; |
424 | break; | 425 | break; |
@@ -491,7 +492,6 @@ acpi_status acpi_hw_register_write(u32 register_id, u32 value) | |||
491 | break; | 492 | break; |
492 | 493 | ||
493 | case ACPI_REGISTER_PM1_CONTROL: /* PM1 A/B: 16-bit access each */ | 494 | case ACPI_REGISTER_PM1_CONTROL: /* PM1 A/B: 16-bit access each */ |
494 | |||
495 | /* | 495 | /* |
496 | * Perform a read first to preserve certain bits (per ACPI spec) | 496 | * Perform a read first to preserve certain bits (per ACPI spec) |
497 | * Note: This includes SCI_EN, we never want to change this bit | 497 | * Note: This includes SCI_EN, we never want to change this bit |
@@ -520,7 +520,6 @@ acpi_status acpi_hw_register_write(u32 register_id, u32 value) | |||
520 | break; | 520 | break; |
521 | 521 | ||
522 | case ACPI_REGISTER_PM2_CONTROL: /* 8-bit access */ | 522 | case ACPI_REGISTER_PM2_CONTROL: /* 8-bit access */ |
523 | |||
524 | /* | 523 | /* |
525 | * For control registers, all reserved bits must be preserved, | 524 | * For control registers, all reserved bits must be preserved, |
526 | * as per the ACPI spec. | 525 | * as per the ACPI spec. |
@@ -555,6 +554,7 @@ acpi_status acpi_hw_register_write(u32 register_id, u32 value) | |||
555 | break; | 554 | break; |
556 | 555 | ||
557 | default: | 556 | default: |
557 | |||
558 | ACPI_ERROR((AE_INFO, "Unknown Register ID: 0x%X", register_id)); | 558 | ACPI_ERROR((AE_INFO, "Unknown Register ID: 0x%X", register_id)); |
559 | status = AE_BAD_PARAMETER; | 559 | status = AE_BAD_PARAMETER; |
560 | break; | 560 | break; |
diff --git a/drivers/acpi/acpica/hwxface.c b/drivers/acpi/acpica/hwxface.c index f4224e6f4e7a..5ee7a814cd92 100644 --- a/drivers/acpi/acpica/hwxface.c +++ b/drivers/acpi/acpica/hwxface.c | |||
@@ -528,10 +528,12 @@ acpi_get_sleep_type_data(u8 sleep_state, u8 *sleep_type_a, u8 *sleep_type_b) | |||
528 | elements = info->return_object->package.elements; | 528 | elements = info->return_object->package.elements; |
529 | switch (info->return_object->package.count) { | 529 | switch (info->return_object->package.count) { |
530 | case 0: | 530 | case 0: |
531 | |||
531 | status = AE_AML_PACKAGE_LIMIT; | 532 | status = AE_AML_PACKAGE_LIMIT; |
532 | break; | 533 | break; |
533 | 534 | ||
534 | case 1: | 535 | case 1: |
536 | |||
535 | if (elements[0]->common.type != ACPI_TYPE_INTEGER) { | 537 | if (elements[0]->common.type != ACPI_TYPE_INTEGER) { |
536 | status = AE_AML_OPERAND_TYPE; | 538 | status = AE_AML_OPERAND_TYPE; |
537 | break; | 539 | break; |
@@ -545,6 +547,7 @@ acpi_get_sleep_type_data(u8 sleep_state, u8 *sleep_type_a, u8 *sleep_type_b) | |||
545 | 547 | ||
546 | case 2: | 548 | case 2: |
547 | default: | 549 | default: |
550 | |||
548 | if ((elements[0]->common.type != ACPI_TYPE_INTEGER) || | 551 | if ((elements[0]->common.type != ACPI_TYPE_INTEGER) || |
549 | (elements[1]->common.type != ACPI_TYPE_INTEGER)) { | 552 | (elements[1]->common.type != ACPI_TYPE_INTEGER)) { |
550 | status = AE_AML_OPERAND_TYPE; | 553 | status = AE_AML_OPERAND_TYPE; |
diff --git a/drivers/acpi/acpica/hwxfsleep.c b/drivers/acpi/acpica/hwxfsleep.c index 35eebdac0f9d..111849c2117f 100644 --- a/drivers/acpi/acpica/hwxfsleep.c +++ b/drivers/acpi/acpica/hwxfsleep.c | |||
@@ -314,20 +314,24 @@ acpi_status acpi_enter_sleep_state_prep(u8 sleep_state) | |||
314 | 314 | ||
315 | switch (sleep_state) { | 315 | switch (sleep_state) { |
316 | case ACPI_STATE_S0: | 316 | case ACPI_STATE_S0: |
317 | |||
317 | sst_value = ACPI_SST_WORKING; | 318 | sst_value = ACPI_SST_WORKING; |
318 | break; | 319 | break; |
319 | 320 | ||
320 | case ACPI_STATE_S1: | 321 | case ACPI_STATE_S1: |
321 | case ACPI_STATE_S2: | 322 | case ACPI_STATE_S2: |
322 | case ACPI_STATE_S3: | 323 | case ACPI_STATE_S3: |
324 | |||
323 | sst_value = ACPI_SST_SLEEPING; | 325 | sst_value = ACPI_SST_SLEEPING; |
324 | break; | 326 | break; |
325 | 327 | ||
326 | case ACPI_STATE_S4: | 328 | case ACPI_STATE_S4: |
329 | |||
327 | sst_value = ACPI_SST_SLEEP_CONTEXT; | 330 | sst_value = ACPI_SST_SLEEP_CONTEXT; |
328 | break; | 331 | break; |
329 | 332 | ||
330 | default: | 333 | default: |
334 | |||
331 | sst_value = ACPI_SST_INDICATOR_OFF; /* Default is off */ | 335 | sst_value = ACPI_SST_INDICATOR_OFF; /* Default is off */ |
332 | break; | 336 | break; |
333 | } | 337 | } |
diff --git a/drivers/acpi/acpica/nsaccess.c b/drivers/acpi/acpica/nsaccess.c index 8769cf83b044..c5316e5bd4ab 100644 --- a/drivers/acpi/acpica/nsaccess.c +++ b/drivers/acpi/acpica/nsaccess.c | |||
@@ -151,6 +151,7 @@ acpi_status acpi_ns_root_initialize(void) | |||
151 | */ | 151 | */ |
152 | switch (init_val->type) { | 152 | switch (init_val->type) { |
153 | case ACPI_TYPE_METHOD: | 153 | case ACPI_TYPE_METHOD: |
154 | |||
154 | obj_desc->method.param_count = | 155 | obj_desc->method.param_count = |
155 | (u8) ACPI_TO_INTEGER(val); | 156 | (u8) ACPI_TO_INTEGER(val); |
156 | obj_desc->common.flags |= AOPOBJ_DATA_VALID; | 157 | obj_desc->common.flags |= AOPOBJ_DATA_VALID; |
diff --git a/drivers/acpi/acpica/nsconvert.c b/drivers/acpi/acpica/nsconvert.c index 8f79a9d2d50e..acd2964c2690 100644 --- a/drivers/acpi/acpica/nsconvert.c +++ b/drivers/acpi/acpica/nsconvert.c | |||
@@ -103,6 +103,7 @@ acpi_ns_convert_to_integer(union acpi_operand_object *original_object, | |||
103 | break; | 103 | break; |
104 | 104 | ||
105 | default: | 105 | default: |
106 | |||
106 | return (AE_AML_OPERAND_TYPE); | 107 | return (AE_AML_OPERAND_TYPE); |
107 | } | 108 | } |
108 | 109 | ||
@@ -191,6 +192,7 @@ acpi_ns_convert_to_string(union acpi_operand_object *original_object, | |||
191 | break; | 192 | break; |
192 | 193 | ||
193 | default: | 194 | default: |
195 | |||
194 | return (AE_AML_OPERAND_TYPE); | 196 | return (AE_AML_OPERAND_TYPE); |
195 | } | 197 | } |
196 | 198 | ||
@@ -294,6 +296,7 @@ acpi_ns_convert_to_buffer(union acpi_operand_object *original_object, | |||
294 | break; | 296 | break; |
295 | 297 | ||
296 | default: | 298 | default: |
299 | |||
297 | return (AE_AML_OPERAND_TYPE); | 300 | return (AE_AML_OPERAND_TYPE); |
298 | } | 301 | } |
299 | 302 | ||
diff --git a/drivers/acpi/acpica/nsdump.c b/drivers/acpi/acpica/nsdump.c index ce6e97326205..7418c77fde8c 100644 --- a/drivers/acpi/acpica/nsdump.c +++ b/drivers/acpi/acpica/nsdump.c | |||
@@ -244,10 +244,12 @@ acpi_ns_dump_one_object(acpi_handle obj_handle, | |||
244 | case ACPI_TYPE_BUFFER: | 244 | case ACPI_TYPE_BUFFER: |
245 | case ACPI_TYPE_STRING: | 245 | case ACPI_TYPE_STRING: |
246 | case ACPI_TYPE_METHOD: | 246 | case ACPI_TYPE_METHOD: |
247 | |||
247 | acpi_os_printf("<No attached object>"); | 248 | acpi_os_printf("<No attached object>"); |
248 | break; | 249 | break; |
249 | 250 | ||
250 | default: | 251 | default: |
252 | |||
251 | break; | 253 | break; |
252 | } | 254 | } |
253 | 255 | ||
@@ -433,6 +435,7 @@ acpi_ns_dump_one_object(acpi_handle obj_handle, | |||
433 | break; | 435 | break; |
434 | 436 | ||
435 | default: | 437 | default: |
438 | |||
436 | break; | 439 | break; |
437 | } | 440 | } |
438 | break; | 441 | break; |
@@ -567,32 +570,39 @@ acpi_ns_dump_one_object(acpi_handle obj_handle, | |||
567 | goto cleanup; | 570 | goto cleanup; |
568 | 571 | ||
569 | case ACPI_TYPE_BUFFER_FIELD: | 572 | case ACPI_TYPE_BUFFER_FIELD: |
573 | |||
570 | obj_desc = | 574 | obj_desc = |
571 | (union acpi_operand_object *)obj_desc->buffer_field. | 575 | (union acpi_operand_object *)obj_desc->buffer_field. |
572 | buffer_obj; | 576 | buffer_obj; |
573 | break; | 577 | break; |
574 | 578 | ||
575 | case ACPI_TYPE_PACKAGE: | 579 | case ACPI_TYPE_PACKAGE: |
580 | |||
576 | obj_desc = (void *)obj_desc->package.elements; | 581 | obj_desc = (void *)obj_desc->package.elements; |
577 | break; | 582 | break; |
578 | 583 | ||
579 | case ACPI_TYPE_METHOD: | 584 | case ACPI_TYPE_METHOD: |
585 | |||
580 | obj_desc = (void *)obj_desc->method.aml_start; | 586 | obj_desc = (void *)obj_desc->method.aml_start; |
581 | break; | 587 | break; |
582 | 588 | ||
583 | case ACPI_TYPE_LOCAL_REGION_FIELD: | 589 | case ACPI_TYPE_LOCAL_REGION_FIELD: |
590 | |||
584 | obj_desc = (void *)obj_desc->field.region_obj; | 591 | obj_desc = (void *)obj_desc->field.region_obj; |
585 | break; | 592 | break; |
586 | 593 | ||
587 | case ACPI_TYPE_LOCAL_BANK_FIELD: | 594 | case ACPI_TYPE_LOCAL_BANK_FIELD: |
595 | |||
588 | obj_desc = (void *)obj_desc->bank_field.region_obj; | 596 | obj_desc = (void *)obj_desc->bank_field.region_obj; |
589 | break; | 597 | break; |
590 | 598 | ||
591 | case ACPI_TYPE_LOCAL_INDEX_FIELD: | 599 | case ACPI_TYPE_LOCAL_INDEX_FIELD: |
600 | |||
592 | obj_desc = (void *)obj_desc->index_field.index_obj; | 601 | obj_desc = (void *)obj_desc->index_field.index_obj; |
593 | break; | 602 | break; |
594 | 603 | ||
595 | default: | 604 | default: |
605 | |||
596 | goto cleanup; | 606 | goto cleanup; |
597 | } | 607 | } |
598 | 608 | ||
diff --git a/drivers/acpi/acpica/nsinit.c b/drivers/acpi/acpica/nsinit.c index 23e426f7fd1a..dd2ceae3f717 100644 --- a/drivers/acpi/acpica/nsinit.c +++ b/drivers/acpi/acpica/nsinit.c | |||
@@ -266,28 +266,34 @@ acpi_ns_init_one_object(acpi_handle obj_handle, | |||
266 | 266 | ||
267 | switch (type) { | 267 | switch (type) { |
268 | case ACPI_TYPE_REGION: | 268 | case ACPI_TYPE_REGION: |
269 | |||
269 | info->op_region_count++; | 270 | info->op_region_count++; |
270 | break; | 271 | break; |
271 | 272 | ||
272 | case ACPI_TYPE_BUFFER_FIELD: | 273 | case ACPI_TYPE_BUFFER_FIELD: |
274 | |||
273 | info->field_count++; | 275 | info->field_count++; |
274 | break; | 276 | break; |
275 | 277 | ||
276 | case ACPI_TYPE_LOCAL_BANK_FIELD: | 278 | case ACPI_TYPE_LOCAL_BANK_FIELD: |
279 | |||
277 | info->field_count++; | 280 | info->field_count++; |
278 | break; | 281 | break; |
279 | 282 | ||
280 | case ACPI_TYPE_BUFFER: | 283 | case ACPI_TYPE_BUFFER: |
284 | |||
281 | info->buffer_count++; | 285 | info->buffer_count++; |
282 | break; | 286 | break; |
283 | 287 | ||
284 | case ACPI_TYPE_PACKAGE: | 288 | case ACPI_TYPE_PACKAGE: |
289 | |||
285 | info->package_count++; | 290 | info->package_count++; |
286 | break; | 291 | break; |
287 | 292 | ||
288 | default: | 293 | default: |
289 | 294 | ||
290 | /* No init required, just exit now */ | 295 | /* No init required, just exit now */ |
296 | |||
291 | return (AE_OK); | 297 | return (AE_OK); |
292 | } | 298 | } |
293 | 299 | ||
@@ -337,7 +343,9 @@ acpi_ns_init_one_object(acpi_handle obj_handle, | |||
337 | break; | 343 | break; |
338 | 344 | ||
339 | default: | 345 | default: |
346 | |||
340 | /* No other types can get here */ | 347 | /* No other types can get here */ |
348 | |||
341 | break; | 349 | break; |
342 | } | 350 | } |
343 | 351 | ||
@@ -416,6 +424,7 @@ acpi_ns_find_ini_methods(acpi_handle obj_handle, | |||
416 | break; | 424 | break; |
417 | 425 | ||
418 | default: | 426 | default: |
427 | |||
419 | break; | 428 | break; |
420 | } | 429 | } |
421 | 430 | ||
diff --git a/drivers/acpi/acpica/nspredef.c b/drivers/acpi/acpica/nspredef.c index 5c83a8b1c157..600268d33aa8 100644 --- a/drivers/acpi/acpica/nspredef.c +++ b/drivers/acpi/acpica/nspredef.c | |||
@@ -344,26 +344,32 @@ static u32 acpi_ns_get_bitmapped_type(union acpi_operand_object *return_object) | |||
344 | 344 | ||
345 | switch (return_object->common.type) { | 345 | switch (return_object->common.type) { |
346 | case ACPI_TYPE_INTEGER: | 346 | case ACPI_TYPE_INTEGER: |
347 | |||
347 | return_btype = ACPI_RTYPE_INTEGER; | 348 | return_btype = ACPI_RTYPE_INTEGER; |
348 | break; | 349 | break; |
349 | 350 | ||
350 | case ACPI_TYPE_BUFFER: | 351 | case ACPI_TYPE_BUFFER: |
352 | |||
351 | return_btype = ACPI_RTYPE_BUFFER; | 353 | return_btype = ACPI_RTYPE_BUFFER; |
352 | break; | 354 | break; |
353 | 355 | ||
354 | case ACPI_TYPE_STRING: | 356 | case ACPI_TYPE_STRING: |
357 | |||
355 | return_btype = ACPI_RTYPE_STRING; | 358 | return_btype = ACPI_RTYPE_STRING; |
356 | break; | 359 | break; |
357 | 360 | ||
358 | case ACPI_TYPE_PACKAGE: | 361 | case ACPI_TYPE_PACKAGE: |
362 | |||
359 | return_btype = ACPI_RTYPE_PACKAGE; | 363 | return_btype = ACPI_RTYPE_PACKAGE; |
360 | break; | 364 | break; |
361 | 365 | ||
362 | case ACPI_TYPE_LOCAL_REFERENCE: | 366 | case ACPI_TYPE_LOCAL_REFERENCE: |
367 | |||
363 | return_btype = ACPI_RTYPE_REFERENCE; | 368 | return_btype = ACPI_RTYPE_REFERENCE; |
364 | break; | 369 | break; |
365 | 370 | ||
366 | default: | 371 | default: |
372 | |||
367 | /* Not one of the supported objects, must be incorrect */ | 373 | /* Not one of the supported objects, must be incorrect */ |
368 | 374 | ||
369 | return_btype = ACPI_RTYPE_ANY; | 375 | return_btype = ACPI_RTYPE_ANY; |
diff --git a/drivers/acpi/acpica/nsprepkg.c b/drivers/acpi/acpica/nsprepkg.c index ab2a3f477e1e..6d55cef7916c 100644 --- a/drivers/acpi/acpica/nsprepkg.c +++ b/drivers/acpi/acpica/nsprepkg.c | |||
@@ -136,7 +136,6 @@ acpi_ns_check_package(struct acpi_evaluate_info *info, | |||
136 | */ | 136 | */ |
137 | switch (package->ret_info.type) { | 137 | switch (package->ret_info.type) { |
138 | case ACPI_PTYPE1_FIXED: | 138 | case ACPI_PTYPE1_FIXED: |
139 | |||
140 | /* | 139 | /* |
141 | * The package count is fixed and there are no sub-packages | 140 | * The package count is fixed and there are no sub-packages |
142 | * | 141 | * |
@@ -169,7 +168,6 @@ acpi_ns_check_package(struct acpi_evaluate_info *info, | |||
169 | break; | 168 | break; |
170 | 169 | ||
171 | case ACPI_PTYPE1_VAR: | 170 | case ACPI_PTYPE1_VAR: |
172 | |||
173 | /* | 171 | /* |
174 | * The package count is variable, there are no sub-packages, and all | 172 | * The package count is variable, there are no sub-packages, and all |
175 | * elements must be of the same type | 173 | * elements must be of the same type |
@@ -186,7 +184,6 @@ acpi_ns_check_package(struct acpi_evaluate_info *info, | |||
186 | break; | 184 | break; |
187 | 185 | ||
188 | case ACPI_PTYPE1_OPTION: | 186 | case ACPI_PTYPE1_OPTION: |
189 | |||
190 | /* | 187 | /* |
191 | * The package count is variable, there are no sub-packages. There are | 188 | * The package count is variable, there are no sub-packages. There are |
192 | * a fixed number of required elements, and a variable number of | 189 | * a fixed number of required elements, and a variable number of |
@@ -284,7 +281,6 @@ acpi_ns_check_package(struct acpi_evaluate_info *info, | |||
284 | case ACPI_PTYPE2_MIN: | 281 | case ACPI_PTYPE2_MIN: |
285 | case ACPI_PTYPE2_COUNT: | 282 | case ACPI_PTYPE2_COUNT: |
286 | case ACPI_PTYPE2_FIX_VAR: | 283 | case ACPI_PTYPE2_FIX_VAR: |
287 | |||
288 | /* | 284 | /* |
289 | * These types all return a single Package that consists of a | 285 | * These types all return a single Package that consists of a |
290 | * variable number of sub-Packages. | 286 | * variable number of sub-Packages. |
@@ -500,7 +496,6 @@ acpi_ns_check_package_list(struct acpi_evaluate_info *info, | |||
500 | break; | 496 | break; |
501 | 497 | ||
502 | case ACPI_PTYPE2_COUNT: | 498 | case ACPI_PTYPE2_COUNT: |
503 | |||
504 | /* | 499 | /* |
505 | * First element is the (Integer) count of elements, including | 500 | * First element is the (Integer) count of elements, including |
506 | * the count field (the ACPI name is num_elements) | 501 | * the count field (the ACPI name is num_elements) |
diff --git a/drivers/acpi/acpica/nsrepair.c b/drivers/acpi/acpica/nsrepair.c index 89caef04691e..f8e71ea60319 100644 --- a/drivers/acpi/acpica/nsrepair.c +++ b/drivers/acpi/acpica/nsrepair.c | |||
@@ -480,6 +480,7 @@ acpi_ns_remove_null_elements(struct acpi_evaluate_info *info, | |||
480 | case ACPI_PTYPE2_MIN: | 480 | case ACPI_PTYPE2_MIN: |
481 | case ACPI_PTYPE2_REV_FIXED: | 481 | case ACPI_PTYPE2_REV_FIXED: |
482 | case ACPI_PTYPE2_FIX_VAR: | 482 | case ACPI_PTYPE2_FIX_VAR: |
483 | |||
483 | break; | 484 | break; |
484 | 485 | ||
485 | default: | 486 | default: |
diff --git a/drivers/acpi/acpica/nsrepair2.c b/drivers/acpi/acpica/nsrepair2.c index 39acc4e6b387..daac8daeaa9f 100644 --- a/drivers/acpi/acpica/nsrepair2.c +++ b/drivers/acpi/acpica/nsrepair2.c | |||
@@ -320,6 +320,7 @@ acpi_ns_repair_FDE(struct acpi_evaluate_info *info, | |||
320 | break; | 320 | break; |
321 | 321 | ||
322 | default: | 322 | default: |
323 | |||
323 | return (AE_AML_OPERAND_TYPE); | 324 | return (AE_AML_OPERAND_TYPE); |
324 | } | 325 | } |
325 | 326 | ||
diff --git a/drivers/acpi/acpica/nsutils.c b/drivers/acpi/acpica/nsutils.c index 2808586fad30..08c0b5beec88 100644 --- a/drivers/acpi/acpica/nsutils.c +++ b/drivers/acpi/acpica/nsutils.c | |||
@@ -419,10 +419,12 @@ acpi_ns_externalize_name(u32 internal_name_length, | |||
419 | 419 | ||
420 | switch (internal_name[0]) { | 420 | switch (internal_name[0]) { |
421 | case AML_ROOT_PREFIX: | 421 | case AML_ROOT_PREFIX: |
422 | |||
422 | prefix_length = 1; | 423 | prefix_length = 1; |
423 | break; | 424 | break; |
424 | 425 | ||
425 | case AML_PARENT_PREFIX: | 426 | case AML_PARENT_PREFIX: |
427 | |||
426 | for (i = 0; i < internal_name_length; i++) { | 428 | for (i = 0; i < internal_name_length; i++) { |
427 | if (ACPI_IS_PARENT_PREFIX(internal_name[i])) { | 429 | if (ACPI_IS_PARENT_PREFIX(internal_name[i])) { |
428 | prefix_length = i + 1; | 430 | prefix_length = i + 1; |
@@ -438,6 +440,7 @@ acpi_ns_externalize_name(u32 internal_name_length, | |||
438 | break; | 440 | break; |
439 | 441 | ||
440 | default: | 442 | default: |
443 | |||
441 | break; | 444 | break; |
442 | } | 445 | } |
443 | 446 | ||
diff --git a/drivers/acpi/acpica/nsxfeval.c b/drivers/acpi/acpica/nsxfeval.c index 82bec40d4508..f553cfdb71dd 100644 --- a/drivers/acpi/acpica/nsxfeval.c +++ b/drivers/acpi/acpica/nsxfeval.c | |||
@@ -511,6 +511,7 @@ static void acpi_ns_resolve_references(struct acpi_evaluate_info *info) | |||
511 | break; | 511 | break; |
512 | 512 | ||
513 | default: | 513 | default: |
514 | |||
514 | return; | 515 | return; |
515 | } | 516 | } |
516 | 517 | ||
diff --git a/drivers/acpi/acpica/psargs.c b/drivers/acpi/acpica/psargs.c index 9f25a3d4e992..91a5a69db80c 100644 --- a/drivers/acpi/acpica/psargs.c +++ b/drivers/acpi/acpica/psargs.c | |||
@@ -629,24 +629,28 @@ static union acpi_parse_object *acpi_ps_get_next_field(struct acpi_parse_state | |||
629 | 629 | ||
630 | switch (opcode) { | 630 | switch (opcode) { |
631 | case AML_BYTE_OP: /* AML_BYTEDATA_ARG */ | 631 | case AML_BYTE_OP: /* AML_BYTEDATA_ARG */ |
632 | |||
632 | buffer_length = | 633 | buffer_length = |
633 | ACPI_GET8(parser_state->aml); | 634 | ACPI_GET8(parser_state->aml); |
634 | parser_state->aml += 1; | 635 | parser_state->aml += 1; |
635 | break; | 636 | break; |
636 | 637 | ||
637 | case AML_WORD_OP: /* AML_WORDDATA_ARG */ | 638 | case AML_WORD_OP: /* AML_WORDDATA_ARG */ |
639 | |||
638 | buffer_length = | 640 | buffer_length = |
639 | ACPI_GET16(parser_state->aml); | 641 | ACPI_GET16(parser_state->aml); |
640 | parser_state->aml += 2; | 642 | parser_state->aml += 2; |
641 | break; | 643 | break; |
642 | 644 | ||
643 | case AML_DWORD_OP: /* AML_DWORDATA_ARG */ | 645 | case AML_DWORD_OP: /* AML_DWORDATA_ARG */ |
646 | |||
644 | buffer_length = | 647 | buffer_length = |
645 | ACPI_GET32(parser_state->aml); | 648 | ACPI_GET32(parser_state->aml); |
646 | parser_state->aml += 4; | 649 | parser_state->aml += 4; |
647 | break; | 650 | break; |
648 | 651 | ||
649 | default: | 652 | default: |
653 | |||
650 | buffer_length = 0; | 654 | buffer_length = 0; |
651 | break; | 655 | break; |
652 | } | 656 | } |
diff --git a/drivers/acpi/acpica/psloop.c b/drivers/acpi/acpica/psloop.c index 63c455447481..065b44ae538f 100644 --- a/drivers/acpi/acpica/psloop.c +++ b/drivers/acpi/acpica/psloop.c | |||
@@ -164,7 +164,6 @@ acpi_ps_get_arguments(struct acpi_walk_state *walk_state, | |||
164 | case AML_IF_OP: | 164 | case AML_IF_OP: |
165 | case AML_ELSE_OP: | 165 | case AML_ELSE_OP: |
166 | case AML_WHILE_OP: | 166 | case AML_WHILE_OP: |
167 | |||
168 | /* | 167 | /* |
169 | * Currently supported module-level opcodes are: | 168 | * Currently supported module-level opcodes are: |
170 | * IF/ELSE/WHILE. These appear to be the most common, | 169 | * IF/ELSE/WHILE. These appear to be the most common, |
@@ -289,6 +288,7 @@ acpi_ps_get_arguments(struct acpi_walk_state *walk_state, | |||
289 | default: | 288 | default: |
290 | 289 | ||
291 | /* No action for all other opcodes */ | 290 | /* No action for all other opcodes */ |
291 | |||
292 | break; | 292 | break; |
293 | } | 293 | } |
294 | 294 | ||
diff --git a/drivers/acpi/acpica/psobject.c b/drivers/acpi/acpica/psobject.c index 12c4028002b1..95dc608a66a8 100644 --- a/drivers/acpi/acpica/psobject.c +++ b/drivers/acpi/acpica/psobject.c | |||
@@ -402,6 +402,7 @@ acpi_ps_complete_op(struct acpi_walk_state *walk_state, | |||
402 | 402 | ||
403 | switch (status) { | 403 | switch (status) { |
404 | case AE_OK: | 404 | case AE_OK: |
405 | |||
405 | break; | 406 | break; |
406 | 407 | ||
407 | case AE_CTRL_TRANSFER: | 408 | case AE_CTRL_TRANSFER: |
diff --git a/drivers/acpi/acpica/psparse.c b/drivers/acpi/acpica/psparse.c index abc4c48b2edd..86198a9139b5 100644 --- a/drivers/acpi/acpica/psparse.c +++ b/drivers/acpi/acpica/psparse.c | |||
@@ -176,10 +176,10 @@ acpi_ps_complete_this_op(struct acpi_walk_state * walk_state, | |||
176 | 176 | ||
177 | switch (parent_info->class) { | 177 | switch (parent_info->class) { |
178 | case AML_CLASS_CONTROL: | 178 | case AML_CLASS_CONTROL: |
179 | |||
179 | break; | 180 | break; |
180 | 181 | ||
181 | case AML_CLASS_CREATE: | 182 | case AML_CLASS_CREATE: |
182 | |||
183 | /* | 183 | /* |
184 | * These opcodes contain term_arg operands. The current | 184 | * These opcodes contain term_arg operands. The current |
185 | * op must be replaced by a placeholder return op | 185 | * op must be replaced by a placeholder return op |
@@ -192,7 +192,6 @@ acpi_ps_complete_this_op(struct acpi_walk_state * walk_state, | |||
192 | break; | 192 | break; |
193 | 193 | ||
194 | case AML_CLASS_NAMED_OBJECT: | 194 | case AML_CLASS_NAMED_OBJECT: |
195 | |||
196 | /* | 195 | /* |
197 | * These opcodes contain term_arg operands. The current | 196 | * These opcodes contain term_arg operands. The current |
198 | * op must be replaced by a placeholder return op | 197 | * op must be replaced by a placeholder return op |
diff --git a/drivers/acpi/acpica/pstree.c b/drivers/acpi/acpica/pstree.c index c1934bf04f0a..877dc0de8df3 100644 --- a/drivers/acpi/acpica/pstree.c +++ b/drivers/acpi/acpica/pstree.c | |||
@@ -308,7 +308,9 @@ union acpi_parse_object *acpi_ps_get_child(union acpi_parse_object *op) | |||
308 | break; | 308 | break; |
309 | 309 | ||
310 | default: | 310 | default: |
311 | |||
311 | /* All others have no children */ | 312 | /* All others have no children */ |
313 | |||
312 | break; | 314 | break; |
313 | } | 315 | } |
314 | 316 | ||
diff --git a/drivers/acpi/acpica/rscalc.c b/drivers/acpi/acpica/rscalc.c index 72077fa1eea5..608ebb56b671 100644 --- a/drivers/acpi/acpica/rscalc.c +++ b/drivers/acpi/acpica/rscalc.c | |||
@@ -352,6 +352,7 @@ acpi_rs_get_aml_length(struct acpi_resource * resource, acpi_size * size_needed) | |||
352 | break; | 352 | break; |
353 | 353 | ||
354 | default: | 354 | default: |
355 | |||
355 | break; | 356 | break; |
356 | } | 357 | } |
357 | 358 | ||
@@ -539,6 +540,7 @@ acpi_rs_get_list_length(u8 * aml_buffer, | |||
539 | break; | 540 | break; |
540 | 541 | ||
541 | default: | 542 | default: |
543 | |||
542 | break; | 544 | break; |
543 | } | 545 | } |
544 | 546 | ||
diff --git a/drivers/acpi/acpica/rsdump.c b/drivers/acpi/acpica/rsdump.c index b5fc0db2e87b..8a2d4986b0aa 100644 --- a/drivers/acpi/acpica/rsdump.c +++ b/drivers/acpi/acpica/rsdump.c | |||
@@ -120,17 +120,20 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table) | |||
120 | /* Strings */ | 120 | /* Strings */ |
121 | 121 | ||
122 | case ACPI_RSD_LITERAL: | 122 | case ACPI_RSD_LITERAL: |
123 | |||
123 | acpi_rs_out_string(name, | 124 | acpi_rs_out_string(name, |
124 | ACPI_CAST_PTR(char, table->pointer)); | 125 | ACPI_CAST_PTR(char, table->pointer)); |
125 | break; | 126 | break; |
126 | 127 | ||
127 | case ACPI_RSD_STRING: | 128 | case ACPI_RSD_STRING: |
129 | |||
128 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, target)); | 130 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, target)); |
129 | break; | 131 | break; |
130 | 132 | ||
131 | /* Data items, 8/16/32/64 bit */ | 133 | /* Data items, 8/16/32/64 bit */ |
132 | 134 | ||
133 | case ACPI_RSD_UINT8: | 135 | case ACPI_RSD_UINT8: |
136 | |||
134 | if (table->pointer) { | 137 | if (table->pointer) { |
135 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, | 138 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, |
136 | table-> | 139 | table-> |
@@ -142,20 +145,24 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table) | |||
142 | break; | 145 | break; |
143 | 146 | ||
144 | case ACPI_RSD_UINT16: | 147 | case ACPI_RSD_UINT16: |
148 | |||
145 | acpi_rs_out_integer16(name, ACPI_GET16(target)); | 149 | acpi_rs_out_integer16(name, ACPI_GET16(target)); |
146 | break; | 150 | break; |
147 | 151 | ||
148 | case ACPI_RSD_UINT32: | 152 | case ACPI_RSD_UINT32: |
153 | |||
149 | acpi_rs_out_integer32(name, ACPI_GET32(target)); | 154 | acpi_rs_out_integer32(name, ACPI_GET32(target)); |
150 | break; | 155 | break; |
151 | 156 | ||
152 | case ACPI_RSD_UINT64: | 157 | case ACPI_RSD_UINT64: |
158 | |||
153 | acpi_rs_out_integer64(name, ACPI_GET64(target)); | 159 | acpi_rs_out_integer64(name, ACPI_GET64(target)); |
154 | break; | 160 | break; |
155 | 161 | ||
156 | /* Flags: 1-bit and 2-bit flags supported */ | 162 | /* Flags: 1-bit and 2-bit flags supported */ |
157 | 163 | ||
158 | case ACPI_RSD_1BITFLAG: | 164 | case ACPI_RSD_1BITFLAG: |
165 | |||
159 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, | 166 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, |
160 | table-> | 167 | table-> |
161 | pointer[*target & | 168 | pointer[*target & |
@@ -163,6 +170,7 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table) | |||
163 | break; | 170 | break; |
164 | 171 | ||
165 | case ACPI_RSD_2BITFLAG: | 172 | case ACPI_RSD_2BITFLAG: |
173 | |||
166 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, | 174 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, |
167 | table-> | 175 | table-> |
168 | pointer[*target & | 176 | pointer[*target & |
@@ -170,6 +178,7 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table) | |||
170 | break; | 178 | break; |
171 | 179 | ||
172 | case ACPI_RSD_3BITFLAG: | 180 | case ACPI_RSD_3BITFLAG: |
181 | |||
173 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, | 182 | acpi_rs_out_string(name, ACPI_CAST_PTR(char, |
174 | table-> | 183 | table-> |
175 | pointer[*target & | 184 | pointer[*target & |
@@ -258,6 +267,7 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table) | |||
258 | break; | 267 | break; |
259 | 268 | ||
260 | default: | 269 | default: |
270 | |||
261 | acpi_os_printf("**** Invalid table opcode [%X] ****\n", | 271 | acpi_os_printf("**** Invalid table opcode [%X] ****\n", |
262 | table->opcode); | 272 | table->opcode); |
263 | return; | 273 | return; |
diff --git a/drivers/acpi/acpica/rsmisc.c b/drivers/acpi/acpica/rsmisc.c index d5bf05a96096..80d12994e0d0 100644 --- a/drivers/acpi/acpica/rsmisc.c +++ b/drivers/acpi/acpica/rsmisc.c | |||
@@ -194,7 +194,6 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource, | |||
194 | break; | 194 | break; |
195 | 195 | ||
196 | case ACPI_RSC_COUNT_GPIO_RES: | 196 | case ACPI_RSC_COUNT_GPIO_RES: |
197 | |||
198 | /* | 197 | /* |
199 | * Vendor data is optional (length/offset may both be zero) | 198 | * Vendor data is optional (length/offset may both be zero) |
200 | * Examine vendor data length field first | 199 | * Examine vendor data length field first |
@@ -410,12 +409,14 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource, | |||
410 | */ | 409 | */ |
411 | switch (info->resource_offset) { | 410 | switch (info->resource_offset) { |
412 | case ACPI_RSC_COMPARE_AML_LENGTH: | 411 | case ACPI_RSC_COMPARE_AML_LENGTH: |
412 | |||
413 | if (aml_resource_length != info->value) { | 413 | if (aml_resource_length != info->value) { |
414 | goto exit; | 414 | goto exit; |
415 | } | 415 | } |
416 | break; | 416 | break; |
417 | 417 | ||
418 | case ACPI_RSC_COMPARE_VALUE: | 418 | case ACPI_RSC_COMPARE_VALUE: |
419 | |||
419 | if (ACPI_GET8(source) != info->value) { | 420 | if (ACPI_GET8(source) != info->value) { |
420 | goto exit; | 421 | goto exit; |
421 | } | 422 | } |
diff --git a/drivers/acpi/acpica/rsutils.c b/drivers/acpi/acpica/rsutils.c index 59bdf37164ba..480b6b40c5ea 100644 --- a/drivers/acpi/acpica/rsutils.c +++ b/drivers/acpi/acpica/rsutils.c | |||
@@ -147,6 +147,7 @@ acpi_rs_move_data(void *destination, void *source, u16 item_count, u8 move_type) | |||
147 | case ACPI_RSC_MOVE_GPIO_RES: | 147 | case ACPI_RSC_MOVE_GPIO_RES: |
148 | case ACPI_RSC_MOVE_SERIAL_VEN: | 148 | case ACPI_RSC_MOVE_SERIAL_VEN: |
149 | case ACPI_RSC_MOVE_SERIAL_RES: | 149 | case ACPI_RSC_MOVE_SERIAL_RES: |
150 | |||
150 | ACPI_MEMCPY(destination, source, item_count); | 151 | ACPI_MEMCPY(destination, source, item_count); |
151 | return; | 152 | return; |
152 | 153 | ||
@@ -157,21 +158,25 @@ acpi_rs_move_data(void *destination, void *source, u16 item_count, u8 move_type) | |||
157 | */ | 158 | */ |
158 | case ACPI_RSC_MOVE16: | 159 | case ACPI_RSC_MOVE16: |
159 | case ACPI_RSC_MOVE_GPIO_PIN: | 160 | case ACPI_RSC_MOVE_GPIO_PIN: |
161 | |||
160 | ACPI_MOVE_16_TO_16(&ACPI_CAST_PTR(u16, destination)[i], | 162 | ACPI_MOVE_16_TO_16(&ACPI_CAST_PTR(u16, destination)[i], |
161 | &ACPI_CAST_PTR(u16, source)[i]); | 163 | &ACPI_CAST_PTR(u16, source)[i]); |
162 | break; | 164 | break; |
163 | 165 | ||
164 | case ACPI_RSC_MOVE32: | 166 | case ACPI_RSC_MOVE32: |
167 | |||
165 | ACPI_MOVE_32_TO_32(&ACPI_CAST_PTR(u32, destination)[i], | 168 | ACPI_MOVE_32_TO_32(&ACPI_CAST_PTR(u32, destination)[i], |
166 | &ACPI_CAST_PTR(u32, source)[i]); | 169 | &ACPI_CAST_PTR(u32, source)[i]); |
167 | break; | 170 | break; |
168 | 171 | ||
169 | case ACPI_RSC_MOVE64: | 172 | case ACPI_RSC_MOVE64: |
173 | |||
170 | ACPI_MOVE_64_TO_64(&ACPI_CAST_PTR(u64, destination)[i], | 174 | ACPI_MOVE_64_TO_64(&ACPI_CAST_PTR(u64, destination)[i], |
171 | &ACPI_CAST_PTR(u64, source)[i]); | 175 | &ACPI_CAST_PTR(u64, source)[i]); |
172 | break; | 176 | break; |
173 | 177 | ||
174 | default: | 178 | default: |
179 | |||
175 | return; | 180 | return; |
176 | } | 181 | } |
177 | } | 182 | } |
diff --git a/drivers/acpi/acpica/rsxface.c b/drivers/acpi/acpica/rsxface.c index c0e5d2d3ce67..94e3517554f9 100644 --- a/drivers/acpi/acpica/rsxface.c +++ b/drivers/acpi/acpica/rsxface.c | |||
@@ -402,6 +402,7 @@ acpi_resource_to_address64(struct acpi_resource *resource, | |||
402 | break; | 402 | break; |
403 | 403 | ||
404 | default: | 404 | default: |
405 | |||
405 | return (AE_BAD_PARAMETER); | 406 | return (AE_BAD_PARAMETER); |
406 | } | 407 | } |
407 | 408 | ||
diff --git a/drivers/acpi/acpica/tbinstal.c b/drivers/acpi/acpica/tbinstal.c index e57cd38004e3..a04e54d984d9 100644 --- a/drivers/acpi/acpica/tbinstal.c +++ b/drivers/acpi/acpica/tbinstal.c | |||
@@ -471,15 +471,19 @@ void acpi_tb_delete_table(struct acpi_table_desc *table_desc) | |||
471 | } | 471 | } |
472 | switch (table_desc->flags & ACPI_TABLE_ORIGIN_MASK) { | 472 | switch (table_desc->flags & ACPI_TABLE_ORIGIN_MASK) { |
473 | case ACPI_TABLE_ORIGIN_MAPPED: | 473 | case ACPI_TABLE_ORIGIN_MAPPED: |
474 | |||
474 | acpi_os_unmap_memory(table_desc->pointer, table_desc->length); | 475 | acpi_os_unmap_memory(table_desc->pointer, table_desc->length); |
475 | break; | 476 | break; |
477 | |||
476 | case ACPI_TABLE_ORIGIN_ALLOCATED: | 478 | case ACPI_TABLE_ORIGIN_ALLOCATED: |
479 | |||
477 | ACPI_FREE(table_desc->pointer); | 480 | ACPI_FREE(table_desc->pointer); |
478 | break; | 481 | break; |
479 | 482 | ||
480 | /* Not mapped or allocated, there is nothing we can do */ | 483 | /* Not mapped or allocated, there is nothing we can do */ |
481 | 484 | ||
482 | default: | 485 | default: |
486 | |||
483 | return; | 487 | return; |
484 | } | 488 | } |
485 | 489 | ||
diff --git a/drivers/acpi/acpica/utcopy.c b/drivers/acpi/acpica/utcopy.c index e4c9291fc0a3..1731c27c36a6 100644 --- a/drivers/acpi/acpica/utcopy.c +++ b/drivers/acpi/acpica/utcopy.c | |||
@@ -178,7 +178,6 @@ acpi_ut_copy_isimple_to_esimple(union acpi_operand_object *internal_object, | |||
178 | 178 | ||
179 | switch (internal_object->reference.class) { | 179 | switch (internal_object->reference.class) { |
180 | case ACPI_REFCLASS_NAME: | 180 | case ACPI_REFCLASS_NAME: |
181 | |||
182 | /* | 181 | /* |
183 | * For namepath, return the object handle ("reference") | 182 | * For namepath, return the object handle ("reference") |
184 | * We are referring to the namespace node | 183 | * We are referring to the namespace node |
@@ -264,7 +263,6 @@ acpi_ut_copy_ielement_to_eelement(u8 object_type, | |||
264 | 263 | ||
265 | switch (object_type) { | 264 | switch (object_type) { |
266 | case ACPI_COPY_TYPE_SIMPLE: | 265 | case ACPI_COPY_TYPE_SIMPLE: |
267 | |||
268 | /* | 266 | /* |
269 | * This is a simple or null object | 267 | * This is a simple or null object |
270 | */ | 268 | */ |
@@ -278,7 +276,6 @@ acpi_ut_copy_ielement_to_eelement(u8 object_type, | |||
278 | break; | 276 | break; |
279 | 277 | ||
280 | case ACPI_COPY_TYPE_PACKAGE: | 278 | case ACPI_COPY_TYPE_PACKAGE: |
281 | |||
282 | /* | 279 | /* |
283 | * Build the package object | 280 | * Build the package object |
284 | */ | 281 | */ |
@@ -304,6 +301,7 @@ acpi_ut_copy_ielement_to_eelement(u8 object_type, | |||
304 | break; | 301 | break; |
305 | 302 | ||
306 | default: | 303 | default: |
304 | |||
307 | return (AE_BAD_PARAMETER); | 305 | return (AE_BAD_PARAMETER); |
308 | } | 306 | } |
309 | 307 | ||
@@ -481,6 +479,7 @@ acpi_ut_copy_esimple_to_isimple(union acpi_object *external_object, | |||
481 | return_ACPI_STATUS(AE_OK); | 479 | return_ACPI_STATUS(AE_OK); |
482 | 480 | ||
483 | default: | 481 | default: |
482 | |||
484 | /* All other types are not supported */ | 483 | /* All other types are not supported */ |
485 | 484 | ||
486 | ACPI_ERROR((AE_INFO, | 485 | ACPI_ERROR((AE_INFO, |
@@ -544,7 +543,9 @@ acpi_ut_copy_esimple_to_isimple(union acpi_object *external_object, | |||
544 | break; | 543 | break; |
545 | 544 | ||
546 | default: | 545 | default: |
546 | |||
547 | /* Other types can't get here */ | 547 | /* Other types can't get here */ |
548 | |||
548 | break; | 549 | break; |
549 | } | 550 | } |
550 | 551 | ||
@@ -800,7 +801,9 @@ acpi_ut_copy_simple_object(union acpi_operand_object *source_desc, | |||
800 | break; | 801 | break; |
801 | 802 | ||
802 | default: | 803 | default: |
804 | |||
803 | /* Nothing to do for other simple objects */ | 805 | /* Nothing to do for other simple objects */ |
806 | |||
804 | break; | 807 | break; |
805 | } | 808 | } |
806 | 809 | ||
@@ -868,7 +871,6 @@ acpi_ut_copy_ielement_to_ielement(u8 object_type, | |||
868 | break; | 871 | break; |
869 | 872 | ||
870 | case ACPI_COPY_TYPE_PACKAGE: | 873 | case ACPI_COPY_TYPE_PACKAGE: |
871 | |||
872 | /* | 874 | /* |
873 | * This object is a package - go down another nesting level | 875 | * This object is a package - go down another nesting level |
874 | * Create and build the package object | 876 | * Create and build the package object |
@@ -891,6 +893,7 @@ acpi_ut_copy_ielement_to_ielement(u8 object_type, | |||
891 | break; | 893 | break; |
892 | 894 | ||
893 | default: | 895 | default: |
896 | |||
894 | return (AE_BAD_PARAMETER); | 897 | return (AE_BAD_PARAMETER); |
895 | } | 898 | } |
896 | 899 | ||
diff --git a/drivers/acpi/acpica/utdelete.c b/drivers/acpi/acpica/utdelete.c index 29b930250b6f..d6b33f29d327 100644 --- a/drivers/acpi/acpica/utdelete.c +++ b/drivers/acpi/acpica/utdelete.c | |||
@@ -303,6 +303,7 @@ static void acpi_ut_delete_internal_obj(union acpi_operand_object *object) | |||
303 | break; | 303 | break; |
304 | 304 | ||
305 | default: | 305 | default: |
306 | |||
306 | break; | 307 | break; |
307 | } | 308 | } |
308 | 309 | ||
@@ -508,7 +509,6 @@ acpi_ut_update_object_reference(union acpi_operand_object *object, u16 action) | |||
508 | case ACPI_TYPE_PROCESSOR: | 509 | case ACPI_TYPE_PROCESSOR: |
509 | case ACPI_TYPE_POWER: | 510 | case ACPI_TYPE_POWER: |
510 | case ACPI_TYPE_THERMAL: | 511 | case ACPI_TYPE_THERMAL: |
511 | |||
512 | /* | 512 | /* |
513 | * Update the notify objects for these types (if present) | 513 | * Update the notify objects for these types (if present) |
514 | * Two lists, system and device notify handlers. | 514 | * Two lists, system and device notify handlers. |
@@ -623,6 +623,7 @@ acpi_ut_update_object_reference(union acpi_operand_object *object, u16 action) | |||
623 | 623 | ||
624 | case ACPI_TYPE_REGION: | 624 | case ACPI_TYPE_REGION: |
625 | default: | 625 | default: |
626 | |||
626 | break; /* No subobjects for all other types */ | 627 | break; /* No subobjects for all other types */ |
627 | } | 628 | } |
628 | 629 | ||
diff --git a/drivers/acpi/acpica/uteval.c b/drivers/acpi/acpica/uteval.c index 9d6802911c01..ee83adb97b1e 100644 --- a/drivers/acpi/acpica/uteval.c +++ b/drivers/acpi/acpica/uteval.c | |||
@@ -123,22 +123,27 @@ acpi_ut_evaluate_object(struct acpi_namespace_node *prefix_node, | |||
123 | 123 | ||
124 | switch ((info->return_object)->common.type) { | 124 | switch ((info->return_object)->common.type) { |
125 | case ACPI_TYPE_INTEGER: | 125 | case ACPI_TYPE_INTEGER: |
126 | |||
126 | return_btype = ACPI_BTYPE_INTEGER; | 127 | return_btype = ACPI_BTYPE_INTEGER; |
127 | break; | 128 | break; |
128 | 129 | ||
129 | case ACPI_TYPE_BUFFER: | 130 | case ACPI_TYPE_BUFFER: |
131 | |||
130 | return_btype = ACPI_BTYPE_BUFFER; | 132 | return_btype = ACPI_BTYPE_BUFFER; |
131 | break; | 133 | break; |
132 | 134 | ||
133 | case ACPI_TYPE_STRING: | 135 | case ACPI_TYPE_STRING: |
136 | |||
134 | return_btype = ACPI_BTYPE_STRING; | 137 | return_btype = ACPI_BTYPE_STRING; |
135 | break; | 138 | break; |
136 | 139 | ||
137 | case ACPI_TYPE_PACKAGE: | 140 | case ACPI_TYPE_PACKAGE: |
141 | |||
138 | return_btype = ACPI_BTYPE_PACKAGE; | 142 | return_btype = ACPI_BTYPE_PACKAGE; |
139 | break; | 143 | break; |
140 | 144 | ||
141 | default: | 145 | default: |
146 | |||
142 | return_btype = 0; | 147 | return_btype = 0; |
143 | break; | 148 | break; |
144 | } | 149 | } |
diff --git a/drivers/acpi/acpica/utexcep.c b/drivers/acpi/acpica/utexcep.c index b543a144941a..ff6d9e8aa842 100644 --- a/drivers/acpi/acpica/utexcep.c +++ b/drivers/acpi/acpica/utexcep.c | |||
@@ -146,6 +146,7 @@ const struct acpi_exception_info *acpi_ut_validate_exception(acpi_status status) | |||
146 | break; | 146 | break; |
147 | 147 | ||
148 | default: | 148 | default: |
149 | |||
149 | break; | 150 | break; |
150 | } | 151 | } |
151 | 152 | ||
diff --git a/drivers/acpi/acpica/utids.c b/drivers/acpi/acpica/utids.c index 43a170a74a61..fa69071db418 100644 --- a/drivers/acpi/acpica/utids.c +++ b/drivers/acpi/acpica/utids.c | |||
@@ -341,14 +341,17 @@ acpi_ut_execute_CID(struct acpi_namespace_node *device_node, | |||
341 | 341 | ||
342 | switch (cid_objects[i]->common.type) { | 342 | switch (cid_objects[i]->common.type) { |
343 | case ACPI_TYPE_INTEGER: | 343 | case ACPI_TYPE_INTEGER: |
344 | |||
344 | string_area_size += ACPI_EISAID_STRING_SIZE; | 345 | string_area_size += ACPI_EISAID_STRING_SIZE; |
345 | break; | 346 | break; |
346 | 347 | ||
347 | case ACPI_TYPE_STRING: | 348 | case ACPI_TYPE_STRING: |
349 | |||
348 | string_area_size += cid_objects[i]->string.length + 1; | 350 | string_area_size += cid_objects[i]->string.length + 1; |
349 | break; | 351 | break; |
350 | 352 | ||
351 | default: | 353 | default: |
354 | |||
352 | status = AE_TYPE; | 355 | status = AE_TYPE; |
353 | goto cleanup; | 356 | goto cleanup; |
354 | } | 357 | } |
diff --git a/drivers/acpi/acpica/utmisc.c b/drivers/acpi/acpica/utmisc.c index 785fdd07ae56..02f9101b65e4 100644 --- a/drivers/acpi/acpica/utmisc.c +++ b/drivers/acpi/acpica/utmisc.c | |||
@@ -382,10 +382,12 @@ acpi_ut_display_init_pathname(u8 type, | |||
382 | 382 | ||
383 | switch (type) { | 383 | switch (type) { |
384 | case ACPI_TYPE_METHOD: | 384 | case ACPI_TYPE_METHOD: |
385 | |||
385 | acpi_os_printf("Executing "); | 386 | acpi_os_printf("Executing "); |
386 | break; | 387 | break; |
387 | 388 | ||
388 | default: | 389 | default: |
390 | |||
389 | acpi_os_printf("Initializing "); | 391 | acpi_os_printf("Initializing "); |
390 | break; | 392 | break; |
391 | } | 393 | } |
diff --git a/drivers/acpi/acpica/utobject.c b/drivers/acpi/acpica/utobject.c index 1099f5c069f8..aa61f66ee861 100644 --- a/drivers/acpi/acpica/utobject.c +++ b/drivers/acpi/acpica/utobject.c | |||
@@ -129,6 +129,7 @@ union acpi_operand_object *acpi_ut_create_internal_object_dbg(const char | |||
129 | break; | 129 | break; |
130 | 130 | ||
131 | default: | 131 | default: |
132 | |||
132 | /* All others have no secondary object */ | 133 | /* All others have no secondary object */ |
133 | break; | 134 | break; |
134 | } | 135 | } |
@@ -353,6 +354,7 @@ u8 acpi_ut_valid_internal_object(void *object) | |||
353 | return (TRUE); | 354 | return (TRUE); |
354 | 355 | ||
355 | default: | 356 | default: |
357 | |||
356 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, | 358 | ACPI_DEBUG_PRINT((ACPI_DB_EXEC, |
357 | "%p is not not an ACPI operand obj [%s]\n", | 359 | "%p is not not an ACPI operand obj [%s]\n", |
358 | object, acpi_ut_get_descriptor_name(object))); | 360 | object, acpi_ut_get_descriptor_name(object))); |
@@ -509,7 +511,6 @@ acpi_ut_get_simple_object_size(union acpi_operand_object *internal_object, | |||
509 | 511 | ||
510 | switch (internal_object->reference.class) { | 512 | switch (internal_object->reference.class) { |
511 | case ACPI_REFCLASS_NAME: | 513 | case ACPI_REFCLASS_NAME: |
512 | |||
513 | /* | 514 | /* |
514 | * Get the actual length of the full pathname to this object. | 515 | * Get the actual length of the full pathname to this object. |
515 | * The reference will be converted to the pathname to the object | 516 | * The reference will be converted to the pathname to the object |
@@ -525,7 +526,6 @@ acpi_ut_get_simple_object_size(union acpi_operand_object *internal_object, | |||
525 | break; | 526 | break; |
526 | 527 | ||
527 | default: | 528 | default: |
528 | |||
529 | /* | 529 | /* |
530 | * No other reference opcodes are supported. | 530 | * No other reference opcodes are supported. |
531 | * Notably, Locals and Args are not supported, but this may be | 531 | * Notably, Locals and Args are not supported, but this may be |
@@ -585,7 +585,6 @@ acpi_ut_get_element_length(u8 object_type, | |||
585 | 585 | ||
586 | switch (object_type) { | 586 | switch (object_type) { |
587 | case ACPI_COPY_TYPE_SIMPLE: | 587 | case ACPI_COPY_TYPE_SIMPLE: |
588 | |||
589 | /* | 588 | /* |
590 | * Simple object - just get the size (Null object/entry is handled | 589 | * Simple object - just get the size (Null object/entry is handled |
591 | * here also) and sum it into the running package length | 590 | * here also) and sum it into the running package length |
diff --git a/drivers/acpi/acpica/utstring.c b/drivers/acpi/acpica/utstring.c index b3e36a81aa4d..31a06a17e29d 100644 --- a/drivers/acpi/acpica/utstring.c +++ b/drivers/acpi/acpica/utstring.c | |||
@@ -186,10 +186,13 @@ acpi_status acpi_ut_strtoul64(char *string, u32 base, u64 *ret_integer) | |||
186 | switch (base) { | 186 | switch (base) { |
187 | case ACPI_ANY_BASE: | 187 | case ACPI_ANY_BASE: |
188 | case 16: | 188 | case 16: |
189 | |||
189 | break; | 190 | break; |
190 | 191 | ||
191 | default: | 192 | default: |
193 | |||
192 | /* Invalid Base */ | 194 | /* Invalid Base */ |
195 | |||
193 | return_ACPI_STATUS(AE_BAD_PARAMETER); | 196 | return_ACPI_STATUS(AE_BAD_PARAMETER); |
194 | } | 197 | } |
195 | 198 | ||
@@ -355,36 +358,44 @@ void acpi_ut_print_string(char *string, u8 max_length) | |||
355 | 358 | ||
356 | switch (string[i]) { | 359 | switch (string[i]) { |
357 | case 0x07: | 360 | case 0x07: |
361 | |||
358 | acpi_os_printf("\\a"); /* BELL */ | 362 | acpi_os_printf("\\a"); /* BELL */ |
359 | break; | 363 | break; |
360 | 364 | ||
361 | case 0x08: | 365 | case 0x08: |
366 | |||
362 | acpi_os_printf("\\b"); /* BACKSPACE */ | 367 | acpi_os_printf("\\b"); /* BACKSPACE */ |
363 | break; | 368 | break; |
364 | 369 | ||
365 | case 0x0C: | 370 | case 0x0C: |
371 | |||
366 | acpi_os_printf("\\f"); /* FORMFEED */ | 372 | acpi_os_printf("\\f"); /* FORMFEED */ |
367 | break; | 373 | break; |
368 | 374 | ||
369 | case 0x0A: | 375 | case 0x0A: |
376 | |||
370 | acpi_os_printf("\\n"); /* LINEFEED */ | 377 | acpi_os_printf("\\n"); /* LINEFEED */ |
371 | break; | 378 | break; |
372 | 379 | ||
373 | case 0x0D: | 380 | case 0x0D: |
381 | |||
374 | acpi_os_printf("\\r"); /* CARRIAGE RETURN */ | 382 | acpi_os_printf("\\r"); /* CARRIAGE RETURN */ |
375 | break; | 383 | break; |
376 | 384 | ||
377 | case 0x09: | 385 | case 0x09: |
386 | |||
378 | acpi_os_printf("\\t"); /* HORIZONTAL TAB */ | 387 | acpi_os_printf("\\t"); /* HORIZONTAL TAB */ |
379 | break; | 388 | break; |
380 | 389 | ||
381 | case 0x0B: | 390 | case 0x0B: |
391 | |||
382 | acpi_os_printf("\\v"); /* VERTICAL TAB */ | 392 | acpi_os_printf("\\v"); /* VERTICAL TAB */ |
383 | break; | 393 | break; |
384 | 394 | ||
385 | case '\'': /* Single Quote */ | 395 | case '\'': /* Single Quote */ |
386 | case '\"': /* Double Quote */ | 396 | case '\"': /* Double Quote */ |
387 | case '\\': /* Backslash */ | 397 | case '\\': /* Backslash */ |
398 | |||
388 | acpi_os_printf("\\%c", (int)string[i]); | 399 | acpi_os_printf("\\%c", (int)string[i]); |
389 | break; | 400 | break; |
390 | 401 | ||
diff --git a/drivers/acpi/acpica/uttrack.c b/drivers/acpi/acpica/uttrack.c index 62774c7b76a8..160f13f4aab5 100644 --- a/drivers/acpi/acpica/uttrack.c +++ b/drivers/acpi/acpica/uttrack.c | |||
@@ -603,6 +603,7 @@ void acpi_ut_dump_allocations(u32 component, const char *module) | |||
603 | switch (ACPI_GET_DESCRIPTOR_TYPE | 603 | switch (ACPI_GET_DESCRIPTOR_TYPE |
604 | (descriptor)) { | 604 | (descriptor)) { |
605 | case ACPI_DESC_TYPE_OPERAND: | 605 | case ACPI_DESC_TYPE_OPERAND: |
606 | |||
606 | if (element->size == | 607 | if (element->size == |
607 | sizeof(union | 608 | sizeof(union |
608 | acpi_operand_object)) | 609 | acpi_operand_object)) |
@@ -613,6 +614,7 @@ void acpi_ut_dump_allocations(u32 component, const char *module) | |||
613 | break; | 614 | break; |
614 | 615 | ||
615 | case ACPI_DESC_TYPE_PARSER: | 616 | case ACPI_DESC_TYPE_PARSER: |
617 | |||
616 | if (element->size == | 618 | if (element->size == |
617 | sizeof(union | 619 | sizeof(union |
618 | acpi_parse_object)) { | 620 | acpi_parse_object)) { |
@@ -622,6 +624,7 @@ void acpi_ut_dump_allocations(u32 component, const char *module) | |||
622 | break; | 624 | break; |
623 | 625 | ||
624 | case ACPI_DESC_TYPE_NAMED: | 626 | case ACPI_DESC_TYPE_NAMED: |
627 | |||
625 | if (element->size == | 628 | if (element->size == |
626 | sizeof(struct | 629 | sizeof(struct |
627 | acpi_namespace_node)) | 630 | acpi_namespace_node)) |
@@ -632,6 +635,7 @@ void acpi_ut_dump_allocations(u32 component, const char *module) | |||
632 | break; | 635 | break; |
633 | 636 | ||
634 | default: | 637 | default: |
638 | |||
635 | break; | 639 | break; |
636 | } | 640 | } |
637 | 641 | ||
@@ -639,6 +643,7 @@ void acpi_ut_dump_allocations(u32 component, const char *module) | |||
639 | 643 | ||
640 | switch (descriptor_type) { | 644 | switch (descriptor_type) { |
641 | case ACPI_DESC_TYPE_OPERAND: | 645 | case ACPI_DESC_TYPE_OPERAND: |
646 | |||
642 | acpi_os_printf | 647 | acpi_os_printf |
643 | ("%12.12s RefCount 0x%04X\n", | 648 | ("%12.12s RefCount 0x%04X\n", |
644 | acpi_ut_get_type_name | 649 | acpi_ut_get_type_name |
@@ -649,6 +654,7 @@ void acpi_ut_dump_allocations(u32 component, const char *module) | |||
649 | break; | 654 | break; |
650 | 655 | ||
651 | case ACPI_DESC_TYPE_PARSER: | 656 | case ACPI_DESC_TYPE_PARSER: |
657 | |||
652 | acpi_os_printf | 658 | acpi_os_printf |
653 | ("AmlOpcode 0x%04hX\n", | 659 | ("AmlOpcode 0x%04hX\n", |
654 | descriptor->op.asl. | 660 | descriptor->op.asl. |
@@ -656,6 +662,7 @@ void acpi_ut_dump_allocations(u32 component, const char *module) | |||
656 | break; | 662 | break; |
657 | 663 | ||
658 | case ACPI_DESC_TYPE_NAMED: | 664 | case ACPI_DESC_TYPE_NAMED: |
665 | |||
659 | acpi_os_printf("%4.4s\n", | 666 | acpi_os_printf("%4.4s\n", |
660 | acpi_ut_get_node_name | 667 | acpi_ut_get_node_name |
661 | (&descriptor-> | 668 | (&descriptor-> |
@@ -663,6 +670,7 @@ void acpi_ut_dump_allocations(u32 component, const char *module) | |||
663 | break; | 670 | break; |
664 | 671 | ||
665 | default: | 672 | default: |
673 | |||
666 | acpi_os_printf("\n"); | 674 | acpi_os_printf("\n"); |
667 | break; | 675 | break; |
668 | } | 676 | } |