Lines Matching full:start

51 add_avail(uint64_t start, uint64_t end, uint64_t type)  in add_avail()  argument
58 segs[nr_seg - 1].end + 1 == start && in add_avail()
69 segs[nr_seg].start = start; in add_avail()
81 remove_avail(uint64_t start, uint64_t end, uint64_t type) in remove_avail() argument
90 if (s->end + 1 == start && in remove_avail()
101 s->start = end + 1; in remove_avail()
108 * (1) The new chunk is at the start of the free space, but didn't catch the above in remove_avail()
109 * folding for whatever reason (different type, start of space). In this case, in remove_avail()
111 * current end is set to <start, end, type> and the new end's start is set to end + 1. in remove_avail()
113 * additional items. We copy the current end to the new end, set the new end's start in remove_avail()
114 * to end + 1, the old end's end to start - 1 and the new item is <start, end, type> in remove_avail()
116 * and adjust the current end's end to start - 1 and set the new end to <start, end, type>. in remove_avail()
123 if (s->start == start) { in remove_avail()
128 /* chunk at start of old chunk -> (1) */ in remove_avail()
132 s->start = start; in remove_avail()
135 s[1].start = end + 1; in remove_avail()
143 s->end = start - 1; in remove_avail()
144 s[1].start = start; in remove_avail()
153 s->end = start - 1; in remove_avail()
154 s[1].start = start; in remove_avail()
157 s[2].start = end + 1; in remove_avail()
168 (uintmax_t)segs[i].start, in print_avail()
182 s = roundup(segs[i].start, align); in first_avail()
190 (uintmax_t)segs[i].start, in first_avail()
227 uint64_t start, end; in parse_line() local
235 start = strtoull(walker, &next, 16); in parse_line()
236 if (start == ULLONG_MAX || walker == next) in parse_line()
249 *startp = start; in parse_line()
283 uint64_t start, end; in populate_avail_from_iomem() local
307 str = parse_line(buf, &start, &end); in populate_avail_from_iomem()
314 add_avail(start, end, system_ram); in populate_avail_from_iomem()
316 add_avail(start, end, firmware_reserved); in populate_avail_from_iomem()
321 str = parse_line(buf, &start, &end); in populate_avail_from_iomem()
326 remove_avail(start, end, unknown); in populate_avail_from_iomem()
328 remove_avail(start, end, kv->type); in populate_avail_from_iomem()
352 * Return the amount of space available in the segment that @start@ lives in,
353 * from @start@ to the end of the segment.
356 space_avail(uint64_t start) in space_avail() argument
359 if (start >= segs[i].start && start <= segs[i].end) in space_avail()
360 return segs[i].end - start; in space_avail()