Lines Matching defs:buddy
10 * to what its name may suggest, zbud is not a buddy allocator, but rather an
19 * single memory page called a "zbud page". The first buddy is "left
20 * justified" at the beginning of the zbud page, and the last buddy is "right
22 * buddy is freed, the freed buddy space, coalesced with whatever slack space
81 * @unbuddied: array of lists tracking zbud pages that only contain one buddy;
107 * @buddy: links the zbud page into the unbuddied/buddied lists in the pool
108 * @first_chunks: the size of the first buddy in chunks, 0 if free
109 * @last_chunks: the size of the last buddy in chunks, 0 if free
112 struct list_head buddy;
121 enum buddy {
141 INIT_LIST_HEAD(&zhdr->buddy);
152 * Encodes the handle of a particular buddy within a zbud page
155 static unsigned long encode_handle(struct zbud_header *zhdr, enum buddy bud)
251 enum buddy bud;
265 struct zbud_header, buddy);
266 list_del(&zhdr->buddy);
294 list_add(&zhdr->buddy, &pool->unbuddied[freechunks]);
297 list_add(&zhdr->buddy, &pool->buddied);
319 /* If first buddy, handle will be page aligned */
325 /* Remove from existing buddy list */
326 list_del(&zhdr->buddy);
335 list_add(&zhdr->buddy, &pool->unbuddied[freechunks]);