Lines Matching refs:region
36 region_t region; in region_create() local
38 region = malloc(sizeof(struct region_struct)); in region_create()
39 if (!region) in region_create()
41 memset(region, 0, sizeof(struct region_struct)); in region_create()
42 region->min = min; in region_create()
43 region->max = max; in region_create()
44 return region; in region_create()
47 void region_free(region_t region) in region_free() argument
51 for (r = region->allocated; r; r = next) { in region_free()
55 memset(region, 0, sizeof(struct region_struct)); in region_free()
56 free(region); in region_free()
59 int region_allocate(region_t region, region_addr_t start, int n) in region_allocate() argument
65 if ((start < region->min) || (end > region->max)) in region_allocate()
77 for (r = region->allocated, prev=NULL; r; prev = r, r = r->next) { in region_allocate()
115 region->allocated = new_region; in region_allocate()
156 void region_print(region_t region, FILE *f) in region_print() argument
161 fprintf(f, "Printing region (min=%d. max=%d)\n\t", region->min, in region_print()
162 region->max); in region_print()
163 for (r = region->allocated; r; r = r->next) { in region_print()