aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/dispatcher/dsutils.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/acpi/dispatcher/dsutils.c')
-rw-r--r--drivers/acpi/dispatcher/dsutils.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/acpi/dispatcher/dsutils.c b/drivers/acpi/dispatcher/dsutils.c
index 36518b4a79c2..97d01dcdc972 100644
--- a/drivers/acpi/dispatcher/dsutils.c
+++ b/drivers/acpi/dispatcher/dsutils.c
@@ -700,10 +700,9 @@ acpi_ds_create_operands(struct acpi_walk_state *walk_state,
700 acpi_status status = AE_OK; 700 acpi_status status = AE_OK;
701 union acpi_parse_object *arg; 701 union acpi_parse_object *arg;
702 union acpi_parse_object *arguments[ACPI_OBJ_NUM_OPERANDS]; 702 union acpi_parse_object *arguments[ACPI_OBJ_NUM_OPERANDS];
703 u8 arg_count = 0; 703 u32 arg_count = 0;
704 u8 count = 0; 704 u32 index = walk_state->num_operands;
705 u8 index = walk_state->num_operands; 705 u32 i;
706 u8 i;
707 706
708 ACPI_FUNCTION_TRACE_PTR(ds_create_operands, first_arg); 707 ACPI_FUNCTION_TRACE_PTR(ds_create_operands, first_arg);
709 708
@@ -734,14 +733,13 @@ acpi_ds_create_operands(struct acpi_walk_state *walk_state,
734 733
735 /* Force the filling of the operand stack in inverse order */ 734 /* Force the filling of the operand stack in inverse order */
736 735
737 walk_state->operand_index = index; 736 walk_state->operand_index = (u8) index;
738 737
739 status = acpi_ds_create_operand(walk_state, arg, index); 738 status = acpi_ds_create_operand(walk_state, arg, index);
740 if (ACPI_FAILURE(status)) { 739 if (ACPI_FAILURE(status)) {
741 goto cleanup; 740 goto cleanup;
742 } 741 }
743 742
744 count++;
745 index--; 743 index--;
746 744
747 ACPI_DEBUG_PRINT((ACPI_DB_DISPATCH, 745 ACPI_DEBUG_PRINT((ACPI_DB_DISPATCH,