Changeset f3272e98 in mainline for kernel/generic/include/mm/slab.h
- Timestamp:
- 2006-10-22T17:42:49Z (18 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/include/mm/slab.h
r78595d6 rf3272e98 69 69 count_t size; /**< Number of slots in magazine */ 70 70 void *objs[0]; /**< Slots in magazine */ 71 } slab_magazine_t;71 } slab_magazine_t; 72 72 73 73 typedef struct { … … 75 75 slab_magazine_t *last; 76 76 SPINLOCK_DECLARE(lock); 77 } slab_mag_cache_t;77 } slab_mag_cache_t; 78 78 79 79 … … 83 83 link_t link; 84 84 /* Configuration */ 85 size_t size; 85 size_t size; /**< Size of slab position - align_up(sizeof(obj)) */ 86 86 int (*constructor)(void *obj, int kmflag); 87 87 int (*destructor)(void *obj); 88 int flags; 88 int flags; /**< Flags changing behaviour of cache */ 89 89 90 90 /* Computed values */ 91 uint8_t order; 92 int objects; 91 uint8_t order; /**< Order of frames to be allocated */ 92 int objects; /**< Number of objects that fit in */ 93 93 94 94 /* Statistics */ … … 99 99 100 100 /* Slabs */ 101 link_t full_slabs; 102 link_t partial_slabs; 101 link_t full_slabs; /**< List of full slabs */ 102 link_t partial_slabs; /**< List of partial slabs */ 103 103 SPINLOCK_DECLARE(slablock); 104 104 /* Magazines */ 105 link_t magazines ;/**< List o full magazines */105 link_t magazines /**< List o full magazines */ 106 106 SPINLOCK_DECLARE(maglock); 107 107 108 108 /** CPU cache */ 109 109 slab_mag_cache_t *mag_cache; 110 } slab_cache_t;110 } slab_cache_t; 111 111 112 112 extern slab_cache_t * slab_cache_create(char *name,
Note:
See TracChangeset
for help on using the changeset viewer.