• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-WNDR4500v2-V1.0.0.60_1.0.38/src/linux/linux-2.6/drivers/acpi/utilities/

Lines Matching defs:object

3  * Module Name: utobject - ACPI object create/delete/size/cache routines
72 * Type - ACPI Type of the new object
74 * RETURN: A new internal object, null on failure
76 * DESCRIPTION: Create and initialize a new internal object.
78 * NOTE: We always allocate the worst-case object descriptor because
81 * the most memory efficient, but the efficiency of the object
92 union acpi_operand_object *object;
98 /* Allocate the raw object descriptor */
100 object =
103 if (!object) {
111 /* These types require a secondary object */
117 acpi_ut_delete_object_desc(object);
124 /* Link the second object to the first */
126 object->common.next_object = second_object;
130 /* All others have no secondary object */
134 /* Save the object type in the object descriptor */
136 object->common.type = (u8) type;
140 object->common.reference_count = 1;
144 return_PTR(object);
153 * RETURN: Pointer to a new Package object, null on failure
155 * DESCRIPTION: Create a fully initialized package object
166 /* Create a new Package object */
195 * RETURN: Pointer to a new Buffer object, null on failure
197 * DESCRIPTION: Create a fully initialized buffer object
208 /* Create a new Buffer object */
230 /* Complete buffer object initialization */
249 * RETURN: Pointer to a new String object
251 * DESCRIPTION: Create a fully initialized string object
262 /* Create a new String object */
281 /* Complete string object initialization */
297 * RETURN: TRUE if object is valid, FALSE otherwise
303 u8 acpi_ut_valid_internal_object(void *object)
310 if (!object) {
317 switch (ACPI_GET_DESCRIPTOR_TYPE(object)) {
320 /* The object appears to be a valid union acpi_operand_object */
327 object, acpi_ut_get_descriptor_name(object)));
342 * RETURN: Pointer to newly allocated object descriptor. Null on error
344 * DESCRIPTION: Allocate a new object descriptor. Gracefully handle
352 union acpi_operand_object *object;
356 object = acpi_os_acquire_object(acpi_gbl_operand_cache);
357 if (!object) {
359 "Could not allocate an object descriptor"));
366 memset(object, 0, sizeof(union acpi_operand_object));
367 ACPI_SET_DESCRIPTOR_TYPE(object, ACPI_DESC_TYPE_OPERAND);
370 object, (u32) sizeof(union acpi_operand_object)));
372 return_PTR(object);
379 * PARAMETERS: Object - An Acpi internal object to be deleted
383 * DESCRIPTION: Free an ACPI object descriptor or add it to the object cache
387 void acpi_ut_delete_object_desc(union acpi_operand_object *object)
389 ACPI_FUNCTION_TRACE_PTR(ut_delete_object_desc, object);
393 if (ACPI_GET_DESCRIPTOR_TYPE(object) != ACPI_DESC_TYPE_OPERAND) {
395 "%p is not an ACPI Operand object [%s]", object,
396 acpi_ut_get_descriptor_name(object)));
400 (void)acpi_os_release_object(acpi_gbl_operand_cache, object);
408 * PARAMETERS: internal_object - An ACPI operand object
414 * contain a simple object for return to an external user.
416 * The length includes the object structure plus any additional
431 * Handle a null object (Could be a uninitialized package
439 /* Start with the length of the Acpi object */
445 /* Object is a named object (reference), just return the length */
452 * The final length depends on the object type
453 * Strings and Buffers are packed right up against the parent object and
483 * Get the actual length of the full pathname to this object.
484 * The reference will be converted to the pathname to the object
500 "Unsupported Reference opcode=%X in object %p",
510 ACPI_ERROR((AE_INFO, "Unsupported type=%X in object %p",
518 * Account for the space required by the object rounded up to the next
519 * multiple of the machine word size. This keeps each object aligned
552 * Simple object - just get the size (Null object/entry is handled
567 /* Package object - nothing much to do here, let the walk handle it */
587 * PARAMETERS: internal_object - An ACPI internal object
593 * contain a package object for return to an external user.
637 * PARAMETERS: internal_object - An ACPI internal object
643 * contain an object for return to an API user.