|
PatchworkOS
|
Copy. More...
Functions | |
| uint64_t | aml_copy_data_and_type (aml_object_t *src, aml_object_t *dest) |
| Copies the data and type from the source object to the destination object, completly overwriting it. | |
| uint64_t | aml_copy_object (aml_state_t *state, aml_object_t *src, aml_object_t *dest) |
| Copies the data from the source object to the destination object. | |
Copy.
| uint64_t aml_copy_data_and_type | ( | aml_object_t * | src, |
| aml_object_t * | dest | ||
| ) |
Copies the data and type from the source object to the destination object, completly overwriting it.
| src | Pointer to the source object to copy from. |
| dest | Pointer to the destination object to copy to, can be of type AML_UNINITIALIZED. |
0. On failure, ERR and errno is set. Definition at line 11 of file copy.c.
References AML_BUFFER, aml_buffer_set(), aml_copy_data_and_type(), AML_DATA_REF_OBJECTS, AML_INTEGER, aml_integer_set(), aml_object_clear(), AML_OBJECT_EXCEPTION_ON_USE, AML_OBJECT_NAMED, AML_OBJECT_REFERENCE, aml_object_reference_set(), AML_PACKAGE, aml_package_set(), AML_STRING, aml_string_set(), aml_type_to_string(), aml_object_t::buffer, aml_buffer_obj_t::content, aml_string_obj_t::content, EINVAL, aml_package_obj_t::elements, ERR, errno, aml_object_t::integer, aml_buffer_obj_t::length, aml_package_obj_t::length, LOG_ERR, NULL, aml_object_t::objectReference, aml_object_t::package, aml_object_t::string, aml_object_reference_obj_t::target, and aml_integer_obj_t::value.
Referenced by aml_convert(), aml_convert_result(), aml_convert_source(), aml_copy_data_and_type(), aml_copy_object(), and aml_store().
| uint64_t aml_copy_object | ( | aml_state_t * | state, |
| aml_object_t * | src, | ||
| aml_object_t * | dest | ||
| ) |
Copies the data from the source object to the destination object.
Follows the rules in table 19.8 section 19.3.5.8 for the "CopyObject" operator are applied.
It will initialize uninitialized objects as specified in section 19.3.5 table 19.5.
| state | Pointer to the current AML state. |
| src | Pointer to the source object to copy from. |
| dest | Pointer to the destination object to copy to, can be of type AML_UNINITIALIZED. |
0. On failure, ERR and errno is set. Definition at line 93 of file copy.c.
References AML_ARG, AML_BUFFER_FIELD, aml_buffer_field_store(), aml_convert_result(), aml_copy_data_and_type(), aml_copy_object(), AML_FIELD_UNIT, aml_field_unit_store(), AML_LOCAL, AML_OBJECT_NAMED, aml_object_new(), AML_OBJECT_REFERENCE, aml_type_to_string(), AML_UNINITIALIZED, aml_object_t::arg, aml_object_t::bufferField, EINVAL, ENOSYS, ERR, errno, aml_object_t::fieldUnit, aml_object_t::local, LOG_ERR, NULL, aml_object_t::objectReference, aml_object_reference_obj_t::target, aml_arg_obj_t::value, and aml_local_obj_t::value.
Referenced by aml_copy_object(), aml_def_copy_object_read(), aml_state_result_get(), and aml_store().