Changeset f3272e98 in mainline for kernel/generic/src/mm/slab.c
- Timestamp:
- 2006-10-22T17:42:49Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 2191541
- Parents:
- 78595d6
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/mm/slab.c
r78595d6 rf3272e98 138 138 /** Slab descriptor */ 139 139 typedef struct { 140 slab_cache_t *cache; /**< Pointer to parent cache*/141 link_t link; /* List of full/partial slabs*/142 void *start; /**< Start address of first available item*/143 count_t available; /**< Count of available items in this slab*/144 index_t nextavail; /**< The index of next available item*/140 slab_cache_t *cache; /**< Pointer to parent cache. */ 141 link_t link; /**< List of full/partial slabs. */ 142 void *start; /**< Start address of first available item. */ 143 count_t available; /**< Count of available items in this slab. */ 144 index_t nextavail; /**< The index of next available item. */ 145 145 }slab_t; 146 146 … … 290 290 spinlock_lock(&cache->slablock); 291 291 } else { 292 slab = list_get_instance(cache->partial_slabs.next, 293 slab_t, 294 link); 292 slab = list_get_instance(cache->partial_slabs.next, slab_t, link); 295 293 list_remove(&slab->link); 296 294 } … … 299 297 slab->available--; 300 298 301 if (! 299 if (!slab->available) 302 300 list_prepend(&slab->link, &cache->full_slabs); 303 301 else … … 900 898 slab_t *slab; 901 899 902 if (!obj) return; 900 if (!obj) 901 return; 903 902 904 903 slab = obj2slab(obj);
Note:
See TracChangeset
for help on using the changeset viewer.