Lines Matching refs:nr_ranges
77 if (!mem_rngs || (mem_rngs->nr_ranges == mem_rngs->max_nr_ranges)) { in __add_mem_range()
83 mem_rngs->ranges[mem_rngs->nr_ranges].start = base; in __add_mem_range()
84 mem_rngs->ranges[mem_rngs->nr_ranges].end = base + size - 1; in __add_mem_range()
86 base, base + size - 1, mem_rngs->nr_ranges); in __add_mem_range()
87 mem_rngs->nr_ranges++; in __add_mem_range()
109 for (i = 1; i < mem_rngs->nr_ranges; i++) { in __merge_memory_ranges()
120 mem_rngs->nr_ranges = idx + 1; in __merge_memory_ranges()
150 sort(&(mem_rngs->ranges[0]), mem_rngs->nr_ranges, in sort_memory_ranges()
158 for (i = 0; i < mem_rngs->nr_ranges; i++) { in sort_memory_ranges()
176 unsigned int nr_ranges; in realloc_mem_ranges() local
180 nr_ranges = mem_rngs ? mem_rngs->nr_ranges : 0; in realloc_mem_ranges()
190 mem_rngs->nr_ranges = nr_ranges; in realloc_mem_ranges()
219 if (!mem_rngs || !(mem_rngs->nr_ranges)) in add_mem_range()
222 for (i = 0; i < mem_rngs->nr_ranges; i++) { in add_mem_range()