aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi/acpica/dsopcode.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/acpi/acpica/dsopcode.c')
-rw-r--r--drivers/acpi/acpica/dsopcode.c32
1 files changed, 3 insertions, 29 deletions
diff --git a/drivers/acpi/acpica/dsopcode.c b/drivers/acpi/acpica/dsopcode.c
index 0c3b4dd60e8a..b4c87b5053e6 100644
--- a/drivers/acpi/acpica/dsopcode.c
+++ b/drivers/acpi/acpica/dsopcode.c
@@ -397,30 +397,6 @@ acpi_status acpi_ds_get_region_arguments(union acpi_operand_object *obj_desc)
397 status = acpi_ds_execute_arguments(node, acpi_ns_get_parent_node(node), 397 status = acpi_ds_execute_arguments(node, acpi_ns_get_parent_node(node),
398 extra_desc->extra.aml_length, 398 extra_desc->extra.aml_length,
399 extra_desc->extra.aml_start); 399 extra_desc->extra.aml_start);
400 if (ACPI_FAILURE(status)) {
401 return_ACPI_STATUS(status);
402 }
403
404 /* Validate the region address/length via the host OS */
405
406 status = acpi_os_validate_address(obj_desc->region.space_id,
407 obj_desc->region.address,
408 (acpi_size) obj_desc->region.length,
409 acpi_ut_get_node_name(node));
410
411 if (ACPI_FAILURE(status)) {
412 /*
413 * Invalid address/length. We will emit an error message and mark
414 * the region as invalid, so that it will cause an additional error if
415 * it is ever used. Then return AE_OK.
416 */
417 ACPI_EXCEPTION((AE_INFO, status,
418 "During address validation of OpRegion [%4.4s]",
419 node->name.ascii));
420 obj_desc->common.flags |= AOPOBJ_INVALID;
421 status = AE_OK;
422 }
423
424 return_ACPI_STATUS(status); 400 return_ACPI_STATUS(status);
425} 401}
426 402
@@ -484,7 +460,7 @@ acpi_ds_init_buffer_field(u16 aml_opcode,
484 460
485 /* Host object must be a Buffer */ 461 /* Host object must be a Buffer */
486 462
487 if (ACPI_GET_OBJECT_TYPE(buffer_desc) != ACPI_TYPE_BUFFER) { 463 if (buffer_desc->common.type != ACPI_TYPE_BUFFER) {
488 ACPI_ERROR((AE_INFO, 464 ACPI_ERROR((AE_INFO,
489 "Target of Create Field is not a Buffer object - %s", 465 "Target of Create Field is not a Buffer object - %s",
490 acpi_ut_get_object_type_name(buffer_desc))); 466 acpi_ut_get_object_type_name(buffer_desc)));
@@ -1365,10 +1341,8 @@ acpi_ds_exec_end_control_op(struct acpi_walk_state * walk_state,
1365 if ((ACPI_GET_DESCRIPTOR_TYPE 1341 if ((ACPI_GET_DESCRIPTOR_TYPE
1366 (walk_state->results->results.obj_desc[0]) == 1342 (walk_state->results->results.obj_desc[0]) ==
1367 ACPI_DESC_TYPE_OPERAND) 1343 ACPI_DESC_TYPE_OPERAND)
1368 && 1344 && ((walk_state->results->results.obj_desc[0])->
1369 (ACPI_GET_OBJECT_TYPE 1345 common.type == ACPI_TYPE_LOCAL_REFERENCE)
1370 (walk_state->results->results.obj_desc[0]) ==
1371 ACPI_TYPE_LOCAL_REFERENCE)
1372 && ((walk_state->results->results.obj_desc[0])-> 1346 && ((walk_state->results->results.obj_desc[0])->
1373 reference.class != ACPI_REFCLASS_INDEX)) { 1347 reference.class != ACPI_REFCLASS_INDEX)) {
1374 status = 1348 status =