Lines Matching full:object

22  *              object_size     - Size of each cached object
24 * return_cache - Where the new cache object is returned
28 * DESCRIPTION: Create a cache object
44 /* Create the cache object */ in acpi_os_create_cache()
51 /* Populate the cache object and return it */ in acpi_os_create_cache()
66 * PARAMETERS: cache - Handle to cache object
94 /* Delete and unlink one cached state object */ in acpi_os_purge_cache()
111 * PARAMETERS: cache - Handle to cache object
116 * cache object.
133 /* Now we can delete the cache object */ in acpi_os_delete_cache()
143 * PARAMETERS: cache - Handle to cache object
144 * object - The object to be released
148 * DESCRIPTION: Release an object to the specified cache. If cache is full,
149 * the object is deleted.
153 acpi_status acpi_os_release_object(struct acpi_memory_list *cache, void *object) in acpi_os_release_object() argument
159 if (!cache || !object) { in acpi_os_release_object()
163 /* If cache is full, just free this object */ in acpi_os_release_object()
166 ACPI_FREE(object); in acpi_os_release_object()
170 /* Otherwise put this object back into the cache */ in acpi_os_release_object()
178 /* Mark the object as cached */ in acpi_os_release_object()
180 memset(object, 0xCA, cache->object_size); in acpi_os_release_object()
181 ACPI_SET_DESCRIPTOR_TYPE(object, ACPI_DESC_TYPE_CACHED); in acpi_os_release_object()
183 /* Put the object at the head of the cache list */ in acpi_os_release_object()
185 ACPI_SET_DESCRIPTOR_PTR(object, cache->list_head); in acpi_os_release_object()
186 cache->list_head = object; in acpi_os_release_object()
199 * PARAMETERS: cache - Handle to cache object
201 * RETURN: the acquired object. NULL on error
203 * DESCRIPTION: Get an object from the specified cache. If cache is empty,
204 * the object is allocated.
211 void *object; in acpi_os_acquire_object() local
230 /* There is an object available, use it */ in acpi_os_acquire_object()
232 object = cache->list_head; in acpi_os_acquire_object()
233 cache->list_head = ACPI_GET_DESCRIPTOR_PTR(object); in acpi_os_acquire_object()
239 "%s: Object %p from %s cache\n", in acpi_os_acquire_object()
240 ACPI_GET_FUNCTION_NAME, object, in acpi_os_acquire_object()
248 /* Clear (zero) the previously used Object */ in acpi_os_acquire_object()
250 memset(object, 0, cache->object_size); in acpi_os_acquire_object()
252 /* The cache is empty, create a new object */ in acpi_os_acquire_object()
271 object = ACPI_ALLOCATE_ZEROED(cache->object_size); in acpi_os_acquire_object()
272 if (!object) { in acpi_os_acquire_object()
277 return_PTR(object); in acpi_os_acquire_object()