union acpi_operand_object *acpi_ut_create_internal_object_dbg(char *module_name, u32 line_number, u32 component_id, acpi_object_type type) { union acpi_operand_object *object; union acpi_operand_object *second_object; ACPI_FUNCTION_TRACE_STR("ut_create_internal_object_dbg", acpi_ut_get_type_name(type)); /* Allocate the raw object descriptor */ object = acpi_ut_allocate_object_desc_dbg(module_name, line_number, component_id); if (!object) { return_PTR(NULL); } switch (type) { case ACPI_TYPE_REGION: case ACPI_TYPE_BUFFER_FIELD: /* These types require a secondary object */ second_object = acpi_ut_allocate_object_desc_dbg(module_name, line_number, component_id); if (!second_object) { acpi_ut_delete_object_desc(object); return_PTR(NULL); } second_object->common.type = ACPI_TYPE_LOCAL_EXTRA; second_object->common.reference_count = 1; /* Link the second object to the first */ object->common.next_object = second_object; break; default: /* All others have no secondary object */ break; } /* Save the object type in the object descriptor */ object->common.type = (u8) type; /* Init the reference count */ object->common.reference_count = 1; /* Any per-type initialization should go here */ return_PTR(object); }
acpi_operand_object * acpi_ut_create_internal_object_dbg ( NATIVE_CHAR *module_name, u32 line_number, u32 component_id, acpi_object_type8 type) { acpi_operand_object *object; FUNCTION_TRACE_STR ("Ut_create_internal_object_dbg", acpi_ut_get_type_name (type)); /* Allocate the raw object descriptor */ object = acpi_ut_allocate_object_desc_dbg (module_name, line_number, component_id); if (!object) { /* Allocation failure */ return_PTR (NULL); } /* Save the object type in the object descriptor */ object->common.type = type; /* Init the reference count */ object->common.reference_count = 1; /* Any per-type initialization should go here */ return_PTR (object); }
union acpi_operand_object *acpi_ut_create_internal_object_dbg(const char *module_name, u32 line_number, u32 component_id, acpi_object_type type) { union acpi_operand_object *object; union acpi_operand_object *second_object; ACPI_FUNCTION_TRACE_STR(ut_create_internal_object_dbg, acpi_ut_get_type_name(type)); object = acpi_ut_allocate_object_desc_dbg(module_name, line_number, component_id); if (!object) { return_PTR(NULL); } switch (type) { case ACPI_TYPE_REGION: case ACPI_TYPE_BUFFER_FIELD: case ACPI_TYPE_LOCAL_BANK_FIELD: second_object = acpi_ut_allocate_object_desc_dbg(module_name, line_number, component_id); if (!second_object) { acpi_ut_delete_object_desc(object); return_PTR(NULL); } second_object->common.type = ACPI_TYPE_LOCAL_EXTRA; second_object->common.reference_count = 1; object->common.next_object = second_object; break; default: break; } object->common.type = (u8) type; object->common.reference_count = 1; return_PTR(object); }