Lines Matching refs:elt
87 slab_free_orphaned(struct slab_element_header *elt)
91 assert(elt->owner & 1);
93 page = (struct slab_page_header *)(elt->owner & ~(intptr_t)1);
152 struct slab_element_header *elt = slab_get_element(pool->parent, page, i);
153 p_atomic_set(&elt->owner, (intptr_t)page | 1);
158 struct slab_element_header *elt = pool->migrated;
159 pool->migrated = elt->next;
160 slab_free_orphaned(elt);
166 struct slab_element_header *elt = pool->free;
167 pool->free = elt->next;
168 slab_free_orphaned(elt);
185 struct slab_element_header *elt = slab_get_element(pool->parent, page, i);
186 elt->owner = (intptr_t)pool;
187 assert(!(elt->owner & 1));
189 elt->next = pool->free;
190 pool->free = elt;
191 SET_MAGIC(elt, SLAB_MAGIC_FREE);
208 struct slab_element_header *elt;
224 elt = pool->free;
225 pool->free = elt->next;
227 CHECK_MAGIC(elt, SLAB_MAGIC_FREE);
228 SET_MAGIC(elt, SLAB_MAGIC_ALLOCATED);
230 return &elt[1];
244 struct slab_element_header *elt = ((struct slab_element_header*)ptr - 1);
247 CHECK_MAGIC(elt, SLAB_MAGIC_ALLOCATED);
248 SET_MAGIC(elt, SLAB_MAGIC_FREE);
250 if (p_atomic_read(&elt->owner) == (intptr_t)pool) {
254 elt->next = pool->free;
255 pool->free = elt;
263 /* Note: we _must_ re-read elt->owner here because the owning child pool
266 owner_int = p_atomic_read(&elt->owner);
270 elt->next = owner->migrated;
271 owner->migrated = elt;
278 slab_free_orphaned(elt);