Changes in kernel/generic/src/cap/cap.c [e394c196:aafed15] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/cap/cap.c
re394c196 raafed15 93 93 94 94 static slab_cache_t *cap_cache; 95 static slab_cache_t *kobject_cache;96 95 97 96 static size_t caps_hash(const ht_link_t *item) … … 124 123 cap_cache = slab_cache_create("cap_t", sizeof(cap_t), 0, NULL, 125 124 NULL, 0); 126 kobject_cache = slab_cache_create("kobject_t", sizeof(kobject_t), 0,127 NULL, NULL, 0);128 125 } 129 126 … … 397 394 } 398 395 399 kobject_t *kobject_alloc(unsigned int flags)400 {401 return slab_alloc(kobject_cache, flags);402 }403 404 void kobject_free(kobject_t *kobj)405 {406 slab_free(kobject_cache, kobj);407 }408 409 396 /** Initialize kernel object 410 397 * … … 475 462 if (atomic_postdec(&kobj->refcnt) == 1) { 476 463 kobj->ops->destroy(kobj->raw); 477 kobject_free(kobj);464 free(kobj); 478 465 } 479 466 }
Note:
See TracChangeset
for help on using the changeset viewer.