* Expand the heap with a memory area. */
| 87 | * Expand the heap with a memory area. |
| 88 | */ |
| 89 | static struct malloc_elem * |
| 90 | malloc_heap_add_memory(struct malloc_heap *heap, struct rte_memseg_list *msl, |
| 91 | void *start, size_t len, bool dirty) |
| 92 | { |
| 93 | struct malloc_elem *elem = start; |
| 94 | |
| 95 | malloc_elem_init(elem, heap, msl, len, elem, len, dirty); |
| 96 | |
| 97 | malloc_elem_insert(elem); |
| 98 | |
| 99 | elem = malloc_elem_join_adjacent_free(elem); |
| 100 | |
| 101 | malloc_elem_free_list_insert(elem); |
| 102 | |
| 103 | return elem; |
| 104 | } |
| 105 | |
| 106 | static int |
| 107 | malloc_add_seg(const struct rte_memseg_list *msl, |
no test coverage detected